← All posts

Guides

How Do You Keep AI Answers Within User Permissions?

Enforce permissions before evidence reaches the model. Check document access, revocation, chat history and cached answers with a practical test matrix.

ENTERPRISE AI · KNOWLEDGE ACCESS

Keep AI answers within user permissions by checking access before company information enters the model's context. Authenticate the user, resolve the current tenant and document rights, and retrieve only authorized material. Apply the same boundary to citations, conversation history and reused answers. A prompt telling the model to keep secrets is not an access-control system.

An enterprise assistant can produce a perfectly accurate answer that the reader should never have received. A sales employee might ask about a customer and receive an internal pricing exception intended only for finance. The problem is not hallucination: the system used real information outside the employee's permitted scope.

Scope: This is a proposed application architecture and verification approach, not a security audit or a claim that Token360 implements company-document permissions. Examples are illustrative. Official sources were checked November 16, 2026; no measured security or performance results are presented.

Why doesn't company login solve document access?

Login establishes who the user is; it does not establish which company records that person may read. Employees can belong to different teams, projects, regions or customer accounts. The assistant needs an authorization decision for the content involved, not merely proof that someone has a valid company account or access to the chat interface.

Consider a shared knowledge assistant connected through a service account that can read every department's files. If retrieval uses only that service account's rights, ordinary users may receive material that their own source-system accounts cannot open. The connection can be technically successful while the access model is wrong.

Keep three permissions separate: the application's ability to connect to a source, the user's right to see a particular item, and the organization's permission to process that item with the selected model service. Satisfying one does not automatically satisfy the others.

API keys also govern a different boundary. They can authorize model calls without expressing the employee's rights to a payroll document or customer contract. Do not assume a separate key per department reproduces every source-system permission.

Where should the permission check happen?

Enforce the user's content scope in the trusted retrieval path before sending passages to the model. Filtering an answer afterward is too late to prevent unauthorized content from reaching that processing stage. Output checks remain useful as another control, but they should not replace a decision about which evidence may be retrieved and disclosed.

Microsoft's document-level access-control documentation describes both application-supplied security filters and native permission-based approaches for Azure AI Search. It distinguishes generally available filter techniques from capabilities marked preview. The relevant design principle is query-time enforcement; actual support depends on the source, API and configuration.

StageDecision to enforceCommon gap to inspect
Request identityWho is calling, in which tenant and role?Trusting an account identifier typed into a prompt
RetrievalWhich records can this user access now?Searching all documents with a broad service account
Context assemblyAre all passages authorized for this request?Adding an unrestricted summary or attachment later
Answer deliveryCan this recipient receive the answer and references?Leaking a restricted title, snippet or downloadable file
ReuseDoes the current audience still have access?Sharing a cached answer across users with different rights

Resolve identity and scope on the server from the authenticated session and trusted policy sources. A model may help phrase a search query, but it should not be able to remove the tenant filter, invent a role or promote itself to an administrator. Required constraints belong in application logic.

How do permissions survive indexing and document chunking?

Preserve the relationship between each searchable passage and the permissions of its source. Splitting a document into chunks does not make its contents public. Store or resolve the necessary access metadata for every retrieval unit, and decide how updates, inherited permissions and derived summaries remain connected to the governing source policy.

A connector that imports text but drops the original access rules creates an incomplete copy. Ask whether it supports the source's actual permission structure, including groups, inherited access and relevant exceptions. “Supports this storage platform” does not necessarily mean “preserves every permission in our deployment.”

Derived content requires attention too. A summary combining several restricted documents should not automatically receive the broadest access of any one input. Define a policy for who may see the combined result; a conservative starting point is to require access to every contributing source unless an authorized publication process produces a separately approved version.

When permissions are missing or cannot be evaluated, hold the affected content rather than treating it as public. An application can still answer from authorized sources, provided it does not imply that the available evidence is complete. Keep failure handling distinct from a genuine search with no relevant results.

What happens when an employee's access changes?

Permission changes must propagate to the assistant's retrieval, stored context and reuse paths. Removing someone from a source folder is insufficient if an index still carries old access metadata or a shared answer cache contains its contents. Define the refresh mechanism, the expected delay and the behavior during uncertainty before making a revocation claim.

Microsoft's query-time enforcement documentation notes that permission freshness depends on ingestion method and that some changes require resynchronization or reingestion. The documented feature is in preview. Use this as a concrete reminder to verify synchronization behavior, not as a universal guarantee about every retrieval product.

For a sensitive removal, the team may need to block the affected material or session until updates are confirmed. Test the actual path: change the source permission, repeat the query as the affected user, inspect retrieved evidence and check reused answers. Record the observed propagation time rather than assuming it is instantaneous.

Revocation can prevent future access through controlled systems; it cannot make a person forget an answer they already saw or erase an independent download. Distinguish those limits in procurement discussions. If broader exposure is suspected, use the organization's incident process instead of presenting index refresh as a complete remedy.

Can chat history, citations and caches bypass the boundary?

Yes, if they are treated as harmless output rather than another store of company information. A previous answer can contain restricted facts even when the next retrieval is correctly filtered. Protect conversation ownership, reassess reuse when rights change, and ensure citations or file links do not expose material outside the current recipient's scope.

Do not rely only on protecting the linked document. A citation title, excerpt or filename may itself disclose a confidential project. If the user cannot access the underlying source, decide whether any reference to it is appropriate. Avoid messages that reveal the existence of a sensitive record merely to explain a refusal.

For reuse, follow the separate AI response-caching guidance: identical question text does not imply an identical permitted answer. Tenant, access scope and source freshness can all change eligibility. Rechecking a cache entry is different from blindly trusting the rights of the user who originally created it.

Restrict operational logs and feedback exports as well. A support dashboard that exposes raw prompts and retrieved passages can undermine a carefully scoped chat interface. Review the complete information path, including administrative viewers, exports and attachments.

Three stages show verifying user identity, limiting retrieved evidence and rechecking reused or delivered information.
Proposed control map: permissions follow the information beyond the search result.

What should a practical access test include?

Run the same business question as users with deliberately different permissions, and inspect both the retrieved context and final answer. Include denied access, changed access and permission-service failures. A successful authorized-user demonstration is not evidence that unauthorized users are excluded; the negative cases are part of the acceptance test.

Use synthetic records with distinctive fictional facts rather than real confidential material. Give one test user access and another no access, then ask direct questions, paraphrases, summary requests and follow-ups. The expected result should cover passages, references and attachments, not only whether a particular sentence appears.

  • Same tenant, different teams: verify that a restricted department document stays out of the other team's context.
  • Different tenants: try overlapping customer names and similar document titles without crossing boundaries.
  • Revoked access: test a fresh query, an existing conversation and a previously generated answer.
  • Missing permission metadata: confirm that the record does not silently become available.
  • Unavailable permission service: check that the system does not fall back to unrestricted retrieval.
  • Allowed control case: ensure authorized users can still complete the task.

Record the application build, identity setup, connector configuration and evidence inspected. A clean final answer is not enough if unauthorized passages were sent to the model. Conversely, a refusal for every user may avoid exposure while making the application unusable. Both isolation and useful authorized access matter.

The blank knowledge-access test matrix is a planning aid, not an audit certificate. Repeat relevant cases when connectors, identity mappings, retrieval code or source permissions change. Select additional tests according to the sensitivity of the deployed workflow.

test_case,user_role,tenant,source_record,expected_access,permission_change,retrieved_context_checked,answer_checked,citations_checked,history_cache_checked,actual_result,observed_refresh_delay,build_connector_version,reviewer
,,,,,,,,,,,,,

Who owns these controls when using Token360?

The enterprise and its application team own the mapping between employee identity, business records and authorized model context unless a specific service contract assigns that responsibility elsewhere. Token360 provides model access across text, image, audio and video. An inference endpoint should not be assumed to know a company's document permissions simply because it receives the content.

Use the Token360 enterprise discussion to scope model access, capacity, pricing and contractual requirements. Separately document who operates the knowledge connector, permission service, index, history store and support tooling. This article does not claim that Token360 automatically synchronizes source ACLs or provides a permission-aware knowledge base.

Permission-aware retrieval also does not replace removing unnecessary data before an API call or agreeing on retention and training terms. Authorized access, necessary processing and acceptable service terms are separate checks. Company information is available in Token360's resources and About section.

Frequently asked questions

Can a system prompt enforce employee permissions?

No. A system prompt can describe desired behavior, but authorization should be enforced by trusted application and retrieval controls. Do not put unauthorized material into context and depend on the model to conceal it.

Do we need a separate model for each department?

Not necessarily. The essential requirement is an effective boundary for each request and its data. Separate models alone do not fix a shared index with missing filters. Deployment isolation may be appropriate for particular requirements, but it must be evaluated with the rest of the architecture.

Is encryption enough to prevent cross-user disclosure?

No. Encryption protects data in specified storage or transport conditions; it does not determine whether an authenticated application should retrieve a document for a particular employee. The application still needs authorization and appropriate result handling.

Should the assistant say a restricted document exists?

Only if that disclosure is permitted. In some workflows, even the title or existence of a record is sensitive. Use a response that explains the available scope without revealing restricted metadata, and provide an approved access-request route when appropriate.

  • Enterprise AI
  • API

Bring your next idea to life.

Create a video scene in Creator, or explore models for images, audio, and text to find the right capabilities for your project.

Get started