- Jaimin Gohel
A web browser is a software program that allows a user to locate, access, and display web pages. In common usage, a web browser is usually shortened to "browser."
Cross-site scripting is a type of computer security vulnerability typically found in web applications. XSS enables attackers to inject client-side scripts into web pages viewed by other users.
Stored Cross-site Scripting
Reflected Cross-site Scripting
DOM Based Cross-Site Scripting
Denial of service attack makes impossible to access the resource by flooding it with useless traffic.
Remote code execution is the ability an attacker has to access someone else's computing device and make changes, no matter where the device is geographically located.
Demo
Same Origin Policy (SOP), also called Single Origin Policy, is a security measure used in Web browser.
Same Origin Policy prevents a web site's scripts from accessing and interacting with scripts used on other sites.
SOP Bypass CVE 2014-6041
SOP bypass found in webview pre - KitKat , Web view happens to be the core component of android used for rendering pages on android devices, It utilizes webkit rendering engine at the backend.
<iframe name="test" src="http://www.rhainfosec.com"></iframe>
<input type=button value="test"
onclick="window.open('\u0000javascript:alert(document.domain)','test')" >
The above POC loads a page in an iframe and then tries to access its document.domain property using javaScript which should not be accessible as per same origin policy. However, in this case it is able to execute JavaScript in context of the domain that was framed.
The most interesting part of POC , however is the null byte which is appended before the “JavaScript” scheme which results in a bypass.
Content Security Policy (CSP) is a computer security standard introduced to prevent cross-site scripting (XSS), clickjacking and other code injection attacks resulting from execution of malicious content in the trusted web page context.
Content-Security-Policy: default-src 'self';
script-src 'self';
script-src 'self' www.google-analytics.com ajax.googleapis.com;
default-src 'none'; script-src 'self'; connect-src 'self';
img-src 'self'; style-src 'self';
This policy allows images, scripts, AJAX, and CSS from the same origin, and does not allow any other resources to load (eg object, frame, media, etc). It is a good starting point for many sites.
Content spoofing, also referred to as content injection or virtual defacement, is an attack targeting a user made possible by an injection vulnerability in a web application.
This attack is typically used as, or in conjunction with, social engineering because the attack is exploiting a code-based vulnerability and a user's trust.
BeEF is short for The Browser Exploitation Framework. It is a penetration testing tool that focuses on the web browser.
What can be done?
Browser Exploitation for Fun and Profit - Dhiraj Mishra
Browser Exploitation Framework