#
#asahi-re · 2022-07-17 06:10
nicolas17so in hardware/wiring it's not AP <-> SEP <-> mesa as I said earlier, rather it's SEP <-> AP <-> mesa; *but* it's encrypted end-to-end
#asahi-re · 2022-07-17 06:10
chadmedyeah it cant i tried poking at the big data packet and it was all nonsense
#asahi-re · 2022-07-17 06:07
svenpretty sure that’s how it works
#asahi-re · 2022-07-17 06:07
nicolas17but yeah I believe the AP can't see raw fingerprint data by design
#asahi-re · 2022-07-17 06:06
nicolas17take none of this as fact, I'm joining the speculation :)
#asahi-re · 2022-07-17 06:05
nicolas17and maybe you don't see that because the SEP tracer isn't catching it
#asahi-re · 2022-07-17 06:04
nicolas17if that's right, then you should see the encrypted garbage being sent to mesa actually came verbatim from the SEP, and viceversa, and the AP is just forwarding ciphertext back and forth
#asahi-re · 2022-07-17 06:02
nicolas17I'm not entirely sure, there's some ambiguity in the way this is written, or I'm too tired to read it confidently
#asahi-re · 2022-07-17 06:01
nicolas17https://support.apple.com/guide/security/face-id-and-touch-id-security-sec067eb0c9e/web
#asahi-re · 2022-07-17 06:01
nicolas17rather the AP has to forward the data between them, but it's encrypted and the AP can't see what it is
#asahi-re · 2022-07-17 06:00
nicolas17hm, I think there isn't a direct SEP-Mesa hardware connection
#asahi-re · 2022-07-17 05:57
chadmedbut idk what it is now im doubting myself constantly :P
#asahi-re · 2022-07-17 05:57
chadmedit does send some silly amount of data over SIO when your finger is on it, which i originally thought might be fingerprint data
#asahi-re · 2022-07-17 05:56
chadmedbut alas no
#asahi-re · 2022-07-17 05:56
chadmedwell my initial plan was to see if we could get fingerprint data out of mesa directly somehow and do it like that until the SEP works
#asahi-re · 2022-07-17 05:55
nicolas17I thought you had to do that anyway
#asahi-re · 2022-07-17 05:55
chadmedif we sort of do the same thing apple does (use the SEP to mediate authentication) then we might not need to, but then touchid support is effectively blocked until we have SEP support
#asahi-re · 2022-07-17 05:54
chadmedyeah so figuring out how mesa interacts with the SEP is going to be almost impossible
#asahi-re · 2022-07-17 05:54
nicolas17SEP for older iPhones can be decrypted, but I'm not sure how useful it would be
#asahi-re · 2022-07-17 05:53
nicolas17the Mac SEP FW is encrypted
#asahi-re · 2022-07-17 05:49
chadmedthe SEP FW is encrypted so we cant really look at it in ghidra can we?
#asahi-re · 2022-07-17 05:49
chadmedto effectively trace mesa i think we need to know a) the endpoint in the SEP the APs use to talk to it about mesa, and b) whatever interface mesa talks to the SEP over which might even just be staight up impossible idk
#asahi-re · 2022-07-17 05:48
chadmedi did try hacking on the tracer sven wrote but it was a goose chase
#asahi-re · 2022-07-17 05:47
nicolas17ah, need better SEP tracing first, I see
#asahi-re · 2022-07-17 05:47
chadmedwell yeah but like i said the SEP tracer isnt really useful for this (yet)
#asahi-re · 2022-07-17 05:46
chadmedand these are the only two DMA channels associated with mesa on the SPI bus so it _must_ be talking to the SEP over a private interface
#asahi-re · 2022-07-17 05:46
nicolas17could it be doing the "negotiation" via the SEP?
#asahi-re · 2022-07-17 05:46
chadmedit just stops after powering it on then a few seconds later there is encrypted data
#asahi-re · 2022-07-17 05:46
chadmedtheres no apparent negotiation or anything like that
#asahi-re · 2022-07-17 05:45
chadmedand i say that because after the power on pings early in boot, theres no more data sent across the interface for a while then all of a sudden there is just encrypted commands
#asahi-re · 2022-07-17 05:45
chadmedi could probably check without dicking around in m1n1 too but im like ~80% sure that its not the full fat driver
#asahi-re · 2022-07-17 05:44
nicolas17can m1n1 set a breakpoint on that code, so you know which one is running?
#asahi-re · 2022-07-17 05:43
chadmedBUT, theres also a much much smaller driver which is just a shim for the SEP interface and i think thats the one these machines use
#asahi-re · 2022-07-17 05:43
chadmedtheres a few functions in one of the mesa drivers associated with encrypting and transmitting a command buffer
#asahi-re · 2022-07-17 05:42
nicolas17well how does the AP come up with that encrypted buffer? either it has some plaintext and encrypts it, or it gets encrypted data from (say) the SEP and forwards it
#asahi-re · 2022-07-17 05:40
nicolas17but that would need code-level RE
#asahi-re · 2022-07-17 05:40
chadmedi dont think it is
#asahi-re · 2022-07-17 05:40
nicolas17if it's the AP encrypting it, it should be possible to intercept...
#asahi-re · 2022-07-17 05:39
chadmedafter that the data is encrypted and changes on every boot (the format/packet size stays the same though which is why i think its an encrypted command buffer)
#asahi-re · 2022-07-17 05:38
chadmedthe only repeatable and intelligible data is a bringup sequence (which seems to just be the APs asking if its awake)
#asahi-re · 2022-07-17 05:38
nicolas17interesting
#asahi-re · 2022-07-17 05:38
nicolas17I always thought it was AP <-> SEP <-> mesa sensor, and no AP <-> mesa connection at all
#asahi-re · 2022-07-17 05:37
chadmedno it talks to the APs over the same SIO interface that the kb and touchpad do
#asahi-re · 2022-07-17 05:37
nicolas17oh what? I thought the touchid sensor was connected to the SEP *only*
#asahi-re · 2022-07-17 04:35
chadmedand to really rub salt in the wound, tracing the SEP is too slow to reliably get anything useful. mesa seems to time out waiting for the SEP to tell it something which invalidates the input data and makes macos refuse to accept it
#asahi-re · 2022-07-17 04:33
chadmedthe only data that is trafficked between it and the APs seems to be an encrypted command buffer of some kind to bring it up and tell it to wait for a fingerprint. everything else goes to the SEP
#asahi-re · 2022-07-17 04:31
chadmedrqou_: i gave up on touchid (mesa) if you wanna have a crack at that. it has a private interface to SEP that i _think_ might be impossible to snoop on from the HV and im not skilled enough to really go beyond what ive already pushed into m1n1 :/
#asahi-re · 2022-07-17 00:04
rqou_do you have any notes on avd?
#asahi-re · 2022-07-17 00:00
Jamie[m](although AVE might be completely un-looked-at too?)
#asahi-re · 2022-07-16 23:59
JTL:(

plus ›