Skip to content

Commit

Permalink
Added 1.2.0 changes for SDK and Local Verifier
Browse files Browse the repository at this point in the history
  • Loading branch information
Karthik Jayaraman committed Feb 24, 2024
1 parent 9d52f56 commit 1434435
Show file tree
Hide file tree
Showing 17 changed files with 702 additions and 43 deletions.
20 changes: 7 additions & 13 deletions guest_tools/attestation_sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,14 @@ The Attestation SDK offers developers easy-to-use APIs for implementing attestat
- [How to do Perform Attestation](#how-to-do-perform-attestation-1)
- [Building Attestation SDK](#building-attestation-sdk)
- [APIs](#apis)
- [Version Info](#version-info)
- [Future Roadmap](#future-roadmap)


## Features

- Local GPU Attestation (using NVIDIA NVML based Python libraries)
- Remote GPU Attestation (using NVIDIA Remote Attestation Service)

Note: SDK v1.2.0 is still in Early Access Release (beta), and the APIs may undergo changes until the GA release.
Note: Attestation SDK is still in Early Access Release (beta), and the APIs may undergo changes until the GA release.

## Install Attestation SDK

Expand Down Expand Up @@ -97,6 +95,7 @@ Please refer to the [sample implementation](tests/RemoteGPUTest.py)
## APIs
### nv_attestation_sdk import attestation
| API | Description |
|---------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------|
| Attestation(<-name->) | Create a new Attestation Object used to call other Attestation methods. |
Expand All @@ -105,17 +104,12 @@ Please refer to the [sample implementation](tests/RemoteGPUTest.py)
| attest() | Trigger the Attestation for client object, This uses the Attestation type configured in add_verifier method |
| validate_token(<-attestation-results-policy->) | Validate the Attestation Claims against a policy |
## Version Info
### nv_attestation_sdk.gpu.attest_gpu_remote
SDK latest version - 1.2.0
## Future Roadmap
The following are some exciting features and improvements that we plan to implement in upcoming releases of the Attestation SDK. Please note that these roadmap items are subject to change based on user feedback and evolving priorities. We are committed to continuously improving our project to meet the needs of our users.
- Integration of NVIDIA Remote Attestation Service.
- Enhanced flexibility in Attestation result policies.
- Support for additional Attestation types such as CPU and DPU, among others.
| API | Description |
|---------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------|
| generate_evidence(<-nonce->) | Generate GPU attestation evidence using the Local GPU Verifier Python SDK with a user-provided nonce. |
| verify_evidence(<-nonce->, <-evidence->,<-nras_url->) |Verify the evidence with the NVIDIA Remote Attestation Service (NRAS) |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions guest_tools/attestation_sdk/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "nv-attestation-sdk"
version = "1.2.0"
version = "1.3.0"
authors = [
{name = "NVIDIA"},
]
Expand All @@ -14,7 +14,7 @@ classifiers = [
]
dependencies = [
'pyjwt ~= 2.7.0',
'verifier == 1.2.0',
'verifier >= 1.2.0',
'requests ~= 2.31.0'
]
keywords = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ def attest(nonce):
'rim_root_cert': None,
'rim_service_url': None,
'allow_hold_cert': True,
'ocsp_url': None,
'nonce': nonce}
attestation_result, jwt_token = cc_admin.attest(params)
except Exception as e:
Expand Down
3 changes: 2 additions & 1 deletion guest_tools/attestation_sdk/tests/RemoteGPUTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@
import os
import json

NRAS_URL="https://nras.attestation.nvidia.com/v1/attest/gpu"
client = attestation.Attestation()
client.set_name("thisNode1")
client.set_nonce("931d8dd0add203ac3d8b4fbde75e115278eefcdceac5b87671a748f32364dfcb")
print ("[RemoteGPUTest] node name :", client.get_name())

client.add_verifier(attestation.Devices.GPU, attestation.Environment.REMOTE, "https://nras.attestation.nvidia.com/v1/attest/gpu", "")
client.add_verifier(attestation.Devices.GPU, attestation.Environment.REMOTE, NRAS_URL, "")

file = "NVGPURemotePolicyExample.json"

Expand Down
15 changes: 0 additions & 15 deletions guest_tools/attestation_sdk/tests/RemoteGPUTest2.py

This file was deleted.

Loading

0 comments on commit 1434435

Please sign in to comment.