IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 1 Active Man in the Middle Attacks The.

Slides:



Advertisements
Similar presentations
Transfer Content to a Website What is FTP? File Transfer Protocol FTP is a protocol – a set of rules Designed to allow files to be transferred across.
Advertisements

Enabling Secure Internet Access with ISA Server
© 2009 IBM Corporation IBM Rational Application Security The Bank Job Utilizing XSS Vulnerabilities Adi Sharabani IBM Rational Application Security Research.
Chapter 17: WEB COMPONENTS
ARP Cache Poisoning How the outdated Address Resolution Protocol can be easily abused to carry out a Man In The Middle attack across an entire network.
How the Internet Works Course Objectives Introduce the various web browsers Introduce some new terms Explain the basic Internet to PC hookup  ISP  Wired.
Session Hijacking Why web security depends on communications security and how TLS everywhere is the only solution. Scott Helme - 6th Aug scotthel.me.
1 Web Servers / Deployment Alastair Dawes Original by Bhupinder Reehal.
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation.
OPSEC Awareness Briefing Man-In-The-Middle Attacks (MITM)
Security Issues and Challenges in Cloud Computing
It’s always better live. MSDN Events Security Best Practices Part 2 of 2 Reducing Vulnerabilities using Visual Studio 2008.
Security Awareness: Applying Practical Security in Your World, Second Edition Chapter 5 Network Security.
Man in the Middle Paul Box Beatrice Wilds Will Lefevers.
It’s always better live. MSDN Events Securing Web Applications Part 1 of 2 Understanding Threats and Attacks.
Cookies COEN 351 E-commerce Security. Client / Session Identification HTTP does not maintain state. State Information can be passed using: HTTP Headers.
1 Enabling Secure Internet Access with ISA Server.
ITGS Networks Based on the textbook “Information Technology in a Global Society for the IB Diploma” by Stuart Gray.
11 SUPPORTING INTERNET EXPLORER IN WINDOWS XP Chapter 11.
Introduction to InfoSec – Recitation 10 Nir Krakowski (nirkrako at post.tau.ac.il) Itamar Gilad (itamargi at post.tau.ac.il)
CS426Fall 2010/Lecture 361 Computer Security CS 426 Lecture 36 Perimeter Defense and Firewalls.
Evolving Threats. Application Security - Understanding the Problem DesktopTransportNetworkWeb Applications Antivirus Protection Encryption (SSL) Firewalls.
Session Hijacking & ARP Poisoning Why web security depends on communications security and how TLS everywhere is the only solution.
IT 210 The Internet & World Wide Web introduction.
Intranet, Extranet, Firewall. Intranet and Extranet.
HTML5 Group 3: Dongyang Zhang, Wei Liu, Weizhou He, Yutong Wei, Yuxin Zhu.
1-Vulnerabilities 2-Hackers 3-Categories of attacks 4-What a malicious hacker do? 5-Security mechanisms 6-HTTP Web Servers 7-Web applications attacks.
Csci5233 Computer Security1 Bishop: Chapter 27 System Security.
Implementing ISA Server Publishing. Introduction What Are Web Publishing Rules? ISA Server uses Web publishing rules to make Web sites on protected networks.
Web Browser Security Prepared By Mohammed EL-Batta Mohammed Soubih Supervised By Eng. Eman alajrami Explain Date 10. may University of Palestine.
1 Chapter 6: Proxy Server in Internet and Intranet Designs Designs That Include Proxy Server Essential Proxy Server Design Concepts Data Protection in.
IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 1 Active Man in the Middle Attacks The.
1 C-DAC/Kolkata C-DAC All Rights Reserved Computer Security.
Security+ Guide to Network Security Fundamentals, Fourth Edition
CSCE 201 Web Browser Security Fall CSCE Farkas2 Web Evolution Web Evolution Past: Human usage – HTTP – Static Web pages (HTML) Current: Human.
Drive-by pharming is an interesting type of networking attack that combines multiple networking vulnerabilities and average user laziness to create an.
Grid Chemistry System Architecture Overview Akylbek Zhumabayev.
Web Applications Testing By Jamie Rougvie Supported by.
Electronic Security Initiative 2005 Security Assessment & Security Services 23 August 2005.
Lecture 16 Page 1 CS 236 Online Web Security CS 236 On-Line MS Program Networks and Systems Security Peter Reiher.
TCP/IP (Transmission Control Protocol / Internet Protocol)
Saphe surfing! 1 SAPHE Secure Anti-Phishing Environment Presented by Uri Sternfeld.
MEMBERSHIP AND IDENTITY Active server pages (ASP.NET) 1 Chapter-4.
Cookies COEN 351 E-commerce Security. Client / Session Identification HTTP Headers Client IP Address HTTP User Login FAT URLs Cookies.
TCP/IP Model & How it Relates to Browsing the Internet Anonymously BY: HELEN LIN.
Mohammed F & Aya. Peer-to-peer network are usually common in homes and small businesses and are not necessarily expensive. On a peer-to-peer network each.
ITGS Network Architecture. ITGS Network architecture –The way computers are logically organized on a network, and the role each takes. Client/server network.
Web Security Lesson Summary ●Overview of Web and security vulnerabilities ●Cross Site Scripting ●Cross Site Request Forgery ●SQL Injection.
Chapter 12: How Private are Web Interactions?. Why we care? How much of your personal info was released to the Internet each time you view a Web page?
Web Browsing *TAKE NOTES*. Millions of people browse the Web every day for research, shopping, job duties and entertainment. Installing a web browser.
CSRF Attacks Daniel Chen 11/18/15. What is CSRF?  Cross Site Request Forgery (Sea-Surf)  AKA XSRF/ One Click / Sidejacking / Session Riding  Exploits.
SSH. 2 SSH – Secure Shell SSH is a cryptographic protocol – Implemented in software originally for remote login applications – One most popular software.
11 SUPPORTING INTERNET EXPLORER IN WINDOWS XP Chapter 11.
Chapter 7: Using Network Clients The Complete Guide To Linux System Administration.
FOOTPRINTING PROXY A proxy server is essentially a middle computer that sits between the attacker and the Victim. To mask your ip under a proxy server.
ArcGIS for Server Security: Advanced
Chapter 5 Electronic Commerce | Security Threats - Solution
Web Application Vulnerabilities, Detection Mechanisms, and Defenses
World Wide Web policy.
Secure Software Confidentiality Integrity Data Security Authentication
Chapter 5 Electronic Commerce | Security Threats - Solution
Introduction to Networking
Riding Someone Else’s Wave with CSRF
Web Security Advanced Network Security Peter Reiher August, 2014
Web Servers / Deployment
Active Man in the Middle Attacks
Designing IIS Security (IIS – Internet Information Service)
Exploring DOM-Based Cross Site Attacks
Securing web applications Externally
Presentation transcript:

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 1 Active Man in the Middle Attacks The OWASP Foundation OWASP 27/02/2009 Adi Sharabani Security Research Group Manager IBM Rational Application Security (a.k.a. Watchfire) adish

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 2 Agenda  Background –Man in the Middle –Network level – heavily researched –Web application level – sporadic research  Outline –Passive MitM attacks –Active MitM attacks –Penetrating an internal network –Remediation

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 3 Man in the Middle Scenario  All laptop users connect to a public network  Wireless connection can easily be compromised or impersonated  Wired connections might also be compromised Internet Internet

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 4 Rules of Thumb – Don’ts …  Someone might be listening to the requests –Don’t browse sensitive sites –Don’t supply sensitive information  Someone might be altering the responses –Don’t trust any information given on web sites –Don’t execute downloaded code

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 5 Rules of Thumb – What Can You Do?  This leaves us with: –Browse your favorite news site –Browse your favorite weather site Internet Internet Non-sensitive sites Boring Non-sensitive sites Boring Sensitive sites Interesting Sensitive sites Interesting

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 6 You are still vulnerable

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 7 Mitigating a Fallacy  Fallacy –Executing JavaScript on victim == executing an attack  Reality –Same origin policy –Executing an attack –JavaScript + browser implementation bug –JavaScript + execution on a specific domain –Can be done through XSS

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 8 Passive Man in the Middle Attacks Victim browses to a website Attacker views the request manipulates it and forwards to server Attacker views the response manipulates it and forwards to victim Server returns a response Other servers are not affected

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 9 Active Man in the Middle Attack  The attacker actively directs the victim to an “interesting” site  The IFrame could be invisible Victim browses to a “boring” site Attack transfers the request to the server Attacker adds an IFRAME referencing an “interesting” site Server returns a response My Weather Channel My Bank Site Automatic request sent to the interesting server My Bank Site Other servers are not affected

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 10

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 11 Stealing Cookies* Automatic request contains victim’s cookies  Obvious result  Stealing cookies associated with any domain attacker desires  Will also work for HTTP ONLY cookies (as opposed to XSS attacks) * A similar attack was presented by Mike Perry – SideJacking

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 12 Demo

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 13 Overcoming Same Origin Policy Attacker adds a malicious script to the response Attacker adds a malicious script to the response Attacker forwards the automatic request to the “interesting” server Script executes with the “interesting” server’s restrictions “Interesting” server returns a response Attacker injects an IFRAME directing to an “interesting” site Victim surfs to a “boring” site Automatic request sent to the interesting server  Result –Attacker can execute scripts on any domain she desires –Scripts can fully interact with any “interesting” website  Limitations –Will only work for non SSL web sites

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 14 Secure Connections Login Mechanism

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 15 Secure Connections Please Login Username Password SUBMIT jsmith ******** SUBMIT Victim browses to site Victim browses to site Site returns a response with login form Victim fills login details, and submits the form Login request is sent through a secure channel Login Successful Hello John Smith,  Pre-login action sent in clear text  Attacker could alter the pre-login response to make the login request sent unencrypted

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 16 Stealing Auto Completion Information Script accesses the auto-completion information using the DOM Attacker redirect victim to a request to a pre-login page Attacker returns the original login form together with a malicious script * A passive version of this attack was described by RSnake in his blog  Result –Attacker can steal any auto-completion information she desires  Limitations –Will only work for pre-login pages not encrypted –Will not work seamlessly in IE

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 17 Demo

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 18 Broadening the Attack (Time Dimension)

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 19 Passive MitM Attacks Active MitM Attacks Present (“boring” sites) Present (“boring” sites) Past (“interesting” sites) Past (“interesting” sites) Future (“interesting” sites) Future (“interesting” sites)

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 20 Session Fixation Cookie is being saved on victim’s computer Attacker redirects victim to the site of interest Attacker returns a page with a cookie generated by server A while later, victim connects to the site (with the pre-provided cookie) A while later, victim connects to the site (with the pre-provided cookie) Attacker uses the same cookie to connect to the server Server authenticates attacker as victim  Result –Attacker can set persistent cookies on victim  Limitations –The vulnerability also lies within the server

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 21 Cache Poisoning Page is being cached on victim’s computer Attacker redirects victim to the site of interest Attacker returns a malicious page with cache setting enabled A while later, victim visits the site A while later, victim visits the site  Result –Attacker can poison any page she desires –Poisoned pages will be persistent  Limitations –Attacker can poison non SSL resources

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 22 Demo

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 23 Complex Hacking Virtual Private Networks

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 24 Virtual Private Networks (VPN)  VPN client initialization –Create a secure network interface –Set user’s routing table  VPN client finalization (upon exit or when connection is lost) –Revert routing table Do not confuse VPN and HTTPS architectures!

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 25 VPN Mixed content Internal Web Site...  Result  VPN web sites are compromised  User is not alerted to the security risk  As opposed to SSL mixed content issues  Limitations  Such mixed content is not widely used Malicious script executes within the secure environment Attacker alters the non- encrypted script Victim surfs to a page in the VPN network

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 26 Hacking Non-Available Sites  Result  Attacker can view and change any HTTP cache object  Even for non available sites

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 27 VPN Cache Injection Attacker disconnects connection to VPN Server After routing table is updated, Attacker poisons the cache of an internal site Attacker recovers connection Cached resource loads and malicious cached script executes Attacker redirects victim to cached resource  Result  VPN is great for the network level  VPN is not enough for the application level  This attack could be applied to other application protocols!

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 28 Complex Hacking Intranet Networks

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 29 Penetrating Internal Network – Simple Cache Poison  Result  Attack will be launched every time victim accesses the resource  The attack would executed within the local intranet  Characteristics  Firewall protections are helpless  Affected servers will never know  The attack is persistent

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 30 Setting Up a Future MitM Scenario  Result  Facilitates future MitM scenarios  Does not require router’s credentials  Fake settings could be displayed to the user  Limitations  Requires victim to access router in the future  Need to guess router’s address ( ) Using Active MitM Techniques, attacker poisons victim’s cache related to his router’s web access Using Active MitM Techniques, attacker poisons victim’s cache related to his router’s web access Router Victim’s router related cache poisoned with a malicious script Script hides the configuration changes Malicious script executed when victim tries to access router Script configures router to tunnel future communication through attacker Outbound Proxy IP Address Primary DNS Server Address

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 31 Increasing the Exposure  Poison common home pages –Script will execute every time victim opens his browser  Poison common scripts –Script will execute on every page using the common script –Example:  The “double active” attack –Common poisoned page redirects to another poisoned resource.JS

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 32 The Double Active Cache Poisoning Attack Using Active MitM techniques, attacker poisons common router’s address (i.e ) Using Active MitM techniques, attacker poisons common router’s address (i.e ) At a later time, Victim opens browser At a later time, Victim opens browser Cached home page is loaded and redirects victim’s browser to router’s web interface Cached router’s web interface is loaded and malicious script changes router’s settings  Result  Internal network has been compromised  Limitation  Need to guess router IP and credentials Attacker also poisons common home pages Router Router is compromised by malicious script

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 33 Active Attack Characteristics –Not noticeable in user’s experience –Not noticeable by any of the web sites –IPS/IDS will not block it –Can be persistent –Can be used to hack into local organization –Bypasses any firewall or VPN –Can be used with DNS Pinning Techniques –A problem with the current design –Requires only one plain HTTP request to be transmitted

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 34 Remediation  Users –Do not use auto-completion –“Clean Slate Policy” –Trust level separation –Two different browsers –Two different users –Two different OS –Virtualization products –Tunnel communication through a secure proxy –Might not be allowed in many hot-spots

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 35  Web owners –Consider risks of partial SSL sites –Do not consider secure VPN connection as an SSL replacement –Use random tokens for common scripts –While considering performance issues –Avoid referring external scripts from internal sites

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 36  Industry –Build integrity mechanism for HTTP –Secure WiFi networks

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 37 Summary  Active MitM attacks– broaden the scope of the passive attacks –Design issues –Dimension of time –Past (steal cookies, auto-completion information, cache) –Future (set up cookies, poison cache, poison form filler) –Penetrating internal networks –Persistent –Bypass any current protection mechanisms  More information: –Paper and presentation will be uploaded to our blog:

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 38 References  Watchfire’s Blog:   Wireless Man in the Middle Attacks: –  SideJacking: –  More on SideJacking: –  Active SideJacking: –  Surf Jacking –  Stealing User Information: –

IBM Rational Application Security Group (aka Watchfire) Web Based Man In the Middle Attack © 2009 IBM Corporation 39 Thank you!