Skip to content
IDOR Disclosed report Beginner

Получение предложенных фотографий паблику

pisarenko Follow

Originally disclosed on HackerOne

Bounty$200 Medium View original
  • Triaged in 1 hour
  • Fixed in 10 months
  • Paid in 10 months
  • Disclosed after 13 months
## Summary by the program

Просмотр предложенны�
 фотографий в паблика�
.

## Summary by the researcher

Обычным перебором id фото мы со�
роним все фото к себе в альбом паблика 

Нужен аккаунт "А" с которого предлагаются фото в паблик и скопируйте ссылки на фото 
Передайте и�
 аккаунту "Б" , на котором перейдите к уязвимости и вставьте индификаторы фотографии в поля и нажмите ***********. 

__ФОТОГРАФИИ С АККАУНТА "А"  ПРЕДЛАГАЕМЫЕ ПАБЛИКУ СОХРАНЯТЬСЯ НА АККАУНТ "Б" 
(не имеющему доступ к фото)__

Или просто возьмите последнее фото в паблике где photo_id будет например 123456 и прибавляйте по единицы и нажимайте выполнить , все фотографии будут со�
раняться если существуют 123457 123458 123459 и т.д

Странно , что вк заплатило 200$ вместо 300$ как предыдущего моего репорта с такой же проблемой https://hackerone.com/reports/106179

███████████████████████████
███████▀▀▀░░░░░░░▀▀▀███████
████▀░░░░░░░░░░░░░░░░░▀████ 
███│░░░░░░░░░░░░░░░░░░░│███ 
██▌│░░░░░░░░░░░░░░░░░░░│▐██ 
██░└┐░░░░░░░░░░░░░░░░░┌┘░██ 
██░░└┐░░░░░░░░░░░░░░░┌┘░░██ 
██░░┌┘▄▄▄▄▄░░░░░▄▄▄▄▄└┐░░██ 
██▌░│██████▌░░░▐██████│░▐██ 
███░│▐███▀▀░░▄░░▀▀███▌│░███ 
██▀─┘░░░░░░░▐█▌░░░░░░░└─▀██ 
██▄░░░▄▄▄▓░░▀█▀░░▓▄▄▄░░░▄██ 
████▄─┘██▌░░░░░░░▐██└─▄████
█████░░▐█─┬┬┬┬┬┬┬─█▌░░█████
████▌░░░▀┬┼┼┼┼┼┼┼┬▀░░░▐████ 
█████▄░░░└┴┴┴┴┴┴┴┘░░░▄█████
███████▄░░░░░░░░░░░▄███████ 
██████████▄▄▄▄▄▄▄██████████ 
███████████████████████████

The original report as published on HackerOne, by pisarenko. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 4 min read.

Context

VK.com lets a public page (a "public" or community) receive photographs that users suggest for it. A user who wants to contribute a photo to a public page proposes it, and the page's administrators decide whether to publish it. The feature therefore has two sides: the account that proposes a photo, and the public page that receives the proposal. The report is about the second side being able to pull in photos it was never offered.

The program summarised the issue in one line: viewing suggested photographs in public pages. The researcher's own summary is that by ordinary enumeration of photo ids, all photos can be saved into the public page's own album.

Setup

Two accounts are needed:

  1. An account "A" that proposes photos to a public page. The researcher asks you to copy the links to those photos.
  2. An account "B" that does not have access to those photos. This is the account on which the vulnerable action is performed.

No tools, versions or specific endpoints are given in the report. The identifiers used are photo ids, and the vulnerable action is described as pasting those identifiers into fields and pressing a button whose label is redacted in the report.

Finding it

The suggested-photos feature of a public page accepts photo identifiers supplied by the person operating the page and saves the corresponding photos into the page's album. The photos being saved did not belong to account "B" and account "B" had no access to them. In other words, the operation that moves a photo into the page album could be pointed at photo ids beyond the ones proposed, including consecutive ids.

Exploitation

Step 1: obtain photo ids from account "A"

With account "A", propose photos to the public page and copy the links to those photos. The report does not show the request that performs the proposal, only the instruction to collect the links.

Step 2: hand the ids to account "B"

Pass the copied links to account "B". Account "B" has no access to the photos themselves; it only has their identifiers.

Step 3: submit the ids on the vulnerable screen

On account "B", open the vulnerable screen, paste the photo identifiers into the fields and press the button. The report redacts the button label, so the exact action name is not available here.

The result, as the researcher states it in capitals, is that photographs from account "A" that were proposed to the public page are saved to account "B", which has no access to the photos.

Step 4: enumerate instead of collecting links

The researcher offers a shortcut that removes the need for account "A" altogether. Take the last photo in a public page, whose photo_id is, for example, 123456, add one to it each time, and press execute. Every photo that exists will be saved: 123457, 123458, 123459 and so on.

Text
123456
123457
123458
123459

Because photo ids are sequential, a page operator can walk the id space and save photos whose ids exist, without being offered them.

Root cause

The report does not describe the server-side code, so the following is inferred from behaviour. The action that moves a suggested photo into the page album appears to trust the photo identifier supplied by the client and to check only that the photo exists, not that it was actually proposed to this page or that the acting account is entitled to see it. Authorisation is therefore tied to the page operator's role rather than to the relationship between the photo and the page. Sequential ids make the gap easy to exploit at scale.

Impact

An account that operates a public page can copy photos into the page album even when it has no access to them, including photos proposed to the page by another user and, through id enumeration, photos with consecutive ids. The program classified the issue as medium severity information disclosure and paid a bounty of 200 USD. The researcher notes that a previous report of his with the same problem received 300 USD.

Fix

The fix that follows from the behaviour is to bind the operation to the proposal: accept only identifiers that are present in the page's pending suggestions for the acting account, and verify on the server that the acting account may view the photo before saving it. Client-supplied ids should never be the sole basis for the copy.

Variants to test

  1. Submit an id that was never proposed to the page and see whether it is still saved. A positive result is the photo appearing in the page album.
  2. Submit ids belonging to a different account that has no relationship with the page. A positive result is the photo being copied despite the lack of access.
  3. Walk sequential ids from a known photo id and record how many existing ids are accepted. A positive result is a run of successful saves for consecutive ids.
  4. Repeat the same submission from an account that does not administer the page. A positive result is the copy succeeding without the operator role.

Hunting notes

This kind of bug hides in moderation and curation features: suggestion queues, approval screens, "add to album" actions and anything that takes an object id from the client and moves or links the object elsewhere. During recon, look for features where a page or group can accept content from other users, then check whether the accept action validates the relationship between the object and the destination rather than just the object's existence. Sequential numeric ids are the signal that enumeration will work once the check is missing. The researcher showed impact by using two accounts, one that proposed the photos and one with no access, and by demonstrating that the second account could save the first account's photos; the program accepted the report and paid a bounty.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 8 min read.

What happened, in plain words

VK.com is a social network. On it, a public page (VK calls it a "public" or a "community") can receive photographs that ordinary users suggest for it. Think of it like a suggestion box in a shop: anyone can drop a photo into the box, and the shop's staff decide whether to put it on the wall. The feature has two sides: the person who proposes a photo, and the public page that receives the proposal.

This report is about the second side. The researcher found that the screen a page operator uses to look at suggested photos would accept photo identifiers typed into it, including ones beyond those actually proposed. The page would then save the matching photo into its own album, even though the operator had no access to that photo. The program summarised the issue in one line: viewing suggested photographs in public pages. The researcher's own summary is that by ordinary enumeration of photo ids, all photos can be saved into the public page's own album.

"Enumeration" here simply means trying one number after another: 1, 2, 3 and so on. Photo ids on VK are sequential numbers, so if you know one id you can guess the next ones. That is what makes the missing check easy to abuse at scale.

Setting up two accounts

To see the problem you need two accounts, because the whole point is that one account can reach another account's photos.

  1. An account "A" that proposes photos to a public page. The researcher asks you to copy the links to those photos.
  2. An account "B" that does not have access to those photos. This is the account on which the vulnerable action is performed.

The report gives no tools, no software versions and no specific web addresses (endpoints). The only identifiers involved are photo ids. The vulnerable action is described as pasting those identifiers into fields and pressing a button whose label is redacted in the report.

Finding it

The researcher noticed that the suggested-photos feature of a public page would accept photo identifiers supplied by the person operating the page, and would save the corresponding photos into the page's album. The photos being saved did not belong to account "B", and account "B" had no access to them.

In plain terms: the operation that moves a photo into the page album could be pointed at photo ids beyond the ones actually proposed. A useful comparison is a cloakroom ticket. Normally the attendant only hands back the coat whose ticket you were given. Here the attendant hands back any coat whose number you say out loud, without checking that the coat was ever left for you.

Exploitation

Step 1: obtain photo ids from account "A"

With account "A", propose photos to the public page and copy the links to those photos. The report does not show the request that performs the proposal, only the instruction to collect the links. The reason for this step is to have a set of real, known photo ids that belong to someone else, so that later you can prove account "B" can reach them.

Step 2: hand the ids to account "B"

Pass the copied links to account "B". Account "B" has no access to the photos themselves; it only has their identifiers. This is the important part of the setup: account "B" is deliberately kept in the dark about the photos, so that anything it manages to save is clearly unauthorised.

Step 3: submit the ids on the vulnerable screen

On account "B", open the vulnerable screen, paste the photo identifiers into the fields and press the button. The report redacts the button label, so the exact action name is not available here.

The result, as the researcher states it in capitals, is that photographs from account "A" that were proposed to the public page are saved to account "B", which has no access to the photos.

Step 4: enumerate instead of collecting links

The researcher offers a shortcut that removes the need for account "A" altogether. Take the last photo in a public page, whose photo_id is, for example, 123456, add one to it each time, and press execute. Every photo that exists will be saved: 123457, 123458, 123459 and so on.

Text
123456
123457
123458
123459

Line by line: 123456 is the id of a photo you can already see, used as a starting point. 123457 is the next number, which probably belongs to a different photo. 123458 and 123459 continue the run. You type each one into the field and press execute; if a photo with that id exists, it is saved into the page album.

Because photo ids are sequential, a page operator can walk the id space and save photos whose ids exist, without being offered them. The reason this works is that the server never asks whether the photo was proposed to this page or whether the operator is allowed to see it.

Root cause

The report does not describe the server-side code, so the following is inferred from behaviour. The action that moves a suggested photo into the page album appears to trust the photo identifier supplied by the client and to check only that the photo exists, not that it was actually proposed to this page or that the acting account is entitled to see it. Authorisation is therefore tied to the page operator's role rather than to the relationship between the photo and the page. Sequential ids make the gap easy to exploit at scale.

"Authorisation" is the part of a system that decides whether a given user is allowed to do a given thing. Here the system checked "is this person an operator of some page?" but not "is this photo connected to this page, and may this person see it?".

Impact

An account that operates a public page can copy photos into the page album even when it has no access to them, including photos proposed to the page by another user and, through id enumeration, photos with consecutive ids.

The program classified the issue as medium severity information disclosure and paid a bounty of 200 USD. The researcher notes that a previous report of his with the same problem received 300 USD.

"Information disclosure" means information that should have stayed out of reach becomes reachable. "Medium severity" is the program's own rating of how serious the issue is. A "bounty" is the money a bug bounty program pays for a valid report.

Fix

The fix that follows from the behaviour is to bind the operation to the proposal: accept only identifiers that are present in the page's pending suggestions for the acting account, and verify on the server that the acting account may view the photo before saving it. Client-supplied ids should never be the sole basis for the copy.

"Client-supplied" means the value came from the user's browser rather than from the server's own records. A server should treat such values as untrusted input and check them against what it knows.

Variants to test

  1. Submit an id that was never proposed to the page and see whether it is still saved. A positive result is the photo appearing in the page album.
  2. Submit ids belonging to a different account that has no relationship with the page. A positive result is the photo being copied despite the lack of access.
  3. Walk sequential ids from a known photo id and record how many existing ids are accepted. A positive result is a run of successful saves for consecutive ids.
  4. Repeat the same submission from an account that does not administer the page. A positive result is the copy succeeding without the operator role.

Hunting notes

This kind of bug hides in moderation and curation features: suggestion queues, approval screens, "add to album" actions and anything that takes an object id from the client and moves or links the object elsewhere. During recon, look for features where a page or group can accept content from other users, then check whether the accept action validates the relationship between the object and the destination rather than just the object's existence. Sequential numeric ids are the signal that enumeration will work once the check is missing. The researcher showed impact by using two accounts, one that proposed the photos and one with no access, and by demonstrating that the second account could save the first account's photos; the program accepted the report and paid a bounty.

"Recon" (reconnaissance) is the early stage of testing where you look around a product to see what features exist and how they behave. "Moderation and curation features" are the parts of a site where content is reviewed, approved or organised, such as a queue of pending suggestions.

Glossary

  • API: a way for one piece of software to talk to another, like a service counter where you hand over a request and get a response back.
  • Authorisation: the check that decides whether a particular user is allowed to perform a particular action.
  • Bounty: money paid by a bug bounty program for a valid security report.
  • Bug bounty program: an arrangement where a company invites outside researchers to report security problems and pays for the useful ones.
  • Client: the user's side of a system, usually the browser, as opposed to the server.
  • Community / public page: a VK page that many users can follow and contribute content to.
  • Endpoint: a specific address on a server that accepts a particular kind of request.
  • Enumeration: trying values one after another, such as consecutive numbers, to find the ones that exist.
  • Information disclosure: a flaw where information that should be out of reach becomes reachable.
  • Medium severity: a rating of how serious a security issue is, in this case the program's own classification.
  • Photo id: the unique number that identifies a photo on the site.
  • Recon: reconnaissance, the early looking-around phase of security testing.
  • Redacted: removed or hidden from the published text.
  • Request: a message a browser sends to a server asking it to do something or return something.
  • Root cause: the underlying reason a vulnerability exists, as opposed to its visible symptom.
  • Sequential ids: identifiers that increase by one each time, so the next one can be guessed.
  • Server: the computer that stores data and answers requests from browsers.
  • Suggested photos: photos that users propose to a public page, which the page's administrators may then publish.
  • Vulnerability: a weakness in a system that lets someone do something they should not be able to do.

More by pisarenko

View all

29 more disclosed reports, best first.

More from VK.com

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Insecure direct object reference (IDOR)

The lesson behind this report.

One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.