All articles

Practical guide · AI agents

AI agents in business: what must be settled before granting real access

A language model that only suggests text is constrained. An agent with access to email, CRM, files, browsers or code can change real state. The prompt is therefore not the security model; the architecture around the model, tools and approvals is.

Published: · About 14 minutes · Technical guide

Deliberately exaggerated AI-agent scene: Alexander Paulus reviews a simple workflow in front of an absurdly large approval button protected by several safeguards.
The image takes “human in the loop” literally: a harmless workflow waits behind keys, a protective cover and an absurdly large approval button. In real systems, theatre is no substitute for dependable architecture.

The essentials in 60 seconds / tl;dr

  • An agent combines model decisions with tools, data access and multi-step actions. Risk comes from that combination, not only from the model.
  • Prompt injection cannot be reliably solved with a stronger system prompt alone. External content must remain untrusted data.
  • The model receives only the tools and parameters required for the task. Permissions are enforced server-side, not interpreted by the model.
  • Approvals help only when the interface displays the actual action from trusted data and the payload cannot change after approval.
  • Every production agent needs scoped identities, traceable logs, step and cost limits, a shutdown path and tests using intentionally malicious input.

Sources: NIST AI 600-1: Generative AI Profile · OWASP Top 10 for Agentic Applications · Model Context Protocol: Security Best Practices

01

When does an assistant become an agent?

“Agent” is not a uniformly protected product term. A practical security boundary is enough: agentic risk begins when an AI system selects tools, plans multiple steps or reads and changes external state.

A text draft is easy to discard. A sent message, deleted file, changed order or triggered payment is a real state transition. The organisation remains responsible even when the model proposed the call.

Answer

The model creates text and a person transfers it deliberately.

Tool call

The model proposes a structured action and the application validates it.

Workflow

Several steps run with defined state, limits and hand-offs.

Autonomy

Actions may execute without individual approval inside narrow boundaries.

Sources (3)

02

Prompt injection is a trust problem, not a text problem

An agent reads email, webpages, documents, tickets and tool output. Those sources can contain instructions that did not come from the operator. If the model treats the same material as both data and authority, an attacker can redirect the agent’s goal.

An indirect injection might tell a support agent to retrieve more customer data and send it to an outside address. The wording can appear plausible. Security therefore cannot depend on making the system prompt sound more emphatic.

Common entry points

Direct user input

A user asks for bypass, disclosure or an action outside the intended purpose.

External content

A webpage, PDF, email or ticket carries embedded instructions.

Tool output

A compromised or over-trusted tool returns manipulated data.

Memory and history

Poisoned notes or earlier output influence future runs.

External content remains data. It must not expand permissions, unlock tools, change recipients or replace approval.

Sources (3)

03

Permissions are decided before the prompt

OWASP describes excessive agency as too much functionality, permission or autonomy. The strongest mitigation is structural: give the agent less power.

  • Narrow tools

    Instead of a universal database or shell tool, expose domain functions such as getOpenInvoices or draftReply.

  • Explicit parameters

    Validate IDs, tenant, recipient, amount, path and allowed values server-side. Never turn free text directly into SQL, shell or URLs.

  • Least privilege

    The technical identity can access only required resources, ideally bounded by time and task as well.

  • Tenant before model

    Derive organisation, project and data scope from the authenticated session, never from model output or a document.

  • Separate read and write

    Read-only search and mutating actions are different tools and permissions. Analysis does not imply write access.

  • Deny by default

    Reject unknown tools, parameters, targets and states. The model cannot creatively work around missing permission.

A good tool expresses business intent

Poor: executeHttpRequest(url, method, body)

Better: createRefundDraft(orderId, reasonCode), with no payout and with server-side tenant and status checks.

Sources (3)

04

Human in the loop protects only through a trustworthy approval

Confirmation is not magic. If the agent writes the dialog or can change parameters afterwards, the person may not be approving the action that actually runs.

  • Show concrete impact

    Display target, recipient, amount, affected records and irreversible effects from validated parameters.

  • Separate untrusted content

    Clearly mark text from email, web or documents; it must not resemble a system warning.

  • Bind the payload

    Approval applies to a hash or immutable action ID. Parameter changes require new approval.

  • Tier by risk

    Reading, drafting, internal changes, external communication, payment and deletion require different thresholds.

  • Use dual control where needed

    High amounts, mass changes or sensitive exports can require a second role.

  • Expire approvals

    Do not reuse approval across tasks, tenants or later repetitions.

Anti-pattern: “The agent wants to continue. Allow?”, without the concrete action, source and impact.

Sources (2)

05

Agents need their own identities, not borrowed master keys

An agent should not inherit an administrator’s long-lived token or a global API key. Separate technical identities enable scoping, revocation and traceability.

  • Separate agent and environment

    Development, test and production, and different agents, receive distinct clients or service identities.

  • Short-lived tokens

    Keep access tokens short, store them securely and never place them in prompts, logs or error messages.

  • Validate audience

    A token must be issued for the service receiving it. MCP requires resource binding and validation when authorization is supported.

  • No token passthrough

    An MCP server must not simply forward a client token to downstream APIs; it uses the appropriate separate authorization flow.

  • Separate user and agent action

    Audit records identify the commissioning user, acting agent identity and executing service.

  • Make access revocable

    Disable a compromised agent or MCP server without stopping the entire platform.

MCP standardises how context and tools are exposed. It does not make a tool trustworthy. Operators still assess server provenance, tool descriptions, permissions, token flow and changes.

Sources (3)

06

Memory and data access need ordinary database-grade isolation

Persistent memory makes agents useful but creates a durable attack surface. False or malicious entries can influence many future runs and cross tenant or project boundaries.

Scope at write time

Attach organisation, project, user, source, purpose and expiry from a trusted application layer.

Preserve provenance

Record whether a fact came from a system of record, user text, model inference or outside content.

No secrets as memory

Passwords, tokens and private keys belong in secret stores, not vector databases or chat history.

Correction and deletion

Entries must be discoverable, correctable and deletable under applicable rules.

Constrain retrieval

Filter by scope and authorization before semantic search; similarity is not access control.

Inferences expire

Summaries and preferences need freshness rules and are not immutable truth.

Sources (2)

07

Without evidence, an agent is difficult to control in production

A full prompt transcript is not always appropriate and is not sufficient. Good observability connects business events to technical decisions while minimising unnecessary content logging.

  • Correlation

    Task, model calls, tool calls, approvals and result share a run ID.

  • Structured tool logs

    Record tool, validated parameter class, actor, scope, result, duration and error code; redact sensitive values.

  • Decision evidence

    Retain policy decisions, approval ID, model and prompt version and data sources.

  • Limits

    Bound steps, runtime, cost, data volume, recipients and retries per task.

  • Shutdown and recovery

    Stop running agents, revoke tokens, block jobs and roll back reversible actions.

  • Evals and adversarial tests

    Test success, misuse, indirect injection, compromised tools, scope switching and incomplete data before release.

The most useful production metric is not autonomous step count. Correct outcomes, blocked policy violations, required interventions and cleanly aborted runs matter more.

Sources (3)

08

The controlled-autonomy ladder

Autonomy should be decided per action type, not as one global agent setting. A system can read invoices autonomously, draft replies and still never release a payout without approval.

LevelWhat the agent may doSuitable for
1 · ObserveRead, classify and cite sources only.Search, analysis, summarisation.
2 · PrepareCreate drafts and structured action proposals.Email draft, ticket proposal, change plan.
3 · Act after approvalExecute an exactly bound action after informed confirmation.External message, status change, bounded booking.
4 · Bounded autonomyOnly predefined, reversible and monitored actions inside hard limits.Classification, routing, harmless standard corrections.

Expand a level only when evidence shows that task quality, refusals, failure modes, shutdown and recovery are under control. A stronger model release alone is not an approval criterion.

Sources (3)

09

The 12-point production checklist

Before the first write access, none of these should be answered with “it is in the prompt”.

  • Document business purpose, allowed actions and explicitly forbidden actions.
  • Classify data sources by trust and sensitivity.
  • Separate external content technically from control instructions.
  • Expose narrow typed tools instead of universal interfaces.
  • Resolve tenant, user and resource scope server-side.
  • Use separate short-lived agent identities and tokens.
  • Approve write, external and irreversible actions according to risk.
  • Bind approvals cryptographically or through immutable IDs to the exact payload.
  • Give memory scope, source, purpose, expiry and a deletion path.
  • Make run IDs, tool actions, policy decisions and outcomes auditable.
  • Set limits for steps, time, cost, volume and recipients.
  • Pass injection, tool manipulation, scope and recovery tests before production.
Sources (3)

10

Frequently asked questions

Is a strong system prompt enough protection?

No. It can guide behaviour but cannot replace access control, parameter validation or transaction boundaries. Security must be enforced outside the model.

Should a human approve every tool call?

No. That creates approval fatigue. Tier confirmations by impact: reading and reversible standard actions differ from payments, exports and deletion.

Is a local model automatically safer?

Local processing can reduce disclosure to an external model provider. It does not solve prompt injection, broad permissions, unsafe tools or poor approvals.

Does MCP make an agent secure?

MCP creates a common protocol for tools and context. Security still depends on server trust, authorization, token validation, tool scope, input validation and operations.

Do internal agents need the same controls?

Internal systems often contain especially sensitive data and broad permissions. A smaller audience does not imply smaller impact.

What is a sensible starting point?

Start with a narrow measurable workflow at level 1 or 2: read, cite sources and create a draft. Expand individual actions only after testing and operational evidence.

How does the EU AI Act relate?

Regardless of risk class, professional AI use has required appropriate AI-literacy measures since February 2025. Further obligations may apply depending on the use case; this article focuses on technical security.

Sources (3)

11

Sources and technical foundations

Original standards, frameworks and official guidance used for this article. Last checked on 15 August 2026.

  1. NIST AI 600-1: Generative AI Profile
  2. OWASP Top 10 for Agentic Applications
  3. OWASP: Excessive Agency
  4. OWASP: Prompt Injection
  5. Model Context Protocol: Authorization
  6. Model Context Protocol: Security Best Practices
  7. Regulation (EU) 2024/1689 (AI Act)
  8. European Commission: AI literacy Q&A

About the author

Alexander Paulus

Alexander Paulus develops and operates digital products, apps and platforms. His work with AI agents focuses on bounded permissions, local processing, traceable tools and verifiable results.

Continue reading

View all articles

Turning an AI demo flow into a dependable process?

I help with architecture, tool and MCP integration, local models, permission design and controlled adoption in existing software.

Discuss an AI use case