Skip to content
Access control Disclosed report Intermediate CVE-2020-8223

Re-Sharing allows increase of privileges

A user who receives a read-only share with re-sharing permission can re-share it and grant write access to a third party, even though the original share was read-only. The third party then gains write access and can edit existing files.

alx_il Follow

Originally disclosed on HackerOne

Medium 5.5 View original
  • Triaged in 17 days
  • Fixed in 38 days
  • Paid in 2 months
  • Disclosed after 4 months
  • User A shares a file/folder to user B with re-sharing permission, but readonly
  • User B shares this file/folder to User C (Needs the shareapi_default_permissions set to 1 (all checkmarks off in admin panel))
  • User B can add write permissions for the share to User C (User C may also be anonymous using a link)
  • User C gets write access and can edit existing files

Impact

User can get write permission on read-only shared files/folders.

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

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Impact

A user could gain write permission on read-only shared files or folders, but the issue depends on the shareapi_default_permissions setting being 1.

What the attacker needed

User A shares read-only with re-share; shareapi_default_permissions set to 1

How it was found

  1. User A shares a file or folder with User B with re-sharing permission but read-only.
  2. User B re-shares the file or folder to User C.
  3. User B adds write permissions to the share for User C.
  4. User C gains write access and can edit existing files.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

When someone shares a file with you, they can allow you to pass it on to others. This report shows that the person passing it on could also give the next person permission to edit the file, even though the original share was only for viewing. That means the original owner's restriction was not respected.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More from Nextcloud

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.