求翻译: Intent and Intent filters

CHR_WHY 2011-06-14 02:16:32
Filters and security
An intent filter cannot be relied on for security. While it opens a component to receiving only certain kinds of implicit intents, it does nothing to prevent explicit intents from targeting the component. Even though a filter restricts the intents a component will be asked to handle to certain actions and data sources, someone could always put together an explicit intent with a different action and data source, and name the component as the target.

在 android的官方文档上发现一段话, 不知道怎样去翻译理解,
尤其是 :it does nothing to prevent explicit intents from targeting the component.
...全文
76 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
xinqiqi123 2011-06-14
  • 打赏
  • 举报
回复
这段话的主要意思就是说用the intent filter是不安全的
it does nothing to prevent explicit intents from targeting the component意思大概是:
the intent filter根本不能阻止一些显式的intent到达组件上
lizhengjun2010 2011-06-14
  • 打赏
  • 举报
回复
intent ,官方译为 意图
intent-filter ,可知为 意图过滤器

intent ,连接组件的桥梁,即一个组件启动另一个组件需要intent,
如Activity 启动activity : intent.setClass(a.this,b.class);startActivity(intent);
Activity启动service: intent.setClass(a.this,b.class);startService(intent);

详细内容:
http://hi.baidu.com/lizhengjun2010/blog/item/2f458c05393758ce267fb557.html

80,492

社区成员

发帖
与我相关
我的任务
社区描述
移动平台 Android
androidandroid-studioandroidx 技术论坛(原bbs)
社区管理员
  • Android
  • yechaoa
  • 失落夏天
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧