1
1
# Intel® Trust Authority TDX CLI
2
2
An easy-to-use command line interface for attesting TDX TEE(TD) with Intel Trust Authority. The CLI will be installed and run inside the TD.
3
3
4
+ ## TPM2 Tools
5
+ Tpm2 tools is required to read the TDX report data from vTPM. Install tpm2-tools package, e.g., on Ubuntu:
6
+ ``` sh
7
+ sudo apt install tpm2-tools
8
+ ```
9
+
4
10
## Go Requirement
5
11
6
12
Use <b >go1.19 or newer</b >. Follow https://go.dev/doc/install for installation of Go.
@@ -26,59 +32,34 @@ See the example test in `tdx-cli/token_test.go` for an example of a test.
26
32
### To get list of all the available commands
27
33
28
34
``` sh
29
- trustauthority-cli --help
35
+ ./ trustauthority-cli --help
30
36
```
31
37
More info about a specific command can be found using
32
38
``` sh
33
- trustauthority-cli < command> --help
34
- ```
35
-
36
- ### To create RSA keypair
37
-
38
- ``` sh
39
- trustauthority-cli create-key-pair --pub-path < public key file path>
39
+ ./trustauthority-cli < command> --help
40
40
```
41
41
42
42
### To get Intel Trust Authority signed token
43
43
44
44
` token ` command requires Intel Trust Authority configuration to be passed in json format
45
45
``` json
46
46
{
47
- "trustauthority_api_url" : " <trustauthority attestation api url> " ,
47
+ "trustauthority_api_url" : " https:// api.trustauthority.intel.com " ,
48
48
"trustauthority_api_key" : " <trustauthority attestation api key>"
49
49
}
50
50
```
51
51
Save this data in config.json file and invoke ` token ` command
52
52
``` sh
53
- trustauthority-cli token --config config.json --user-data < base64 encoded userdata> --policy-ids < comma separated trustauthority attestation policy ids>
54
- ```
55
- OR
56
- ``` sh
57
- trustauthority-cli token --config config.json --pub-path < public key file path> --policy-ids < comma separated trustauthority attestation policy ids>
53
+ sudo ./trustauthority-cli token --config config.json --user-data < base64 encoded userdata> --no-eventlog
58
54
```
59
55
60
- ### To get TD quote with Nonce and UserData
61
-
62
- ``` sh
63
- trustauthority-cli quote --nonce < base64 encoded nonce> --user-data < base64 encoded userdata>
64
- ```
65
-
66
- ### To decrypt an encrypted blob
67
-
68
- ``` sh
69
- trustauthority-cli decrypt --key-path < private key file path> --in < base64 encoded encrypted blob>
70
- ```
71
- OR
72
- ``` sh
73
- trustauthority-cli decrypt --key < base64 encoded private key> --in < base64 encoded encrypted blob>
74
- ```
75
56
76
57
### To verify Intel Trust Authority signed token
77
58
78
59
` verify ` command requires Intel Trust Authority URL to be passed in json format
79
60
``` json
80
61
{
81
- "trustauthority_url" : " < trustauthority url> "
62
+ "trustauthority_url" : " https://portal. trustauthority.intel.com "
82
63
}
83
64
```
84
65
Save this data in config.json file and invoke ` verify ` command
0 commit comments