Resources
AI Knowledge Base Permissions: Keep Retrieval Authorized
Pointing an assistant at your document library does not carry that library's access rules along with it. AI knowledge base permissions have to hold at four separate points: the source repository, the retrieval layer, the derived data the pipeline creates, and the answer returned to a specific person. Most deployments secure the first point and quietly assume the other three inherit it.
By Mike Hulick, Founder, Marketing Powered

Follow permissions from source to output
Draw the path before you draw the architecture. A typical pipeline moves content through repository rights, an ingestion job, extracted text, chunks, an index or vector store, a retrieved context window, a generated answer, and finally a log. Each hop is a copy, and a copy only keeps permissions if someone deliberately carries them across.
The people involved are rarely the same at each hop. A site owner controls the source library, a platform engineer configures the indexer, an application team writes the query logic, and a business owner approves the use case. Permission loss usually happens in the gaps between those four, not inside any one of them.
Two implementation details matter more than they look. First, chunking multiplies records, so every generated chunk needs the permission metadata and source context of its parent item, which is why Microsoft's documentation instructs teams to configure chunk mappings that retain that metadata and to avoid parsing modes that split one source item into multiple logical records without a supported permission propagation contract, including JSON, CSV, plain text and Markdown specific modes (Microsoft Learn).
Second, identifiers are not authorization. The same documentation is explicit that a document key selects a record for updates or merges and is not an authorization boundary, and that the ingestion design has to establish who is allowed to assign a record's identity and grant access to its content (Microsoft Learn).
Write that map down as a diagram with owners on every hop. If no one can name the owner of the chunk-to-index step, that is the step that will fail.
Enforce identity during retrieval
Authorization belongs in the retrieval call, not in the wording of a prompt. Microsoft lists security and governance alongside query understanding, multi-source data access, token constraints and response time as core retrieval challenges, and states that users and agents must only retrieve authorized content (Microsoft Learn).
There are two broad ways to do that. Security trimming with filters stores user or group identities as a string field, then passes the caller's identity as a filter at query time so non-matching documents are excluded, which suits custom or non-Microsoft security models (Microsoft Learn).
Native permission filtering instead evaluates indexed permission metadata against a delegated user token, and the same documentation separates the application's own credential from the user token used to evaluate document permissions, noting that an application able to call search is not automatically a valid document permission subject (Microsoft Learn).
Filtering inside the search pipeline is also described as faster than loading larger result sets into the application and trimming them there (Microsoft Learn).
What does not work is instructing the model to keep secrets. OWASP describes direct and indirect prompt injection, where input, including content inside retrieved files, alters model behavior and can lead to disclosure of sensitive information or unauthorized access to functions available to the model, and notes it is unclear whether fool-proof prevention exists (OWASP).
System instructions are a useful constraint layered on top of enforcement. They are not enforcement. The same logic applies to where retrieval runs and who can see the content in transit, which is the subject of our page on data custody and processing boundaries.
Handle change, revocation and deletion
Access is not a one-time state. People change roles, contractors leave, folders get restricted, and documents get deleted, and an index built last quarter does not know any of that until something tells it.
Permission freshness behaves differently by source type. Microsoft documents that access control list changes on one supported storage source are indexed snapshots refreshed roughly daily on eligible runs or through an explicit permissions resync, that container role scopes identify resources rather than role assignments and are evaluated separately at query time with their own propagation and caching, and that group membership resolution has its own propagation behavior as well (Microsoft Learn).
For SharePoint content, incremental processing covers detected item-level changes and supported non-root folder permission changes, while other scopes or missed notifications can require an explicit refresh (Microsoft Learn).
The sentence to take to your architecture review is this one: permission refresh does not provide immediate revocation or a corpus-wide freshness service level agreement (Microsoft Learn). Where ingestion is custom, the documentation places responsibility for synchronizing permission metadata on the publisher (Microsoft Learn).
So write revocation test cases, not revocation assumptions. An illustrative set: remove a contractor from a group and time how long restricted answers persist; delete a file and query for a phrase only that file contained; move a document into a restricted folder and check descendants; and confirm that a cached or logged answer produced before the change is not replayed afterward.
Measurement discipline on retention and deletion applies to marketing data too, which we cover in Privacy First Marketing: Measurement Architecture.
Free Audit
Want a straight read on where your budget is leaking?
Review derived data, citations and logs
The index is not the only copy of your content. A retrieval system also produces embeddings, citation metadata, evaluation datasets, debug traces and chat transcripts, and each of those can carry restricted text outside the control that was supposed to protect it.
OWASP treats this directly. Inadequate or misaligned access controls can allow unauthorized access to embeddings containing sensitive information, shared vector databases in multi-tenant settings risk context leakage between classes of users, and embedding inversion attacks can recover meaningful source information (OWASP). The recommended controls are fine-grained access control with permission-aware vector and embedding stores, strict logical and access partitioning of datasets, classification and tagging of knowledge base content, and detailed immutable logs of retrieval activity (OWASP).
Make it concrete by asking four questions about every derived artifact. Who can read it today, including vendors and support staff. How long is it retained. Is it covered by the same classification as the source document. Does it get deleted when the source is deleted.
A debug log that stores retrieved passages in plain text is a second, unprotected copy of the index. Citation metadata deserves the same scrutiny, because a reference that exposes a file path, a title or a matter name can disclose the existence and subject of a restricted document without quoting a word of it.
Where the pipeline runs shapes how much of this you can inspect. Marketing Powered operates owned, local AI infrastructure for HIPAA-aware inference, which supports control and auditability over these artifacts. Ownership of infrastructure is not the same as compliance, a distinction we draw in owned AI systems and deployment boundaries.

Test misuse and leakage before go-live
Treat the assistant as an untrusted user and try to break the boundary on purpose. OWASP recommends regular penetration testing and breach simulations that test trust boundaries and access controls, segregating and clearly denoting untrusted external content, enforcing least privilege with application-held API tokens handled in code rather than exposed to the model, and requiring human approval for high-risk actions (OWASP).
Four test families cover most of the realistic failure modes. Cross-role requests: have an account with narrow scope ask, in several phrasings, for content scoped to a different role, including summaries and counts rather than full text.
Indirect injection: OWASP describes an attacker modifying a document in a repository used by a retrieval-augmented application so that returned content alters the model's output, and a separate scenario where hidden text inside a submitted file carries instructions, so your corpus needs extraction that detects hidden content (OWASP). Inference leakage: check whether the assistant confirms the existence of restricted documents through citations, file names or refusal patterns. Replay: repeat an earlier question after a permission change to catch cached results.
Record expected and actual behavior for each case, with the account used, the timestamp and the index state. That record is what you hand an auditor when someone asks how you know the system is scoped correctly. For deployments where test data cannot leave your environment, see supported local processing.
Validate implementation maturity before you commit
Vendor capability moves quickly, and preview is not production. Microsoft's documentation states that features marked preview are in public preview and subject to supplemental preview terms, while describing SharePoint access control list ingestion with query-time permission filtering, Azure Data Lake Storage Gen2 access control lists and role scopes, standard blob container role scopes and push ingestion of access control lists as generally available with the 2026-10-01 data plane REST API, and Microsoft Purview sensitivity label enforcement as remaining in preview (Microsoft Learn).
It also cautions that general availability of a REST API does not establish readiness of the software development kit packages (Microsoft Learn). Confirm status against current documentation on the day you design, because that table changes.
Then require three artifacts before go-live. A source-to-index permission diagram with an owner on every hop. A set of access-change and deletion test cases with recorded results. A documented administrative access model that names every path which bypasses user-level filtering, including service accounts and elevated read, which the documentation notes does not evaluate application group membership on a non-label-enforced index (Microsoft Learn).
One named person should own the retrieval permission design. Marketing Powered has been AI-native since 2022 and builds in regulated categories where that ownership question gets asked early. Related reading: AI governance and approval controls, open-source selection and licensing, and how configurable AI workflows are scoped.

Email Us
Prefer to send the context directly?
Questions IT and data owners ask
Can we rely on instructions telling the model not to reveal restricted files?
No. OWASP documents that prompt injection can come from the user or from external content the model reads, and that consequences include disclosure of sensitive information and unauthorized access to connected functions, with no fool-proof prevention method established (OWASP). Instructions are a hardening layer. The access decision has to happen in the retrieval query, where an identity is evaluated against permission metadata, so that unauthorized content never reaches the model.
What happens when access is revoked after indexing?
Until the index learns about the change, retrieval can still return the content. Microsoft documents refresh behavior that varies by source, including roughly daily snapshot refresh or explicit resync for one storage source and incremental processing for detected SharePoint changes, and states plainly that permission refresh does not provide immediate revocation or a corpus-wide freshness service level agreement (Microsoft Learn).
Plan for a revocation window, measure it, and decide whether sensitive collections need a forced resync step in the offboarding process.
Do embeddings and logs require access controls too?
Yes. OWASP identifies unauthorized access to embeddings, cross-context leakage in shared vector stores and embedding inversion as real risks, and recommends permission-aware vector and embedding stores, strict logical partitioning and immutable retrieval logs (OWASP). Apply the source document's classification to its derived artifacts, restrict who can read debug traces and transcripts, and include those stores in deletion workflows.
How should a small team adapt this approach?
Scale the scope, not the controls. Start with one repository and one group of users rather than the whole corpus. Use group-based access instead of per-user assignments, which the vendor documentation recommends for manageability of access-controlled content (Microsoft Learn). Replace continuous automation with a written access model, a monthly review of group membership and index scope, and a short, repeatable test script run after every change. A two-page document maintained by one accountable person beats an elaborate model nobody updates.
What evidence would change the recommended approach?
Confirmed production availability of permission-aware retrieval features in the platform you actually use, verified in current vendor documentation rather than a blog post or a sales deck, including client library support and documented refresh behavior. Evidence of a shorter and measurable revocation window would reduce the need for compensating controls. Conversely, if your source system cannot export reliable permission metadata, the honest answer is to narrow the corpus to content that is safe for the whole audience until it can.
Bring your source list, your identity model and your intended audience, and we will work through where permissions survive the pipeline and where they do not.
More Resource Topics
Ready to see where your marketing can improve?
Request a free audit of your paid media, landing pages, attribution, and measurement setup. You'll get a straight assessment of where the opportunities are.
or email us at info@marketingpowered.ai