Beta

Create a tenant

A new tenant starts with its own users, OAuth settings, audit history and logs. You are its first Tenant Admin.

Who is acting?

Before the assistant can choose photos, it has to reach your album at photos.example. This lesson compares the three broad ways it can do that: borrowing your credentials, using an identity of its own, and acting as your delegate. They differ in what the photo service can see, what the assistant can do, and what you can take back afterwards.

Borrowing your credentials

The simplest way is for the assistant to become you. You could type your photo service password into the assistant. Or the assistant could operate a web browser in which you are already signed in, clicking through pages the way you would. Some agents work exactly like that.

Either way, the photo service sees you: your password, your session, your browser. Your account there is user-2048, and its activity record looks like this:

14:02:11  user-2048  album.list    session=web
14:02:15  user-2048  album.read    "Lisbon trip"     session=web
14:09:40  user-2048  album.delete  "Old screenshots" session=web

All domains, credentials, and tokens in these examples are fictional. Did you delete "Old screenshots", or did the assistant? The photo service cannot tell, and neither can you when you read the record later.

It cannot limit the assistant either. The assistant can do whatever your password or session allows, because there is no separate grant for this task that could be narrower. And stopping it means containing the credential it borrowed. If the service can tell which session the assistant is using, it can end that one; if the exposure is wider, you end your other sessions and change your password. Either way your own use is disrupted, because your authority and the assistant's were never separate.

This is the problem from The problem OAuth solves, where a printing service asked for your photo password. Agents have brought it back.

An identity of its own

The opposite approach gives the assistant its own account at the photo service, the way the printer has its own registration at the print lab in Client credentials. The assistant authenticates as itself, and the photo service knows exactly which software is calling.

That is the right model for the assistant's own resources, such as storage it keeps for its own use. It is the wrong model for your album. The photo service could share specific albums with the assistant's account, the way you share one with a friend, but then the assistant's account reaches every album anyone shared with it, and the photo service has only the assistant's word for which customer asked for each task. In the risky version, the account is given broad access to customers' photos to make that easy. A bug, or one injected instruction, could then reach every customer the assistant serves.

Acting as your delegate

The third way combines the two. The assistant keeps its own identity, and you give it limited authority over your data. The photo service sees both parties: the assistant, acting for you, with exactly the access you approved.

14:02:15  user-2048  album.read    "Lisbon trip"     via assistant.example
14:09:40  user-2048  album.delete  "Old screenshots" session=web

Now the record shows that the assistant read the Lisbon album and that you deleted the screenshots yourself. The photo service can apply its own rules to the assistant, such as refusing deletions from any agent. And you can take back the assistant's access without touching your password or any other app.

Three ways the assistant can reach your album
How the assistant reaches your albumWhat the photo service seesWhat the assistant can doHow you stop it
Your credentials or sessionYouWhatever your password or session allows, with no separate grant to narrow itEnd the session it uses, or your other sessions and password if the exposure is wider
Its own identityThe assistantOnly what was shared or granted to its own accountThe operator controls the account; you can unshare what you shared with it, where the service allows
Your delegateThe assistant, acting for youOnly what you approvedTake back its access on its own

Read the last row against the first. Both let the assistant act on your album, but only delegation leaves the photo service a record that names the assistant and a grant you can end without ending anything of your own. Delegation is the idea OAuth was built on, which is why the assistant's access in the following lessons is an OAuth grant.

What an agent's identity includes

"The assistant" can mean several different things, and a good record keeps them apart:

  • The agent product. The assistant offered by assistant.example, registered at the photo service as a client with its own client ID.
  • The running software. The copies of the assistant running on the operator's infrastructure right now. Each is a workload with its own identity and short-lived credentials, as in Credentials for workloads.
  • The operator. The company that runs assistant.example, responsible for its behavior and for protecting its credentials.
  • The person it serves. You, for this task.

A token or record entry should not blur these together. The client ID says which product is calling. The subject says whose authority it is using. The operator answers for the product.

The model the assistant uses, and its version, is a different kind of fact. It may change every few weeks without the assistant becoming a different party. It can be a useful detail in a record, but it is not the assistant's identity, and permissions should not have to be granted again each time the model is updated.

A directory can list agents separately from people and ordinary workloads, each with an owner and a way to disable it, which gives an organization an inventory of its agents. The entry still has to be tied to the credentials a service actually checks, or disabling it in the directory changes nothing the agent presents.

Telling agents and people apart

A service has good reasons to know when a request comes from an agent. It may set different limits for agents, such as fewer requests per minute or no deletions. It may want to show you which actions an agent took for you. And when something goes wrong, it needs to know who did what.

Delegation shows the service which client is acting. To apply an agent rule, the service also needs a trustworthy way to know that this client is an agent, such as a classification it recorded when the client registered; a client name alone does not prove it. When an agent borrows your session, the service can only guess from behavior. A request header announcing "I am an assistant" is a claim like any other: anyone can send it, and an agent that wants to pass as you can leave it out.

New protocol work is adding ways to describe and authorize agents, such as IETF drafts on client identifiers and on carrying identity across domains, and the agent cards that agent-to-agent protocols use to describe what an agent is. These are Internet-Drafts and vendor specifications, not settled standards, so check each one's status and trust model before relying on it. The foundation this lesson builds outlasts any of them: an agent with its own identity, acting with authority a person delegated to it.

Check your understanding

Try these questions before moving on. If an answer isn't right, use the feedback and try again.

The assistant uses your signed-in browser session and deletes an album. What does the photo service's record show? 1 of 3

Choose one answer.

Which arrangement lets you remove the assistant's access without changing your password or affecting your other apps? 2 of 3

Choose one answer.

The assistant is given its own account at the photo service, with access to every customer's photos, and decides for itself which customer each task is for. What is the risk? 3 of 3

Choose one answer.

Try it in the Lab

We value your privacy

We use cookies and similar technologies to enhance your browsing experience, and analytics to understand our traffic. By clicking "Allow all", you consent to optional analytics. Cookie Policy

Learn identity