This package provides an open-source license manager.
Use this command to add AutoLicensing to your project.
dotnet add package AutoLicensing --version 1.0.5
var key = LicenseKeyGenerator.GenerateRsaKeyPair();
var privateKey = key.PrivateKey;
var publicKey = key.PublicKey;
var signedLicense = new LicenseFactory()
.WithRsaPrivateKey(key.PrivateKey)
.WithName("Enterprise License")
.WithCustomerName("Some Guy")
.WithProduct(new LicenseProductFactory()
.WithName("Application 1")
.WithExpiryDate(DateTime.Now.AddDays(180))
.WithAttribute("Limitation 1", 100)
.WithFeature("Feature 1")
.WithFeature("Feature 2")
.Create())
.SignAndCreate();
var licenseKey = signedLicense.Export();
var signedLicense = Licenser.Verifier
.WithRsaPublicKey(publicKey)
.LoadAndVerify(licenseKey);
You can change the confusing bytes by using this code
Confuser.ConfusingBytes = "Some random bytes"u8.ToArray();