The key is better for large batches and for codes you didn’t download in advance; the list also
tells you about revocations made after the key was loaded.
Get the verification key
1
Open the batch
Batches, then the batch. The key exists once the batch is signed.
2
Download the key
Under Offline checking, admins download Verification key · JSON. Each download is
recorded in the audit log.
3
Load it into your system
Store it where your system keeps other secrets, never in an app or device that leaves your
control.
An offline batch: Offline checking and its verification key
B-1045-verification-key.json
Field scanners’ phones
Your field scanners can check offline batches in the Satyakod app without handling keys:1
Enrol the phone
Settings → Offline devices: name the phone, choose the field scanner, then Enrol device.
You get a one-time code, valid for 30 minutes.
2
Turn it on in the app
Signed in as that field scanner, Account → Offline checking, then type the code.
Check a serial
A serial is genuine for the batch when its tag equals the first 4 bytes of HMAC-SHA256(key, message), where the message isworkspaceId|keyId| followed by the serial’s
6-byte batch sequence and index. See Serial numbers for the format.
Test your implementation
With the example key above:The example key is made up for these docs. It belongs to no workspace, and its serials won’t pass
Satyakod’s online checks.
What an offline check can’t tell you
- Copies. A genuine serial printed twice passes offline. Satyakod’s clone check compares scans across places and times; upload your offline scans to get it.
- Revocations after you loaded the key. Download the Serial list again, or check online when you can, for batches you have revoked codes from.
Upload scans made offline
When the device or plant is back online, send its scans toPOST /v1/verify/offline, up to 500 at a time. Satyakod checks
each as of when it was scanned and adds it to your scan history, alerts and reports.