SlideShare a Scribd company logo
1 of 41
AppSec USA2014
Denver, Colorado
CuSRF
It’s Pronounced “See You Surf” and It’s Dangerous
Barry Shteiman
• Director of Security Strategy at Imperva
• Security Researcher working with the
Imperva CTO office
• Author of several application security tools,
including HULK
• Open source security projects code
contributor
• Twitter @bshteiman
Introduction
• CSRF brief intro
• CUSRF: A close encounter with CSRF of the
third kind
 CUSRF explained
 Vulnerable applications in the wild
• Google Docs
• Linkedin.com
• Mitigations
• Summary and conclusion
Agenda
3
The Motivation:
Protecting Your ID in a Hostile
Online Environment
4
Privacy on the Web: An UphillBattle?
5
Source: www.askingsmarterquestions.com
Privacy Can Be Achieved Through Anonymity
6
Source: www.antiquaprintgallery.com
• CuSRF (pronounced “See You Surf”)
– Cross USer Request Forgery
• Web sites you visit can see your privates:
– In real-time
– Name, email, work place, title, etc.
• Potential outcomes:
– “Ice Hole Phishing”: e.g. infect only certain roles in a
specific organization.
– Display different price
– Disinformation
CuSRF Vulnerability Opens Your Social Kimono!
7
CSRF Intro
8
SOP Threat Model
9
Communication
Custom Code
Accounts
Finance
Administration
Transactions
KnowledgeMgmt
E-Commerce
Bus.Functions
Target Application
3
Vulnerable site sees legitimate
request from victim, performs
the requested action and
sends a response
Attacker sets the trap on some website on the internet1
2
While logged into vulnerable site,
victim views attacker site
Target site interaction
Some interaction
with victim site
CSRF Illustrated: “Bypassing SOP”
1
3
Attacker sets the trap on some website on the internet
(or simply via an e-mail)
1
Vulnerable site sees
legitimate request from
victim and performs the
requested action
Custom Code
Accounts
Finance
Administration
Transactions
Communication
KnowledgeMgmt
E-Commerce
Bus.Functions
Hidden <img> tag
contains attack
against vulnerable
site
Application with CSRF
vulnerability
2
While logged into vulnerable site,
victim views attacker site
<img> tag loaded by
browser – sends GET
request (including
credentials) to
vulnerable site
• The “Confused Deputy” Problem
– Web browsers automatically include access tokens with
each request
– Requests can be invoked by malicious sites from victim’s
browser without user consent
• Automatically Provided Tokens:
• Session cookie, basic authentication header, IP address,client
side SSL certificates, Windows domain authentication
CSRF
1
• The “Transfer Fund” attack
• Attacker tricks the browser into issuing a “transfer
funds” request to the attacker’s account
• “/transferFund.jsp?To=<attacker>&Sum=10000000”
CSRF Type I: ClassicCSRF
1
Attack Type Used credentials Interacts with
Classic CSRF Victim’s Victim’s web account
• The attacker mounts a CSRF attack that logs the
victim into an attacker controlled account (sink
account)
• “signin.jsp?user=<attacker>&password=123456”
• Later on, the attacker is able to track the victim’s
activity in the sink account
• e.g. log the victim to attacker’s controlled Google
account to collect search history
CSRF Type II: Login CSRF
1
• The attacker mounts a CSRF attack that logs
the victim into an attacker controlled account
(sink account)
• “signin.jsp?user=<attacker>&password=12345
6”
• Later on, the attacker is able to track the
victim’s activity in the sink account
• e.g. log the victim to attacker’s controlled
Google account to collect search history
CSRF Type II: Login CSRF
1
Attack Type Used credentials Interacts with
Classic CSRF Victim’s Victim’s web account
Login CSRF Attacker’s Attacker web account
Source: WhiteHat Security
CSRF is Very Relevant
1
CuSRF:
A Close Encounter With CSRF
of the Third Kind
16
• A new type of CuSRF, bringing CSRF to Web 2.0
environment
• “Cross USer Request Forgery” (CuSRF, pronounced
“See You Surf”) attack
• Composition of the known CSRF vulnerability types,
for collaboration environment
CSRF Type III: CuSRF
1
• “A Web 2.0 site may allow users to interact and
collaborate with each other in a social media
dialogue as creators of user-generated content in a
virtual community” (Source: Wikipedia)
Web 2.0: It’s All About Collaboration
1
Source: http://conceptart.ca
• The attacker forges collaboration requests on behalf of the
victim
– Similar to the “Classic CSRF”
• The collaboration target is located on an attacker controlled
account
– Similar to the “Login CSRF”
• Outcome: Attacker can reveal the victim’s social network
identity
CUSRF Explained
1
Attack Type Used credentials Interacts with
Classic CSRF Victim’s Victim’s web account
Login CSRF Attacker’s Attacker’s web account
CUSRF Victim’s Attacker’s web account
CuSRF in the Wild #1:
LinkedIn Profile
20
• Attacker sets up a LinkedIn account
AttackSetup: Creating a LinkedIn Profile
2
• In order to view the identity of profile visitors,
the attacker can either:
– Go “Pro”
– Make their “LinkedIn” identity available to others
AttackSetup: Settings
2
• Attacker adds an invisible CSRF link
referencing the attacker’s LinkedIn profile to
their online asset
• Asset can be:
– A “watering hole” page
– A “phishing” page
– Etc.
AttackSetup: CSRF Page
2
• When the intended target visits the CSRF
page:
– The attacker discovers his identity (“Tal Be’ery”)
instantly
• Can act accordingly:
– e.g. infect him personally with a “drive by
download“ infection
Launchingthe Attack
2
• Victim can choose to share only “profile
characteristics”
– e.g “Engineer in Imperva”
• This is the default setting
• Sometimes that’s enough information for the
attacker
Resolving “Semi Anonymous Profiles”
2
• In 2013, Linkedininsights.com had demonstrated a bypass
• Linkedin “Red Herring” Module showed list of 10 possible
“candidates” for the “Semi Anonymous Profiles”
• One was the actual person; others were just “Red Herrings”
• The problem: “Red Herrings” were randomized, actual person
was not
• Exploit: Attacker should view the “candidates” list twice and
mark the overlapping item
Resolving “Semi Anonymous Profiles”
2
A Smelly Red Herring
2
Source: www.linkedinsights.com
CuSRF in the Wild #1:
Google Docs
28
• Attacker (“honeymadhatter”)
shares her doc with targeted
account(s) (“sam.burekas”)
• Only needs to know the targets’
email
• No email is sent, as the option
can be unchecked
AttackSetup: Creating a Google Doc
2
• Attacker adds an invisible CSRF link referencing to the
attacker’s Google Doc to their online asset
• Asset can be
– A “watering hole” page
– A “phishing” page
– Etc.
• Invisible link example:
– “<script src = "https://docs.google.com/document/d/<some doc
id>/edit"></script>”
AttackSetup: CSRF Page
3
• When the intended target visits the CSRF page:
– The attacker uncovers victim’s identity (“sam.burekas”)
instantly
• Can act accordingly: e.g. infect victim with malware
Launchingthe Attack
3
Google’s Response
3
Mitigations
33
• Logout more!
• Use stricter privacy settings for vulnerable
applications
– Full anonymity for LinkedIn
• Use personal Anti CSRF add-ons to block cross-site
requests
– RequestPolicy
– CsFire
– NoScript
Consumers
3
• Use standard CSRF protections
– Don’t allow a collaboration based on a single request from
other domain
• Other domains can be determined by HTTP headers
– Referer
– Origin
Platform Providers
3
• Single request collaboration, within same domain can be
secured with a CSRF token
– Changing, un-guessable, unique identifier appended to the request
• Libraries exist to include this functionality in the code
– http://anticsrf.codeplex.com/ (.NET)
– https://www.owasp.org/index.php/Category:OWASP_CSRFGuard_Proj
ect (Java, PHP, .NET)
Platform Providers
3
Microsoft Seems to get it right
3
Summary and Conclusions
38
• CSRF vulnerabilities of various types are common within
applications
• CuSRF is a new type of CSRF that affects users of collaboration
platforms and applications
– Disclosing the true identity of a victim, when accessing an attacker
controlled application
• CuSRF can be used for fraud as well as “Ice Hole Phishing”
Summary
3
• Consumers
– Review privacy settings for collaboration platforms
• Providers
– Apply anti-CSRF mechanisms to collaboration activity
Recommendations
4
Questions? Tomatoes?

More Related Content

What's hot

Cross Site Request Forgery (CSRF) Scripting Explained
Cross Site Request Forgery (CSRF) Scripting ExplainedCross Site Request Forgery (CSRF) Scripting Explained
Cross Site Request Forgery (CSRF) Scripting Explained
Valency Networks
 
Cross Site Request Forgery Vulnerabilities
Cross Site Request Forgery VulnerabilitiesCross Site Request Forgery Vulnerabilities
Cross Site Request Forgery Vulnerabilities
Marco Morana
 
CSRF_RSA_2008_Jeremiah_Grossman
CSRF_RSA_2008_Jeremiah_GrossmanCSRF_RSA_2008_Jeremiah_Grossman
CSRF_RSA_2008_Jeremiah_Grossman
guestdb261a
 

What's hot (14)

Cross Site Request Forgery (CSRF) Scripting Explained
Cross Site Request Forgery (CSRF) Scripting ExplainedCross Site Request Forgery (CSRF) Scripting Explained
Cross Site Request Forgery (CSRF) Scripting Explained
 
Hack using firefox
Hack using firefoxHack using firefox
Hack using firefox
 
Cross-Site Request Forgery Vulnerability: “A Sleeping Giant”
Cross-Site Request Forgery Vulnerability: “A Sleeping Giant”Cross-Site Request Forgery Vulnerability: “A Sleeping Giant”
Cross-Site Request Forgery Vulnerability: “A Sleeping Giant”
 
CSRF Attack and Its Prevention technique in ASP.NET MVC
CSRF Attack and Its Prevention technique in ASP.NET MVCCSRF Attack and Its Prevention technique in ASP.NET MVC
CSRF Attack and Its Prevention technique in ASP.NET MVC
 
HallTumserFinalPaper
HallTumserFinalPaperHallTumserFinalPaper
HallTumserFinalPaper
 
Cross Site Request Forgery Vulnerabilities
Cross Site Request Forgery VulnerabilitiesCross Site Request Forgery Vulnerabilities
Cross Site Request Forgery Vulnerabilities
 
SeanRobertsThesis
SeanRobertsThesisSeanRobertsThesis
SeanRobertsThesis
 
Shiv seminar final
Shiv seminar finalShiv seminar final
Shiv seminar final
 
Understanding Cross-site Request Forgery
Understanding Cross-site Request ForgeryUnderstanding Cross-site Request Forgery
Understanding Cross-site Request Forgery
 
A simple PHP LinkedIn OAuth 2.0 example
A simple PHP LinkedIn OAuth 2.0 exampleA simple PHP LinkedIn OAuth 2.0 example
A simple PHP LinkedIn OAuth 2.0 example
 
CSRF_RSA_2008_Jeremiah_Grossman
CSRF_RSA_2008_Jeremiah_GrossmanCSRF_RSA_2008_Jeremiah_Grossman
CSRF_RSA_2008_Jeremiah_Grossman
 
Cross Site Request Forgery
Cross Site Request ForgeryCross Site Request Forgery
Cross Site Request Forgery
 
VodQA3_PenetrationTesting_AmitDhakkad
VodQA3_PenetrationTesting_AmitDhakkadVodQA3_PenetrationTesting_AmitDhakkad
VodQA3_PenetrationTesting_AmitDhakkad
 
Api security-eic-prabath
Api security-eic-prabathApi security-eic-prabath
Api security-eic-prabath
 

Viewers also liked

Managing SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk EnterpriseManaging SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk Enterprise
Splunk
 

Viewers also liked (14)

Pöyry ICS Cyber Security brochure (English)
Pöyry ICS Cyber Security brochure (English)Pöyry ICS Cyber Security brochure (English)
Pöyry ICS Cyber Security brochure (English)
 
The 4horsemen of ics secapocalypse
The 4horsemen of ics secapocalypseThe 4horsemen of ics secapocalypse
The 4horsemen of ics secapocalypse
 
RSAC 2016: How to Get into ICS Security
RSAC 2016: How to Get into ICS SecurityRSAC 2016: How to Get into ICS Security
RSAC 2016: How to Get into ICS Security
 
Managing SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk EnterpriseManaging SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk Enterprise
 
MT81 Keys to Successful Enterprise IoT Initiatives
MT81 Keys to Successful Enterprise IoT InitiativesMT81 Keys to Successful Enterprise IoT Initiatives
MT81 Keys to Successful Enterprise IoT Initiatives
 
2016 m2 m_forum_industrie4_cybersecurity_tieghi
2016 m2 m_forum_industrie4_cybersecurity_tieghi2016 m2 m_forum_industrie4_cybersecurity_tieghi
2016 m2 m_forum_industrie4_cybersecurity_tieghi
 
Cyber Security resilience - what's in a number? The real threat to industrial...
Cyber Security resilience - what's in a number? The real threat to industrial...Cyber Security resilience - what's in a number? The real threat to industrial...
Cyber Security resilience - what's in a number? The real threat to industrial...
 
Managing SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk EnterpriseManaging SCADA Operations and Security with Splunk Enterprise
Managing SCADA Operations and Security with Splunk Enterprise
 
Managing and Securing Remote Access To Critical Infrastructure, Yariv Lenchne...
Managing and Securing Remote Access To Critical Infrastructure, Yariv Lenchne...Managing and Securing Remote Access To Critical Infrastructure, Yariv Lenchne...
Managing and Securing Remote Access To Critical Infrastructure, Yariv Lenchne...
 
IT vs. OT: ICS Cyber Security in TSOs
IT vs. OT: ICS Cyber Security in TSOsIT vs. OT: ICS Cyber Security in TSOs
IT vs. OT: ICS Cyber Security in TSOs
 
2016 Top 10 Critical Infrastructures and SCADA/ICS Cyber Security Vulnerabili...
2016 Top 10 Critical Infrastructures and SCADA/ICS Cyber Security Vulnerabili...2016 Top 10 Critical Infrastructures and SCADA/ICS Cyber Security Vulnerabili...
2016 Top 10 Critical Infrastructures and SCADA/ICS Cyber Security Vulnerabili...
 
Cybersecurity in Industrial Control Systems (ICS)
Cybersecurity in Industrial Control Systems (ICS)Cybersecurity in Industrial Control Systems (ICS)
Cybersecurity in Industrial Control Systems (ICS)
 
Scada Industrial Control Systems Penetration Testing
Scada Industrial Control Systems Penetration Testing Scada Industrial Control Systems Penetration Testing
Scada Industrial Control Systems Penetration Testing
 
SCADA hacking industrial-scale fun
SCADA hacking industrial-scale funSCADA hacking industrial-scale fun
SCADA hacking industrial-scale fun
 

Similar to CuSRF. OWASP AppSecUS 2014

Web application security
Web application securityWeb application security
Web application security
Jin Castor
 
Cm7 secure code_training_1day_xss
Cm7 secure code_training_1day_xssCm7 secure code_training_1day_xss
Cm7 secure code_training_1day_xss
dcervigni
 
BSides Cleveland: Active Defense - Helping threat actors hack themselves!
BSides Cleveland: Active Defense - Helping threat actors hack themselves!BSides Cleveland: Active Defense - Helping threat actors hack themselves!
BSides Cleveland: Active Defense - Helping threat actors hack themselves!
ThreatReel Podcast
 
Andrews whitakrer lecture18-security.ppt
Andrews whitakrer lecture18-security.pptAndrews whitakrer lecture18-security.ppt
Andrews whitakrer lecture18-security.ppt
SilverGold16
 

Similar to CuSRF. OWASP AppSecUS 2014 (20)

CUSRF | It's Pronounced "See You Surf" and It's Dangerous
CUSRF | It's Pronounced "See You Surf" and It's DangerousCUSRF | It's Pronounced "See You Surf" and It's Dangerous
CUSRF | It's Pronounced "See You Surf" and It's Dangerous
 
Identifying XSS Vulnerabilities
Identifying XSS VulnerabilitiesIdentifying XSS Vulnerabilities
Identifying XSS Vulnerabilities
 
Security threats in social networks
Security threats in social networksSecurity threats in social networks
Security threats in social networks
 
Secure Form Processing and Protection - Sunshine PHP 2015
Secure Form Processing and Protection - Sunshine PHP 2015Secure Form Processing and Protection - Sunshine PHP 2015
Secure Form Processing and Protection - Sunshine PHP 2015
 
Web application security
Web application securityWeb application security
Web application security
 
Cyber Threats
Cyber ThreatsCyber Threats
Cyber Threats
 
Web application security part 01
Web application security part 01Web application security part 01
Web application security part 01
 
Discretion in APT
Discretion in APTDiscretion in APT
Discretion in APT
 
Isys20261 lecture 09
Isys20261 lecture 09Isys20261 lecture 09
Isys20261 lecture 09
 
Cos 432 web_security
Cos 432 web_securityCos 432 web_security
Cos 432 web_security
 
Cm7 secure code_training_1day_xss
Cm7 secure code_training_1day_xssCm7 secure code_training_1day_xss
Cm7 secure code_training_1day_xss
 
Do You Write Secure Code? by Erez Metula
Do You Write Secure Code? by Erez MetulaDo You Write Secure Code? by Erez Metula
Do You Write Secure Code? by Erez Metula
 
BSides Cleveland: Active Defense - Helping threat actors hack themselves!
BSides Cleveland: Active Defense - Helping threat actors hack themselves!BSides Cleveland: Active Defense - Helping threat actors hack themselves!
BSides Cleveland: Active Defense - Helping threat actors hack themselves!
 
Do security toolbars actually prevent phishing attacks
Do security toolbars actually prevent phishing attacksDo security toolbars actually prevent phishing attacks
Do security toolbars actually prevent phishing attacks
 
Vulnerabilities in Web Applications
Vulnerabilities in Web ApplicationsVulnerabilities in Web Applications
Vulnerabilities in Web Applications
 
Andrews whitakrer lecture18-security.ppt
Andrews whitakrer lecture18-security.pptAndrews whitakrer lecture18-security.ppt
Andrews whitakrer lecture18-security.ppt
 
Cloud security best practices in AWS by: Ankit Giri
Cloud security best practices in AWS by: Ankit GiriCloud security best practices in AWS by: Ankit Giri
Cloud security best practices in AWS by: Ankit Giri
 
Django (Web Applications that are Secure by Default)
Django �(Web Applications that are Secure by Default�)Django �(Web Applications that are Secure by Default�)
Django (Web Applications that are Secure by Default)
 
Oauth 2.0 Security Considerations for Client Applications
Oauth 2.0 Security Considerations for Client ApplicationsOauth 2.0 Security Considerations for Client Applications
Oauth 2.0 Security Considerations for Client Applications
 
CSRF-Lecture13.pptx
CSRF-Lecture13.pptxCSRF-Lecture13.pptx
CSRF-Lecture13.pptx
 

Recently uploaded

Recently uploaded (14)

TSM unit 5 Toxicokinetics seminar by Ansari Aashif Raza.pptx
TSM unit 5 Toxicokinetics seminar by  Ansari Aashif Raza.pptxTSM unit 5 Toxicokinetics seminar by  Ansari Aashif Raza.pptx
TSM unit 5 Toxicokinetics seminar by Ansari Aashif Raza.pptx
 
Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.Deciding The Topic of our Magazine.pptx.
Deciding The Topic of our Magazine.pptx.
 
Microsoft Fabric Analytics Engineer (DP-600) Exam Dumps 2024.pdf
Microsoft Fabric Analytics Engineer (DP-600) Exam Dumps 2024.pdfMicrosoft Fabric Analytics Engineer (DP-600) Exam Dumps 2024.pdf
Microsoft Fabric Analytics Engineer (DP-600) Exam Dumps 2024.pdf
 
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docxThe Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
The Influence and Evolution of Mogul Press in Contemporary Public Relations.docx
 
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdfACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
ACM CHT Best Inspection Practices Kinben Innovation MIC Slideshare.pdf
 
STM valmiusseminaari 26-04-2024 PUUMALAINEN Ajankohtaista kansainvälisestä yh...
STM valmiusseminaari 26-04-2024 PUUMALAINEN Ajankohtaista kansainvälisestä yh...STM valmiusseminaari 26-04-2024 PUUMALAINEN Ajankohtaista kansainvälisestä yh...
STM valmiusseminaari 26-04-2024 PUUMALAINEN Ajankohtaista kansainvälisestä yh...
 
SaaStr Workshop Wednesday with CEO of Guru
SaaStr Workshop Wednesday with CEO of GuruSaaStr Workshop Wednesday with CEO of Guru
SaaStr Workshop Wednesday with CEO of Guru
 
DAY 0 8 A Revelation 05-19-2024 PPT.pptx
DAY 0 8 A Revelation 05-19-2024 PPT.pptxDAY 0 8 A Revelation 05-19-2024 PPT.pptx
DAY 0 8 A Revelation 05-19-2024 PPT.pptx
 
The Concession of Asaba International Airport: Balancing Politics and Policy ...
The Concession of Asaba International Airport: Balancing Politics and Policy ...The Concession of Asaba International Airport: Balancing Politics and Policy ...
The Concession of Asaba International Airport: Balancing Politics and Policy ...
 
Understanding Poverty: A Community Questionnaire
Understanding Poverty: A Community QuestionnaireUnderstanding Poverty: A Community Questionnaire
Understanding Poverty: A Community Questionnaire
 
2024-05-15-Surat Meetup-Hyperautomation.pptx
2024-05-15-Surat Meetup-Hyperautomation.pptx2024-05-15-Surat Meetup-Hyperautomation.pptx
2024-05-15-Surat Meetup-Hyperautomation.pptx
 
ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024ServiceNow CIS-Discovery Exam Dumps 2024
ServiceNow CIS-Discovery Exam Dumps 2024
 
Databricks Machine Learning Associate Exam Dumps 2024.pdf
Databricks Machine Learning Associate Exam Dumps 2024.pdfDatabricks Machine Learning Associate Exam Dumps 2024.pdf
Databricks Machine Learning Associate Exam Dumps 2024.pdf
 
2024 mega trends for the digital workplace - FINAL.pdf
2024 mega trends for the digital workplace - FINAL.pdf2024 mega trends for the digital workplace - FINAL.pdf
2024 mega trends for the digital workplace - FINAL.pdf
 

CuSRF. OWASP AppSecUS 2014

  • 1. AppSec USA2014 Denver, Colorado CuSRF It’s Pronounced “See You Surf” and It’s Dangerous
  • 2. Barry Shteiman • Director of Security Strategy at Imperva • Security Researcher working with the Imperva CTO office • Author of several application security tools, including HULK • Open source security projects code contributor • Twitter @bshteiman Introduction
  • 3. • CSRF brief intro • CUSRF: A close encounter with CSRF of the third kind  CUSRF explained  Vulnerable applications in the wild • Google Docs • Linkedin.com • Mitigations • Summary and conclusion Agenda 3
  • 4. The Motivation: Protecting Your ID in a Hostile Online Environment 4
  • 5. Privacy on the Web: An UphillBattle? 5 Source: www.askingsmarterquestions.com
  • 6. Privacy Can Be Achieved Through Anonymity 6 Source: www.antiquaprintgallery.com
  • 7. • CuSRF (pronounced “See You Surf”) – Cross USer Request Forgery • Web sites you visit can see your privates: – In real-time – Name, email, work place, title, etc. • Potential outcomes: – “Ice Hole Phishing”: e.g. infect only certain roles in a specific organization. – Display different price – Disinformation CuSRF Vulnerability Opens Your Social Kimono! 7
  • 9. SOP Threat Model 9 Communication Custom Code Accounts Finance Administration Transactions KnowledgeMgmt E-Commerce Bus.Functions Target Application 3 Vulnerable site sees legitimate request from victim, performs the requested action and sends a response Attacker sets the trap on some website on the internet1 2 While logged into vulnerable site, victim views attacker site Target site interaction Some interaction with victim site
  • 10. CSRF Illustrated: “Bypassing SOP” 1 3 Attacker sets the trap on some website on the internet (or simply via an e-mail) 1 Vulnerable site sees legitimate request from victim and performs the requested action Custom Code Accounts Finance Administration Transactions Communication KnowledgeMgmt E-Commerce Bus.Functions Hidden <img> tag contains attack against vulnerable site Application with CSRF vulnerability 2 While logged into vulnerable site, victim views attacker site <img> tag loaded by browser – sends GET request (including credentials) to vulnerable site
  • 11. • The “Confused Deputy” Problem – Web browsers automatically include access tokens with each request – Requests can be invoked by malicious sites from victim’s browser without user consent • Automatically Provided Tokens: • Session cookie, basic authentication header, IP address,client side SSL certificates, Windows domain authentication CSRF 1
  • 12. • The “Transfer Fund” attack • Attacker tricks the browser into issuing a “transfer funds” request to the attacker’s account • “/transferFund.jsp?To=<attacker>&Sum=10000000” CSRF Type I: ClassicCSRF 1 Attack Type Used credentials Interacts with Classic CSRF Victim’s Victim’s web account
  • 13. • The attacker mounts a CSRF attack that logs the victim into an attacker controlled account (sink account) • “signin.jsp?user=<attacker>&password=123456” • Later on, the attacker is able to track the victim’s activity in the sink account • e.g. log the victim to attacker’s controlled Google account to collect search history CSRF Type II: Login CSRF 1
  • 14. • The attacker mounts a CSRF attack that logs the victim into an attacker controlled account (sink account) • “signin.jsp?user=<attacker>&password=12345 6” • Later on, the attacker is able to track the victim’s activity in the sink account • e.g. log the victim to attacker’s controlled Google account to collect search history CSRF Type II: Login CSRF 1 Attack Type Used credentials Interacts with Classic CSRF Victim’s Victim’s web account Login CSRF Attacker’s Attacker web account
  • 15. Source: WhiteHat Security CSRF is Very Relevant 1
  • 16. CuSRF: A Close Encounter With CSRF of the Third Kind 16
  • 17. • A new type of CuSRF, bringing CSRF to Web 2.0 environment • “Cross USer Request Forgery” (CuSRF, pronounced “See You Surf”) attack • Composition of the known CSRF vulnerability types, for collaboration environment CSRF Type III: CuSRF 1
  • 18. • “A Web 2.0 site may allow users to interact and collaborate with each other in a social media dialogue as creators of user-generated content in a virtual community” (Source: Wikipedia) Web 2.0: It’s All About Collaboration 1 Source: http://conceptart.ca
  • 19. • The attacker forges collaboration requests on behalf of the victim – Similar to the “Classic CSRF” • The collaboration target is located on an attacker controlled account – Similar to the “Login CSRF” • Outcome: Attacker can reveal the victim’s social network identity CUSRF Explained 1 Attack Type Used credentials Interacts with Classic CSRF Victim’s Victim’s web account Login CSRF Attacker’s Attacker’s web account CUSRF Victim’s Attacker’s web account
  • 20. CuSRF in the Wild #1: LinkedIn Profile 20
  • 21. • Attacker sets up a LinkedIn account AttackSetup: Creating a LinkedIn Profile 2
  • 22. • In order to view the identity of profile visitors, the attacker can either: – Go “Pro” – Make their “LinkedIn” identity available to others AttackSetup: Settings 2
  • 23. • Attacker adds an invisible CSRF link referencing the attacker’s LinkedIn profile to their online asset • Asset can be: – A “watering hole” page – A “phishing” page – Etc. AttackSetup: CSRF Page 2
  • 24. • When the intended target visits the CSRF page: – The attacker discovers his identity (“Tal Be’ery”) instantly • Can act accordingly: – e.g. infect him personally with a “drive by download“ infection Launchingthe Attack 2
  • 25. • Victim can choose to share only “profile characteristics” – e.g “Engineer in Imperva” • This is the default setting • Sometimes that’s enough information for the attacker Resolving “Semi Anonymous Profiles” 2
  • 26. • In 2013, Linkedininsights.com had demonstrated a bypass • Linkedin “Red Herring” Module showed list of 10 possible “candidates” for the “Semi Anonymous Profiles” • One was the actual person; others were just “Red Herrings” • The problem: “Red Herrings” were randomized, actual person was not • Exploit: Attacker should view the “candidates” list twice and mark the overlapping item Resolving “Semi Anonymous Profiles” 2
  • 27. A Smelly Red Herring 2 Source: www.linkedinsights.com
  • 28. CuSRF in the Wild #1: Google Docs 28
  • 29. • Attacker (“honeymadhatter”) shares her doc with targeted account(s) (“sam.burekas”) • Only needs to know the targets’ email • No email is sent, as the option can be unchecked AttackSetup: Creating a Google Doc 2
  • 30. • Attacker adds an invisible CSRF link referencing to the attacker’s Google Doc to their online asset • Asset can be – A “watering hole” page – A “phishing” page – Etc. • Invisible link example: – “<script src = "https://docs.google.com/document/d/<some doc id>/edit"></script>” AttackSetup: CSRF Page 3
  • 31. • When the intended target visits the CSRF page: – The attacker uncovers victim’s identity (“sam.burekas”) instantly • Can act accordingly: e.g. infect victim with malware Launchingthe Attack 3
  • 34. • Logout more! • Use stricter privacy settings for vulnerable applications – Full anonymity for LinkedIn • Use personal Anti CSRF add-ons to block cross-site requests – RequestPolicy – CsFire – NoScript Consumers 3
  • 35. • Use standard CSRF protections – Don’t allow a collaboration based on a single request from other domain • Other domains can be determined by HTTP headers – Referer – Origin Platform Providers 3
  • 36. • Single request collaboration, within same domain can be secured with a CSRF token – Changing, un-guessable, unique identifier appended to the request • Libraries exist to include this functionality in the code – http://anticsrf.codeplex.com/ (.NET) – https://www.owasp.org/index.php/Category:OWASP_CSRFGuard_Proj ect (Java, PHP, .NET) Platform Providers 3
  • 37. Microsoft Seems to get it right 3
  • 39. • CSRF vulnerabilities of various types are common within applications • CuSRF is a new type of CSRF that affects users of collaboration platforms and applications – Disclosing the true identity of a victim, when accessing an attacker controlled application • CuSRF can be used for fraud as well as “Ice Hole Phishing” Summary 3
  • 40. • Consumers – Review privacy settings for collaboration platforms • Providers – Apply anti-CSRF mechanisms to collaboration activity Recommendations 4

Editor's Notes

  1. http://www.askingsmarterquestions.com/wp-content/uploads/2011/08/internet-privacy-cartoon2.jpg Discuss the perception among some people that privacy is no longer an issue, yet some day they’ll grow up.
  2. One anecdote has it that a number of dons were sunbathing nude at Parson's Pleasure when a female student floated by in a punt. All but one of the startled dons covered their genitals — Maurice Bowra placed a flannel over his head instead. When asked why he had done that, he replied haughtily, "I don’t know about you, gentlemen, but in Oxford, I, at least, am known by my face."[2] http://en.wikipedia.org/wiki/Parson's_Pleasure The idea is do show the difference between anonymity and privacy. The bottom line is that there is an important distinction between perfect forward privacy (which I agree is probably a relic of the past) and being forced to expose one’s identity unwittingly.
  3. Higher price – anecdotal evidence about different pricing for users with Apple user-agent. http://online.wsj.com/news/articles/SB10001424052702304458604577488822667325882 Company is Orbitz. This is from June 2012
  4. SOP = Same Origin Policy
  5. Whitehatsec WEBSITE SECURITYSTATISTICS REPORTMAY 2013 https://www.whitehatsec.com/assets/WPstatsReport_052013.pdf SC Magazine November 2013: http://www.scmagazine.com/google-fixes-flaw-in-gmail-password-reset-process/article/322343/
  6. http://en.wikipedia.org/wiki/Web_2.0
  7. Pay attention to what is RECOMMENDED by LinkedIn (of course). A note to myself – the settings of the attacker do not override the settings of victims (i.e. if attacker is “Pro” he cannot see information for uses who chose to be totally anonymous)
  8. https://securityledger.com/2013/03/many-watering-holes-targets-in-hacks-that-netted-facebook-twitter-and-apple/
  9. http://www.linkedinsights.com/useful-linkedin-hack-identify-your-anonymous-browser-by-screenshot/