Intent Scheme URL 漏洞 - parseUri方法


一、Intent scheme URL的解析及过滤


1. 利用 Intent.parseUri 解析uri,获取原始的intent对象


2. 对intent对象设置过滤规则,不同的浏览器有不同的策略


3. 通过Context.startActivityIfNeeded或者Context.startActivity发送intent


4. 其中,步骤2起关键作用,过滤规则缺失或者存在缺陷都会导致Intent Schem URL攻击


二、触发条件


1. Intent.parseUri()


【1】对应到smali中的特征:Landroid/content/Intent;->parseUri(


【2】缺失过滤规则:

  Intent.addCategory("android.intent.category.BROWSABLE")

  Intent.setComponent(null)

  Intent.setSelector(null)


三、漏洞原理


【1】如果浏览器支持Intent Scheme Uri语法,如果过滤不当,那么恶意用户可能通过浏览器js代码进行一些恶意行为,比如盗取cookie等。如果使用了Intent.parseUri函数,获取的intent必须严格过滤,intent至少包含addCategory(“android.intent.category.BROWSABLE”),setComponent(null),setSelector(null)3个策略


【2】详细的原理&POC,参考链接:


Android Intent Scheme URLs攻击


http://wolfeye.baidu.com/blog/intent-scheme-url/

http://drops.wooyun.org/papers/2893


四、修复建议


Intent Scheme URL 漏洞_第1张图片" width="650" height="265" style="border:1px solid black;">

更多相关文章

  1. android浏览器研究-UserAgent
  2. ColorMatrixColorFilter颜色过滤(离线用户的灰色头像处理)
  3. Android--调用内置的浏览器
  4. 全球十个最佳Android应用
  5. 从 Chrome 谈到 Adobe
  6. Android(安卓)logcat保存当前应用程序的日志并上传服务器或指定
  7. Android常见漏洞介绍(1):Intent Scheme URL 攻击
  8. 2013.09.04——— android Location 过滤最佳的位置
  9. APPS大乱斗:4大Android文件浏览器横评(七)

随机推荐

  1. 在android下获取有线和无线IP地址的方法,
  2. Android菜单的定义及ActionBar的实现
  3. android camera开发笔记
  4. Android之selector
  5. error: Error retrieving parent for ite
  6. Android学习笔记Android必备开发工具之一
  7. android studio external tool 自定义工
  8. 【Android】音效配置文件 audio_effects.
  9. android Gridview生成程序快捷键的复杂方
  10. Android(安卓)studio报错module not spec