The student who could see other people’s documents

An application let students access their personal documents.

Access required a username and password. Each student had an account and could not sign into anyone else’s.

One student discovered that they could view documents belonging to other users without knowing their passwords or accessing their accounts.

How could they access someone else’s documents if the application required them to sign in?

How to solve the cases
A personal document open in a browser next to numbered folders

Hints

Reveal them one at a time, only when you need them.

Solution

The application checked that the student had signed in, but never checked whether the student was allowed to view the requested document. That let them read other people’s files.

What happened?

The application identified each document by a number in its URL.

A student could view their own document at an address like this:

https://centro.example/documentos/125

Changing the last number let them request a different document:

https://centro.example/documentos/126

The server checked the student’s session without checking ownership or authorisation for the requested document.

If the document existed, the server could return it even if someone else owned it.

This vulnerability is called IDOR (Insecure Direct Object Reference). It occurs when an application uses identifiers to retrieve resources without properly checking the requester’s permissions.

How could it have been prevented?

Check the user’s permission on every document request.

After verifying the session, the server also needs to verify access to that particular resource.

Hard-to-guess identifiers make other files harder to discover, but do not replace authorisation checks.

Further reading

Have a story worth investigating?

Suggest a case

A project by Eniun

How do you solve the cases?

Each case presents a mystery that seems to defy explanation.

A moderator who knows the solution reads the mystery to the group. The group works out what happened by asking questions, discussing hypotheses and using what they know.

You can project the case on a screen so everyone can read it and refer back to it during the discussion.

The moderator can guide the discussion without giving away the answer. If the group gets stuck, each case offers three graded hints under “Hints”, which can be revealed one at a time.

Once the moderator confirms that the group has found the answer, select “Show answer” to open the solution.

You can also solve the cases on your own: read the story, try to come up with an explanation and use the hints only when you need them.