Generating Signed Licence Files
Rivlo Licensing only validates offline .lic files signed with your private key. You are responsible for generating these files securely.
There are numerous methods to generate your key pair.
Example Key Pair
Using openssl to generate key pair:
openssl genrsa -out private.pem 2048
openssl rsa -in private.pem -outform PEM -pubout -out public.pem
Or in a C# class:
using RSAKeyUtils = System.Security.Cryptography;
var rsa = RSA.Create(2048);
var privateKey = rsa.ExportRSAPrivateKey();
var publicKey = rsa.ExportRSAPublicKey();
Licence File Format (simple example)
{
"ProductName": "YourPackage",
"AllowedDomains": [ "clientsite.com" ],
"Issued": "2025-01-01"
"Expires": "2026-12-31",
"Tier": "Pro"
}
You’ll serialize this, sign it with your private key, and distribute the .lic file to your customer.
🔐 Important: Never distribute your private key. Only your public key should be injected into the validator.
Signing Tools
You could use:
- A custom signing tool (e.g. CLI app or admin panel)
- .NET's RSA + SHA256 for signing
- Third-party tools like JWT (if extending to web APIs in the future)