public void NotSignedLicenseIsRejected() { var license = CreateLicenseFromNewContact(); var encodedLicense = LicenseWriter.ToString(license); LicenseReader.FromString(encodedLicense.Split('.').First()); }
public void TamperedLicenseIsRejected() { var license = CreateLicenseFromNewContact(); var encodedLicense = new StringBuilder(LicenseWriter.ToString(license)); encodedLicense[0] = 'A'; // I'd assume we dont already have this sequence... encodedLicense[1] = 'B'; encodedLicense[2] = 'C'; encodedLicense[3] = 'D'; LicenseReader.FromString(encodedLicense.ToString()); }
public void InvalidLicenseIsRejected2() { LicenseReader.FromString( Convert.ToBase64String(Encoding.UTF8.GetBytes("This is an invalid license text"))); }
public void InvalidLicenseIsRejected1() { LicenseReader.FromString("This is an invalid license text"); }