A municipality launches an AI assistant for its public safety department. Instead of opening five screens, staff type a question in plain language and get an answer with everything the system knows.
An administrative assistant in the traffic division types: "What do we have on this person?" The assistant replies in seconds with a neat summary. It includes two arrest referrals, the neighborhood where the person is usually detained, and a line saying the medical certificate from their last detention reported injuries.
In the usual system, that assistant cannot open medical certificates. But nobody opened the certificate. The AI read it, summarized it and delivered it in a single sentence.
Nobody hacked anything. The index behind the assistant was built with a technical account that can read everything, and when it answered, nobody checked again who was asking.
That is the underlying mistake: treating AI search as a convenience feature, when in fact it is a new door to the same data. A search box is not a master key. Every result it retrieves has to pass the same permission check it would pass if someone opened the case file by hand.
In a traditional system, permissions live on the screen. If a role cannot see medical certificates, the button does not appear or the screen returns an error. The control sits at the door of each module.
AI search works differently. The most common technique is called retrieval-augmented generation, or RAG. The system splits documents into fragments, turns them into numerical representations of their meaning and stores them in an index. When someone asks a question, the index returns the fragments most similar to it, and the language model writes an answer with them.
Along that path there are no screens anymore. There are fragments. A paragraph from the medical certificate, a line from the ruling and the address captured in the referral can end up together in the same answer, without any of them passing through the door of the module it belongs to.
The index knows nothing about roles. It returns whatever resembles the question. If nobody filters by permission at retrieval time, the assistant delivers what is most relevant, which is often exactly what is most sensitive.
The OWASP project, an international reference in application security, includes this risk in its 2025 list for applications built on language models. Entry LLM08 gives unauthorized access through misaligned controls as its first example and recommends permission-aware indexes, with strict separation between groups of users.
To build the index, the easiest path is to give the process a technical account with full access. The problem appears when queries run under that same identity: the assistant answers with the technical account's permissions, not those of the person who asked.
Contexts get mixed
A single vendor may serve several municipalities, and within a municipality, departments with different legal mandates coexist: police, civic court, medical services, citizen services. If everything lives in one index without partitions, a question from one department can pull fragments from another.
OWASP describes this scenario among groups that share the same vector database. In government, that other group can be another institution.
Each piece of data on its own may be visible to the person asking, but together they reveal something no screen showed.
The US National Institute of Standards and Technology's generative AI risk profile (NIST AI 600-1) warns that these models can infer personal or sensitive information nobody gave them by stitching together pieces from different sources. The inference does harm even when it is wrong.
An address in one service report, a phone number in another and a detention schedule in a third say little on their own. A summary that puts them in one paragraph builds a profile.
Someone moves to another department, a case file is restricted, an agreement with another agency ends. If permissions were copied into the index on the day it was built, the assistant keeps answering with a snapshot of that day.
Mexico's General Law on the Protection of Personal Data Held by Obligated Parties was published as a new law in the Official Gazette of the Federation (DOF) on March 20, 2025, and applies to federal, state and municipal agencies. It does not mention semantic search, but its security duties do not depend on the technology.
Article 25 requires administrative, physical and technical security measures against unauthorized use, access or processing, "regardless of the type of system" where the data is held. A vector index is one more system.
Article 32 lists what counts as a security breach, and section III includes unauthorized use, access or processing. If an assistant summarizes for someone a piece of data their role does not allow them to see, it is hard to argue there was no unauthorized access just because nobody opened the original file.
The law also requires things that become concrete with AI:
- Duties and obligations of staff (Article 27, section II). Before turning on an assistant, you need to know what each role can see, because the assistant will either inherit that definition or ignore it.
- An inventory of personal data and processing systems (Article 27, section III, and Article 29). An assistant's index is a processing system and must appear in that inventory and in the security document.
- Proportionality (Article 19). Only data strictly necessary for the stated purpose should be processed. An assistant that brings back everything resembling the question works in the opposite direction.
- A breach log (Article 33). To log a breach you first have to detect it, and that requires knowing what the assistant retrieved and for whom.
In an earlier post we explained why role-based access is operational governance and not just an IT setting. AI does not change that conclusion. It puts it to the test.
Respecting permissions does not mean asking the assistant to "not share sensitive data." OWASP notes in entry LLM02, on sensitive information disclosure, that restrictions written into the model's instructions are not always honored and can be bypassed. The permission has to be applied before the model sees the data. Seven conditions make that possible.
- The query travels with the identity of the person asking. Not with that of the technical account that built the index. Every retrieval has to know which person, in which role and in which institution is asking.
- Permission is checked on every result. Each fragment that reaches the model must have passed the same rule it would pass if that person opened the case file. Whatever fails does not make it into the answer.
- Data carries its classification. A fragment of a medical certificate has to know it is a medical certificate. OWASP recommends tagging and classifying data in the index to control access levels. Without a tag, the filter has nothing to decide with.
- Institutions and departments stay separate. One municipality must not be able to retrieve fragments from another, and one department must not see what belongs to another unless an explicit rule allows it.
- Permissions are checked live. If someone changes departments or a case file is restricted, the very next question must be answered under the new rule, without waiting for the index to be rebuilt.
- Every retrieval leaves a trail. OWASP recommends immutable logs of retrieval activity. That makes it possible to answer which fragments were retrieved, for whom, when and with what question.
- Sensitive data requires a reason. If opening a sensitive case file requires recording a reason, asking the assistant about that file must require the same. Otherwise the assistant becomes the shortcut around the control.
There is a consequence worth accepting from the design stage: two people who ask the same question should get different answers. If the assistant answers the civic judge and the administrative assistant the same way, one of them is seeing too much or too little.
A demo of AI search is almost always run with an administrator account, which sees everything. It says nothing about permissions.
Before buying or turning on an assistant, ask for five tests with real users in different roles:
- Same question, two roles. A supervisor and a data-entry clerk ask about the same person. The answers should be different.
- Revoked permission. Remove a user's access to a case file and ask the assistant to summarize it. The answer should change immediately.
- The other institution. A user from one municipality asks about data that only exists in another. The assistant should not find it.
- The full summary. Ask for "everything there is" on a person. Check whether the result assembles a profile no screen would show in one place.
- The log. After the tests, ask for the record of what was retrieved, for whom and when. If it does not exist, none of the above could be proven in an audit.
These tests complement what we said about evaluating before go-live: a demo is not an evaluation.
In Tribuna, the platform for public safety and civic justice, 360° search finds people, vehicles, events and referrals from any screen. Results are filtered by the role of the person searching, and semantic search verifies permissions on every result. Opening a sensitive case file requires a reason, and the audit module records every read and every change in a log. The INTELLO AI assistant helps draft the narrative of events, suggests how to classify offenses and reviews the case file before it is submitted. The decision belongs to the person.
In Agora, the platform for citizen services, each municipality operates separately from the others and each department sees only what concerns it. The WhatsApp assistant only cites what is in its sources, and a judge model reviews every answer before it is sent. When it checks a property tax balance by cadastral key, it does so with the treasury's authorization and without showing the owner's data.
No platform decides on its own who should see what. That decision belongs to the institution, its departments and its data protection officer. What a well-designed system guarantees is that, once that decision is made, search and AI respect it just like any screen does.
For years, security in public systems was designed as a collection of doors: one per module, one per screen, one per report. AI search does not come in through those doors.
So the question for an institution that wants to use AI on its case files is not whether the assistant finds things well. It is whether the assistant knows, on every result, who is asking and what that person is allowed to see. If it does not, the institution did not buy a search tool. It handed out a master key.
If your institution wants to search and summarize information with AI without opening a back door to its data, see how Tribuna verifies permissions on every search result and logs every read, how Agora keeps each municipality and each department separate, or request a demo.