Nitride
HomeDocumentationTutorials
  • Nitride
  • Documentation
    • What is Nitride?
    • Use Cases
    • Setup
      • Install Nitride
      • Configure
    • Get Started
      • Attesting a MariaDB database with Cloud-Init
    • Concepts
      • Attestation
        • AMD SEV PKI
        • Intel TDX PKI
      • enclaivelet
    • Supported Technologies
  • Tutorials
    • Create identities and policies
    • Attesting a buckypaper VM
  • Developers
    • API
      • Overview
      • Identities
      • Policies
      • Totp
      • Attestations
      • Logs
      • Config
      • Annotations
  • CLI
    • Enable Auth
    • Register Identities
    • Create Policy
    • Create Attestation
    • Enable Namespacing
  • Resources
    • Blog
    • GitHub
    • Youtube
    • CCx101
Powered by GitBook
On this page

Was this helpful?

  1. Developers
  2. API

Policies

Last updated 7 months ago

Was this helpful?

List policies

get
Query parameters
liststring · enumRequired

Must be set to true

Possible values:
Responses
200
OK
application/json
get
GET /v1/auth/ratls/policies/?list=true HTTP/1.1
Host: 
Accept: */*
200

OK

{
  "auth": {},
  "data": {
    "keys": [
      {}
    ]
  }
}

Read policy

get
Path parameters
namestringRequired

Name of the policy

Responses
200
OK
application/json
get
GET /v1/auth/ratls/policies/{name} HTTP/1.1
Host: 
Accept: */*
200

OK

{
  "auth": {},
  "data": {
    "created": 1,
    "identities": {},
    "name": "text"
  }
}

Delete policy

delete
Path parameters
namestringRequired

Name of the policy

Responses
200
OK
delete
DELETE /v1/auth/ratls/policies/{name} HTTP/1.1
Host: 
Accept: */*
200

OK

No content

  • PUTCreate policy
  • POSTUpdate policy
  • GETList policies
  • GETRead policy
  • DELETEDelete policy

Create policy

put
Body
createdinteger · int64Required

Creation timestamp, set by the plugin

identitiesobject · mapRequired

A map of all identity types with their respective selector

Default: {"provider":"azure-sev-snp-vtpm","platform":null,"firmware":[{"name":"azure-dc2asv5","policy":null},{"name":"azure-dc4asv5","policy":null}],"workload":{"name":"azure-ubuntu","policy":{"pcrs.0":false}},"metadata":null}
namestringRequired

Name of the policy

Responses
200
OK
application/json
put
PUT /v1/auth/ratls/policies HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 43

{
  "created": 1,
  "identities": {},
  "name": "text"
}
200

OK

{
  "auth": {},
  "data": {
    "created": 1,
    "identities": {},
    "name": "text"
  }
}

Update policy

post
Body
createdinteger · int64Required

Creation timestamp, set by the plugin

identitiesobject · mapRequired

A map of all identity types with their respective selector

Default: {"provider":"azure-sev-snp-vtpm","platform":null,"firmware":[{"name":"azure-dc2asv5","policy":null},{"name":"azure-dc4asv5","policy":null}],"workload":{"name":"azure-ubuntu","policy":{"pcrs.0":false}},"metadata":null}
namestringRequired

Name of the policy

Responses
200
OK
application/json
post
POST /v1/auth/ratls/policies HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 43

{
  "created": 1,
  "identities": {},
  "name": "text"
}
200

OK

{
  "auth": {},
  "data": {
    "created": 1,
    "identities": {},
    "name": "text"
  }
}