4 ms·
It’s like the ‘you can store a virus in a jpeg and running it just requires this decoder’ “scare” from a decade back.
by tinus_hn 7y ago
It’s like the ‘you can store a virus in a jpeg and running it just requires this decoder’ “scare” from a decade back.
- baroffoos 7y agoDon't joke. I have had security people report my stuff is insecure because there is a document upload feature and a user could upload a virus and name it virus.png and then a user could download it and rename it to virus.exe and run it.
- fulafel 7y agoChange the scenario to "download it and double click it, exploiting vuln in file format handler" and it's correct.
- baroffoos 7y agoAt that point you may as well ban all user generated content since one user might have an insecure OS
- fulafel 7y agoWell, security engineering is about tradeoffs and managing risk, you won't get far outlawing all sources of risk. The smart way to handle attachments is to scrub them somehow (re-encode, pdf2pdf etc).
- badrabbit 7y agoThat is actually a serious issue especially if you allow unicode and RTL override in the file name. Always validate input file type.
- gruez 7y agoMS07-052: Code execution results in code execution https://devblogs.microsoft.com/oldnewthing/?p=25683 https://devblogs.microsoft.com/oldnewthing/?p=25683
- badrabbit 7y agoThat's very interesting but I have to disagree with the response. The vuln might be used iirc to bypass signature verification of the PE? It might also possibly be used to evade sandbox analysis of malware, AV heuristics and ML based approaches might also be thrown off guard. But yes, It would have been a lot more interesting if there are cases where the executable is attacker controlled and the exploit would end up running code as the privileged parent process or some other user that has more rights.
- satanspastaroll 7y agoModifying the binary should change it's digital signature, making it invalid in the first place. Running unsigned code is running arbitrary code
- badrabbit 7y agoNo,what I meant was the header containing the signature does not get included in PE sig verification, since sig/certs are part of the header to begin with, or at least large parts of the header are not included. I vaguely remember bypass techniques that depended on this.
- fulafel 7y agoThat's plausible and could have been implemented, by exploiting RCE vulnerabilities in jpeg decoder libraries.