SlideShare a Scribd company logo
1Web Insecurity and Browser Exploitationbrought to you by Michele “AntiSnatchOr” Orrù                      and Integrating Web LTD20th January 2009
http://www.integratingweb.comhttp://antisnatchor.comWho am I?Director and CSO of Integrating Web LTD
Bachelor Degree in Internet Sciences
Owner of http://antisnatchor.com security advisory blog
JEE developerOutline2 of 59
http://www.integratingweb.comhttp://antisnatchor.comSeminar outline Discuss the most relevant SANS top 25 errors that concern Web Applications
Practical demonstrations of some vulnerable Real World web applications (my totally independent security research)
Understand the impact of these threats on the most valuable web-app assets
Practical screen-casts that show how attackers exploit common flows
Browser exploitation discussionSeminar outline3 of 59
http://www.integratingweb.comhttp://antisnatchor.comWhat we will discuss:CWE-20: Improper Input Validation
CWE-116: Improper Encoding or Escaping of Output
CWE-209: Error Message Information Leak
CWE-89: Failure to Preserve SQL Query Structure (SQL injection)
CWE-79: Failure to Preserve Web Page Structure (XSS)
CWE-352: Cross-Site Request Forgery (XSRF)What we will discuss4 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: Improper Input ValidationThe biggest issue on today’s Internet Applications (not just Web Applications)
Improper Input Validation can lead to security vulnerabilities when attackers can modify input in unexpected ways for the application
The only way to protect our applications is by understanding that all input can be maliciousCWE-20: Improper Input Validation5 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: Example8e6 R3000 Internet Filter (commercial HTTP(S) Proxy filter solution)CWE-20: Example6 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: ExampleCredits: nnposter
DNS based website blacklist can be bypassed by providing a forged request with a custom HTTP headerHttp request:GET / HTTP/1.1X-DecoyHost: www.milw0rm.orgHost: www.blocked.orgCWE-20: Example7 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: MitigationUnderstand every potential attack areas: parameters, arguments, cookies, headers, files, database queries...
Whitelist approachinstead of blacklist (you are certainly going to miss some character encoding variants)
WebApp case: use a WebApp Firewall (ModSecurity/F5) or an Input Validation Framework for your language.CWE-20: Mitigation8 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: MitigationModSecurityCWE-20: Mitigation with ModSecurity9 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20:MITIGATION OWASP ESAPIA common set of interfaces for security controls such as:
Authentication
Access Control
Input Validation
Output Encoding
Cryptography
Error handling/loggingCWE-20:MITIGATION OWASP ESAPI10 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-20: MITIGATION PHPIDSCWE-20: MITIGATION PHPIDSInput validation framework for PHP based applications
Developed by skilled hackers (Mario Heiderich  - .mario on sla.ckers.org)
Try their demo with your nasty attack vectors here: http://demo.php-ids.org
Integrated as a module in Drupal, works with the powerful Zend Framework (http://forum.php-ids.org/comments.php?DiscussionID=113)11 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-116: Improper Encoding/Escaping of OutputInsufficient output encoding is the often-ignored sibling to poor input validation
Even if input has been filtered, application output could not be safe:  it need to be encoded too
Common examples: HTML/JavaScript injection on web based applicationsCWE-116: Improper Encoding of Output12 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-116: ExampleEclipse BIRT (reporting system that integrates with Java/JEE applications)CWE-116: Example13 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-116: ExampleCredits: antisnatchor[http://antisnatchor.com/2008/12/18/eclipse-birt-reflected-xss]
Java Exception stack trace was not  HTML-encoded, so we can inject an iframeGET		/birt-viewer/run?__report='"><iframe%20src=javascript:alert(666)>&r=-703171660 	HTTP/1.1		Host: localhost:8780Our code was executed correctly in the application outputCWE-116: Example14 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-116: MitigationAlways encode Java stack traces (better to don’t show them to prevent Information Leakage)
Always encode application output, especially if it contains previously user-supplied input
WebApp firewall and ESAPI/PHPIDS (you lazy developers :-))CWE-116: Mitigation15 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Error Message Information LeakChatty or debug error messages could disclose important important information to attackers
This information is used in the Penetration Testing phase called “Reconnaissance”
Even these little secrets can greatly simplify a more concerted attack that yields much bigger rewardsCWE-209: Error Message Information Leak16 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Examples1. www.dm.unibo.itCredits: antisnatchor
MySQL error when forging a malicious request altering the anno parameterGET /seminari/archivio.php?anno=2008%27 HTTP/1.1Host: www.dm.unibo.it[...]Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7Keep-Alive: 300Proxy-Connection: keep-aliveCookie: dm=[...]CWE-209:  www.dm.unibo.it17 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Examples1. www.dm.unibo.itApplication response:CWE-209:  www.dm.unibo.itCausing an SQL syntax error we discovered that the DB backend is MySQL
We can now run more targeted attacks18 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Examples2. uniwex.unibo.itCredits: antisnatchor
Session Management was (IS actually) broken and can be manipulated
If we are the hacker riding the victim’s session, and the victim then logout from Uniwex, his session (and ours, because is the same) is invalidated.
If we invalidate a session and then we try to submit the previously “invalid” session token... MAGICALLY ...CWE-209:  unibo.unibo.it19 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Examples2. uniwex.unibo.itCWE-209:  unibo.unibo.it20 of 59
http://www.integratingweb.comhttp://antisnatchor.comCWE-209: Examples2. uniwex.unibo.itThe JSP page /unique/UniqueNewException.jsp is clearly leaved there for debug purposes

More Related Content

PPTX
Hacking 101 (Session 2)
PPTX
Hacking 101 (Henallux, Owasp Top 10, WebGoat, Live Demo)
PPTX
Hacking 101 3
PDF
Web Application Firewall: Suckseed or Succeed
PPTX
Waf bypassing Techniques
PDF
Garage4Hackers Ranchoddas Webcast Series - Bypassing Modern WAF's Exemplified...
PPTX
CONFidence 2015: The Top 10 Web Hacks of 2014 - Matt Johansen, Johnathan Kuskos
PDF
Secure Programming And Common Errors[Michele Orru Dec 2008]
Hacking 101 (Session 2)
Hacking 101 (Henallux, Owasp Top 10, WebGoat, Live Demo)
Hacking 101 3
Web Application Firewall: Suckseed or Succeed
Waf bypassing Techniques
Garage4Hackers Ranchoddas Webcast Series - Bypassing Modern WAF's Exemplified...
CONFidence 2015: The Top 10 Web Hacks of 2014 - Matt Johansen, Johnathan Kuskos
Secure Programming And Common Errors[Michele Orru Dec 2008]

What's hot (20)

PPTX
Make profit with UI-Redressing attacks.
PPT
Identifying Web Servers: A First-look Into the Future of Web Server Fingerpri...
PPTX
Don't get stung - an introduction to the OWASP Top 10
PDF
They Ought to Know Better: Exploiting Security Gateways via Their Web Interfaces
ODP
Virtually Pwned
PDF
Secure Programming And Common Errors Part II
PPTX
Security Function
PDF
[CB16] 80時間でWebを一周:クロムミウムオートメーションによるスケーラブルなフィンガープリント by Isaac Dawson
PPTX
Advanced SQL Injection
PPT
Securing Your WordPress Website - WordCamp GC 2011
PPTX
Top Ten Web Hacking Techniques of 2012
PDF
Внедрение безопасности в веб-приложениях в среде выполнения
PDF
End to end web security
PPT
На страже ваших денег и данных
PDF
Beating Spam On Your WordPress Website - WordCamp Melbourne 2013
PDF
Serverless Security: Defence Against the Dark Arts
PPTX
Practical Cyber Attacking Tutorial
PPTX
Web Application Security in front end
PDF
Attack Chaining: Advanced Maneuvers for Hack Fu
PDF
Ekoparty 2017 - The Bug Hunter's Methodology
Make profit with UI-Redressing attacks.
Identifying Web Servers: A First-look Into the Future of Web Server Fingerpri...
Don't get stung - an introduction to the OWASP Top 10
They Ought to Know Better: Exploiting Security Gateways via Their Web Interfaces
Virtually Pwned
Secure Programming And Common Errors Part II
Security Function
[CB16] 80時間でWebを一周:クロムミウムオートメーションによるスケーラブルなフィンガープリント by Isaac Dawson
Advanced SQL Injection
Securing Your WordPress Website - WordCamp GC 2011
Top Ten Web Hacking Techniques of 2012
Внедрение безопасности в веб-приложениях в среде выполнения
End to end web security
На страже ваших денег и данных
Beating Spam On Your WordPress Website - WordCamp Melbourne 2013
Serverless Security: Defence Against the Dark Arts
Practical Cyber Attacking Tutorial
Web Application Security in front end
Attack Chaining: Advanced Maneuvers for Hack Fu
Ekoparty 2017 - The Bug Hunter's Methodology
Ad

Viewers also liked (18)

PPT
Software maliciós i fraus en linea
PDF
PROVOST STUDIO-Firm Profile & Experience
PPT
Iss
PPT
software maliciós
PPT
Thomas Lynch Racing Team Bohunk Rev2
PDF
Peter Provost-Selected Work (BRANDSPACE)
PPT
PPT
IES VALLDEMOSSA
PPTX
V8 a-primer video a insertar-imagenes evaluacion
PDF
Provost Studio_Portfolio_ALL PROJECTS_email
PPT
Què és internet?
PPSX
Integra Micro Software Services (P) Ltd. - Imaging Expertise
PPTX
Compost
PPT
Jobs And Professions
PDF
Dr. Strangelove or: How I Learned to Stop Worrying and Love the BeEF
PPTX
compost javier
PPTX
Globalization
PPT
Creating Relationships Presentations
Software maliciós i fraus en linea
PROVOST STUDIO-Firm Profile & Experience
Iss
software maliciós
Thomas Lynch Racing Team Bohunk Rev2
Peter Provost-Selected Work (BRANDSPACE)
IES VALLDEMOSSA
V8 a-primer video a insertar-imagenes evaluacion
Provost Studio_Portfolio_ALL PROJECTS_email
Què és internet?
Integra Micro Software Services (P) Ltd. - Imaging Expertise
Compost
Jobs And Professions
Dr. Strangelove or: How I Learned to Stop Worrying and Love the BeEF
compost javier
Globalization
Creating Relationships Presentations
Ad

Similar to Web Insecurity And Browser Exploitation (20)

PDF
OWASP TOP 10 for PHP Programmers
PDF
4 andrii kudiurov - web application security 101
PPTX
Vulnerabilities in data processing levels
PPTX
Vulnerabilities on Various Data Processing Levels
PPTX
Secure coding - Balgan - Tiago Henriques
PDF
Web Development Security
PDF
Intro to Php Security
PPTX
The path of secure software by Katy Anton
PPTX
Owasp Top 10 - A1 Injection
PPTX
State of the information security nation
PDF
owasp-top-10 presentation dhs ad health .
PDF
Coding Security: Code Mania 101
PDF
Web Security Threats and Solutions
PPTX
Web security-–-everything-we-know-is-wrong-eoin-keary
PPTX
BEST PRACTICES OF WEB APPLICATION SECURITY By SAMVEL GEVORGYAN
PDF
Attques web
DOCX
WEB APPLICATION VULNERABILITIES: DAWN, DETECTION, EXPLOITATION AND DEFENSE
PPTX
Sql injection
DOCX
supraja technologies material for secure coding
PDF
Owasp Top 10
OWASP TOP 10 for PHP Programmers
4 andrii kudiurov - web application security 101
Vulnerabilities in data processing levels
Vulnerabilities on Various Data Processing Levels
Secure coding - Balgan - Tiago Henriques
Web Development Security
Intro to Php Security
The path of secure software by Katy Anton
Owasp Top 10 - A1 Injection
State of the information security nation
owasp-top-10 presentation dhs ad health .
Coding Security: Code Mania 101
Web Security Threats and Solutions
Web security-–-everything-we-know-is-wrong-eoin-keary
BEST PRACTICES OF WEB APPLICATION SECURITY By SAMVEL GEVORGYAN
Attques web
WEB APPLICATION VULNERABILITIES: DAWN, DETECTION, EXPLOITATION AND DEFENSE
Sql injection
supraja technologies material for secure coding
Owasp Top 10

Recently uploaded (20)

PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
Spectroscopy.pptx food analysis technology
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PPT
Teaching material agriculture food technology
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Electronic commerce courselecture one. Pdf
PDF
Empathic Computing: Creating Shared Understanding
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PPTX
A Presentation on Artificial Intelligence
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
Encapsulation theory and applications.pdf
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Approach and Philosophy of On baking technology
PDF
NewMind AI Weekly Chronicles - August'25-Week II
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
The AUB Centre for AI in Media Proposal.docx
Spectroscopy.pptx food analysis technology
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Teaching material agriculture food technology
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Electronic commerce courselecture one. Pdf
Empathic Computing: Creating Shared Understanding
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
A Presentation on Artificial Intelligence
Assigned Numbers - 2025 - Bluetooth® Document
“AI and Expert System Decision Support & Business Intelligence Systems”
Chapter 3 Spatial Domain Image Processing.pdf
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Encapsulation theory and applications.pdf
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Mobile App Security Testing_ A Comprehensive Guide.pdf
MYSQL Presentation for SQL database connectivity
Approach and Philosophy of On baking technology
NewMind AI Weekly Chronicles - August'25-Week II

Web Insecurity And Browser Exploitation