Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP.

Slides:



Advertisements
Similar presentations
WEB DESIGN TABLES, PAGE LAYOUT AND FORMS. Page Layout Page Layout is an important part of web design Why do you think your page layout is important?
Advertisements

JavaScript FaaDoOEngineers.com FaaDoOEngineers.com.
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the Creative Commons Attribution-ShareAlike.
OWASP 1 Flash Parameter Injection The OWASP Foundation OWASP 25/09/2008 Ayal Yogev Adi Sharabani IBM Rational Application Security.
Server-Side vs. Client-Side Scripting Languages
The Application Layer Chapter 7. Electronic Mail Architecture and Services The User Agent Message Formats Message Transfer Final Delivery.
Dynamic Web Pages Bert Wachsmuth. Review  Internet, IP addresses, ports, client-server, http, smtp  HTML, XHTML, XML  Style Sheets, external, internal,
Computer Science 101 Web Access to Databases Overview of Web Access to Databases.
E-Commerce The technical side. LAMP Linux Linux Apache Apache MySQL MySQL PHP PHP All Open Source and free packages. Can be installed and run on most.
ITM352 Javascript and Dynamic Web Pages: Client Side Processing.
Web Programming Language Dr. Ken Cosh Week 1 (Introduction)
HTML 1 Introduction to HTML. 2 Objectives Describe the Internet and its associated key terms Describe the World Wide Web and its associated key terms.
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the Creative Commons Attribution-ShareAlike.
Web Design Basic Concepts.
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
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.
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the Creative Commons Attribution-ShareAlike.
Computer Concepts 2014 Chapter 7 The Web and .
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
FALL 2005CSI 4118 – UNIVERSITY OF OTTAWA1 Part 4 Web technologies: HTTP, CGI, PHP,Java applets)
Agenda Web Development Chapter 7 Review Class Discussion Issues.
Introduction to AJAX AJAX Keywords: JavaScript and XML
AJAX Chat Analysis and Design Rui Zhao CS SPG UCCS.
RIA & Adobe Flex Yunhui Fu 11/05/2008. What’s RIA RIA (Rich Internet Applications) –web applications which look and perform like desktop applications.
Beyond DHTML So far we have seen and used: CGI programs (using Perl ) and SSI on server side Java Script, VB Script, CSS and DOM on client side. For some.
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.
Copyright © cs-tutorial.com. Introduction to Web Development In 1990 and 1991,Tim Berners-Lee created the World Wide Web at the European Laboratory for.
Ruth Betcher Ruth Christie
Dynamic Web Pages (Flash, JavaScript)
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
Prepared by Stephen Olaño June 12, Rich Internet Applications It allow to build rich applications with data and multimedia contents, offering a.
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.
CNIT 133 Interactive Web Pags – JavaScript and AJAX JavaScript Environment.
Flash & JavaScript Mariela Hristova October 19, 2004 INF 385E – Fall 2004 – School of Information.
Flex 2.0 Flex for ColdFusion developers Part 1. What is Flex Flex allows developers to create Flash content for Rich Internet Applications in a more programmer.
Chapter 8 Cookies And Security JavaScript, Third Edition.
INTRODUCTION TO JAVASCRIPT AND DOM Internet Engineering Spring 2012.
An Introduction to JavaScript Summarized from Chapter 6 of “Web Programming: Building Internet Applications”, 3 rd Edition.
Extending HTML CPSC 120 Principles of Computer Science April 9, 2012.
Web Pages with Features. Features on Web Pages Interactive Pages –Shows current date, get server’s IP, interactive quizzes Processing Forms –Serach a.
Chapter 8 Collecting Data with Forms. Chapter 8 Lessons Introduction 1.Plan and create a form 2.Edit and format a form 3.Work with form objects 4.Test.
Tutorial 7 Planning and Creating a Flash Web Site.
2006 Adobe Systems Incorporated. All Rights Reserved. 1 Adobe RIA Technologies: Adobe Flex 3 Cornel Creanga Platform Evangelist
Flex 2 We’re Not in Kansas Anymore! or Welcome to Flex Theo Rushin Jr TeraTech, Inc.
JavaScript Tutorial 1 - Introduction to JavaScript1 Tutorial 1 Introduction to JavaScript Section A – Programming, HTML, and JavaScript.
XP Tutorial 8 Adding Interactivity with ActionScript.
Web Pages with Features. Features on Web Pages Interactive Pages –Shows current date, get server’s IP, interactive quizzes Processing Forms –Serach a.
Introduction to Flex 2 by Rich Tretola. About Me Rich Tretola is a senior software developer at Herff Jones, Inc. specializing in Rich Internet Applications.
Module: Software Engineering of Web Applications Chapter 2: Technologies 1.
Scripting Languages Client Side and Server Side. Examples of client side/server side Examples of client-side side include: JavaScript Jquery (uses a JavaScript.
Introduction to HTML. _______________________________________________________________________________________________________________ 2 Outline Key issues.
Internet Applications (Cont’d) Basic Internet Applications – World Wide Web (WWW) Browser Architecture Static Documents Dynamic Documents Active Documents.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
JavaScript Overview Developer Essentials How to Code Language Constructs The DOM concept- API, (use W3C model) Objects –properties Methods Events Applications;
 Web pages originally static  Page is delivered exactly as stored on server  Same information displayed for all users, from all contexts  Dynamic.
HTML Concepts and Techniques Fifth Edition Chapter 1 Introduction to HTML.
ASP-2-1 SERVER AND CLIENT SIDE SCRITPING Colorado Technical University IT420 Tim Peterson.
Chapter 11 Adding Media and Interactivity. Chapter 11 Lessons Introduction 1.Add and modify Flash objects 2.Add rollover images 3.Add behaviors 4.Add.
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP.
Web Technology (NCS-504) Prepared By Mr. Abhishek Kesharwani Assistant Professor,UCER Naini,Allahabad.
Introduction to JavaScript LIS390W1A Web Technologies and Techniques 24 Oct M. Cameron Jones.
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,
A S P. Outline  The introduction of ASP  Why we choose ASP  How ASP works  Basic syntax rule of ASP  ASP’S object model  Limitations of ASP  Summary.
Open Solutions for a Changing World™ Eddy Kleinjan Copyright 2005, Data Access WordwideNew Techniques for Building Web Applications June 6-9, 2005 Key.
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.
1 Chapter 1 INTRODUCTION TO WEB. 2 Objectives In this chapter, you will: Become familiar with the architecture of the World Wide Web Learn about communication.
CX Introduction to Web Programming
Application with Cross-Platform GUI
About Multimedia Files
Presentation transcript:

Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP Foundation OWASP Automated Crawling & Security Testing of Flash/Flex Web Applications Ronen Bachar Organization: IBM Phone: /9/2008

OWASP 2 Agenda  Introduction to Flash/Flex applications  AMF  High level description  AMF data format and its usage  Automated Flash Testing Challenges  Automated Crawling  Automated Testing  Overview of security risks in Flash/Flex applications

OWASP 3 Flash/Flex Introduction  Flash  Developed by Macromedia (now Adobe)  Flash is used to create animations, ads, and various Web components, to integrate video into web pages and, more recently, to develop RIA  Can be consumed as web page element or standalone application  Includes Scripting languages - Action Script 1, 2 & 3  Flash player  Runs Flash content (SWF file format)  Available as a plug-in for browsers (such as Mozilla Firefox and Internet Explorer) or as standalone application  Each version is completely backward-compatible

OWASP 4 Flash/Flex Introduction (ctd.)  Flex  Flex provides a framework for developing RIAs that run in Flash Player  Instead of forcing applications into the “animation” model, developers can program real applications using MXML (XML document) for layout user-interface components, and Action Script for programming  Requires Flash Player v9  Same File Format (SWF)  Supports only Action Script 3  AJAX-like attributes

OWASP 5 Flash/Flex Introduction (ctd.)  When Flash movie is embedded in Web page:  Flash  DOM: interacts with DOM by executing JavaScript code  JavaScript (HTML Host)  Flash Object Host (Browser) Flash Player Flash Movie (SWF)

OWASP 6 Flash in HTML page

OWASP 7 AMF - ActionScript Message Format  A binary message format  Used primarily to exchange data between Flash/Flex application and server side component, by serializing Action Script data types  NetConnection uses AMF to send messages to a server to asynchronously invoke remote services (RPC)  AMF 0, 3 - require Flash Player 9  AMF protocol specification is available (see references)  Understanding AMF format is crucial for manipulating (fuzzing) applications that use AMF

OWASP 8 AMF Format Description  Version: 0, 3  Header(s):  Header Name  Data: Serialized data (binary)  Message(s):  Target URI: Service name/Response result  Response URI: /id  Data: Serialized data (binary)

OWASP 9 AMF Example Request (raw format) Request (decoded) Response (decoded)

OWASP 10 Challenges of Crawling Flash  In order to properly test Flash/Flex-based applications, we have to crawl them  Detect server-side end-points (new URLs)  Detect client-side states and logic (Flash Application tree)  We must play the Flash movie in its “native” context  Flash movie runs in the original HTML page  Browser - include JavaScript engine (for JS  Flash interaction)  Use Flash Player plug-in  We must support dynamic content too (where script creates content on the fly), parsing is not enough!

OWASP 11 Challenges of Crawling Flash (Cont.)  States in Flash application  Navigation in Flash application  Blind Crawling (soundless, no pop-ups, no visuals)  Support inline movie too  Since Flash Player is designed only to play movies, its programming interface is limited

OWASP 12 State Management in Flash applications  Flash Applications are primarily based on animation. We encounter the following issues:  How do we identify/define “application state”?  How do we get the current state?  Figuring out that the current state is over/idle?  We define “state” as “GUI Object” container, i.e. Movie Clips, Buttons & Text Fields  Heuristics & Flash Plug-in gives us hints that the player is “idle”

OWASP 13 Navigation in Flash Application  Navigate Flash application in its native flow  still hard to define correct “functional flow”  Build application tree (each node represents a state)  Get current state details (GUI Objects(  Activate each GUI object according to type:  Button – click on it, move mouse over a button area.  TextField – fill it in  MovieClip – click on it  Navigating between states through Flash  Unfortunately, navigating back is not trivial  We need to store and play sequences

OWASP 14 Flash Application tree Root (State A) MC2 State C (State B) B1 B2 MC1 State FState EState D

OWASP 15  Identify controlled Flash parameters:  Query parameters (from HTML)   FlashVars (from HTML)   Uninstantiated variables (from Action Script)  getURL (clickTag,'_self')  Locate potentially dangerous code:  Where controlled Flash parameters are used inside PDNFs (getURL, loadMovie, loadVariables, etc.)  Save sequences leading to potentially dangerous code  Associate with parameter Testing Flash Applications

OWASP 16 Testing Flash Applications (ctd.)  Mutation - Inject values to the parameters  XSS: parm1=javascript:window.open(‘  XSF: param2=  Phishing: param3=  Validation  Play relevant sequence belongs to mutated parameter  Verify test results  Browser events  Action Script level

OWASP 17 Testing AMF Parameters  Testing Server-side AMF-speaking end-points  Using standard parameter tampering techniques on AMF message fields: XSS, SQLi, HTTP Response Splitting, Command Execution, Etc. ' having 1=1-- Original Request Mutated Request

OWASP 18 Overview of security risks in Flash/Flex applications  XSS Through Flash  Read & Write access to HTML page or javascript code  XSF  Read & Write access to SWF loader or HTML or javascript code  Phishing Through Flash  AMF Parameters  XSS, SQLi  Cross Domain Promiscuous Access  Read & Write access to HTML page or javascript code

OWASP 19 Recommendations  HTML Code  “allowNetworking” set to ‘internal’  “allowScriptAccess” set to ‘samedomain’  Perform data validation on variables sent to URL functions  Refining access with “crossdomain.xml”  Use fscommand or ExternalInterface.call Instead of "javascript:”  Compiler settings:  Compile Flash movie for Flash Player 8 or latter  Set Omit trace flag

OWASP 20 References  Creating more secure SWF web applications: e_swf_apps.html e_swf_apps.html  Adobe Flash Player 9 Security: _player_9_security.pdf _player_9_security.pdf  AMF 0 Specification: pec_ pdf pec_ pdf  AMF 3 Specification: pec_ pdf pec_ pdf  Testing Flash Applications (Stefano Di Paola / OWASP): 7.pdf 7.pdf