Skip to content
On this page

Services

Auth service

The Factory+ service that stores grants and identities and computes the access control list of each principal.

13 min read Edit this page
Central services
ACS implementationACS Auth serviceSee how the AMRC Connectivity Stack implements this.View on GitHub

The Auth service holds every Factory+ grant and computes the access control list (ACL) of each principal.

Every Factory+ service decides, for each request, whether the principal making it may do what it asks. If each service kept its own list of who may do what, an administrator would have to change many services to give one person access, and the lists would drift apart. Instead, the Auth service holds all grants in one place and works out, for any principal, the complete list of permissions that principal holds. Services fetch that list and make their own decisions from it.

The Auth service enforces nothing itself. It computes ACLs and serves them, and each consuming service checks the request against the caller’s ACL. The model the service implements, with grants, groups, plural targets and the special target UUIDs, is described in Authorisation. Principals and their identities are described in Principals.

Service identity

Clients find the Auth service through the Directory by its service UUID, like any other Factory+ service. The service follows the common rules in the Service specification. It reports interface version 2.0.0 in its /ping response.

Service FunctionAuth
cab2642a-f7d9-42e5-8845-8f35affe1fd4
The service UUID of the Auth service. A client looks this up in the Directory to find the service URL.

Data model

The Auth service stores two kinds of record of its own, grants and identities. It reads everything else it needs from the Configuration Store. Because of this dependency, an implementation needs a way to start the two services together, as described under Root principal.

Grants. A grant is a record of the form {uuid, principal, permission, target, plural}. The Auth service assigns each grant its own UUID when the grant is created. The principal field holds a principal or a principal group, the permission field holds a permission or a composite permission, and the target field holds the object the permission applies to. When plural is false, the target is the object itself. When plural is true, the target is a class and every member of that class is a target. A grant with plural set to true and one with plural set to false can exist for the same principal, permission and target, and they are separate grants. Grants only allow, and anything a principal has not been granted is denied.

Identities. An identity links a principal UUID to a name that the principal authenticates with. Each identity has a kind, and the only kind in use is kerberos, whose names are Kerberos principal names such as alice@EXAMPLE.COM. A principal has at most one name of each kind, and a name belongs to at most one principal. Sparkplug addresses are not identities in the Auth service. A principal’s Sparkplug address is held in the Sparkplug Address app of the Configuration Store.

The service reads these from the Configuration Store:

InformationWhere it comes from in the Configuration Store
Which UUIDs are principalsMembers of the class Principal (11614546-b6d7-11ef-aebd-8fbb45451d7c)
Principal groupsSubclasses of Principal, with their members
Which UUIDs are permissionsMembers of the class Permission (8ae784bb-c4b5-4995-9bf6-799b3c7f21ad)
Composite permissionsSubclasses of Permission, with their members
Members of a plural targetMembers of the target class, including members of its subclasses
Ownership of objectsThe owner field of each object’s entry in the Registration app (cb40bed5-49ad-4443-a7f5-08c75009da8f)

Groups are therefore edited in the Configuration Store through class membership, not through the Auth service.

Computing an ACL

An ACL is a flat list of entries of the form {permission, target}, with every group and class already expanded. The Auth service MUST compute the ACL of a principal by these rules. They give the same result on every implementation.

  1. If the UUID is not a member of the class Principal, directly or through a subclass, the principal has no ACL. The ACL endpoints then return 404.
  2. A grant applies to the principal when its principal field is the principal’s own UUID. It also applies when that field is any subclass of Principal that has the principal as a member. Because principal types such as Human user are subclasses of Principal, a grant to a principal type applies to every principal of that type.
  3. If the grant’s permission is a member of the class Permission, it is used as it is. If the permission is a subclass of Permission (a composite permission), the grant gives one entry for each member of that subclass. A grant whose permission is neither gives no entries.
  4. If plural is false, the target is used as it is. If plural is true, the grant gives one entry for each member of the target class. A target class with no members gives no entries.
  5. If plural is true and the target is Mine (724c0316-4cfd-11f0-b355-0b70840faae8), the grant gives one entry for each object whose Registration owner is the principal. Objects whose owner is Unowned (091e796a-65c0-4080-adff-c3ce01a65b2e) are never included.
  6. A target of Self (5855a1cc-46d8-4b16-84f8-ab3916ecb230) is replaced by the principal’s own UUID.
  7. A target of Wildcard (00000000-0000-0000-0000-000000000000) is left as it is. Wildcard is the null UUID. The consuming service decides whether Wildcard matches a given target, because only that service knows whether its permission can apply to every target.

For example, a principal group called ACL editors is a subclass of Principal with Alice as a member. A composite permission called ACL admin has Read ACLs and Manage ACLs as members. The single grant {principal: ACL editors, permission: ACL admin, target: Wildcard, plural: false} gives Alice’s ACL these two entries: {permission: Read ACLs, target: Wildcard} and {permission: Manage ACLs, target: Wildcard}.

The ACL changes whenever a grant changes. It also changes when class membership or ownership changes in the Configuration Store. Clients that need to follow these changes SHOULD use change-notify rather than polling.

Checking a request

A service that checks permissions follows this pattern for each request.

sequenceDiagram
    participant C as Client
    participant S as Consuming service
    participant A as Auth service
    C->>S: Request with Authorization header
    S->>S: Authenticate the caller
    S->>A: GET /v2/acl/kerberos/{upn} (or /v2/acl/{uuid})
    A-->>S: ACL entries the service may read
    S->>S: Look for {permission, target}, or {permission, Wildcard}
    S-->>C: Response, or 403
  1. The service authenticates the caller as described in Authentication. A Kerberos caller is identified by a Kerberos principal name, and a caller with an OpenID Connect token is identified by the principal UUID in the token.
  2. The service fetches the caller’s ACL with GET /v2/acl/kerberos/{upn} or GET /v2/acl/{uuid}, or keeps it up to date with a change-notify subscription. The service MAY cache the ACL for a short time.
  3. The service looks for an entry with the permission the request needs and the target the request acts on. If the permission allows it, an entry with the Wildcard target also matches.

A service sees ACL entries only for permissions it holds Read ACLs on. Each service therefore needs Read ACLs on its own permissions, usually as one plural grant on the class that holds them.

Root principal

Because the Configuration Store needs the Auth service to check permissions and the Auth service needs the Configuration Store to compute ACLs, neither can be configured through the other until both are running. To break this loop, an implementation MAY define a root principal that is not limited by its ACL. Because the root principal’s extra access does not appear in its ACL, GET /v2/whoami/acl reports it with the root flag. The implementation defines how the root principal is chosen.

Permissions

These permissions control the Auth service itself. Their UUIDs are fixed, and every Auth service implementation MUST interpret them as described here.

Permission setAuth permission
50b727d4-3faa-40dc-b347-01c99a226c58
The set of Auth service permissions. It is a subclass of Permission, so a grant of it is a grant of every Auth permission.

This UUID is a composite permission whose members are the permissions below. It is a member of the class Service permission set (b7f0c2f4-ccf5-11ef-be77-777cd4e8cb41). A plural grant of Read ACLs with this UUID as the target allows reading every ACL entry for an Auth permission.

PermissionRead ACLs
ba566181-0e8a-405b-b16e-3fb89130fbee
Read ACL entries for the target permission.

The target is the permission whose ACL entries the holder may read, a class of permissions with plural set to true, or Wildcard for every permission. GET /v2/acl/... returns only the entries whose permission is covered. A caller does not need this permission to read their own ACL through GET /v2/whoami/acl.

PermissionManage ACLs
3a41f5ce-fc08-4669-9762-ec9e71061168
Create, change, read and delete grants of the target permission.

The target is the permission whose grants the holder may manage, or Wildcard for every permission. It controls /v2/grant and its sub-paths. It does not limit the principal or target of the grants the holder creates. Changing a grant from one permission to another needs Manage ACLs on both.

PermissionRead Kerberos mappings
e8c9c0f7-0d54-4db2-b8d6-cd80c45f6a5c
Read any identity record and any principal's group memberships.

This permission controls the identity lookups under /v2/principal and /v2/identity, and GET /v2/principal/{uuid}/groups. The v2 endpoints treat it as a blanket permission, and holding it on any target allows reading every identity. It SHOULD be granted only with the Wildcard target. The deprecated GET /authz/principal/{uuid} still checks the target, and on that route the target is the principal being looked up.

PermissionManage Kerberos mappings
327c4cc8-9c46-4e1e-bb6b-257ace37b0f6
Add, change or remove the identities of the target principal.

The target is the principal whose identities may be changed, or Wildcard for every principal. It controls PUT and DELETE on /v2/principal/{uuid}/{kind}.

PermissionManage groupDeprecated
be9b6d47-c845-49b2-b9d5-d87b83f11c3b
Read and clear group records left from the version 1 API.

Groups are Configuration Store classes. This permission is used only by the deprecated /authz/group routes, which need it on the Wildcard target.

PermissionRead effective permissionsDeprecated
35252562-51e5-4dd8-84cd-ba0fafa62669
Read the effective permissions of a principal through the version 1 API.

No current endpoint checks this permission. Read ACLs and GET /v2/acl/{principal} replace it.

HTTP API

Every request MUST be authenticated with one of the schemes in Authentication. The service SHOULD offer POST /token bearer tokens, as other Factory+ services do. All request and response bodies are JSON. The full interface, with every status code, is in the specification at the end of this page.

If a path parameter should be a UUID or a Kerberos principal name but is not, the response is 410 Gone rather than 404, because no resource can ever exist at that path. A 403 means the caller lacks the permission the endpoint needs.

ACLs

Method and pathPurposePermission
GET /v2/acl/{principal}The ACL of a principal UUIDRead ACLs, which filters the entries
GET /v2/acl/kerberos/{upn}The ACL of the principal with this Kerberos identityRead ACLs, which filters the entries

Both return an array of {permission, target} objects, filtered to the permissions the caller holds Read ACLs on. A caller with no Read ACLs grant at all gets 403, and a principal that is not a member of the class Principal gets 404. For a name that belongs to no principal, the Kerberos form returns an empty array, not 404.

Grants

Method and pathPurposeSuccess
GET /v2/grantList the UUIDs of the grants the caller can manage200
POST /v2/grantCreate a grant201 with {uuid}, or 200 with {uuid} if an identical grant exists
GET /v2/grant/{uuid}Read a grant200
PUT /v2/grant/{uuid}Replace a grant, keeping its UUID204
DELETE /v2/grant/{uuid}Delete a grant204
POST /v2/grant/findFind grants by any of principal, permission, target and plural200

Every grant operation needs Manage ACLs on the permission of the grant concerned. A caller with no Manage ACLs grant at all gets 403 from the list and find endpoints. The POST and PUT bodies are grant objects without the uuid field, and all four fields are required:

{
    "principal":  "<principal or principal group UUID>",
    "permission": "<permission or composite permission UUID>",
    "target":     "00000000-0000-0000-0000-000000000000",
    "plural":     false
}

A body that is not a valid grant gets 422. Because creating a grant that already exists is not an error, a client can create the grants it needs every time it starts without checking first. POST /v2/grant/find matches every field given and ignores fields that are missing or null.

Principals and identities

Method and pathPurposePermission
GET /v2/principalUUIDs of the principals that have at least one identityRead Kerberos mappings
GET /v2/principal/{uuid}All identities of a principal, as {uuid, kerberos}Read Kerberos mappings
GET /v2/principal/{uuid}/groupsUUIDs of every principal group that contains the principal, including nested groupsRead Kerberos mappings
GET /v2/principal/{uuid}/{kind}One identity name, as a JSON stringRead Kerberos mappings
PUT /v2/principal/{uuid}/{kind}Set one identity name. The body is a JSON stringManage Kerberos mappings on the principal
DELETE /v2/principal/{uuid}/{kind}Remove one identityManage Kerberos mappings on the principal
GET /v2/identityThe identity kinds the service supports, ["kerberos"]None
GET /v2/identity/{kind}All names of one kindRead Kerberos mappings
GET /v2/identity/{kind}/{name}The UUID of the principal with this identity, as a JSON stringRead Kerberos mappings

GET /v2/principal lists only the principals that have identities in the Auth service. The full list of principals is the membership of the class Principal in the Configuration Store.

PUT /v2/principal/{uuid}/{kind} returns 409 if the principal already has a different name of that kind or if the name already belongs to another principal. Setting the name a principal already has returns 204 and changes nothing. An unknown kind returns 404.

GET /v2/principal/{uuid}/groups returns 410 if the UUID is not a member of the class Principal. With it, an external service can make the same group-based decisions as the Auth service without repeating the group expansion. An identity provider that issues tokens is one such service.

The caller’s own information

Method and pathReturns
GET /v2/whoamiThe caller’s principal UUID and identities, as {uuid, kerberos}
GET /v2/whoami/uuidThe caller’s principal UUID, as a JSON string
GET /v2/whoami/acl{principal, root, acl} for the caller

These endpoints need no permission and work for every authentication scheme. GET /v2/whoami/acl returns the caller’s whole ACL without the Read ACLs filter. A user interface can then show its user only the actions they are allowed to take. If the caller’s credentials map to no principal, principal is null and acl is empty. In that case the first two endpoints return 404.

Bulk loading

An implementation MAY offer an endpoint that loads many grants and identities at once, for example to set up a new installation. The implementation defines the format of such an endpoint, and it is not part of this interface.

Change-notify

The Auth service supports change-notify version 2 over a WebSocket at notify/v2 under the service URL. A client opens the WebSocket, authenticates and sends WATCH requests for these URLs:

Notify URLSame response as
v2/principal/GET /v2/principal
v2/identity/{kind}/GET /v2/identity/{kind}
v2/acl/{principal}GET /v2/acl/{principal}
v2/acl/kerberos/{upn}GET /v2/acl/kerberos/{upn}
v2/whoami/aclGET /v2/whoami/acl

Each update carries the status code and body that the matching GET would return at that moment, after the same permission checks. A subscription that would get 403 therefore gets a 403 update. Two details differ from the GET. A v2/acl/kerberos/{upn} subscription for a name that belongs to no principal gets 404 rather than an empty list. A caller with no Read ACLs grant gets 403 before any 404 for a UUID that is not a principal. A consuming service that watches the ACL of each active caller learns about a revoked grant without waiting for a cache to expire.

Deprecated version 1 routes

An implementation that has to serve older clients MAY keep these routes. The reference implementation handles them as follows:

RouteBehaviour
GET /authz/acl?principal=…&by-uuid=…&permission=…Forwards to GET /v2/acl/{principal} or GET /v2/acl/kerberos/{upn}. The permission value must be a UUID but is ignored.
GET /authz/principal/find?kerberos=…Forwards to GET /v2/identity/kerberos/{name}, or to GET /v2/whoami/uuid without the parameter.
GET /authz/principal/{uuid}Returns {uuid, kerberos}. Needs Read Kerberos mappings on the principal, except for the caller’s own principal.
GET /authz/group, /authz/group/all, /authz/group/{group}, DELETE /authz/group/{group}/{member}Read and clear version 1 group records left before migration. Need Manage group on the Wildcard.
Any method on /authn/authenticateReturns {"ok": true} if the credentials are valid.
GET and POST /authz/principal, DELETE /authz/principal/{uuid}, GET and POST /authz/ace, GET /authz/effective, GET /authz/effective/{principal}, PUT /authz/group/{group}/{member}Return 410 Gone.

Specification

The OpenAPI 3.1 file for the Auth service is at /spec/authorisation.yaml.

OpenAPI specificationView the full OpenAPI specification for the Auth serviceView specification
get/ping
Check the service is running and identify it.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

Service identification.

application/jsonPing
  • versionrequiredstring

    The version of the service interface specification this service implements.

  • servicerequiredUUID

    The service UUID, cab2642a-f7d9-42e5-8845-8f35affe1fd4 for the Auth service.

  • softwareobject

    Optional information about the implementation.

    Fields
    • vendorstring
    • applicationstring
    • revisionstring
401

No credentials were given, or they were refused.

503

The service could not check the credentials. The caller should retry later and should not discard its credentials.

post/token
Get a bearer token for this service.

Issues an opaque bearer token for the authenticated caller. The token is valid only on the service instance that issued it, until the returned expiry time. Clients usually authenticate here with Negotiate and then use the token as Authorization: Bearer <token> on later requests.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

A new token.

application/jsonToken
  • tokenrequiredstring

    The opaque bearer token.

  • expiryrequiredinteger

    When the token expires, in milliseconds since the Unix epoch.

401

No credentials were given, or they were refused.

503

The service could not check the credentials. The caller should retry later and should not discard its credentials.

get/v2/acl/{principal}
Get the ACL of a principal.

Returns the expanded ACL of the principal. Only entries whose permission the caller holds Read ACLs on are returned, so two callers can see different subsets of the same ACL.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
principalpathYesUUID

A principal UUID.

Responses
200

The ACL, filtered by the caller's Read ACLs grants.

application/jsonACL
  • permissionrequiredUUID

    A permission UUID. Composite permissions have already been expanded.

  • targetrequiredUUID

    A target UUID. Plural grants have already been expanded to the members of the target class, and Self has been replaced by the principal's own UUID. The Wildcard (the null UUID) is left as it is, for the consuming service to interpret.

403

The caller holds Read ACLs on no permission at all.

404

The UUID is not a member of the Principal class in the ConfigDB.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

get/v2/acl/kerberos/{upn}
Get the ACL of a principal by Kerberos name.

As GET /v2/acl/{principal}, but the principal is found by its Kerberos identity. An unknown Kerberos name gives an empty list rather than 404, because the service has not yet checked the caller's permissions at that point.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
upnpathYesKerberos

A Kerberos principal name, URL-encoded.

Responses
200

The ACL, filtered by the caller's Read ACLs grants, or an empty list if no principal has this Kerberos identity.

application/jsonACL
  • permissionrequiredUUID

    A permission UUID. Composite permissions have already been expanded.

  • targetrequiredUUID

    A target UUID. Plural grants have already been expanded to the members of the target class, and Self has been replaced by the principal's own UUID. The Wildcard (the null UUID) is left as it is, for the consuming service to interpret.

403

The caller holds Read ACLs on no permission at all.

404

The principal is not a member of the Principal class in the ConfigDB.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

get/v2/grant
List grants the caller can manage.

Returns the UUIDs of the grants the caller holds Manage ACLs on, meaning grants whose permission is a target of one of the caller's Manage ACLs grants. Manage ACLs on the Wildcard covers every grant.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

A list of grant UUIDs.

application/jsonUUIDList
403

The caller holds Manage ACLs on nothing.

post/v2/grant
Create a grant.

Creates a grant. The caller needs Manage ACLs on the grant's permission (or on the Wildcard). Creating a grant that already exists, with the same principal, permission, target and plural flag, is not an error and returns the existing grant's UUID.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Request body (required)
application/jsonGrantRequest
  • principalrequiredUUID

    A principal UUID, or a principal group UUID.

  • permissionrequiredUUID

    A permission UUID, or a composite permission UUID.

  • targetrequiredUUID

    The target UUID. With plural false this is the target itself. With plural true it is a class, and every member of that class is a target.

  • pluralrequiredboolean

    Whether the target is a class whose members are the targets.

Responses
200

An identical grant already exists.

application/jsonGrantUUID
  • uuidrequiredUUID
201

The grant was created.

application/jsonGrantUUID
  • uuidrequiredUUID
403

The caller does not hold Manage ACLs on the grant's permission.

409

The grant could not be created because it conflicts with another.

422

The request body is not a valid grant.

get/v2/grant/{uuid}
Read a grant.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

The grant UUID.

Responses
200

The grant.

application/jsonGrant
  • uuidrequiredUUID

    The grant UUID.

  • principalrequiredUUID

    A principal UUID, or a principal group UUID.

  • permissionrequiredUUID

    A permission UUID, or a composite permission UUID.

  • targetrequiredUUID

    The target UUID. With plural false this is the target itself. With plural true it is a class, and every member of that class is a target.

  • pluralrequiredboolean

    Whether the target is a class whose members are the targets.

403

The caller does not hold Manage ACLs on the grant's permission.

404

No grant has this UUID.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

put/v2/grant/{uuid}
Replace a grant.

Replaces the principal, permission, target and plural flag of an existing grant, keeping its UUID. The caller needs Manage ACLs on both the existing permission and the new one.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

The grant UUID.

Request body (required)
application/jsonGrantRequest
  • principalrequiredUUID

    A principal UUID, or a principal group UUID.

  • permissionrequiredUUID

    A permission UUID, or a composite permission UUID.

  • targetrequiredUUID

    The target UUID. With plural false this is the target itself. With plural true it is a class, and every member of that class is a target.

  • pluralrequiredboolean

    Whether the target is a class whose members are the targets.

Responses
204

The grant was replaced.

403

The caller does not hold Manage ACLs on the existing permission or on the new one.

404

No grant has this UUID.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

422

The request body is not a valid grant.

delete/v2/grant/{uuid}
Delete a grant.

The caller needs Manage ACLs on the grant's permission.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

The grant UUID.

Responses
204

The grant was deleted.

403

The caller does not hold Manage ACLs on the grant's permission.

404

No grant has this UUID.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

post/v2/grant/find
Search for grants.

Returns the UUIDs of grants that match every field given in the request body. Fields left out, or set to null, match anything. Only grants the caller can manage are returned, as for GET /v2/grant.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Request body (required)
application/jsonGrantQuery
  • principalUUID | null
  • permissionUUID | null
  • targetUUID | null
  • pluralboolean | null
Responses
200

The matching grant UUIDs.

application/jsonUUIDList
403

The caller holds Manage ACLs on nothing.

422

A field is not a UUID, or plural is not a boolean.

get/v2/principal
List principals that have identities.

Returns the UUID of every principal that has at least one identity recorded in the Auth service. This is not the list of principals, which is the membership of the Principal class in the ConfigDB. Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

A list of principal UUIDs.

application/jsonUUIDList
403

The caller does not hold Read Kerberos mappings.

404

No identities are recorded.

get/v2/principal/{uuid}
Get all identities of a principal.

Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

Responses
200

The principal's identities.

application/jsonIdentities
  • uuidrequiredUUID
  • kerberosKerberos

    A Kerberos principal name, including the realm.

403

The caller does not hold Read Kerberos mappings.

404

The principal has no identities.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

get/v2/principal/{uuid}/groups
List the principal groups a principal belongs to.

Returns the UUID of every principal group (subclass of the Principal class in the ConfigDB) that contains the principal, directly or through nested groups. These are the groups whose grants apply to the principal. Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

Responses
200

A list of principal group UUIDs.

application/jsonUUIDList
403

The caller does not hold Read Kerberos mappings.

410

The path parameter is not a UUID, or the UUID is not a member of the Principal class.

get/v2/principal/{uuid}/{kind}
Get one identity of a principal.

Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

kindpathYesstring

An identity kind, as listed by GET /v2/identity.

Responses
200

The identity name, as a JSON string.

application/jsonstring
403

The caller does not hold Read Kerberos mappings.

404

The principal has no identity of this kind.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

put/v2/principal/{uuid}/{kind}
Set one identity of a principal.

Records the identity name for this principal and kind. A principal has at most one name of each kind, and a name belongs to at most one principal. Setting the name the principal already has succeeds and changes nothing. Needs Manage Kerberos mappings on the principal UUID (or on the Wildcard).

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

kindpathYesstring

An identity kind, as listed by GET /v2/identity.

Request body (required)

The identity name, as a JSON string.

application/jsonstring
Responses
204

The identity is recorded.

403

The caller does not hold Manage Kerberos mappings on this principal.

404

The identity kind is not known.

409

The principal already has a different name of this kind, or the name already belongs to another principal.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

delete/v2/principal/{uuid}/{kind}
Remove one identity of a principal.

Needs Manage Kerberos mappings on the principal UUID (or on the Wildcard).

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

kindpathYesstring

An identity kind, as listed by GET /v2/identity.

Responses
204

The identity was removed.

403

The caller does not hold Manage Kerberos mappings on this principal.

404

The principal has no identity of this kind.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

get/v2/identity
List the identity kinds the service supports.

No permission is needed.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The identity kinds.

application/jsonarray of string
get/v2/identity/{kind}
List all identity names of one kind.

Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
kindpathYesstring

An identity kind, as listed by GET /v2/identity.

Responses
200

The identity names.

application/jsonarray of string
403

The caller does not hold Read Kerberos mappings.

404

No identities of this kind are recorded.

get/v2/identity/{kind}/{name}
Find the principal that has an identity.

Needs Read Kerberos mappings.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
kindpathYesstring

An identity kind, as listed by GET /v2/identity.

namepathYesstring

The identity name. For the kerberos kind this is a principal name such as alice@EXAMPLE.COM.

Responses
200

The principal UUID, as a JSON string.

application/jsonUUID
403

The caller does not hold Read Kerberos mappings.

404

No principal has this identity.

410

The name is not a valid name for this kind.

get/v2/whoami
Get the caller's own identities.

No permission is needed.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The caller's principal UUID and identities.

application/jsonIdentities
  • uuidrequiredUUID
  • kerberosKerberos

    A Kerberos principal name, including the realm.

404

The caller's credentials do not map to a principal with identities.

get/v2/whoami/uuid
Get the caller's principal UUID.

No permission is needed.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The caller's principal UUID, as a JSON string.

application/jsonUUID
404

The caller's credentials do not map to a principal.

get/v2/whoami/acl
Get the caller's own ACL.

Returns the caller's whole expanded ACL. No permission is needed, so a client can offer its user only the actions they are allowed to take.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The caller's principal UUID, root flag and ACL.

application/jsonOwnACL
  • principalrequiredUUID | null

    The caller's principal UUID, or null if the credentials map to no principal.

  • rootrequiredboolean

    True if the caller is the implementation's root principal, whose access is not limited by its ACL and does not show in it.

  • aclrequiredACL
    Fields
    • permissionrequiredUUID

      A permission UUID. Composite permissions have already been expanded.

    • targetrequiredUUID

      A target UUID. Plural grants have already been expanded to the members of the target class, and Self has been replaced by the principal's own UUID. The Wildcard (the null UUID) is left as it is, for the consuming service to interpret.

get/authz/aclDeprecated
Get the ACL of a principal (version 1).

Forwards to GET /v2/acl/{principal} or GET /v2/acl/kerberos/{upn}. The permission parameter must be a UUID but is ignored, so the response holds every entry the caller may read.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
principalqueryYesstring

A principal UUID, or a Kerberos principal name.

by-uuidqueryNoboolean

true if principal is a UUID. Absent or false means principal is a Kerberos principal name.

permissionqueryYesUUID

Any UUID. The value is ignored.

Responses
200

As for the /v2 ACL endpoints.

application/jsonACL
  • permissionrequiredUUID

    A permission UUID. Composite permissions have already been expanded.

  • targetrequiredUUID

    A target UUID. Plural grants have already been expanded to the members of the target class, and Self has been replaced by the principal's own UUID. The Wildcard (the null UUID) is left as it is, for the consuming service to interpret.

400

The by-uuid value is not a recognised boolean.

403

As for the /v2 ACL endpoints.

404

As for the /v2 ACL endpoints.

410

The principal or permission parameter is malformed.

get/authz/principal/findDeprecated
Find a principal by Kerberos name (version 1).

Forwards to GET /v2/identity/kerberos/{name}, or to GET /v2/whoami/uuid when no kerberos parameter is given.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
kerberosqueryNoKerberos

A Kerberos principal name.

Responses
200

The principal UUID, as a JSON string.

application/jsonUUID
403

The caller does not hold Read Kerberos mappings.

404

No principal has this identity.

410

The kerberos value is not a valid Kerberos principal name.

get/authz/principal/{uuid}Deprecated
Get the Kerberos identity of a principal (version 1).

Needs Read Kerberos mappings on the principal UUID (or on the Wildcard), except that callers may always look up their own principal.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

Responses
200

The principal and its Kerberos name.

application/jsonPrincipalMappingV1
  • uuidrequiredUUID
  • kerberosrequiredKerberos

    A Kerberos principal name, including the realm.

403

The caller may not read this principal's identity.

404

The principal has no Kerberos identity.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

delete/authz/principal/{uuid}Deprecated
Removed.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
uuidpathYesUUID

A principal UUID.

Responses
410

This version 1 route has been removed.

get/authz/principalDeprecated
Removed.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
410

This version 1 route has been removed.

post/authz/principalDeprecated
Removed. Use PUT /v2/principal/{uuid}/{kind}.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
410

This version 1 route has been removed.

get/authz/aceDeprecated
Removed. Use GET /v2/grant.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
410

This version 1 route has been removed.

post/authz/aceDeprecated
Removed. Use POST /v2/grant and /v2/grant/{uuid}.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
410

This version 1 route has been removed.

get/authz/effectiveDeprecated
Removed. Use GET /v2/acl/{principal}.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
410

This version 1 route has been removed.

get/authz/effective/{principal}Deprecated
Removed. Use GET /v2/acl/{principal}.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
principalpathYesstring
Responses
410

This version 1 route has been removed.

get/authz/groupDeprecated
List version 1 groups (migration only).

Groups are classes in the ConfigDB. This route reads any version 1 group records left from before migration. Needs Manage group on the Wildcard.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The UUIDs of version 1 groups that still have members.

application/jsonUUIDList
403

The caller does not hold Manage group on the Wildcard.

get/authz/group/allDeprecated
List all version 1 group memberships (migration only).

Needs Manage group on the Wildcard.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

Every remaining version 1 group membership.

application/jsonarray of object
  • parentrequiredUUID
  • childrequiredUUID
403

The caller does not hold Manage group on the Wildcard.

get/authz/group/{group}Deprecated
List the members of a version 1 group (migration only).

Needs Manage group on the Wildcard.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
grouppathYesUUID
Responses
200

The member UUIDs.

application/jsonUUIDList
403

The caller does not hold Manage group on the Wildcard.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

put/authz/group/{group}/{member}Deprecated
Removed. Edit class membership in the ConfigDB instead.
Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
grouppathYesUUID
memberpathYesUUID
Responses
410

This version 1 route has been removed.

delete/authz/group/{group}/{member}Deprecated
Remove a version 1 group membership (migration only).

Needs Manage group on the Wildcard.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Parameters
NameInRequiredTypeDescription
grouppathYesUUID
memberpathYesUUID
Responses
204

The membership is gone.

403

The caller does not hold Manage group on the Wildcard.

410

A path parameter is not a valid UUID or Kerberos principal name, so no resource can exist at this path.

get/authn/authenticateDeprecated
Check the caller's credentials (version 1).

Accepts any HTTP method. Because every request is authenticated before it reaches this route, a response of 200 means the credentials are valid. Use GET /v2/whoami/uuid instead.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The credentials are valid.

Response headers
HeaderRequiredTypeDescription
X-Auth-PrincipalNostring

The authenticated principal name.

application/jsonobject
  • oktrue
401

No credentials were given, or they were refused.

post/authn/authenticateDeprecated
Check the caller's credentials (version 1).

Behaves the same as the GET form.

Authentication: Any one of: Negotiate (Kerberos), HTTP Basic, Bearer token
Responses
200

The credentials are valid.

401

No credentials were given, or they were refused.

Esc