how we hacked
play

How we hacked and how you can be safe and what happened next Ruben - PowerPoint PPT Presentation

How we hacked How we hacked and how you can be safe and what happened next Ruben van Vreeland Ruben van Vreeland Web Application Security Web hosting / infrastructure Web applications / platforms VB6, C#, PHP, (Spring) Java


  1. How we hacked How we hacked and how you can be safe and what happened next Ruben van Vreeland

  2. Ruben van Vreeland • Web Application Security • Web hosting / infrastructure • Web applications / platforms • VB6, C#, PHP, (Spring) Java • The art of exploitation of the Web • Co-Founder BitSensor: security & insight

  3. Fixed

  4. Fixed

  5. Black magic?

  6. The ¡art ¡of ¡exploita.on • Dissect ¡in ¡5 ¡steps ¡ • Intro ¡XSS ¡ ¡ • Visual ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡HTML ¡+ ¡styling ¡ ¡ • Whitelist ¡bypass ¡ ¡ • Internet ¡Explorer ¡password ¡autocomplete ¡ ¡ • ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡combining ¡both ¡ ¡

  7. Easy ¡intro ¡XSS

  8. Browser ¡Exploita.on ¡Framework User ¡Data ¡ Change ¡Data ¡ XSS ¡ Bootstrap ¡ Payload ¡ Passwords ¡ WEBPAGE ¡ WEBPAGE ¡ BeEF ¡ Comand ¡& ¡Control ¡ BROWSER ¡ Firewalled ¡

  9. Common ¡XSS ¡vectors Unsani.z Unsani.zed ed ¡HTML HTML <script>payload</script> Unesc Unescaped aped ¡ ¡aGribut aGribute <img ¡src=“ ” ¡/><script>payload</script><a ¡“ ” ¡/> <img ¡src=“/favicon.png” ¡onload=“payload” ¡/> Unsani.z Unsani.zed ed ¡ ¡aGribut aGribute ¡c ¡con onten ent <a ¡href=“javascript:payload” ¡/> Unsani.z Unsani.zed ed/Wr Wrongly ¡ ¡en encod oded ed ¡scrip ¡script Var ¡a ¡= ¡b; ¡ ¡Payload; Unsani.z Unsani.zed ed ¡S ¡Style ¡( yle ¡(ol older er ¡IE ¡ ¡IE ¡on only) ) <img ¡src=“” ¡style=“width: ¡expression(payload); ¡” ¡/>

  10. <a ¡href="javascript:alert(/Exploit ¡me!/)"> javascript:alert(/Exploit ¡me!/) </a> ¡ ¡

  11. <a href=“javascript:payload” style=“ background: rgba(255, 0, 0, 0.5); position: fixed; left: 0px; top: 0px; width: 100%; height: 100%; ” > </a> hMp://output.jsbin.com/cipozanute/1/ ¡ ¡

  12. But, ¡wait <a href=“*”> <* width=“*” height=“*” class=“*” style=“” /> Unsanitized Style (older IE only) <img src=“” style=“width: expression(payload); ” />

  13. ¡<head> ¡ ¡ ¡ ¡<meta ¡charset="u[-­‑8"> ¡ ¡ ¡ ¡<meta ¡hGp-­‑equiv="X-­‑UA-­‑Compa.ble" ¡ content="IE=edge"> ¡ ¡ ¡ ¡<meta ¡name="viewport" ¡content="width=device-­‑ width, ¡ini.al-­‑scale=1"> ¡ ¡ ¡ ¡<!-­‑-­‑ ¡Bootstrap ¡core ¡CSS ¡-­‑-­‑> ¡ ¡ ¡ ¡<l <link ¡ ¡hr href=" ="hGp://getbootstrap.com/ m/dis dist/cs css/ bootstrap.mi min.css" ¡ ¡re rel=" ="stylesheet"> >

  14. Defined ¡in ¡ bootstrap.min.css 3663 ¡.dropdown-­‑backdrop ¡{ ¡ ¡ 4299 ¡.navbar-­‑fixed-­‑top, ¡ ¡ 3664 ¡ ¡ ¡posiZon: ¡fixed; ¡ ¡ 4300 ¡.navbar-­‑fixed-­‑boMom ¡{ ¡ ¡ 3665 ¡ ¡ ¡top: ¡0; ¡ ¡ 4301 ¡ ¡ ¡posiZon: ¡fixed; ¡ ¡ 3666 ¡ ¡ ¡right: ¡0; ¡ ¡ 4302 ¡ ¡ ¡right: ¡0; ¡ ¡ 3667 ¡ ¡ ¡boMom: ¡0; ¡ ¡ 4303 ¡ ¡ ¡le`: ¡0; ¡ ¡ 3668 ¡ ¡ ¡le`: ¡0; ¡ ¡ 4304 ¡ ¡ ¡z-­‑index: ¡1030; ¡ ¡ 3669 ¡ ¡ ¡z-­‑index: ¡990; ¡ ¡ 4305 ¡} ¡ ¡ 3670 ¡} ¡ ¡

  15. Exploi.ng ¡with ¡style <a ¡ ¡ ¡ ¡ ¡width=“100%” ¡ ¡ ¡ ¡height=“100%” ¡ ¡ ¡ ¡ ¡href=“javascript:payload” ¡ ¡ ¡ ¡ ¡class=“dropdown-­‑backdrop ¡navbar-­‑fixed-­‑top”> </a> ¡ ¡ ¡ ¡ hMp://output.jsbin.com/zoqipeloca/1/ ¡ ¡ ¡

  16. Hijack ¡login Using ¡class ¡aGribute Recreate ¡pixel-­‑perfect ¡clone ¡ ¡ user ¡ ¡ ¡ password ¡ ¡ ¡ hMp://jsbin.com/dejite/13/edit ¡ ¡ Login ¡ ¡

  17. Abuse ¡Password ¡Manager • Same-­‑Origin ¡IE: ¡Autofilled • Submit ¡buGon ¡overlay ¡100% ¡x ¡100% ¡ • Not ¡autofilled: ¡spoof user ¡ password ¡ Login ¡ hMp://jsbin.com/dejite/13/edit hMps://www.cs.utexas.edu/~suman/publicaZons/suman_pwdmgr.pdf ¡

  18. Fixed

  19. LinkedIn

  20. Failed: ¡javascript ¡link

  21. Failed: ¡iframe ¡cross ¡domain

  22. Worked ¡100% ¡covering ¡iframe ¡

  23. Failed: ¡iframe ¡open ¡redirect

  24. Worked: ¡Covering ¡link

  25. Worked: ¡Covering ¡image ¡+ ¡Link

  26. To ¡conclude Sani.z Sani.ze AGribute: ¡id, ¡class, ¡style oembed/embed.ly Har Harden en HTML5 ¡IFrame ¡Sandbox

  27. info@bitsensor.io ¡

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend