Created
February 26, 2015 11:30
-
-
Save HowardvanRooijen/ec023b8f774cc4a97868 to your computer and use it in GitHub Desktop.
LicenseValidator's Validate method
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void Validate(IClientLicense clientLicense, ICryptoKey publicKey, IEnumerable<ILicenseValidationRule> validationRules) | |
{ | |
if (!LicenseSignatureValidator.ValidateSignature(clientLicense, publicKey)) | |
{ | |
throw new InvalidLicenseException(clientLicense); | |
} | |
this.LicenseCriteria = this.licenseCriteriaParser.Parse(clientLicense); | |
validationRules.ForEachFailEnd(x => x.Validate(this.LicenseCriteria)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment