liyafe1997
V2EX  ›  Android

为什么 Android 插 USB 仅充电要实现一个空的 MTP 设备

  •  
  •   liyafe1997 · Dec 11, 2023 · 11803 views
    This topic created in 900 days ago, the information mentioned may be changed or developed.

    从安全的角度讲,直接禁用掉整个 USB slave system ,禁止任何数据传输不是更安全吗?

    6 replies    2023-12-12 23:05:53 +08:00
    BruceXu
        1
    BruceXu  
       Dec 12, 2023
    瞎猜一下,对接口做一个空的实现比直接传 null 要好???哈哈
    irrigate2554
        2
    irrigate2554  
       Dec 12, 2023
    有的极致优化耗电的系统,在 USB 端口没有 Device 的时候会直接断电
    liyafe1997
        3
    liyafe1997  
    OP
       Dec 12, 2023
    @xausky 但实现一个空的 USB 设备也比 MTP 要好?
    liyafe1997
        4
    liyafe1997  
    OP
       Dec 12, 2023
    @xubingok 不知道有没有这种可能,Linux Kernel 的 MTP Driver 有存在漏洞的可能,就算是个空的 MTP 设备,按 MTP 协议发一些什么数据过去让它溢出有可能能拿到内核权限(手动滑稽
    irrigate2554
        5
    irrigate2554  
       Dec 12, 2023
    @liyafe1997 那岂不是太好了,不用考试就能解锁 BL ,建议多来点
    felixlong
        6
    felixlong  
       Dec 12, 2023
    @liyafe1997 那会使用户插上电脑之后显示个不认识的设备。明显没有空的 MTP 设备体验好。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1104 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 17:59 · PVG 01:59 · LAX 10:59 · JFK 13:59
    ♥ Do have faith in what you're doing.