Chapter 10 — Security considerations

Status: Normative


This chapter specifies the threat model for AAEP, the security guarantees the protocol does and does not provide, and the mitigations available to producers, subscribers, and operators. Security is treated as a first-class concern because AAEP carries information that can authorize side-effecting and irreversible actions; weakness here directly translates to user harm.

Implementers building AAEP support for safety-critical or regulated workflows (financial transactions, medical decisions, legal actions, infrastructure control) MUST read this chapter and the dispute resolution procedures in governance/SECURITY.md before deployment.

10.1 Security model and trust boundaries

AAEP is a peer protocol between a producer and one or more subscribers. The trust relationship between these parties is established outside the protocol, typically by:

AAEP itself does not authenticate parties. The protocol assumes that the transport layer, the operating system, or organizational policy establishes trust. AAEP then adds protocol-level mechanisms (reply tokens, signed manifests, blocking contract) that depend on that established trust for safety.

A consequence: an AAEP deployment is only as secure as the transport and identity infrastructure carrying it. A producer reachable over an unauthenticated public HTTP endpoint cannot be trusted; an AAEP-conformant implementation will not by itself fix that.

10.1.1 Within-host trust

For local-IPC transports (Windows named pipes, Unix domain sockets, stdio), trust is established by the operating system. The producer is a process owned by a user account; the subscriber is another process. The two parties trust each other to the extent that the OS isolates user accounts and process privileges.

For these deployments, AAEP's security model is straightforward: anyone with the same user account as the producer can connect; anyone without cannot. Filesystem permissions on the socket or named pipe enforce this.

10.1.2 Cross-host trust

For network transports (HTTPS/SSE, WSS, gRPC over TLS), trust is established by TLS plus an additional authentication layer (Bearer tokens, mutual TLS certificates, signed JWS messages). AAEP does not specify which mechanism; implementations choose based on their organizational context.

The minimum requirement for production cross-host deployments is TLS 1.2 (with TLS 1.3 RECOMMENDED) plus subscriber authentication. Producers MUST refuse subscriptions from unauthenticated subscribers in cross-host deployments.

10.1.3 User-to-subscriber trust

The user's trust in their subscriber is established outside AAEP. The user installs Narrator, NVDA, JAWS, VoiceOver, or another assistive technology and configures it; that configuration includes trusting the AT to act on the user's behalf.

AAEP-conformant subscribers MUST honor this trust:

A subscriber that violates user trust through any of the above is non-conforming, regardless of its technical correctness on other dimensions.

10.2 Threat model

The threat model below enumerates the specific threats AAEP addresses, the assumed capabilities of the attacker, and the mitigations the protocol provides. Threats not listed here are out of scope; implementers requiring additional protections must add them in the transport or application layer.

10.2.1 Assumed attacker capabilities

The threat model assumes a malicious actor with one or more of these capabilities:

  1. Network observer. Can read traffic between producer and subscriber if the transport is unencrypted.
  2. Network injector. Can inject or modify traffic if the transport is unauthenticated.
  3. Compromised subscriber. A malicious or compromised subscriber that participates in the protocol but pursues malicious goals.
  4. Compromised producer. A malicious or compromised producer that emits events designed to mislead users.
  5. Local process attacker. A process running on the same host that does not have the same privileges as the legitimate producer or subscriber.
  6. Replay attacker. Can capture and later replay valid messages.

The threat model does NOT assume:

10.2.2 Specific threats and mitigations

Each numbered threat below states the attack, the AAEP-level mitigation, and any additional defense-in-depth recommendations.

Threat T1: Forged confirmation reply

Attack: An attacker sends a confirmation.reply message containing a valid reply_token (obtained through some means), causing the producer to perform a confirmed action that the user did not actually authorize.

Why this matters: This is the highest-impact attack on AAEP. A successful forged reply directly authorizes a side-effecting action.

AAEP-level mitigation:

Defense in depth:

Threat T2: Replay attack

Attack: An attacker captures a valid confirmation.reply message and replays it later to cause the producer to repeat the confirmed action.

AAEP-level mitigation:

Defense in depth:

Threat T3: Confirmation phishing

Attack: A malicious or compromised producer emits a confirmation event whose action and consequence strings misrepresent what the agent will actually do. The user, reading the confirmation, accepts in good faith; the producer then performs a different action.

AAEP-level mitigation:

Defense in depth:

Threat T4: Denial of service via event flooding

Attack: A malicious or buggy producer floods a subscriber with events at a rate exceeding the subscriber's processing capacity, causing the subscriber to drop events, freeze, or crash.

AAEP-level mitigation:

Defense in depth:

Threat T5: Information disclosure via event content

Attack: A producer emits an event containing personally identifiable information (PII), credentials, secrets, or other sensitive data that should not be in the event payload. A network observer or compromised subscriber gains access to that data.

AAEP-level mitigation:

Defense in depth:

Threat T6: Producer impersonation

Attack: An attacker stands up a producer that pretends to be a known, trusted producer (using the same agent_id, agent_name, etc.) but performs malicious actions or extracts user data.

AAEP-level mitigation:

Defense in depth:

Threat T7: Malicious extension

Attack: An attacker publishes an AAEP extension that, when adopted by subscribers, causes them to disclose data, accept unsafe defaults, or be vulnerable to other attacks.

AAEP-level mitigation:

Defense in depth:

Threat T8: Subscription hijacking

Attack: An attacker uses some side channel to obtain a subscription_id and inject events or replies onto that subscription, masquerading as the legitimate party.

AAEP-level mitigation:

Defense in depth:

10.3 Authentication and authorization

AAEP does not specify a single authentication mechanism. The choice depends on transport, deployment context, and organizational policy. The following mechanisms are RECOMMENDED:

10.3.1 Transport-level authentication

For TLS-based transports (HTTPS/SSE, WSS, gRPC):

For local-IPC transports:

For stdio JSON-RPC:

10.3.2 Authorization

Authorization is the question of whether an authenticated party is allowed to perform a specific action (subscribe, reply to a confirmation, request renegotiation). AAEP does not specify an authorization model; the producer applies its own policy.

Recommended pattern: associate each authenticated subscriber identity with a role (e.g., accessibility_consumer, auditor, admin). Map roles to AAEP capabilities (e.g., accessibility_consumer can subscribe and reply; auditor can subscribe in read-only mode; admin can additionally view internal state).

10.4 Signed producer manifests

At Conformance Level 3, producers MAY cryptographically sign their manifests using JSON Web Signature (JWS, RFC 7515). A signed manifest gives subscribers proof that the manifest was issued by the holder of a specific private key, enabling defense against producer impersonation.

10.4.1 Signing procedure

The producer:

  1. Generates a JSON manifest per Chapter 5 §5.10.
  2. Constructs a JWS with the manifest as the payload, the producer's signing key, and alg: ES256 or alg: RS256 (others permitted; ES256 RECOMMENDED for new keys).
  3. Includes the JWS in the subscription.accepted message's signed_manifest field, OR makes the JWS-wrapped manifest available at the manifest URI.

10.4.2 Verification procedure

The subscriber:

  1. Receives the signed manifest (inline or by dereferencing the manifest URI).
  2. Identifies the signing key, either from a kid (key ID) in the JWS header that resolves to a known key, or via a key included in the JWS header (with appropriate trust evaluation), or from a separately-managed key directory.
  3. Verifies the JWS signature.
  4. Verifies the manifest's agent_id matches the agent_id claimed in subscription.accepted.
  5. Verifies the manifest's claims (supported transports, conformance levels, languages) are consistent with what the producer is offering on this subscription.

10.4.3 Key management

AAEP does not standardize key distribution. Implementers may use:

The choice depends on deployment context. The conformance test suite verifies that signed manifests are valid JWS but does not enforce a specific key distribution mechanism.

10.5 Privacy considerations

AAEP carries information about agent activity, including potentially-sensitive content. Implementers MUST consider:

10.5.1 Event content sensitivity

Event payloads may include:

This content may be confidential, sensitive, or regulated. Producers MUST consider the privacy implications of every field they populate. The principle of data minimization applies: include only what is necessary for the subscriber to fulfill its purpose.

10.5.2 Logging and retention

Subscribers and infrastructure intermediaries (proxies, observability platforms) may log AAEP events. Implementers SHOULD:

10.5.3 Cross-subscriber leakage

When a producer has multiple subscribers, events emitted to one subscriber are observable by all that match the filters. Producers MUST consider whether sensitive content should be filtered per subscriber identity. For example, an auditor subscription might receive full PII while an accessibility_consumer subscription receives only summary data.

This is implemented by tailoring event_filters and per-subscriber summary content; AAEP supports the pattern but does not enforce it.

10.6 Security audit recommendations

Before deploying AAEP to production with safety-critical actions, organizations SHOULD conduct a security audit covering:

  1. Transport security: TLS version, cipher suites, certificate validation, mTLS configuration.
  2. Authentication: Identity provider, token validation, key rotation policy.
  3. Authorization: Mapping of authenticated identities to AAEP capabilities.
  4. Confirmation flow review: Verify default_decision is correct per Chapter 6 §6.4.1 for every action type.
  5. Producer manifest: Verify signed manifest if Level 3; verify accuracy of claimed capabilities.
  6. Extension review: Audit all AAEP extensions used for spec quality and threat model.
  7. Logging and retention: Verify logs do not retain sensitive content beyond necessity.
  8. Conformance test results: Run the conformance suite and review the report.

Organizations operating in regulated industries SHOULD additionally:

10.7 Vulnerability disclosure

The AAEP project follows a responsible disclosure process for security vulnerabilities in the specification or reference implementations. See governance/SECURITY.md for the disclosure process, contact addresses, and response commitments.

Implementers SHOULD subscribe to the AAEP security advisory channel (linked from governance/SECURITY.md) to receive notifications of relevant vulnerabilities.

10.8 Where to go next

Readers should now proceed to Chapter 11 (Internationalization), which specifies how AAEP handles languages, locales, character encoding, right-to-left text, and culturally-sensitive content.

Implementers preparing security review documentation should additionally consult governance/SECURITY.md for the disclosure process.