Node-Locking & Machine Identifiers
Bind software license keys to physical hardware and handle stable machine identification across platforms.
Node-locking restricts license key usage to authorized devices. To enforce this control, the client application must generate a stable hardware fingerprint and register it as a host identifier during activation.
Configuration Modes
1. Node-Locked Keys
Pass the allowedHosts parameter (an array of pre-authorized hardware IDs) when issuing a license key. Keymint will reject activations from any device whose hostId is not present in this list.
{
"productId": "YOUR_PRODUCT_ID",
"maxActivations": 3,
"allowedHosts": ["mac-studio-m2", "windows-workstation-9"]
}2. Unrestricted Node-Locked Keys
Omit allowedHosts. The key can activate on any hardware device up to the maxActivations count limit. Each activation is tracked by its unique hostId.
This is not a floating license. Floating (concurrent-seat) licenses are a separate license type (licenseType: "floating"): apps lease a seat with POST /key/checkout instead of calling POST /key/activate, seats are capped by maxConcurrentSessions, and allowedHosts is not checked at checkout. See Floating Licenses.
3. Anonymous Activations
If you omit the hostId during activation, Keymint uses the reusable hostless slot N/A and returns that value in metadata.hostId. Pass N/A back on subsequent calls when you want to refer to the same hostless activation; a stable SDK-generated identifier is still recommended for true device binding.
Stable Hardware Fingerprinting
Instead of querying command line utilities or writing custom scripts to resolve system serial numbers, use Keymint's built-in hardware identification methods.
The official Keymint SDKs include best-effort fingerprinting out of the box. On the first call, the installation-ID helper:
- Queries the hardware/BIOS UUID (Windows, macOS, Linux).
- Falls back to the OS machine ID, then the primary network adapter's MAC address, if the BIOS UUID isn't available.
- Filters out generic or cloned virtual machine strings (e.g. all zeros, all Fs, or standard OEM placeholders) to avoid machine collisions.
- Combines that hardware anchor with a random UUID and saves it to a local file (
~/.keymint/installation-idby default, or a path you pass), so the ID stays the same across application restarts, software updates, and hardware changes. Later calls return the stored ID.
Use this persistent identifier as the hostId (Machine Code) when checking out or activating keys.
Using the SDK Utilities
import { KeyMint } from 'keymint';
// Generates, persists, and returns a stable machine identifier
const hostId = KeyMint.getOrCreateInstallationId();
console.log(`Machine fingerprint: ${hostId}`);Persistence Fallback: If the ID file can't be written (for example on a read-only or ephemeral filesystem), the SDK still returns an ID but doesn't save it, so the next start produces a different ID and uses another activation. Pass a writable storage path, or supply your own stable hostId, in those environments.