Introduction – NVIDIA Attestation CLI#
nvattest is a command‑line tool built on the NVIDIA Attestation SDK to collect device attestation evidence and verify integrity for NVIDIA GPUs and Switches.
It supports:
Collecting evidence from live devices (via NVML for GPUs and NSCQ for Switch)
Verifying locally or via a remote verifier
Supplying pre‑serialized evidence from files (for offline/replay workflows)
Applying a custom Relying Party policy (Rego)
Emitting JSON output suitable for automation, with meaningful exit codes
Global Options#
--log-level: Sets the log level. Accepted values are: “trace”, “debug”, “info”, “warn”, “error”, “off”. Default is “warn”.
Subcommands#
version#
Displays CLI version information as JSON.
nvattest version
# {
# "nvattest": "1.0"
# }
collect-evidence#
Collects device evidence from live devices and prints results as JSON.
This evidence can be saved and used with attest --gpu-evidence or attest --switch-evidence. [optional]
Options: (see nvattest collect-evidence -h for more information):
--device {gpu|switch}: Device to attest. Default isgpu.--nonce: Nonce for the attestation in hex format.
Example command:
nvattest collect-evidence --device gpu
Output:
Prints a JSON document to stdout. At a minimum it includes:
evidences: the attestation evidences as a JSON array (one entry per device)result_code: NVAT SDK return coderesult_message: NVAT SDK return code string
Example output (truncated):
{
"evidences": [
{
"version": "1.0",
"arch": "HOPPER",
"nonce": "123..",
"vbios_version": "96.00.00.00.01",
"driver_version": "575.03",
"evidence": "EeAB..",
"certificate": "LS0t.."
},
{
"version": "1.0",
// ...
}
],
"result_code": 0,
"result_message": "Ok"
}
attest#
Runs attestation and prints results as JSON.
Options: (see nvattest attest -h for more information):
--device {gpu|switch}: Device to attest. Default isgpu.--nonce: Nonce for the attestation in hex format.--verifier {local|remote}(default:local)--gpu-evidence <path>: JSON evidence file to use instead of NVML--switch-evidence <path>: JSON evidence file to use instead of NSCQ--relying-party-policy <path>: Rego policy file--rim-url: Base URL for the NVIDIA RIM service (e.g.: https://rim.attestation.nvidia.com)--ocsp-url: Base URL for the OCSP responder (e.g.: https://ocsp.ndis.nvidia.com)--nras-url: Base URL for the NVIDIA Remote Attestation Service (e.g.: https://nras.attestation.nvidia.com)--allow-cert-hold: Allow attestation to continue when OCSP revocation status is certificate hold (default: false)
Behavior:
If no
--gpu-evidence/--switch-evidencefiles are provided, the CLI enables corresponding device drivers and collects live evidence.When provided, evidence files replace live collection for that device class.
If a Rego policy is supplied, attestation will fail with a specific exit code when the policy does not match.
Output#
Prints a JSON document to stdout. At a minimum it includes:
claims: the attestation claims as a JSON array (one entry per device)detached_eat: the signed detached EAT bundle containing the claim setresult_code: NVAT SDK return coderesult_message: NVAT SDK return code string
Example output (truncated):
{
"claims": [
{
"x-nvidia-device-type": "gpu",
"secboot": true,
"x-nvidia-gpu-driver-version": "575.32"
// ...
}
],
"detached_eat": [
[
"JWT",
"the-overall-jwt"
],
{
"GPU-0": "jwt-for-this-submodule",
"GPU-1": "jwt-for-this-submodule",
// ...
}
],
"result_code": 0,
"result_message": "Ok"
}
See the SDK’s claims schema documentation for the complete schema of the claims.
Example CLI commands#
Local GPU attestation:
nvattest attest --device gpu --verifier local
Attest using pre‑collected GPU evidence and a custom policy:
nvattest attest --device gpu \
--gpu-evidence ./path/to/gpu_evidence.json \
--relying-party-policy ./path/to/policy.rego
Rego policy example:
Supply a Rego file that defines package policy and a boolean rule nv_match. If nv_match evaluates to false, the attestation failes with error code `NVAT_RP_POLICY_MISMATCH.
See here for more information
Example rego policy:
package policy
import future.keywords.every
default nv_match := false
nv_match {
every result in input {
result["x-nvidia-device-type"] == "gpu"
result.secboot
result.dbgstat == "disabled"
}
}
Pass it with --relying-party-policy option
Next steps#
Refer to the Installation and Development docs for dependency setup, building, and configuration.