Approaches to Application Security – DSM

Slides:



Advertisements
Similar presentations
Webgoat.
Advertisements

Infosec 2012 | 25/4/12 Application Performance Monitoring Ofer MAOR CTO Infosec 2012.
Hands on Demonstration for Testing Security in Web Applications
Creating Stronger, Safer, Web Facing Code JPL IT Security Mary Rivera June 17, 2011.
Principles of Computer Security: CompTIA Security + ® and Beyond, Third Edition © 2012 Principles of Computer Security: CompTIA Security+ ® and Beyond,
WebGoat & WebScarab “What is computer security for $1000 Alex?”
-Ajay Babu.D y5cs022.. Contents Who is hacker? History of hacking Types of hacking Do You Know? What do hackers do? - Some Examples on Web application.
By Brian Vees.  SQL Injection  Username Enumeration  Cross Site Scripting (XSS)  Remote Code Execution  String Formatting Vulnerabilities.
ReferencesReferences DiscussionDiscussion Vulnerability Example: SQL injection Auditing Tool for Eclipse LAPSE: a Security Auditing Tool for Eclipse IntroductionIntroductionResultsResults.
It’s always better live. MSDN Events Securing Web Applications Part 1 of 2 Understanding Threats and Attacks.
Information Networking Security and Assurance Lab National Chung Cheng University 1 Top Vulnerabilities in Web Applications (I) Unvalidated Input:  Information.
Introduction to Web Application Security
Leveraging User Interactions for In-Depth Testing of Web Applications Sean McAllister, Engin Kirda, and Christopher Kruegel RAID ’08 1 Seoyeon Kang November.
Sara SartoliAkbar Siami Namin NSF-SFS workshop July 14-18, 2014.
“Today over 70% of attacks against a company’s network come at the ‘Application Layer’ not the Network or System layer.” - Gartner Is Your Web Application.
Handling Security Threats in Kentico CMS Karol Jarkovsky Sr. Solution Architect Kentico Software
Presenter Deddie Tjahjono.  Introduction  Website Application Layer  Why Web Application Security  Web Apps Security Scanner  About  Feature  How.
Security Scanning OWASP Education Nishi Kumar Computer based training
Web Application Testing with AppScan Terry Labach.
By: Razieh Rezaei Saleh.  Security Evaluation The examination of a system to determine its degree of compliance with a stated security model, security.
CVSQL 2 The Design. System Overview System Components CVSQL Server –Three network interfaces –Modular data source provider framework –Decoupled SQL parsing.
W3af LUCA ALEXANDRA ADELA – MISS 1. w3af  Web Application Attack and Audit Framework  Secures web applications by finding and exploiting web application.
Testing Tools. Categories of testing tools Black box testing, or functional testing Testing performed via GUI. The tool helps in emulating end-user actions.
Software Quality Assurance Lecture #8 By: Faraz Ahmed.
+ Websites Vulnerabilities. + Content Expand of The Internet Use of the Internet Examples Importance of the Internet How to find Security Vulnerabilities.
Brakeman and Jenkins: The Duo Detects Defects in Ruby on Rails Code Justin Collins Tin Zaw AppSec USA September 23, 2011.
A Framework for Automated Web Application Security Evaluation
Web Application Access to Databases. Logistics Test 2: May 1 st (24 hours) Extra office hours: Friday 2:30 – 4:00 pm Tuesday May 5 th – you can review.
Automatically Hardening Web Applications Using Precise Tainting Anh Nguyen-Tuong Salvatore Guarnieri Doug Greene Jeff Shirley David Evans University of.
November 13, 2008 Ohio Information Security Forum Attack Surface of Web Applications James Walden Northern Kentucky University
Lecture slides prepared for “Computer Security: Principles and Practice”, 3/e, by William Stallings and Lawrie Brown, Chapter 5 “Database and Cloud Security”.
Web Application Security Testing Automation.. Copyright © 2008 Deloitte Touche Tohmatsu. All rights reserved.1 What types of automated testing are there?
Chapter 2. Core Defense Mechanisms. Fundamental security problem All user input is untrusted.
Web Application Security ECE ECE Internetwork Security What is a Web Application? An application generally comprised of a collection of scripts.
Security Scanners Mark Shtern. Popular attack targets Web – Web platform – Web application Windows OS Mac OS Linux OS Smartphone.
Introduction To Web Application Security in PHP. Security is Big And Often Difficult PHP doesn’t make it any easier.
Watching Software Run Brian ChessNov 18, Success is foreseeing failure. – Henry Petroski.
An Ad Hoc Writable Rule Language for White-Box Security Scanners Author:Sebastian Schinzel Referent:Prof. Dr. Alexander del Pino Korreferent:Prof. Dr.
Hands-On with RailsGoat WEB APPLICATION SECURITY TESTING.
October 3, 2008IMI Security Symposium Application Security through a Hacker’s Eyes James Walden Northern Kentucky University
nd Joint Workshop between Security Research Labs in JAPAN and KOREA Marking Scheme for Semantic- aware Web Application Security HPC.
Aniket Joshi Justin Thomas. Agenda Introduction to SQL Injection SQL Injection Attack SQL Injection Prevention Summary.
Building Secure Web Applications With ASP.Net MVC.
Misc. Announcements Pre-Test2 (with past test questions!) and Final Milestone are posted! Which teams to go first? 2 options Any volunteers for the first.
Web Application Vulnerabilities ECE 4112 Internetwork Security, Spring 2005 Chris Kelly Chris Lewis April 28, 2005 ECE 4112 Internetwork Security, Spring.
PwC New Technologies New Risks. PricewaterhouseCoopers Technology and Security Evolution Mainframe Technology –Single host –Limited Trusted users Security.
Web Security Lesson Summary ●Overview of Web and security vulnerabilities ●Cross Site Scripting ●Cross Site Request Forgery ●SQL Injection.
Michael Dalton, Christos Kozyrakis, and Nickolai Zeldovich MIT, Stanford University USENIX 09’ Nemesis: Preventing Authentication & Access Control Vulnerabilities.
Example – SQL Injection MySQL & PHP code: // The next instruction prompts the user is to supply an ID $personID = getIDstringFromUser(); $sqlQuery = "SELECT.
1 Idea: Using System Level Testing for Revealing SQL Injection-Related Error Message Information Leaks Ben Smith Laurie Williams Andrew Austin North Carolina.
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,
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP.
Introduction SQL Injection is a very old security attack. It first came into existence in the early 1990's ex: ”Hackers” movie hero does SQL Injection.
Database and Cloud Security
Joshua Garcia Institute for Software Research
Web Application Security
Web Application Protection Against Hackers and Vulnerabilities
Web Application Vulnerabilities, Detection Mechanisms, and Defenses
Chapter 7: Identifying Advanced Attacks
World Wide Web policy.
API Security Auditing Be Aware,Be Safe
SQL Injection.
Theodore Lawson CSCE548 Student Presentation, Topic #2
Example – SQL Injection
What is REST API ? A REST (Representational State Transfer) Server simply provides access to resources and the REST client accesses and presents the.
Secure Software Development: Theory and Practice
Marking Scheme for Semantic-aware Web Application Security
Penetration Test Debrief
HTML Level II (CyberAdvantage)
Automatically Hardening Web Applications Using Precise Tainting
Presentation transcript:

Approaches to Application Security – DSM Maheshan C N Maheshan.Chemminiyan@lntinfotech.com

Agenda Sample illustration of a SQL Injection Different Approaches to Security Testing Dynamic (Black Box) Vs Static (White Box) Vs Manual Summary

Sample illustration of a SQL injection

SQL Injection

Normal login for JSMITH Username: jsmith Password: *******

Normal login for JSMITH

Username = Apostrophe? The start of a SQL injection attack Password:

Step 1 – We have an error Syntax error in string query expression ‘username = “’ and password = “’

Step 2 – Try a more complete SQL statement Username:’ or username like ‘s%’ or ‘ --

Now we are Sam!

Approaches to Security Testing

Dynamic, Static and Manual (DSM) Potential Security Defects Manual Analysis Static Analysis or White Box Testing Or Code Review WB BB Dynamic Analysis or Black Box Testing

Static and Dynamic Analysis Two types of security analysis: Static and Dynamic Dynamic Analysis Analyzes a running application Looks for issues both within the application and around it Web application scanners, run-time analyzers Users: “black-box” penetration testing specialists Static Analysis Analyzes source code Looks for security issues within the application source code Users: “white-box”, source code auditors, development teams

Dynamic (Black Box) Vs Static (White Box) Manual

How Dynamic (Black Box) Testing Works?

SQL Injection User input is embedded as-is in predefined SQL statements: jsmith demo1234 query = "SELECT * from tUsers where userid='" + + "' AND password='" + + "'"; iUserID iPassword John Smith demo1234 jsmith 1824 Name Password Username UserID SELECT * from tUsers where userid=‘jsmith' AND password=‘demo1234' Hacker supplies input that modifies the original SQL statement, for example: iUserID = ' or 1=1 -- Administrator $#kaoeFor56 admin 1 Name Password Username UserID SELECT * from tUsers where userid=' ' AND password='bar' ' AND password='bar'

Stage 1: Crawling as an honest user How BB Scanners Work Stage 1: Crawling as an honest user http://mySite/ http://mySite/login.jsp http://mySite/feedback.jsp http://mySite/editProfile.jsp http://mySite/logout.jsp

Stage 1: Crawling as an honest user How BB Scanners Work Stage 1: Crawling as an honest user http://mySite/ http://mySite/login.jsp http://mySite/feedback.jsp http://mySite/editProfile.jsp http://mySite/logout.jsp

How BB Scanners Work Stage 1: Crawling as an honest user Stage 2: Testing by tampering requests

How Static (White Box) Testing Works?

Detecting SQL Injection (White Box) Source – a method returning tainted string // ... Stringusername = request.getParameter("username"); Stringpassword = request.getParameter("password"); Stringquery = "SELECT * from tUsers where " + "userid='" +username + "' " + "AND password='" + password + "'"; ResultSet rs = stmt.executeQuery(query); User can change executed SQL commands Sink - a potentially dangerous method

Detecting SQL Injection (White Box) String username = request.getParameter("username"); // ... Stringpassword = request.getParameter("password"); "userid='" +username + "' " + "AND password='" + password + "'"; Stringusername = request.getParameter("username"); Stringquery = "SELECT * from tUsers where " +' String query = "SELECT …" + username ResultSet rs = stmt.executeQuery(query); ResultSet rs = stmt.executeQuery(query);

How WB Scanners Work Many injection problems: Sources: SQLi, XSS, LogForging, PathTraversal, Remote code execution … Sources: Sanitizers: Undecidable problem Sinks:

Pros and Cons of Black Box and White Box testing

Dynamic (Black) Vs Static (White) Feature Dynamic (Black) Static(White) Paradigm Cleverly “guessing” behaviors that may introduce vulnerabilities Examines infinite numbers of behaviors in a finite approach Perspective Works as an attacker HTTP awareness only Works on the big picture Resembles code auditing Inspects the small details Hard to “connect the dots” Pre-Requisite Any deployed application Mainly used during testing stage Application code Mainly used in development stage Development Effort Oblivious to different languages Different communication protocols require attention Different languages require support Some frameworks too Oblivious to communication protocols

Dynamic (Black) Vs Static (White) contd Feature Dynamic (Black) Static(White) Scope Scans the entire system Servers (Application, Http, DB, etc.) External interfaces Network, firewalls Identifies issues regardless of configuration Time/Accuracy Tradeoffs Crawling takes time Testing mutations takes (infinite) time Refined model consumes space and time… Analyzing only “important” code Approximating the rest Accuracy Challenges Challenge: Cover all attack vectors Eliminate non-exploitable issues

Manual Testing Pros and Cons Cheaper than Automated solutions Can identify any form of issues (based on skill set!!!) Cons Lack of security knowledge Time consuming Inconsistent

Dynamic, Static and Manual (DSM) Potential Security Defects Some Authentication Issues Business Logic Issues Some authorization Issues Manual Analysis Static Analysis or White Box Testing Or Code Review WB Dynamic Analysis or Black Box Testing BB Exception Handling Design Issues Threading Issues Potential NULL Derefrences Patch level issues Production Configuration Issues Cross Site Scripting (XSS) Some Configuration Issues SQL Injection

Summary White Box / static analysis covers 80% of your application specific vulnerabilities Black box / dynamic testing is really good for dynamic Vulnerabilities and Infrastructure based issues Manual testing would still be needed to resolve Application logic and authorization based vulnerabilities

Our Business Knowledge Thank you Our Business Knowledge Your Winning Edge