You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 4, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: docs/How_to_Protect_AI_Models_in_Cloud_Native_Environments.md
+18-17Lines changed: 18 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,27 +40,27 @@ The service supports attestation, measurement fetching and event logs collecting
40
40
CCNP is a good choice to fetch these evidences including measurements and event logs, which hides the complexity of the underlying platforms and increase the usability of the APIs. Here's the sample code using CCNP:
41
41
42
42
```Python
43
-
from ccnp importEventlog
44
-
event_logs =Eventlog.get_platform_eventlog()
43
+
from ccnp importCcnpsdk
44
+
event_logs =CcnpSdk.inst().get_cc_eventlog()
45
45
```
46
46
47
47
To verify that the event logs have not been tampered with, we can compare the measurement replayed from event logs with the IMR (Integrated Measurement Register) values fetched using CCNP.
48
48
Here's the sample code using CCNP to fetch IMR values (use Intel TDX RTMR as example):
CCNP API detail documentation can be found [here](https://intel.github.io/confidential-cloud-native-primitives/).
55
+
CCNP API detail documentation can be found [here](https://cc-api.github.io/confidential-cloud-native-primitives/).
56
56
57
57
### 1.3 Attestation by using Confidential Cloud-Native Primitives (CCNP)
58
58
59
59
To get the key to decrypt the model, we need provide the quote of TEE for attestation, CCNP is a good choice to get the quote and it hides the complexity and is easy to use, sample code from CCNP:
60
60
61
61
```Python
62
-
from ccnp importQuote
63
-
quote=Quote.get_quote()
62
+
from ccnp importCcnpsdk
63
+
quote= CcnpSdk.inst().get_cc_report().dump()
64
64
```
65
65
66
66
### 1.4 AI Model Decryption
@@ -221,20 +221,20 @@ We can fetch, replay and verify event logs before attestation, the sample code:
221
221
```Python
222
222
import logging
223
223
224
-
from ccnp importEventlog, Measurement, MeasurementType
0 commit comments