17 lines
608 B
C#
17 lines
608 B
C#
namespace IronLicensing.Client;
|
|
|
|
/// <summary>
|
|
/// Verifies license signatures for offline validation
|
|
/// </summary>
|
|
public interface ISignatureVerifier
|
|
{
|
|
/// <summary>
|
|
/// Verifies that the data was signed with the corresponding private key
|
|
/// </summary>
|
|
/// <param name="publicKeyPem">The RSA public key in PEM format</param>
|
|
/// <param name="data">The original data that was signed</param>
|
|
/// <param name="signature">The base64-encoded signature</param>
|
|
/// <returns>True if signature is valid</returns>
|
|
bool Verify(string publicKeyPem, string data, string signature);
|
|
}
|