Automated vulnerability scanning and exploitation

Similar documents
Automated vulnerability scanning and exploitation

Automated vulnerability scanning and exploitation

ASL IT SECURITY BEGINNERS WEB HACKING AND EXPLOITATION

WordPress Security Scan Configuration

CS 558 Internet Systems and Technologies

Integrated Network Vulnerability Scanning & Penetration Testing SAINTcorporation.com

Hardening Joomla 1. HARDENING PHP. 1.1 Installing Suhosin. 1.2 Disable Remote Includes. 1.3 Disable Unneeded Functions & Classes

SANS Dshield Webhoneypot Project. OWASP November 13th, The OWASP Foundation Jason Lam

Penetration: from Application down to OS

SEAGATE BUSINESS NAS ACCESSING THE SHELL. February 1, 2014 by Jeroen Diel IT Nerdbox

Hacking de aplicaciones Web

by Debasis Mohanty (Orissa, India)

ABC LTD EXTERNAL WEBSITE AND INFRASTRUCTURE IT HEALTH CHECK (ITHC) / PENETRATION TEST

Pentests more than just using the proper tools

Pentests more than just using the proper tools

Rise of the Machines: An Internet-Wide Analysis of Web Bots in 2014

Hacking the WordpressEcosystem

Exploiting Fundamental Weaknesses in Command and Control (C&C) Panels

3. Broken Account and Session Management. 4. Cross-Site Scripting (XSS) Flaws. Web browsers execute code sent from websites. Account Management

Attack Frameworks and Tools

Web Application Security Payloads. Andrés Riancho Director of Web Security OWASP AppSec USA Minneapolis

Penetration Testing with Kali Linux

Web Security CS th November , Jonathan Francis Roscoe, Department of Computer Science, Aberystwyth University

Advanced Web Security, Lab

Webapps Vulnerability Report

NETWORK PENETRATION TESTS FOR EHR MANAGEMENT SOLUTIONS PROVIDER

RIPS. A static source code analyser for vulnerabilities in PHP scripts. NDS Seminar. A static source code analyser for vulnerabilities in PHP scripts

Is Drupal secure? A high-level perspective on web vulnerabilities, Drupal s solutions, and how to maintain site security

STABLE & SECURE BANK lab writeup. Page 1 of 21

Ethical Hacking Course Layout

WEB Penetration Testing

WHITEPAPER. Nessus Exploit Integration

How to break in. Tecniche avanzate di pen testing in ambito Web Application, Internal Network and Social Engineering

Penetration Testing in Romania

JOOMLA SECURITY. ireland website design. by Oliver Hummel. ADDRESS Unit 12D, Six Cross Roads Business Park, Waterford City

Deep Security/Intrusion Defense Firewall - IDS/IPS Coverage Statistics and Comparison

Passing PCI Compliance How to Address the Application Security Mandates

Cyber Security Challenge Australia 2014

5 Mistakes to Avoid on Your Drupal Website

LT Auditor Windows Assessment SP1 Installation & Configuration Guide

Professional Penetration Testing Techniques and Vulnerability Assessment ...

Guarding Against SQL Server Attacks: Hacking, cracking, and protection techniques.

Don t scan, just ask A new approach of identifying vulnerable web applications. 28th Chaos Communication Congress, 12/28/11 - Berlin

Recon and Mapping Tools and Exploitation Tools in SamuraiWTF Report section Nick Robbins

Deep Security Intrusion Detection & Prevention (IDS/IPS) Coverage Statistics and Comparison

FINAL DoIT v.4 PAYMENT CARD INDUSTRY DATA SECURITY STANDARDS APPLICATION DEVELOPMENT AND MAINTENANCE PROCEDURES

Application Security Testing. Generic Test Strategy

Penetration Testing Report Client: Business Solutions June 15 th 2015

Web Security Threat Report: January April Ryan C. Barnett WASC Member Project Lead: Distributed Open Proxy Honeypots

Analysis of SQL injection prevention using a proxy server

Detecting Web Application Vulnerabilities Using Open Source Means. OWASP 3rd Free / Libre / Open Source Software (FLOSS) Conference 27/5/2008

Offensive Security. Advanced Web Attacks and Exploitation. Mati Aharoni Devon Kearns. v. 1.0

Networks and Security Lab. Network Forensics

Security Threat Kill Chain What log data would you need to identify an APT and perform forensic analysis?

1. Building Testing Environment

EC-Council Certified Security Analyst (ECSA)

EC-Council CAST CENTER FOR ADVANCED SECURITY TRAINING. CAST 619 Advanced SQLi Attacks and Countermeasures. Make The Difference CAST.

XCloner Official User Manual

SQL injection: Not only AND 1=1. The OWASP Foundation. Bernardo Damele A. G. Penetration Tester Portcullis Computer Security Ltd

Web application security

Windows PowerShell Cookbook

SECURING APACHE : THE BASICS - III

Network Security In Linux: Scanning and Hacking

OWASP OWASP. The OWASP Foundation Selected vulnerabilities in web management consoles of network devices

CYBERTRON NETWORK SOLUTIONS

WebCruiser User Guide

From Rivals to BFF: WAF & VA Unite OWASP The OWASP Foundation

InfoSec Academy Pen Testing & Hacking Track

Attacking MongoDB. Firstov Mihail

Web Vulnerability Scanner by Using HTTP Method

Joomla Security Report

SQL Injection. By Artem Kazanstev, ITSO and Alex Beutel, Student

Braindumps.C questions

Content Management System

Cracking the Perimeter via Web Application Hacking. Zach Grace, CISSP, CEH January 17, Mega Conference

Utilizing SFTP within SSIS

Data Breaches and Web Servers: The Giant Sucking Sound

PTSv2 in pills: The Best First for Beginners who want to become Penetration Testers. Self-paced, online, flexible access

Introduction Connecting Via FTP Where do I upload my website? What to call your home page? Troubleshooting FTP...

Magento Security and Vulnerabilities. Roman Stepanov

Acunetix Web Vulnerability Scanner. Getting Started. By Acunetix Ltd.

CCM 4350 Week 11. Security Architecture and Engineering. Guest Lecturer: Mr Louis Slabbert School of Science and Technology.

Hacking Database for Owning your Data

Learning security through insecurity

RIPS - A static source code analyser for vulnerabilities in PHP scripts

ANNEXURE-1 TO THE TENDER ENQUIRY NO.: DPS/AMPU/MIC/1896. Network Security Software Nessus- Technical Details

About This Document 3. About the Migration Process 4. Requirements and Prerequisites 5. Requirements... 5 Prerequisites... 5

BASELINE SECURITY TEST PLAN FOR EDUCATIONAL WEB AND MOBILE APPLICATIONS

CSE598i - Web 2.0 Security OWASP Top 10: The Ten Most Critical Web Application Security Vulnerabilities

Web Application Guidelines

AUTOMATE CRAWLER TOWARDS VULNERABILITY SCAN REPORT GENERATOR

vtiger Customer Portal 4.2 User Manual

Client logo placeholder XXX REPORT. Page 1 of 37

Extending Remote Desktop for Large Installations. Distributed Package Installs

Transcription:

Automated vulnerability scanning and exploitation Dennis Pellikaan Thijs Houtenbos University of Amsterdam System and Network Engineering October 22, 2013 Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 1 / 40

Introduction Open Source scripts Shared on the internet, can be used by anyone Lots of attention for large projects (Wordpress, Joomla, etc) What about the rest? Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 2 / 40

System overview Completely automated system which gathers source code as input and outputs a list of vulnerable servers. Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 3 / 40

Sourceforge Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 4 / 40

Github Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 5 / 40

Github Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 6 / 40

System parts Collect a large number of projects Analyse code for possible vulnerabilities Exploit the findings in a local environment to confirm Search installations of the project online Validate the found installation matches the project Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 7 / 40

Collect projects Two sources Sourceforge GitHub Focus on PHP scripts Automated download and extraction Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 8 / 40

Collect projects Collected projects Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 9 / 40

Analyse code SQL Injection mysql_query ("SELECT * FROM users WHERE id= $_GET[id] "); File Inclusion require $_POST["lang_install"].".php"; Command Injection exec ($_GET[ com ], $result); Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 10 / 40

Regular Expressions Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 11 / 40

Analyse projects Vulnerable projects Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 12 / 40

Analyse projects Vulnerable projects Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 13 / 40

Analyse projects Vulnerability categories Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 14 / 40

Exploit vulnerabilities SQL Injection mysql_query ("SELECT * FROM users WHERE id= $_GET[id] "); File Inclusion require $_POST["lang_install"].".php"; Command Injection exec ($_GET[ com ], $result); Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 15 / 40

Exploit vulnerabilities SQL Injection override_function (mysql_query, log_function); Script sources mysql_query ("SELECT * FROM users WHERE id= $_GET[id] "); Executed log_function ("SELECT * FROM users WHERE id= $_GET[id] "); Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 16 / 40

Exploit vulnerabilities File Inclusion require $_POST["lang_install"].".php"; log_function ($_POST["lang_install"].".php"); Command Injection exec ($_GET[ com ], $result); log_function ($_GET[ com ], $result); Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 17 / 40

Exploit vulnerabilities Request the page http://localhost/myscript/admin.php?id=hacklu Log function Write the function arguments to a logfile Logfile admin.php:137 mysql_query SELECT * FROM users WHERE id = hacklu Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 18 / 40

Exploit vulnerabilities Request the page http://localhost/myscript/admin.php?id=hack lu Log function Write the function arguments to a logfile Logfile admin.php:137 mysql_query SELECT * FROM users WHERE id = hack lu Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 19 / 40

Exploit vulnerabilities Confirmation of results Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 20 / 40

Search Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 21 / 40

Search Google Advanced Search Operators allinurl page.php: require $_GET[ page_id ]; allinurl:"/page.php?page_id=" allintitle index.php: echo "<title>". $title. "</title>"; allintitle:"my special script v0.2a" Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 22 / 40

Search Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 23 / 40

Search Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 24 / 40

Search Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 25 / 40

Search Rotate between 13 IPv4 addresses Pause for 8 seconds between each request 20,000 search queries per day 120,000 results with 22,000 queries Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 26 / 40

Validate search results Find the project s installation root Identify six common file types Compare locally identified files with the remote host Calculate a score Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 27 / 40

Validate search results Installation root: deterministic approach Google result: http://example.com/user/app/login.php?token=432 Local script /script/app/admin/login.php /script/app/admin/ /script/app/ /script/ Remote script /example.com/user/app/admin/login.php /example.com/user/app/admin/ /example.com/user/app/ /example.com/user/ Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 28 / 40

Validate search results Installation root: probabilistic approach Google result: http://example.com/user/app/guide.html Local script /script/a/docs/examples/index.php /script/b/index.html /script/index.php /script/ Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 29 / 40

Validate search results Common file types Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 30 / 40

Validate search results Comparing files Local file /script/images/file1.gif /script/images/logo.png /script/app/js/code.js /script/contact.html Remote file /example.com/user/images/file1.gif /example.com/user/images/logo.png /example.com/user/app/js/code.js /example.com/user/contact.html Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 31 / 40

Validate search results Text matching Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 32 / 40

Validate search results Text matching Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 33 / 40

Validate search results MD5 Hash Matching md5(local File) md5(remote File) LocalScore = 0 RemoteScore = 0 md5(local File) = md5(remote File) LocalScore = 100 RemoteScore = 100 Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 34 / 40

Validate search results Calculating the final score Score between 0 and 100 Number of identified files is taken into account LocalScore and the RemoteScore are weighted Score = N i=1 S i N + N i=1 S i 1 6 LocalScore i +RemoteScore i 4 S i = N = Total number of selected files Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 35 / 40

Validate search results Validated website scores Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 36 / 40

Results Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 37 / 40

System overview Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 38 / 40

Questions Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 39 / 40

Contact Contact: Dennis: Thijs: dennis.pellikaan@os3.nl thijs.houtenbos@os3.nl Paper reference: http://rp.delaat.net/2012-2013/p91/report.pdf Dennis Pellikaan, Thijs Houtenbos Automated vulnerability scanning and exploitation 40 / 40