Testing with the demo product
Exercise your integration end to end against a Portcullis development instance.
Portcullis development environments are seeded with a product whose code is demo, so you
can test an integration before your real product is set up. Ask the Portcullis team for access
to a development instance and a demo license key.
1. Get the keyring
curl -sS "https://<portcullis-api-host>/api/v1/client/keys/demo"Put the returned kid → publicKey pairs into your test build's keyring.
2. Run the test vectors
Make your verification code pass the test vectors, including the tampered variants that must fail.
3. Walk through the scenarios
| Scenario | How | Expected |
|---|---|---|
| Online activation | Activate with the demo key | 200, file verifies, nonce and fingerprint match, state valid |
| Re-activation | Activate again with the same fingerprint | 200 with created: false; no extra seat used |
| Machine limit | Activate more fingerprints than the license allows | 409 MACHINE_LIMIT_REACHED with current and max |
| Wrong key | Activate with a made-up key | 404 LICENSE_NOT_FOUND |
| Check-in | Run a check-in with licenseKey and licenseFileId | 200, fresh file with a later exp |
| Server unreachable | Point PORTCULLIS_URL at an unreachable host | Product keeps running on its current file and retries with backoff |
| Suspension | Ask staff to suspend the test license, then check in | 200 with a signed file whose status is suspended; product enters restricted mode |
| Reinstatement / renewal | Ask staff to reinstate or renew, then check in | Product returns to valid |
| License key rotation | Ask staff to rotate the key, then check in | Check-in still succeeds via licenseFileId |
| Tampered file | Change one character in the stored file's payload | State invalid |
| Offline | Generate a .req, have staff process it, import the .lic | File verifies with the pending nonce, state valid |
| Offline renewal | Have staff issue a new file for the same machine; import it | Accepted because its iat is newer |
| Deactivation | Deactivate from your admin screen | 200 { deactivated: true }; file deleted; state not_activated |
Inspecting files
Digicom staff can paste or upload any .lic or .req file into the console's Inspect license
file tool. It decodes the contents, checks the signature and the signing key's status, and
links to the matching license or machine. Ask the Portcullis team when a file doesn't behave as
expected.