Re:Intel SA-00145: Lazy FP State Restore
by cperciva on Wednesday June 13, 2018 @07:10PM
(#17307818)
"FP State" in this case includes MMX and SSE registers; they're handled via the same "lazy context switching" mechanism. Yes, you can steal keys which are being used for AESNI.
Leaking secrets via javascript -- I'll be impressed if someone pulls that off. There's a very tight timing window to exploit this before a trap fires and flushes your pipeline, and I doubt you can get the right instructions in there using javascript.
Can't you executive the trapping access in a not-taken speculatively-executed branch à la Meltdown?
Re:Intel SA-00145: Lazy FP State Restore
by cperciva on Wednesday June 13, 2018 @09:04PM
(#17308425)
Sure, but that gives you an even shorter window because the pipeline flushes as soon as the CPU realizes that it mis-speculated.
It is my understanding that you can make that window very long by having the mis-speculated branch depend on a value that has to be loaded from main memory.
Hmm, good point. Yes, that would probably make this much easier to exploit.
Unless the CPU does a partial pipeline flush upon realizing that there would be a trap. I don't know -- do Intel CPUs check for exceptions in order?
Well, they don't for #PF at least, because that's how Meltdown works - I'm not sure if it works differently for #NM though.
Re:Intel SA-00145: Lazy FP State Restore
by ndesaulniers on Wednesday June 13, 2018 @08:02PM
(#17308124)
Rarely contain interesting stuff, like parts of AES keys.
If this also affects register used for crypto acceleration then it could be used for stuff like leaking browser secrets from javascript, right?