SlideShare una empresa de Scribd logo
1 de 30
Descargar para leer sin conexión
Gerald Benischke
Software Engineer
XML is Evil
Making Software. Better.
Simple solutions to big business problems.
Equal Experts is a network of talented, experienced, software
consultants, specialising in agile delivery.
The network
I’m part of the Equal Experts network,
a community of highly-experienced
software professionals.
At Equal Experts we’re given the
freedom to get on with what’s
important - delivering better software
for our clients’ customers.
XML is evil!
! Services not maintained as much as they ought to
! Services contain vulnerabilities
! Services that are public facing
! Information Disclosure
! Server Side Request Forgery
! Denial of Service
Billion Laughs
Real World Example - Reauthentication
App
Reauthe
ntication
Login
POST
back
App
Billion Laughs - Real World Example
Dependency Checking
Billion Laughs - The Attack
Billion Laughs - Real World Example
Billion Laughs - Risks
! DoS without DDoS
! Only a few requests can cause CPU spikes
! With Auto Scaling Groups this could be expensive
Billion Laughs - Mitigation
! Upgrade to OpenSAML 3.3
! Unfortunately, as the API for OpenSAML changed
significantly, that wasn't just a matter of changing
dependencies but rewriting the SAML generation code
from scratch.
! Dependency Scanning
Hiding XXE in Spreadsheets
Hiding XXE in Spreadsheets
! XXE = XML eXternal Entity injection
! User-provided XML with external reference
Real World Example - Hiding XXE in Spreadsheets
App
Upload
ODS
Parse
Create
XML
Backend
Hiding XXE - Real World Example
Hiding XXE in Spreadsheets - Risks
! Steal your AWS
Keys - Keys to the
Kingdom
! Call internal APIs
! Turn you into a
Monero miner
Hiding XXE in Spreadsheets - Mitigation
Xerces Hash Collisions
Xerces Hash Collisions
Xerces Hash Collisions
Xerces Hash Collisions
Xerces Hash Collisions
! By uploading as few as 5 files with a size of 2MB each
simultaneously, I was able to cause a CPU load of 100%
for up to about a minute.
! Sustain this enough and it might cause a rather
inconvenient Denial of Service probably without being
caught by the traditional DDoS protections...
Hiding XXE in Spreadsheets
Xerces Hash Collisions - Risks
! DoS without DDoS
! Only a few requests can cause CPU spikes
! With Auto Scaling Groups this could be expensive
! You might be vulnerable without knowing
! Play 2.5 uses Xerces 2.11.0
Xerces Hash Collisions - Mitigations
! Upgrade Xerces (>=2.12.0)
! Dependency Scanning
! Do not trust requests
Summary
Security
! Know your inputs
! Know your dependencies
! Know about vulnerabilities
! XML can be a minefield
QUESTIONS?
https://www.equalexperts.com/services/security/
Thank You
United Kingdom
+44 203 603 7830
helloUK@equalexperts.com
Equal Experts UK Ltd
30 Brock Street
London NW1 3FG
India
+91 20 6607 7763
helloIndia@equalexperts.com
Equal Experts India Private Ltd
Office No. 4-C
Cerebrum IT Park No. B3
Kumar City, Kalyani Nagar
Pune, 411006
Canada
+1 403 775 4861
helloCanada@equalexperts.com
Equal Experts Devices Inc
205 - 279 Midpark way S.E.

T2X 1M2

Calgary, Alberta
 
Portugal
+351 211 378 414
helloPortugal@equalexperts.com
Equal Experts Portugal

Avenida Dom João II, Nº35
Edificio Infante 11ºA
1990-083 Parque das Nações

Lisboa – Portugal
Thank You
USA


+1 866-943-9737
helloUSA@equalexperts.com
Equal Experts Inc
1460 Broadway
New York
NY 10036
 
LinkedIn
linkedin.com/company/equal-experts
Twitter
@EqualExperts
Web
www.equalexperts.com

Más contenido relacionado

Similar a XML is Evil - OWASP Manchester May 2019

Web security-–-everything-we-know-is-wrong-eoin-keary
Web security-–-everything-we-know-is-wrong-eoin-kearyWeb security-–-everything-we-know-is-wrong-eoin-keary
Web security-–-everything-we-know-is-wrong-eoin-keary
drewz lin
 
The Enemy On The Web
The Enemy On The WebThe Enemy On The Web
The Enemy On The Web
Bishan Singh
 
Analysis of web application worms and viruses
Analysis of web application worms and virusesAnalysis of web application worms and viruses
Analysis of web application worms and viruses
UltraUploader
 
What is-flame-miniflame
What is-flame-miniflameWhat is-flame-miniflame
What is-flame-miniflame
Venafi
 
Virtualization Techniques & Cloud Compting
Virtualization Techniques & Cloud ComptingVirtualization Techniques & Cloud Compting
Virtualization Techniques & Cloud Compting
Ahmed Mekkawy
 

Similar a XML is Evil - OWASP Manchester May 2019 (20)

Web Application Security
Web Application SecurityWeb Application Security
Web Application Security
 
WebAssembly & Zero Trust for Code
WebAssembly & Zero Trust for CodeWebAssembly & Zero Trust for Code
WebAssembly & Zero Trust for Code
 
Virtualizing OTM - Real World Experiences and Pitfalls
Virtualizing OTM - Real World Experiences and PitfallsVirtualizing OTM - Real World Experiences and Pitfalls
Virtualizing OTM - Real World Experiences and Pitfalls
 
Open Source Security
Open Source SecurityOpen Source Security
Open Source Security
 
ESXpert strategies VMware vSphere
ESXpert strategies VMware vSphereESXpert strategies VMware vSphere
ESXpert strategies VMware vSphere
 
Website hacking and prevention (All Tools,Topics & Technique )
Website hacking and prevention (All Tools,Topics & Technique )Website hacking and prevention (All Tools,Topics & Technique )
Website hacking and prevention (All Tools,Topics & Technique )
 
Security in the Real World - JavaOne 2013
Security in the Real World - JavaOne 2013Security in the Real World - JavaOne 2013
Security in the Real World - JavaOne 2013
 
Richardrodger nodeday-2014-final
Richardrodger nodeday-2014-finalRichardrodger nodeday-2014-final
Richardrodger nodeday-2014-final
 
Richardrodger nodeday-2014-final
Richardrodger nodeday-2014-finalRichardrodger nodeday-2014-final
Richardrodger nodeday-2014-final
 
Web security-–-everything-we-know-is-wrong-eoin-keary
Web security-–-everything-we-know-is-wrong-eoin-kearyWeb security-–-everything-we-know-is-wrong-eoin-keary
Web security-–-everything-we-know-is-wrong-eoin-keary
 
The Enemy On The Web
The Enemy On The WebThe Enemy On The Web
The Enemy On The Web
 
Analysis of web application worms and viruses
Analysis of web application worms and virusesAnalysis of web application worms and viruses
Analysis of web application worms and viruses
 
Internet Scale Architecture
Internet Scale ArchitectureInternet Scale Architecture
Internet Scale Architecture
 
What is-flame-miniflame
What is-flame-miniflameWhat is-flame-miniflame
What is-flame-miniflame
 
Is the Web at Risk?
Is the Web at Risk?Is the Web at Risk?
Is the Web at Risk?
 
Virtualization Techniques & Cloud Compting
Virtualization Techniques & Cloud ComptingVirtualization Techniques & Cloud Compting
Virtualization Techniques & Cloud Compting
 
Pentesting With Web Services in 2012
Pentesting With Web Services in 2012Pentesting With Web Services in 2012
Pentesting With Web Services in 2012
 
AWS vs. Azure
AWS vs. AzureAWS vs. Azure
AWS vs. Azure
 
External XML Entities
External XML EntitiesExternal XML Entities
External XML Entities
 
Decoupled cms sunshinephp 2014
Decoupled cms sunshinephp 2014Decoupled cms sunshinephp 2014
Decoupled cms sunshinephp 2014
 

Último

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 

XML is Evil - OWASP Manchester May 2019

  • 2. Making Software. Better. Simple solutions to big business problems. Equal Experts is a network of talented, experienced, software consultants, specialising in agile delivery.
  • 3. The network I’m part of the Equal Experts network, a community of highly-experienced software professionals. At Equal Experts we’re given the freedom to get on with what’s important - delivering better software for our clients’ customers.
  • 4. XML is evil! ! Services not maintained as much as they ought to ! Services contain vulnerabilities ! Services that are public facing ! Information Disclosure ! Server Side Request Forgery ! Denial of Service
  • 6. Real World Example - Reauthentication App Reauthe ntication Login POST back App
  • 7. Billion Laughs - Real World Example
  • 9. Billion Laughs - The Attack
  • 10. Billion Laughs - Real World Example
  • 11. Billion Laughs - Risks ! DoS without DDoS ! Only a few requests can cause CPU spikes ! With Auto Scaling Groups this could be expensive
  • 12. Billion Laughs - Mitigation ! Upgrade to OpenSAML 3.3 ! Unfortunately, as the API for OpenSAML changed significantly, that wasn't just a matter of changing dependencies but rewriting the SAML generation code from scratch. ! Dependency Scanning
  • 13. Hiding XXE in Spreadsheets
  • 14. Hiding XXE in Spreadsheets ! XXE = XML eXternal Entity injection ! User-provided XML with external reference
  • 15. Real World Example - Hiding XXE in Spreadsheets App Upload ODS Parse Create XML Backend
  • 16. Hiding XXE - Real World Example
  • 17. Hiding XXE in Spreadsheets - Risks ! Steal your AWS Keys - Keys to the Kingdom ! Call internal APIs ! Turn you into a Monero miner
  • 18. Hiding XXE in Spreadsheets - Mitigation
  • 23. Xerces Hash Collisions ! By uploading as few as 5 files with a size of 2MB each simultaneously, I was able to cause a CPU load of 100% for up to about a minute. ! Sustain this enough and it might cause a rather inconvenient Denial of Service probably without being caught by the traditional DDoS protections...
  • 24. Hiding XXE in Spreadsheets
  • 25. Xerces Hash Collisions - Risks ! DoS without DDoS ! Only a few requests can cause CPU spikes ! With Auto Scaling Groups this could be expensive ! You might be vulnerable without knowing ! Play 2.5 uses Xerces 2.11.0
  • 26. Xerces Hash Collisions - Mitigations ! Upgrade Xerces (>=2.12.0) ! Dependency Scanning ! Do not trust requests
  • 28. Security ! Know your inputs ! Know your dependencies ! Know about vulnerabilities ! XML can be a minefield
  • 30. Thank You United Kingdom +44 203 603 7830 helloUK@equalexperts.com Equal Experts UK Ltd 30 Brock Street London NW1 3FG India +91 20 6607 7763 helloIndia@equalexperts.com Equal Experts India Private Ltd Office No. 4-C Cerebrum IT Park No. B3 Kumar City, Kalyani Nagar Pune, 411006 Canada +1 403 775 4861 helloCanada@equalexperts.com Equal Experts Devices Inc 205 - 279 Midpark way S.E.
 T2X 1M2
 Calgary, Alberta   Portugal +351 211 378 414 helloPortugal@equalexperts.com Equal Experts Portugal
 Avenida Dom João II, Nº35 Edificio Infante 11ºA 1990-083 Parque das Nações
 Lisboa – Portugal Thank You USA 
 +1 866-943-9737 helloUSA@equalexperts.com Equal Experts Inc 1460 Broadway New York NY 10036   LinkedIn linkedin.com/company/equal-experts Twitter @EqualExperts Web www.equalexperts.com