SlideShare a Scribd company logo
detectify 
detectify 
SECURITY FOR DEVELOPERS
Remember the AT&T Hack? #freeweev 
detectify
…or how about the Apple Developer site! 
detectify 
incident? #down4maint
What do they have in common? 
detectify
What do they have in common? 
detectify 
IDOR #wth?
detectify 
Frans Rosén! 
@fransrosen! 
#hacktheplanet
detectify 
Co-founder #daytime
detectify 
Hacked a few #nightime 
0x09 in Google Hall of Fame! 
www.google.com/about/appsecurity/hall-of-fame/
detectify 
…a few more #uhere?
detectify 
aaand a few more #sorry
What does it mean? #owasp4 
detectify 
“A direct object reference occurs 
when a developer exposes a reference 
to an internal implementation object, 
such as a file, directory, or database 
key. ! 
! 
Without an access control check or 
other protection, attackers can 
manipulate these references to access 
unauthorized data.”
I! Insecure 
D! Direct 
O! Object 
R! Reference 
detectify 
Without proper access control 
exposing unauthorized data, 
such as a file, directory, or 
database key.
Eye-ball the URL #waitisover 
detectify
Eye-ball the URL #waitisover 
detectify 
Ouch.
detectify 
Update a user #totallylegit
detectify 
Update a user #totallylegit 
Ouch.
detectify 
Business Impact #obvious 
• Keys, Passwords! 
• Credit Card Data! 
• User Information / Email! 
• Invoices / Billing Data!
Business Impact #notsoobvious 
Numeric IDs for Order Receipts! 
! 
“Not found” vs “No access”! 
! 
Poll every day, you get analytics!! 
$$$! 
detectify
Business Impact #notsoobvious 
Numeric IDs for email invites = spam.! 
! 
! 
detectify 
Found 
by 
d4d1a179c0f3 
https://hackerone.com/reports/1533
Business Impact #evenworse 
Change Delivery Address of an order.! 
! 
Deleting another user’s information.! 
! 
Reclaiming other user’s data. Gift 
Certificates anyone? 
detectify
detectify 
Are you fully protected?
detectify 
Why so few? #ohnoez 
1. No secure access model.! 
! 
“User X should only have access to A” 
“User X that has access to A should only have access to B”! 
! 
and so on…
detectify 
Why so few? #ohnoez 
2. Numeric IDs.! 
! 
Enumerable/Sequential. Decrease value with 1 and try. ! 
! 
Easy to test. Easy to attack.
detectify 
Why so few? #ohnoez 
3. Error messages show and tell.! 
! 
“User X cannot view object owned by User Y”! 
! 
“No access to this object” ! 
! 
“Object does not exist”
detectify 
Why so few? #ohnoez 
4. Inconsequent ID sources.! 
! 
/receipt/view/434! 
! 
/receipt/?view=434! 
! 
POST /receipt/view/ HTTP/1.1! 
receipt=434
detectify 
Why so few? #ohnoez 
5. Lack of proper code review.! 
! 
How to automate this?
detectify 
Examples! #bringpopcorn
detectify 
Example – Twitter 
Credit Card deletion from other users.! 
! 
Sequential IDs when deleting cards.! 
! 
Bounty $2,800 
Found 
by 
secgeek 
(Ahmed 
Aboul-­‐Ela) 
https://hackerone.com/reports/27404
detectify 
Example – Oculus 
RCE through IDOR! 
! 
Sequential IDs when updating users.! 
! 
Bounty in total $25,000 
Found 
by 
Bitquark 
(Jon) 
https://bitquark.co.uk/blog/2014/08/31/ 
popping_a_shell_on_the_oculus_developer_portal
detectify 
Example – Square 
Update other users / Get user info! 
! 
ID as hashes, but visible using Google.! 
! 
No check if user was in another company.! 
! 
Bounty $3,000 
! https://hackerone.com/reports/23126
detectify 
Example – Zapier 
Get log-history from other user’s Zaps.! 
! 
Contained sensitive information such as 
OAuth tokens / Credentials,! 
! 
No access control for log entries.! 
! 
Bounty $3,000 
! https://zapier.com/engineering/bug-­‐bounty-­‐program/
detectify 
Example – getClouder 
Remove Cloud Scaling for other users.! 
! 
No check if user owned the Cloud 
Scaling setting.! 
! 
Bounty $200
detectify 
Example – WordPress 
Get all users on a WordPress site.! 
! 
.com/?author=1! 
! 
WONTFIX by Wordpress 
! http://hackertarget.com/wordpress-­‐user-­‐enumeration/
Doing it right. #anyoneoutthere? 
detectify
detectify 
Doing it right. #hellyeh 
1. User ID in Session or Token! 
! 
/user/view/me! 
/user/transactions
detectify 
Doing it right. #hellyeh 
2. Make generic access model and stick to it.! 
! 
function get($type, $id) { //check access for all objects }! 
! 
$user->get(‘transaction’, $id);! // if not owned by user! 
! ! ! ! ! ! ! ! // then error!!
detectify 
Doing it right. #hellyeh 
3. Access model in routes or controllers.! 
! 
Stick to it! Easy to miss.! 
!
detectify 
Doing it right. #hellyeh 
4. Code review. Don’t miss this.! 
!
Quick repetition #eatsleepraverepeat 
detectify 
1. IDORs are bad. Easy to exploit. East to find.! 
! 
2. Being actively exploited as we speak. Worth €€€! 
! 
3. Generic access model.! 
! 
4. Numeric IDs vs Hashes! 
! 
5. Review your code.
detectify 
THAT’S ALL FOLKS!! 
Questions?! 
! 
by Frans Rosén (@fransrosen) 
www.detectify.com

More Related Content

PDF
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
PDF
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
PPTX
Attacking thru HTTP Host header
PDF
Frans Rosén Keynote at BSides Ahmedabad
PDF
Live Hacking like a MVH – A walkthrough on methodology and strategies to win big
PPTX
Bug Bounty 101
PDF
Bug Bounty Hunter Methodology - Nullcon 2016
PDF
Time based CAPTCHA protected SQL injection through SOAP-webservice
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
Attacking thru HTTP Host header
Frans Rosén Keynote at BSides Ahmedabad
Live Hacking like a MVH – A walkthrough on methodology and strategies to win big
Bug Bounty 101
Bug Bounty Hunter Methodology - Nullcon 2016
Time based CAPTCHA protected SQL injection through SOAP-webservice

What's hot (20)

PDF
SSRF workshop
PDF
Offzone | Another waf bypass
PDF
Bug bounty null_owasp_2k17
PPTX
A Forgotten HTTP Invisibility Cloak
PDF
XSS Magic tricks
PPTX
Waf bypassing Techniques
PPTX
Reverse proxies & Inconsistency
PDF
Ekoparty 2017 - The Bug Hunter's Methodology
PDF
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
PDF
Building Advanced XSS Vectors
PDF
Bug Bounty - Hackers Job
PPTX
WAF Bypass Techniques - Using HTTP Standard and Web Servers’ Behaviour
PPTX
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
PDF
HTTP Request Smuggling via higher HTTP versions
PPT
Cross Site Request Forgery
PPTX
SSRF For Bug Bounties
PDF
Bug Bounty Basics
PDF
X-XSS-Nightmare: 1; mode=attack XSS Attacks Exploiting XSS Filter
PDF
The Game of Bug Bounty Hunting - Money, Drama, Action and Fame
SSRF workshop
Offzone | Another waf bypass
Bug bounty null_owasp_2k17
A Forgotten HTTP Invisibility Cloak
XSS Magic tricks
Waf bypassing Techniques
Reverse proxies & Inconsistency
Ekoparty 2017 - The Bug Hunter's Methodology
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
Building Advanced XSS Vectors
Bug Bounty - Hackers Job
WAF Bypass Techniques - Using HTTP Standard and Web Servers’ Behaviour
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
HTTP Request Smuggling via higher HTTP versions
Cross Site Request Forgery
SSRF For Bug Bounties
Bug Bounty Basics
X-XSS-Nightmare: 1; mode=attack XSS Attacks Exploiting XSS Filter
The Game of Bug Bounty Hunting - Money, Drama, Action and Fame
Ad

Viewers also liked (19)

PDF
Hackfest presentation.pptx
PDF
Writing vuln reports that maximize payouts - Nullcon 2016
PPTX
Nitor Infotech - Big Data Services
DOC
Partes del cpu
PPTX
PART OF AN ABSTRACT
PPTX
E1a1 biological explanations for criminality
PDF
CURRICULUM VITAE
PPTX
PPTX
E3c1 the job of a forensic psychologist
PDF
PPTX
Globalisation
PPTX
Sistem pengolah dataa
DOCX
Ece 214 week 2 dq 1
DOC
Youtube marketing music
PPTX
Hakla ilişkiler analiz
PDF
Lookin headhunt gold rush 成長企業様向け資料
DOCX
Importancia de la búsqueda, selección, evaluación y manejo de la información ...
PPTX
Pengenalan teknologi informasiiiiiiii
PPTX
Router
Hackfest presentation.pptx
Writing vuln reports that maximize payouts - Nullcon 2016
Nitor Infotech - Big Data Services
Partes del cpu
PART OF AN ABSTRACT
E1a1 biological explanations for criminality
CURRICULUM VITAE
E3c1 the job of a forensic psychologist
Globalisation
Sistem pengolah dataa
Ece 214 week 2 dq 1
Youtube marketing music
Hakla ilişkiler analiz
Lookin headhunt gold rush 成長企業様向け資料
Importancia de la búsqueda, selección, evaluación y manejo de la información ...
Pengenalan teknologi informasiiiiiiii
Router
Ad

Similar to How to steal and modify data using Business Logic flaws - Insecure Direct Object References (20)

PDF
Using logic flaws to steal data and how PHP can stab you in the back – Frans ...
PDF
Data security in the age of GDPR – most common data security problems
PDF
Insecure direct object reference (null delhi meet)
PDF
OWASP Top 10 A4 – Insecure Direct Object Reference
PDF
6 ways to hack your JavaScript application by Viktor Turskyi
PDF
OWASP TOP 10 by Team xbios
PPTX
InsecureDirectObjectReferences
PPTX
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
PPTX
How Secure Is Your Secure API?
PPTX
2022 APIsecure_Go Hack Yourself: API Hacking for Beginners
PDF
Astra-Security-Sample-VAPT-Report leadind auditt.pdf
PDF
JS Fest 2019. Виктор Турский. 6 способов взломать твое JavaScript приложение
PDF
dotScale 2014
PPTX
State of the information security nation
PDF
Watch How the Giants Fall
PDF
BugBounty Roadmap with Mohammed Adam
PPTX
OAuth2 Authorization Server Under the Hood
PDF
How-To Find Malicious Backdoors and Business Logic Vulnerabilities in Your Code
PDF
OWASP API Security Top 10 Examples
PDF
Testing the OWASP Top 10
Using logic flaws to steal data and how PHP can stab you in the back – Frans ...
Data security in the age of GDPR – most common data security problems
Insecure direct object reference (null delhi meet)
OWASP Top 10 A4 – Insecure Direct Object Reference
6 ways to hack your JavaScript application by Viktor Turskyi
OWASP TOP 10 by Team xbios
InsecureDirectObjectReferences
Finding Zero-Days Before The Attackers: A Fortune 500 Red Team Case Study
How Secure Is Your Secure API?
2022 APIsecure_Go Hack Yourself: API Hacking for Beginners
Astra-Security-Sample-VAPT-Report leadind auditt.pdf
JS Fest 2019. Виктор Турский. 6 способов взломать твое JavaScript приложение
dotScale 2014
State of the information security nation
Watch How the Giants Fall
BugBounty Roadmap with Mohammed Adam
OAuth2 Authorization Server Under the Hood
How-To Find Malicious Backdoors and Business Logic Vulnerabilities in Your Code
OWASP API Security Top 10 Examples
Testing the OWASP Top 10

Recently uploaded (20)

PDF
5 Lead Qualification Frameworks Every Sales Team Should Use
PPTX
Online Work Permit System for Fast Permit Processing
PPT
Introduction Database Management System for Course Database
PPTX
ai tools demonstartion for schools and inter college
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
Softaken Excel to vCard Converter Software.pdf
PPTX
Materi-Enum-and-Record-Data-Type (1).pptx
PPTX
CRUISE TICKETING SYSTEM | CRUISE RESERVATION SOFTWARE
PPTX
Essential Infomation Tech presentation.pptx
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
PDF
medical staffing services at VALiNTRY
PPTX
Safe Confined Space Entry Monitoring_ Singapore Experts.pptx
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
PPTX
Mini project ppt template for panimalar Engineering college
PPTX
ISO 45001 Occupational Health and Safety Management System
PDF
PTS Company Brochure 2025 (1).pdf.......
PPTX
Transform Your Business with a Software ERP System
PDF
System and Network Administraation Chapter 3
5 Lead Qualification Frameworks Every Sales Team Should Use
Online Work Permit System for Fast Permit Processing
Introduction Database Management System for Course Database
ai tools demonstartion for schools and inter college
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Softaken Excel to vCard Converter Software.pdf
Materi-Enum-and-Record-Data-Type (1).pptx
CRUISE TICKETING SYSTEM | CRUISE RESERVATION SOFTWARE
Essential Infomation Tech presentation.pptx
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
Which alternative to Crystal Reports is best for small or large businesses.pdf
medical staffing services at VALiNTRY
Safe Confined Space Entry Monitoring_ Singapore Experts.pptx
2025 Textile ERP Trends: SAP, Odoo & Oracle
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Mini project ppt template for panimalar Engineering college
ISO 45001 Occupational Health and Safety Management System
PTS Company Brochure 2025 (1).pdf.......
Transform Your Business with a Software ERP System
System and Network Administraation Chapter 3

How to steal and modify data using Business Logic flaws - Insecure Direct Object References

  • 2. Remember the AT&T Hack? #freeweev detectify
  • 3. …or how about the Apple Developer site! detectify incident? #down4maint
  • 4. What do they have in common? detectify
  • 5. What do they have in common? detectify IDOR #wth?
  • 6. detectify Frans Rosén! @fransrosen! #hacktheplanet
  • 8. detectify Hacked a few #nightime 0x09 in Google Hall of Fame! www.google.com/about/appsecurity/hall-of-fame/
  • 9. detectify …a few more #uhere?
  • 10. detectify aaand a few more #sorry
  • 11. What does it mean? #owasp4 detectify “A direct object reference occurs when a developer exposes a reference to an internal implementation object, such as a file, directory, or database key. ! ! Without an access control check or other protection, attackers can manipulate these references to access unauthorized data.”
  • 12. I! Insecure D! Direct O! Object R! Reference detectify Without proper access control exposing unauthorized data, such as a file, directory, or database key.
  • 13. Eye-ball the URL #waitisover detectify
  • 14. Eye-ball the URL #waitisover detectify Ouch.
  • 15. detectify Update a user #totallylegit
  • 16. detectify Update a user #totallylegit Ouch.
  • 17. detectify Business Impact #obvious • Keys, Passwords! • Credit Card Data! • User Information / Email! • Invoices / Billing Data!
  • 18. Business Impact #notsoobvious Numeric IDs for Order Receipts! ! “Not found” vs “No access”! ! Poll every day, you get analytics!! $$$! detectify
  • 19. Business Impact #notsoobvious Numeric IDs for email invites = spam.! ! ! detectify Found by d4d1a179c0f3 https://hackerone.com/reports/1533
  • 20. Business Impact #evenworse Change Delivery Address of an order.! ! Deleting another user’s information.! ! Reclaiming other user’s data. Gift Certificates anyone? detectify
  • 21. detectify Are you fully protected?
  • 22. detectify Why so few? #ohnoez 1. No secure access model.! ! “User X should only have access to A” “User X that has access to A should only have access to B”! ! and so on…
  • 23. detectify Why so few? #ohnoez 2. Numeric IDs.! ! Enumerable/Sequential. Decrease value with 1 and try. ! ! Easy to test. Easy to attack.
  • 24. detectify Why so few? #ohnoez 3. Error messages show and tell.! ! “User X cannot view object owned by User Y”! ! “No access to this object” ! ! “Object does not exist”
  • 25. detectify Why so few? #ohnoez 4. Inconsequent ID sources.! ! /receipt/view/434! ! /receipt/?view=434! ! POST /receipt/view/ HTTP/1.1! receipt=434
  • 26. detectify Why so few? #ohnoez 5. Lack of proper code review.! ! How to automate this?
  • 28. detectify Example – Twitter Credit Card deletion from other users.! ! Sequential IDs when deleting cards.! ! Bounty $2,800 Found by secgeek (Ahmed Aboul-­‐Ela) https://hackerone.com/reports/27404
  • 29. detectify Example – Oculus RCE through IDOR! ! Sequential IDs when updating users.! ! Bounty in total $25,000 Found by Bitquark (Jon) https://bitquark.co.uk/blog/2014/08/31/ popping_a_shell_on_the_oculus_developer_portal
  • 30. detectify Example – Square Update other users / Get user info! ! ID as hashes, but visible using Google.! ! No check if user was in another company.! ! Bounty $3,000 ! https://hackerone.com/reports/23126
  • 31. detectify Example – Zapier Get log-history from other user’s Zaps.! ! Contained sensitive information such as OAuth tokens / Credentials,! ! No access control for log entries.! ! Bounty $3,000 ! https://zapier.com/engineering/bug-­‐bounty-­‐program/
  • 32. detectify Example – getClouder Remove Cloud Scaling for other users.! ! No check if user owned the Cloud Scaling setting.! ! Bounty $200
  • 33. detectify Example – WordPress Get all users on a WordPress site.! ! .com/?author=1! ! WONTFIX by Wordpress ! http://hackertarget.com/wordpress-­‐user-­‐enumeration/
  • 34. Doing it right. #anyoneoutthere? detectify
  • 35. detectify Doing it right. #hellyeh 1. User ID in Session or Token! ! /user/view/me! /user/transactions
  • 36. detectify Doing it right. #hellyeh 2. Make generic access model and stick to it.! ! function get($type, $id) { //check access for all objects }! ! $user->get(‘transaction’, $id);! // if not owned by user! ! ! ! ! ! ! ! ! // then error!!
  • 37. detectify Doing it right. #hellyeh 3. Access model in routes or controllers.! ! Stick to it! Easy to miss.! !
  • 38. detectify Doing it right. #hellyeh 4. Code review. Don’t miss this.! !
  • 39. Quick repetition #eatsleepraverepeat detectify 1. IDORs are bad. Easy to exploit. East to find.! ! 2. Being actively exploited as we speak. Worth €€€! ! 3. Generic access model.! ! 4. Numeric IDs vs Hashes! ! 5. Review your code.
  • 40. detectify THAT’S ALL FOLKS!! Questions?! ! by Frans Rosén (@fransrosen) www.detectify.com