<?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"><channel><title><![CDATA[InfoSec Writeups And Notes By Jubaer]]></title><description><![CDATA[A security guy with 5+ years of experience in web application and mobile pen-testing. My work and notes will be shared on this infosec blog.]]></description><link>https://jubaeralnazi.com</link><image><url>https://cdn.hashnode.com/res/hashnode/image/upload/v1650397588260/IjwD6q4A2.png</url><title>InfoSec Writeups And Notes By Jubaer</title><link>https://jubaeralnazi.com</link></image><generator>RSS for Node</generator><lastBuildDate>Thu, 15 Oct 2026 01:07:28 GMT</lastBuildDate><atom:link href="https://jubaeralnazi.com/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[How I passed OSCP on the first attempt? [ Part 2  ]]]></title><description><![CDATA[The Offensive Security Certified Professional (OSCP) certification is widely regarded as one of the most challenging and respected certifications in the cybersecurity field. To pass the OSCP exam, it's crucial to have not only technical knowledge but...]]></description><link>https://jubaeralnazi.com/how-i-passed-oscp-on-the-first-attempt-part-2</link><guid isPermaLink="true">https://jubaeralnazi.com/how-i-passed-oscp-on-the-first-attempt-part-2</guid><category><![CDATA[oscp]]></category><category><![CDATA[Security]]></category><category><![CDATA[research]]></category><category><![CDATA[labs]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Thu, 08 Jun 2023 02:19:37 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1686190683044/403df02f-7fd6-4229-b768-9b3ccbbbb123.avif" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The Offensive Security Certified Professional (OSCP) certification is widely regarded as one of the most challenging and respected certifications in the cybersecurity field. To pass the OSCP exam, it's crucial to have not only technical knowledge but also a strategic plan and effective use of available resources.</p>
<p>In this article, I will share my successful approach to passing the OSCP exam. I primarily focused on Offensive Security labs, mastered a few key tools, and watched tons of techniques to enhance my learning experience.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=1Pz7PnwsR_4">https://www.youtube.com/watch?v=1Pz7PnwsR_4</a></div>
<p> </p>
<h2 id="heading-emphasizing-offensive-security-labs">Emphasizing Offensive Security Labs</h2>
<p>Offensive Security provides comprehensive lab environments for OSCP candidates to practice their skills and gain hands-on experience. Instead of spreading my efforts across multiple platforms, I chose to concentrate on the Offensive Security labs. This focused approach helped me achieve better results. The labs provide a controlled environment where I could explore various networks and systems, identify vulnerabilities, and practice exploiting them.</p>
<p>By dedicating my time to the Offensive Security labs, The labs challenged me, pushing my limits and helping me build the skills necessary to tackle the OSCP exam successfully. <strong>To be honest the labs were harder than the exam!</strong></p>
<h2 id="heading-mastering-a-few-tools">Mastering a Few Tools</h2>
<p>With a vast array of tools available for offensive security, trying to master all of them can be overwhelming. Instead, I chose to focus on a core set of tools and become proficient in their usage. Here are a few popular tools that I mastered:</p>
<ol>
<li><p>Nmap</p>
</li>
<li><p>Netcat</p>
</li>
<li><p>Metasploit (Allowed only for one machine)</p>
</li>
<li><p>Burp</p>
</li>
<li><p>Mimikatz</p>
</li>
<li><p>Impacket</p>
</li>
<li><p>CrackMapExec</p>
</li>
<li><p>CrackMapExecWin</p>
</li>
<li><p>Responder</p>
</li>
<li><p>PowerShell Empire</p>
</li>
<li><p>Enum4linux</p>
</li>
<li><p>Evil-winrm</p>
</li>
<li><p>Dirsearch</p>
</li>
<li><p>Nikto</p>
</li>
<li><p>dirb</p>
</li>
<li><p>dirbuster</p>
</li>
<li><p>MSFVenom</p>
</li>
<li><p><strong>Exploit Databases-</strong></p>
<ul>
<li><p>Exploit-DB — <a target="_blank" href="https://www.exploit-db.com/">https://www.exploit-db.com/</a></p>
</li>
<li><p>Windows Kernel Exploits — <a target="_blank" href="https://github.com/SecWiki/windows-kernel-exploits">https://github.com/SecWiki/windows-kernel-exploits</a></p>
</li>
<li><p>AutoNSE — <a target="_blank" href="https://github.com/m4ll0k/AutoNSE">https://github.com/m4ll0k/AutoNSE</a></p>
</li>
<li><p>Linux Kernel Exploits — <a target="_blank" href="https://github.com/lucyoa/kernel-exploits">https://github.com/lucyoa/kernel-exploits</a></p>
</li>
</ul>
</li>
<li><p>Hashcat</p>
</li>
<li><p>Ripper</p>
</li>
<li><p>Linux Exploit Suggester</p>
</li>
<li><p>Windows Exploit Suggester</p>
</li>
<li><p>GTFOBins</p>
</li>
<li><p>Chisel &lt;3</p>
</li>
<li><p>Proxychains</p>
</li>
<li><p>Best Site That Helped Me? - <a target="_blank" href="https://www.hackingarticles.in/">https://www.hackingarticles.in/</a></p>
</li>
</ol>
<p>I used many other tools throughout my labs but these were the major ones I can remember which you should master at least.</p>
<p>During the exam, a valuable strategy was to search for similar labs to those found in the Offensive Security labs using the keyword "Hackthebox" in my search. Sometimes, I came across HTB VMs that mirrored the same vulnerable services as in the exam. This parallel exploration provided additional hints and exposed me to alternative exploitation techniques.</p>
<p>Passing the OSCP exam requires dedication, perseverance, and a strategic approach to training. By focusing primarily on the Offensive Security labs, and mastering a select few tools I significantly enhanced my chances of success.</p>
<p>[ <em>Disclaimer: I could have given a lot more into this but I didn't want to throw a ton of stuff at you which didn't even help me during the exam but yes don't take this as the ultimate thing rather its better to do your own research and get comfortable with the things you prefer and like to work on with</em> ]</p>
]]></content:encoded></item><item><title><![CDATA[Setup basic CI/CD pipeline with GitHub Actions]]></title><description><![CDATA[In today's fast-paced world, delivering software products quickly and efficiently has become a necessity. This is where Continuous Integration and Continuous Deployment (CI/CD) pipelines come into play. CI/CD pipelines are a set of practices and tool...]]></description><link>https://jubaeralnazi.com/setup-basic-cicd-pipeline-with-github-actions</link><guid isPermaLink="true">https://jubaeralnazi.com/setup-basic-cicd-pipeline-with-github-actions</guid><category><![CDATA[GitHub]]></category><category><![CDATA[CI/CD]]></category><category><![CDATA[#cybersecurity]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Mon, 17 Apr 2023 11:15:38 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1681729711923/de008088-1447-41f4-a4c0-5ffce08e8bb0.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>In today's fast-paced world, delivering software products quickly and efficiently has become a necessity. This is where Continuous Integration and Continuous Deployment (CI/CD) pipelines come into play. CI/CD pipelines are a set of practices and tools that allow developers to deliver code changes more frequently and reliably. In this blog post, we will learn how to set up a basic CI/CD pipeline with GitHub.</p>
<h2 id="heading-what-is-cicd">What is CI/CD?</h2>
<p>Continuous Integration (CI) is a practice of automatically building and testing code changes whenever they are pushed to the code repository. Continuous Deployment (CD) is a practice of automatically deploying code changes to the production environment whenever they pass the CI process. Together, CI/CD pipelines provide an automated process for building, testing, and deploying code changes.</p>
<h2 id="heading-setting-up-a-basic-cicd-pipeline-with-github">Setting up a Basic CI/CD Pipeline with GitHub</h2>
<p>To set up a basic CI/CD pipeline with GitHub, you will need the following:</p>
<ol>
<li><p>A GitHub account</p>
</li>
<li><p>A code repository on GitHub</p>
</li>
<li><p>A CI/CD tool (we will be using GitHub Actions)</p>
</li>
</ol>
<h2 id="heading-what-are-the-use-cases-of-cicd-in-cybersecurity">What are the use cases of CI/CD in cybersecurity?</h2>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1681728458378/d6fe9b7d-2dfe-46d9-866e-d3c2e7293060.png" alt class="image--center mx-auto" /></p>
<p>Almost every security professionals maintain a dedicated server for multiple purposes, It can be bug bounty, enumeration, POC assistance etc. but all of these can be troublesome if every time you had to SSH into the server and update your codes. With CI/CD you can design the entire deployment and how you want the server to behave right from your IDE which is very handy and easy to do.</p>
<p>I have seen people making autonomous recon tools entirely using the GitHub workflow so even that area can be explored.</p>
<h2 id="heading-steps-to-set-it-up">Steps to set it up</h2>
<p>I have used a very basic VPS server to set up a simple CI/CD pipeline, Firstly I SSHed into my VPS and did the steps below:</p>
<p>Generate an SSH key</p>
<pre><code class="lang-plaintext">ssh-keygen -t rsa -b 4096 -C "test@example.com"
</code></pre>
<p>Add the public key to the authorized keys</p>
<pre><code class="lang-plaintext">cat ~/.ssh/id_rsa.pub &gt;&gt; ~/.ssh/authorized_keys

#You can also copy the contents of id_rsa.pub to authorized_keys file
</code></pre>
<p>Copy the key</p>
<pre><code class="lang-plaintext">cat ~/.ssh/id_rsa
</code></pre>
<p>Go to the "Actions And Secrets Variable" page and setup all these values</p>
<ul>
<li><p><strong>SSH_USERNAME</strong>: set the key to the username you use to SSH into your VPS.</p>
</li>
<li><p><strong>SSH_HOST</strong>: set the key to your hostname or ip address.</p>
</li>
<li><p><strong>SSH_KEY</strong>: set the key to you copied contents from the command above.</p>
</li>
<li><p><strong>SSH_PASS</strong>: set the password for the vps</p>
</li>
</ul>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1681729084133/9a59078d-e786-480e-b8eb-1da29e2ae99d.png" alt class="image--center mx-auto" /></p>
<p>Now navigate to "Actions" page and create a new workflow with this template, This template is to test if you can actually login to the VPS using Github Actions.</p>
<pre><code class="lang-plaintext">name: remote ssh command
on: [push]
jobs:

  build:
    name: Build
    runs-on: ubuntu-latest
    steps:
    - name: executing remote ssh commands using password
      uses: appleboy/ssh-action@v0.1.10
      with:
        host: ${{ secrets.SSH_HOST }}
        username: ${{ secrets.SSH_USERNAME }}
        password: ${{ secrets.SSH_PASSWORD }}
        key: ${{ secrets.SSH_KEY }}
        port: 22
        script: |
          whoami
</code></pre>
<p>If it's successful then you can go back to your VPS and set up your GitHub credentials there and now instead of "whoami" you can run GitHub operations such as "git pull" to always deploy your code and then run it using the particular command.</p>
<p>For deployment, such templates can be used and deploy your desired application.</p>
<pre><code class="lang-plaintext">name: Deploy Flask App

on:
  push:
    branches:
      - main

jobs:
  deploy:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Set up Python 3
        uses: actions/setup-python@v2
        with:
          python-version: 3.8

      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install -r requirements.txt

      - name: Build and test the app
        run: |
          python -m pytest
          python setup.py sdist bdist_wheel

      - name: Deploy to server
        uses: easingthemes/ssh-deploy@v2.1.1
        env:
          SSH_PRIVATE_KEY: ${{ secrets.SSH_KEY }}
          ARGS: "-rltgoDzvO --delete"
          SOURCE: "dist/*"
          REMOTE_HOST: ${{ secrets.SSH_HOST }}
          REMOTE_USER: ${{ secrets.SSH_USERNAME }}
          TARGET: "/var/www/flask_app"
</code></pre>
<p>If the repository is private, you will need to set up SSH keys for Git authentication. Here are the steps to follow:</p>
<ol>
<li>Generate an SSH key pair on your Ubuntu machine by running the following command in your terminal:</li>
</ol>
<ul>
<li><pre><code class="lang-plaintext">  ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
</code></pre>
<p>  This command will generate a public and private key pair in the <code>~/.ssh</code> directory on your machine.</p>
</li>
<li><p>Add the SSH public key to your GitHub account by copying the public key to your clipboard:</p>
</li>
<li><pre><code class="lang-plaintext">  cat ~/.ssh/id_rsa.pub
</code></pre>
<p>  This command will print the contents of your public key to the terminal. Copy the entire output.</p>
<p>  Then, go to your GitHub account settings, select "SSH and GPG keys," and click "New SSH key." Paste the contents of your public key into the "Key" field and click "Add SSH key."</p>
</li>
<li><p>Configure your SSH agent to store your private key:</p>
</li>
<li><pre><code class="lang-plaintext">  eval "$(ssh-agent -s)"
  ssh-add ~/.ssh/id_rsa
</code></pre>
<p>  The first command will start the SSH agent, and the second command will add your private key to the agent.</p>
</li>
<li><p>Clone the private repository using the SSH URL:</p>
</li>
<li><pre><code class="lang-plaintext">  git clone git@github.com:username/repository.git
</code></pre>
<p>  Replace <code>username</code> with your GitHub username and <code>repository</code> with the name of the repository you want to clone.</p>
</li>
<li><p>Once the repository is cloned to your machine, you can perform a <code>git pull</code> to fetch the latest changes from the remote repository:</p>
</li>
</ul>
<ol>
<li><pre><code class="lang-plaintext"> cd repository
 git pull
</code></pre>
<p> This command will update your local repository with the latest changes from the remote repository.</p>
</li>
</ol>
<p>That's it! You should now be able to perform a <code>git pull</code> on your machine for the private repository.</p>
]]></content:encoded></item><item><title><![CDATA[How I passed OSCP on the first attempt? [ Part 1  ]]]></title><description><![CDATA[https://www.youtube.com/watch?v=1Pz7PnwsR_4&t=215s
 
I thought of sharing my OSCP journey and the hurdles I had to overcome to pass this certificate. If you are looking for any learning resources then they will come in the next part, In this part, I ...]]></description><link>https://jubaeralnazi.com/how-i-passed-oscp-on-the-first-attempt-part-1</link><guid isPermaLink="true">https://jubaeralnazi.com/how-i-passed-oscp-on-the-first-attempt-part-1</guid><category><![CDATA[oscp]]></category><category><![CDATA[Certification]]></category><category><![CDATA[hacking]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Tue, 07 Feb 2023 16:25:14 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1675787059447/54cf15e1-02f9-4f54-b80c-af67f51d1505.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=1Pz7PnwsR_4&amp;t=215s">https://www.youtube.com/watch?v=1Pz7PnwsR_4&amp;t=215s</a></div>
<p> </p>
<p>I thought of sharing my OSCP journey and the hurdles I had to overcome to pass this certificate. If you are looking for any learning resources then they will come in the next part, In this part, I will only cover my journey, timeline, and mental preparation.</p>
<p>To start off those who think OSCP is easy and you are not someone who is not a regular HTB/TryHackMe player then you are in for a big surprise.</p>
<p><img src="https://media.tenor.com/-2zO2Y2I3L4AAAAC/surprise-motherfucker-surprise-mother-father.gif" alt="Surprise Motherfucker Surprise Mother Father GIF - Surprise Motherfucker  Surprise Mother Father - Discover &amp; Share GIFs" /></p>
<p>I thought it would be relatively easy since you are just learning about some tools and using them to enumerate, pivot, escalate, and root. This is what my initial assumption was "UNTIL" I saw this...</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1675784199185/140e88ea-afa4-48e8-816c-7caa11f48660.png" alt class="image--center mx-auto" /></p>
<p>So many people were failing OSCP and it hit me quite hard, I was wondering how come so many people are failing it when from my assumption it should be easy. I did more research on it and also talked to the people who failed it and what I understood was all of the cases had a similar pattern.</p>
<ul>
<li><p>Like they failed because they didn't maintain a proper time schedule throughout the exam</p>
</li>
<li><p>Like they failed because they didn't do many labs</p>
</li>
<li><p>Like they failed because they did some mistakes while submitting the report</p>
</li>
</ul>
<p>So a similar pattern was "<strong>Preparation and Planning</strong>"</p>
<p>I believe all these could have easily been avoided if the person had enough preparation and he did enough planning to ace the exam. I'm lucky to realize this beforehand because I had 90 days to complete the labs and then sit for the exam now I need to evaluate if the 90 days are enough for me to go for the exam and after 90 days I only managed to finish around 20 machines that also with the help from Google mostly so I wasn't satisfied at all, It is also hard to push myself to do more labs as I have a fulltime job so I ended up extending my lab period and It helped me a lot because then I managed to solve more than 30+ labs and I was a bit satisfied with my preparation, At the same time I was building labs at my office and testing them also for extra preparation.</p>
<p>And <strong>NEVER STOP DOING NOTES</strong>, they are life savers. Make sure you note down everything and special scenarios also to help you with those special cases.</p>
<p>I knew AD will be there in the exam so I didn't take any risk with the AD and learned the simplest tools and easiest ways to take control of an AD, I planned to keep things simple and to make sure I spend less brain power on tools and more brain power on planning the attack, So I wouldn't choose any tools that require sophisticated steps rather I will research the tools and if I find something easy to use I will stick with it.</p>
<p>After all these, I realized that people who fail OSCP are not because they are less skilled or knowledgable but because they prepared less for the exam. To be honest, I also didn't think I will pass it on the first attempt since the exam was completely changed this year and the tips I was getting were old since most of my friends and connections passed the old version, So I had the challenge to overcome and plan the entire thing myself. In the end, Confidence is the key that worked out for me.</p>
<h2 id="heading-oscp-exam-day">OSCP EXAM DAY</h2>
<p><strong>Funny Story</strong>: As I was showing my room to the proctor he asked me to take down my TV and face it towards the wall, It made me laugh because it wasn't even powered on and it was quite heavy, I did tell him that it is very heavy I will need some time to do that. He said no problem do it!</p>
<p><img src="https://media.tenor.com/YmYYTz-cW7sAAAAC/memes-just-do-it.gif" alt="Memes Just Do It GIF - Memes Just Do It Shia La Beouf - Discover &amp; Share  GIFs" /></p>
<p><strong>7.00 AM:</strong> I sat for the exam and was quite nervous. I spent 20 minutes understanding the requirements and the environments, made sure I could ping all the machines and before starting my first machine I reverted it just to double confirm that the machine will be fresh.</p>
<p><strong>12:00 PM</strong>: I managed to pwn my first machine in AD before this I didn't take any breaks and I was constantly focused on this machine due to my nervousness. This gave me the realization that if I continue to sweat like this and lose all my focus I will not be able to use my full potential on the other machines, So I will have to balance it out.</p>
<p>I took a hot shower after this and a good lunch, Took some rest, and also planned a few things in my head before restarting.</p>
<p><strong>2:00 PM:</strong> I managed to pwn my second machine and I was so happy because my trick was working and I was taking constant breaks, It helps you SOOOOOO much to cool down and think of other ways to get inside the machine.</p>
<p>[<em>Throughout this period I was having fruits and healthy snacks to keep my strength up and to feel energetic</em> ]</p>
<p><strong>3:00 PM</strong>: I managed to complete the entire AD and I couldn't be anymore happier than this, At this stage, I had enough confidence to ace the exam because I knew I had the time and resources now to push forward.</p>
<p><strong>5:00 PM</strong>: Managed to get local privilege on the first standalone machine and after this decided to go for a walk and get an Ice cream, Rewarding myself for such achievement was also working a lot. Had a nice dinner with a tasty dessert and restarted my exam.</p>
<p><strong>9:00 PM</strong>: Managed to root my first standalone machine. At this point, I was already noticing fatigue and I started to push myself even more.</p>
<p><strong>2:00 AM</strong>: Managed to get the local privilege of the second standalone machine and at this stage, I was completely done, My head was screaming to go to sleep and asking me to give it a rest. Since I ensured 70 I didn't push myself anymore and went to sleep happily knowing that I also have a lab report to submit so in total I will have 80 points and will pass it quite easily.</p>
<p>So then I just waited for the final email and then, it arrives...</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1675786937009/58c9d1fc-ae33-4f76-9abc-c3484064806c.jpeg" alt class="image--center mx-auto" /></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1675786947528/31116343-b376-487d-861e-30c5dc34e971.jpeg" alt class="image--center mx-auto" /></p>
<h2 id="heading-golden-tips">GOLDEN TIPS</h2>
<ul>
<li><p>DO NOTES!</p>
</li>
<li><p>Don't be lazy with the labs and exercises!</p>
</li>
<li><p>During the exam, if you are completely stuck on a machine then search about that specific service in google but add the keyword "<strong>hack the box</strong>", If you are lucky HTB will have a similar box with that service from where you can take new ideas to get the initial shell.</p>
</li>
<li><p>If possible keep a separate terminal just for enumerating, Take a good wordlist and start enumerating. Sometimes you might get lucky and end up inside some user's account since the password would be quite easy to guess like "<strong>john</strong>"</p>
</li>
<li><p>Don't change your plan frequently it will lead to burnout, Instead do an initial enumeration and choose the attack plan you are comfortable with and can escalate to an advanced level.</p>
</li>
<li><p>If you find an exploit not running and giving errors, most probably that's intended. Try to look into the code and fix it if necessary or look for alternatives in GitHub if someone had already fixed it.</p>
</li>
<li><p>For python, if you are running some tools on your local kali for the sake of god use virtualenv, This fella saved me from so many troubles.</p>
</li>
</ul>
]]></content:encoded></item><item><title><![CDATA[How to verify a file's authenticity which you downloaded from the internet?]]></title><description><![CDATA[A digital signature is a way to ensure the authenticity and integrity of a digital document or file. It is similar to a traditional signature on a paper document, but it uses encryption to create a unique code that is tied to the document and the per...]]></description><link>https://jubaeralnazi.com/how-to-verify-a-files-authenticity-which-you-downloaded-from-the-internet</link><guid isPermaLink="true">https://jubaeralnazi.com/how-to-verify-a-files-authenticity-which-you-downloaded-from-the-internet</guid><category><![CDATA[digitalsignature]]></category><category><![CDATA[Hashnode]]></category><category><![CDATA[Hash]]></category><category><![CDATA[authenticity]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Fri, 13 Jan 2023 02:23:18 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1673576557333/8e8919b5-08da-46e7-bd13-8e998080aab7.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>A digital signature is a way to ensure the authenticity and integrity of a digital document or file. It is similar to a traditional signature on a paper document, but it uses encryption to create a unique code that is tied to the document and the person signing it.</p>
<p>When a digital signature is created, a hash is generated using a cryptographic algorithm and is specific to the document being signed. This hash, along with other signature information, is then embedded in the document. When the document is received by someone else, the signature can be verified using the sender's public key to confirm that the document has not been tampered with and that it was indeed signed by the person or organization that it claims to be signed by.</p>
<p>Digital signatures can be used to verify the authenticity of downloaded files in several ways:</p>
<ol>
<li><p>By checking the file's digital signature: If the file has a digital signature from a trusted source, it is likely to be authentic.</p>
</li>
<li><p>By using the software's built-in signature verification tools: Many software programs, such as Adobe Acrobat or Microsoft Word, have built-in mechanisms for verifying digital signatures. These tools will typically allow you to check the signature, view the certificate information, and ensure that the signature is valid and the document has not been tampered with.</p>
</li>
<li><p>By using online verification: Some organizations or websites provide online verification tools that can be used to check the validity of a digital signature.</p>
</li>
<li><p>Using open-source libraries: Some open-source libraries like OpenSSL, GnuPG, etc. can be used to verify digital signatures on a command-line interface.</p>
</li>
</ol>
<p>It's important to note that while digital signatures can help ensure the authenticity of a downloaded file, they do not guarantee the safety or accuracy of the content of the file. Additionally, digital signatures can be forged, and it is important to verify the authenticity of the signature itself, and not just rely on the signature present.</p>
<h2 id="heading-example">Example:</h2>
<p>Let's say we download "Py Charm" from this link: <a target="_blank" href="https://www.jetbrains.com/pycharm/download/#section=windows">https://www.jetbrains.com/pycharm/download/#section=windows</a></p>
<p>And after we download the exe file, We go to the location of the file and check the properties</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1673575499083/0bfe6bc4-6160-4aa4-9c35-cdb05a8691f4.png" alt class="image--center mx-auto" /></p>
<p>We notice that in the properties section, there is something called "Digital Signatures" and when we open that section we can see that <strong>JetBrains</strong> actually signed this file with their certificate.</p>
<p>Now we download the same file from Softonic</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1673576042297/218256a8-a10b-4b1b-9555-85bdab4d1e59.png" alt class="image--center mx-auto" /></p>
<p>So how do we know that Softonic didn't just add their malware into it and it could be a completely different file right?</p>
<p>After the download finishes, we can check the properties again and see that this is also been signed by <strong>JetBrains</strong></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1673576168540/6de1d38f-1271-464d-8bf9-7ecedb740002.png" alt class="image--center mx-auto" /></p>
<p>So this is how you can verify if the file you downloaded is authentic or not.</p>
<p>In conclusion, Digital Signatures provide an additional layer of security when it comes to verifying the authenticity of downloaded files, it's important to use multiple methods to ensure that you are downloading a secure file and always verify the authenticity of the signature itself.</p>
]]></content:encoded></item><item><title><![CDATA[The "Unsubscribe Tragedy" That Exposed 200000+ User Data On Search Engines]]></title><description><![CDATA[This happened in 2018 when I was a regular bug bounty hunter, At that time CloudBleed was still trending. So as a young hacker full of enthusiasm I tried to find something similar and then I ended up finding the "Unsubscribe tragedy"!
So why am I sha...]]></description><link>https://jubaeralnazi.com/unsubscribe-tragedy-exposed-200000-user-data-on-search-engines</link><guid isPermaLink="true">https://jubaeralnazi.com/unsubscribe-tragedy-exposed-200000-user-data-on-search-engines</guid><category><![CDATA[Security]]></category><category><![CDATA[hacking]]></category><category><![CDATA[bugbounty]]></category><category><![CDATA[leak]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Sun, 14 Aug 2022 04:19:34 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/91LGCVN5SAI/upload/v1660449525039/h20BSvHw8.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>This happened in 2018 when I was a regular bug bounty hunter, At that time <a target="_blank" href="https://en.wikipedia.org/wiki/Cloudbleed">CloudBleed</a> was still trending. So as a young hacker full of enthusiasm I tried to find something similar and then I ended up finding the "Unsubscribe tragedy"!</p>
<p>So why am I sharing it now? I didn't get permission to disclose it at that time but I think since the issue still exists in the wild, we should talk about it.</p>
<p>This happened when I was receiving too many emails from a particular company and I wanted to unsubscribe from their newsletter, So I noticed the "Unsubscribe Button" and basically unsubscribed from the newsletter. But few things were stuck in my mind when I visited the unsubscribe page, they are: </p>
<ol>
<li>It had information such as my email, address, and phone number</li>
<li>And the unsubscribe token was more like a tracking token also which was getting used throughout the website. <em>(<strong>How did I know?</strong> Because the moment I went to their homepage from the unsubscribe page the token also followed along)</em></li>
</ol>
<p>After a few days, I was trying to understand and study the cloudbleed issue and then it came to my head that I can try my luck there on that unsubscribe page since it was also throwing the token everywhere then technically it should also be leaking somewhere. </p>
<p>My first plan was to find the company behind that marketing software because I knew companies wouldn't allow third-party branding for their own usage. Luckily that company using the marketing software was in hackerone so by risking my reputation knowing it's an out-of-scope vulnerability I still reported it to know what software they used. Because my strategy of going through HTML source codes to find any traces of the software didn't help much so this was the only option. </p>
<p>So basically I reported an issue to the company based on my 2nd observation, saying that it was leaking the token to social media sites because that page also had links to their twitter/facebook pages so when I clicked on it the token was also getting captured there by those social media sites.</p>
<blockquote>
<p>And the unsubscribe token was more like a tracking token also which was getting used throughout the website. <em>(<strong>How did I know?</strong> Because the moment I went to their homepage from the unsubscribe page the token also followed along)</em></p>
</blockquote>
<p>And it worked! We got the company!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660445893559/hV-C2h2AR.png" alt="Screenshot 2022-08-14 at 10.55.05 AM.png" /></p>
<p>After knowing the company name I was quite shocked to find out that it was one of the leading marketing software at that time and even they were getting ready to be acquired by <strong>Adobe</strong>. So after this, I instantly knew if I find any issue regarding this it will affect a massive userbase. That just motivated me even more to find something in it, I was working for days to find out how I can leak the token at a mass level, and then it hit me, Why am I trying to leak it? Since the token gets tied to any URL user visits, it should get archived or cached by something somewhere. </p>
<p>First guess? Obviously! <strong>Google</strong>!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660447450979/RFE_sIkHa.png" alt="Screenshot 2022-08-14 at 11.21.46 AM.png" /></p>
<p>So google was giving us 50k+ results for the tokens but it got interesting when I searched it on bing.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660447763135/29bsQPR9N.png" alt="Screenshot 2022-08-14 at 11.26.56 AM.png" /></p>
<p>(Sorry for the blurry screenshot, this is the only photo I had to proof the bing results)</p>
<p>I was getting 500k+ results on bing, I think google was restricting a lot of results due to region and other settings but seeing the results on bing convinced me that yes this is something that needs to be reported.</p>
<p>I directly reached out to the CISO of the company on linkedin and he was a nice guy who instantly connected back to me and we had few meetings and then they decided to fix the issue. Even though they didn't have any bug bounty program they decided to reward me still.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660448362387/KrQgTgvc7.png" alt="Screenshot 2022-08-14 at 11.35.56 AM.png" /></p>
<p>By the way, I never managed to use the money on that card because it would only work in the US but did I make any money out of it?</p>
<p>Well, yes I did. Because the CISO told me they implemented a new configuration where users can choose to not leak that token and I knew what to do then, Just find the vulnerable ones which are misconfigured and report them.</p>
<p>Voila...</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660448632808/w1v3Mje6Z.png" alt="Screenshot 2022-08-14 at 11.43.17 AM.png" />
<img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660448863222/Z8i7CPQfz.png" alt="Screenshot 2022-08-14 at 11.47.38 AM.png" /></p>
<p>And Many more...</p>
<p>Let's say most of my earnings for "Information Disclosure" came from this one "Unsubscribe Tragedy" because it only takes 2-3 minutes to find and report.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1660449131603/ApjXDXzAr.png" alt="Screenshot 2022-08-14 at 11.52.07 AM.png" /></p>
]]></content:encoded></item><item><title><![CDATA[What is the CIA triad? [CHAPTER - 1]]]></title><description><![CDATA[The CIA triad, also known as confidentiality, integrity, and availability, is a concept created to direct information security policies inside a company. To avoid confusion with the Central Intelligence Agency, the approach is sometimes frequently re...]]></description><link>https://jubaeralnazi.com/what-is-the-cia-triad-chapter-1</link><guid isPermaLink="true">https://jubaeralnazi.com/what-is-the-cia-triad-chapter-1</guid><category><![CDATA[Security]]></category><category><![CDATA[Certification]]></category><category><![CDATA[CISSP]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Fri, 24 Jun 2022 08:53:34 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1656060182102/C2ehtgUpk.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The CIA triad, also known as confidentiality, integrity, and availability, is a concept created to direct information security policies inside a company. To avoid confusion with the Central Intelligence Agency, the approach is sometimes frequently referred to as the AIC triad (availability, integrity, and confidentiality). Although the CIA triad's components are three of the most fundamental and important cybersecurity requirements, experts think the triad has to be updated to be effective.</p>
<p>In this context, availability refers to a commitment that the information will be dependable for use by authorized individuals, integrity refers to the assurance that the information is trustworthy and accurate, and confidentiality refers to a system of rules that restrict access to information.</p>
<h2 id="heading-confidentiality">Confidentiality</h2>
<p>Special training for those who have access to sensitive documents is often required to protect data confidentiality. Authorized individuals can benefit from training to become more familiar with risk factors and preventative measures. Strong passwords, password-related best practices, and knowledge of social engineering techniques are possible additional components of training to deter users from violating data handling policies with good intentions and potentially devastating outcomes.</p>
<p>Requiring an account number or routing number while banking online is a good illustration of a strategy used to protect confidentiality. Another popular technique for protecting confidentiality is data encryption. Two-factor authentication (2FA) is starting to replace the conventional practice of using user IDs and passwords. Security tokens, key fobs, and biometric verification are other choices.</p>
<p>Documents that contain highly sensitive information may require additional security precautions, such as storage solely on air-gapped computers, disconnected storage devices, or in physical copy form.</p>
<h3 id="heading-in-short">In Short:</h3>
<ul>
<li>Data should be handled based on the organization's required privacy.</li>
<li>Data should be encrypted using 2FA.</li>
<li>Keep access control lists and other file permissions up to date.</li>
</ul>
<h2 id="heading-integrity">Integrity</h2>
<p>These security measures include user access restrictions and file permissions. Version control can be used to stop authorized users from making mistakes or accidentally deleting things. Organizations must also provide some method for detecting any data changes that can happen from non-human events like an electromagnetic pulse (EMP) or server crash.</p>
<p>Checksums, including cryptographic checksums, may be used in data to verify its integrity. To restore the impacted data to its original condition, backups or redundancies must be accessible. Additionally, by using digital signatures to provide effective protection, it is impossible to dispute the evidence of logins, messages transmitted, and the reading and sending of electronic documents.</p>
<h3 id="heading-in-short">In Short:</h3>
<ul>
<li><p>Ensure employees are knowledgeable about compliance and regulatory requirements to minimize human error.</p>
</li>
<li><p>Use backup and recovery software.</p>
</li>
<li><p>To ensure integrity, use version control, access control, security control, data logs and checksums.</p>
</li>
<li><p>Ensure nobody can modify data without proper authorization.</p>
</li>
</ul>
<h2 id="heading-availability">Availability</h2>
<p>The best ways to do this are to keep all hardware under strict maintenance, fix any hardware issues as soon as they arise, and maintain a stable OS environment free of software conflicts. Additionally, it's critical to stay up to date on all required system upgrades. Equally crucial strategies include ensuring sufficient communication capacity and avoiding bottlenecks. When hardware problems do arise, redundancy, failover, RAID, and even high-availability clusters can help to prevent major repercussions.</p>
<p>For the worst-case scenarios, quick and adaptable disaster recovery is crucial; this capability depends on the presence of a thorough DR plan. </p>
<h3 id="heading-in-short">In Short:</h3>
<ul>
<li><p>Use preventive measures such as redundancy, failover and RAID. Ensure systems and applications stay updated.</p>
</li>
<li><p>Use network or server monitoring systems.</p>
</li>
<li><p>Ensure a data recovery and business continuity (BC) plan is in place in case of data loss</p>
</li>
<li><p>Ensure that nothing takes down the server</p>
</li>
</ul>
]]></content:encoded></item><item><title><![CDATA[How To Build Your Bug Bounty/Pentest Recon Dashboard Using Python? 🤔]]></title><description><![CDATA[Dashboards are necessary especially when you are doing much more advanced stuff. Pentesters/Bug bounty hunters can save both time and energy by building efficient dashboards to bring ease to their jobs. By dashboards what I mean is basically automati...]]></description><link>https://jubaeralnazi.com/how-to-build-your-bug-bountypentest-recon-dashboard-using-python</link><guid isPermaLink="true">https://jubaeralnazi.com/how-to-build-your-bug-bountypentest-recon-dashboard-using-python</guid><category><![CDATA[Python]]></category><category><![CDATA[Flask Framework]]></category><category><![CDATA[Security]]></category><category><![CDATA[hacking]]></category><category><![CDATA[dashboard]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Tue, 10 May 2022 20:49:56 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/Skf7HxARcoc/upload/v1652213178355/bW9khDA_8f.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Dashboards are necessary especially when you are doing much more advanced stuff. Pentesters/Bug bounty hunters can save both time and energy by building efficient dashboards to bring ease to their jobs. By dashboards what I mean is basically automating your entire methodology and bringing that whole overview into a dashboard. If you use tools like subfinder, amass and dirsearch etc. for your daily hunting/pentest job then why not automate these tools to build a smooth workflow which will help you do your tasks faster. </p>
<h2 id="heading-requirements-to-build-your-own-recon-dashboard">Requirements To Build Your Own Recon Dashboard</h2>
<p>For this, I will be recommending python since I'm guessing you are completely new to building dashboards.</p>
<ul>
<li>Python3 (Basics related to scraping, async coding, subprocess, and formatting outputs)</li>
<li>FLASK</li>
<li>FASTAPI</li>
<li>MongoDB (No SQL Database)</li>
</ul>
<p>Python is easy to learn and FLASK is for fast development which gives you the power to build something quite faster than traditional languages or frameworks. I usually design an idea diagram of the whole program and then start writing code to turn the idea into reality.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1652214718133/lmlakxpv1.png" alt="Subfinder In FASTAPI.png" /></p>
<p>We can deploy the open-source bug bounty/pentest recon tools using subprocess and launch them in FASTAPI to reduce the load in the main application. After that, you can focus on fetching and extracting various data, especially JSON to gather data from these microservices. </p>
<h2 id="heading-free-flask-templates-for-dashboard">FREE FLASK Templates For Dashboard</h2>
<p>You can use all these free FLASK templates to build your dashboards:</p>
<ul>
<li>https://github.com/app-generator/flask-dashboard-azia</li>
<li>https://github.com/app-generator/boilerplate-code-flask-dashboard</li>
<li>https://github.com/app-generator/flask-soft-ui-dashboard</li>
</ul>
<p>Now all you need to do is just plug and play, Deploy the tools using FASTAPI and capture them using your FLASK application to populate your dashboard.</p>
]]></content:encoded></item><item><title><![CDATA[Passive Bug Bounty Income From Taking Over Related Domains]]></title><description><![CDATA[Subdomain takeovers are now becoming harder and harder to find as people have set up massive automated monitorings to detect subdomain takeovers. It gets a lot harder if you are new to bug bounty as the unique techniques are unknown to you.
So what d...]]></description><link>https://jubaeralnazi.com/passive-bug-bounty-income-from-taking-over-related-domains</link><guid isPermaLink="true">https://jubaeralnazi.com/passive-bug-bounty-income-from-taking-over-related-domains</guid><category><![CDATA[Security]]></category><category><![CDATA[hacking]]></category><category><![CDATA[domain]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Mon, 25 Apr 2022 09:28:50 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/8lnbXtxFGZw/upload/v1650870872835/mOv2gEHp4.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Subdomain takeovers are now becoming harder and harder to find as people have set up massive automated monitorings to detect subdomain takeovers. It gets a lot harder if you are new to bug bounty as the unique techniques are unknown to you.</p>
<p>So what do you do? Give up? Well since everyone is focusing on enumerating subdomains we can actually look at related domains.</p>
<h2 id="heading-what-are-related-domains">What are related domains?</h2>
<p>Related domains are basically registered domains by the companies but they are just not mentioned in the scope. But these are active domains in production that are maybe responsible for running other services so if you take them over you could also takeover active services.</p>
<h2 id="heading-how-to-takeover-related-domains">How to takeover related domains?</h2>
<p>I have built a platform called SNIFFCON which has a subdomain scanner that actually looks for such related domains and gives output like this:</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1650877618477/0DMwePtEf.png" alt="Screenshot 2022-04-25 at 5.06.54 PM.png" /></p>
<p>But you can also find related domains here: <code>https://otx.alienvault.com/indicator/domain/media.net</code></p>
<p>As you can see OTX provides a lot of false-positive results for related domains but SNIFFCON managed to find the actual domain that belongs to that company.</p>
<p>After identifying the related domains you need to find the domain expiry date because usually, companies forget to renew these low priority domains and expose themselves to critical vulnerabilities because some of the servers might try to communicate with that expired domain. Attackers can implement a TCP dumper in the website to start capturing sensitive data. </p>
<p>SNIFFCON has a whois monitoring tool that allows you to monitor these domains and alerts you when they are expired so you will need something like that to start taking over these related domains as soon as they get dropped.</p>
]]></content:encoded></item><item><title><![CDATA[Reverse Array In Python]]></title><description><![CDATA[An array is a collection of items stored together in sequential memory locations. The idea is to store multiple items of the same type together.

So there are three ways we can reverse an array in python,
1. Slicing
We can use slicing to turn any nor...]]></description><link>https://jubaeralnazi.com/reverse-array-in-python</link><guid isPermaLink="true">https://jubaeralnazi.com/reverse-array-in-python</guid><category><![CDATA[Python 3]]></category><category><![CDATA[Python]]></category><category><![CDATA[data structures]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Sat, 23 Apr 2022 13:24:00 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/HQH-GOZ6K2c/upload/v1650716901002/dIH2DstUt.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>An array is a collection of items stored together in sequential memory locations. The idea is to store multiple items of the same type together.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1650717712473/7E-376C6M.png" alt="image.png" /></p>
<p>So there are three ways we can reverse an array in python,</p>
<h2 id="heading-1-slicing">1. Slicing</h2>
<p>We can use slicing to turn any normal list array into a reverse list array. </p>
<pre><code><span class="hljs-string">list</span> <span class="hljs-string">=</span> [<span class="hljs-number">1</span>,<span class="hljs-number">2</span>,<span class="hljs-number">3</span>,<span class="hljs-number">4</span>]
<span class="hljs-string">print(list[::-1])</span>
</code></pre><pre><code><span class="hljs-attribute">Result</span>: <span class="hljs-number">4</span>,<span class="hljs-number">3</span>,<span class="hljs-number">2</span>,<span class="hljs-number">1</span>
</code></pre><h3 id="heading-how-does-slicing-work">How does slicing work?</h3>
<p>Slicing has three values <code>start</code> <code>stop</code> and <code>step</code> which makes it easier for us to reverse the list here. Some of the examples for slicing would be:</p>
<pre><code>list[<span class="hljs-keyword">start</span>:<span class="hljs-keyword">stop</span>]  <span class="hljs-comment"># items start through stop -1</span>
<span class="hljs-keyword">list</span>[<span class="hljs-keyword">start</span>:]      <span class="hljs-comment"># items start through the rest of the array</span>
<span class="hljs-keyword">list</span>[:<span class="hljs-keyword">stop</span>]       <span class="hljs-comment"># items from the beginning through stop -1</span>
<span class="hljs-keyword">list</span>[:]           <span class="hljs-comment"># a copy of the whole array</span>
<span class="hljs-keyword">list</span>[<span class="hljs-keyword">start</span>:<span class="hljs-keyword">stop</span>:step] <span class="hljs-comment"># start through not past stop, by step</span>
</code></pre><p>To make it easier we can look at this diagram below where positive values mean sequential increment and negative values mean the complete opposite.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1650719122293/kiMgCrv4x.png" alt="image.png" /></p>
<p>As you can see we only used <code>step</code> here <code>list[::-1]</code> in our code to reverse the array and that is because this <code>step</code> works with items from first to last and the amount you put are the steps it will take, for example, if we put this <code>list[::2]</code> it will print only 1 and 3 because the step started from 1 and then skipped 1 and 2 and found 3 so it shows 1 and 3!</p>
<p>Now if you put this <code>list[::1]</code> it will show the all 1,2,3,4 because it is taking 1 and then taking one step and finding 2 then again another step finding 3 this way it will continue. </p>
<p>So now if we <code>list[::-1]</code> put this it goes to the last items and starts from there so the whole list gets reversed!</p>
<h2 id="heading-2-reverse">2. Reverse()</h2>
<p>Python has a built-in method reverse() that automatically reverses the order of the list arrays right at the original place.</p>
<pre><code><span class="hljs-keyword">list</span> = [<span class="hljs-number">1</span>,<span class="hljs-number">2</span>,<span class="hljs-number">3</span>,<span class="hljs-number">4</span>] 
<span class="hljs-keyword">print</span>(<span class="hljs-keyword">list</span>)
<span class="hljs-keyword">list</span>.reverse()
</code></pre><pre><code><span class="hljs-attribute">Result</span>: <span class="hljs-number">4</span>,<span class="hljs-number">3</span>,<span class="hljs-number">2</span>,<span class="hljs-number">1</span>
</code></pre><h2 id="heading-3-reversed">3. Reversed()</h2>
<p>Another similar method is there which is <code>reversed()</code> when passed with a list returns an iterable in reverse order. </p>
<pre><code><span class="hljs-string">arr_list</span> <span class="hljs-string">=</span> [<span class="hljs-number">1</span>,<span class="hljs-number">2</span>,<span class="hljs-number">3</span>,<span class="hljs-number">4</span>] 
<span class="hljs-string">print(list(reversed(arr_list)))</span>
</code></pre><pre><code><span class="hljs-attribute">Result</span>: <span class="hljs-number">4</span>,<span class="hljs-number">3</span>,<span class="hljs-number">2</span>,<span class="hljs-number">1</span>
</code></pre>]]></content:encoded></item><item><title><![CDATA[How to make your FLASK APP asynchronous with gunicorn?]]></title><description><![CDATA[While deep-diving into python's flask framework I realized that flask has some huge issues with asynchronous tasks. See every good thing comes with pros and cons and the asynchronous task seems to be one of the cons here for the flask. 
So as I was b...]]></description><link>https://jubaeralnazi.com/how-to-make-your-flask-app-asynchronous-with-gunicorn</link><guid isPermaLink="true">https://jubaeralnazi.com/how-to-make-your-flask-app-asynchronous-with-gunicorn</guid><category><![CDATA[Flask Framework]]></category><category><![CDATA[asynchronous]]></category><category><![CDATA[deployment]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Tue, 19 Apr 2022 19:31:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/tvHtIGbbjMo/upload/v1650394945371/Zlc_NnPNg5.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>While deep-diving into python's flask framework I realized that flask has some huge issues with asynchronous tasks. See every good thing comes with pros and cons and the asynchronous task seems to be one of the cons here for the flask. </p>
<p>So as I was building this app I realized that even though I used threading <em>(Which is a bad idea to replace async tasks with)</em> inside the application to easily bypass some of these issues it still didn't solve what I wanted. So basically this was the scenario my application was working fine until I realized that all the view functions are not asynchronous at all, If one page was loading then the other page wouldn't load until that was finished which was a complete disaster because it will make the application very slow. </p>
<p>I started asking my friends they suggested me to use queues , celery or other similar projects to do asynchronous tasks smoothly but I had my security scanner developed already and didn't want to add things back to it again so I started looking for solutions and came across gunicorn which gave the exact result I wanted. </p>
<p>So Gunicorn has something called workers which works asynchronously and by spawning 5-6 such workers I achieved complete asynchronous functionality for the view functions in flask. </p>
<h2 id="heading-gunicorn-commands">Gunicorn Commands:</h2>
<p>If you used threading use this:</p>
<p><code>gunicorn --workers=5 --threads=10 --worker-class=gthread app:app</code></p>
<p>If you want to use gevent use this:</p>
<p><code>gunicorn --worker-class=gevent --worker-connections=1000 --workers=5 app:app</code></p>
<p>Note: You don't have to launch more than 10-12 workers as it is mentioned in the <a target="_blank" href="https://docs.gunicorn.org/en/stable/design.html">documentation</a> that 5-6 such workers can easily handle thousands of requests so use them wisely.</p>
]]></content:encoded></item><item><title><![CDATA[Story Of Hacking Grab And How I Got 10000$ From Grab (Hackerone)]]></title><description><![CDATA[So I did not get permission to blog about the whole POC so I will be just throwing some hints here.
Basically, I was able to bypass the grab food’s payment mechanism and it was a serious issue, Imagine ordering foods for free. No more business for gr...]]></description><link>https://jubaeralnazi.com/story-of-hacking-grab-and-how-i-got-10000dollar-from-grab-hackerone</link><guid isPermaLink="true">https://jubaeralnazi.com/story-of-hacking-grab-and-how-i-got-10000dollar-from-grab-hackerone</guid><category><![CDATA[Security]]></category><category><![CDATA[hacking]]></category><dc:creator><![CDATA[Jubaer Alnazi]]></dc:creator><pubDate>Mon, 30 Dec 2019 21:27:22 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1675837633966/d7d312cf-db43-4693-a2bb-fa458341ff07.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>So I did not get permission to blog about the whole POC so I will be just throwing some hints here.</p>
<p>Basically, I was able to bypass the grab food’s payment mechanism and it was a serious issue, Imagine ordering foods for free. No more business for grab, so it was closed as a very severe bug and because of its impact grab was kind of forced to shut down the entire service for it and they paid 10000$ upon verifying the issue and another 1000$ later.</p>
<p>Grab acted very responsible in this manner and was very quick with the bounty also I found a similar issue with Grab’s ride application where you can have unlimited rides but unfortunately it was known to them. After my first report and they still paid 1k$ for that which was really generous of them. Moreover, I was also asked to send my resume because of that bug but I had to reject it due to my studies at that time.</p>
<p>The best part about this whole experience was due to some miscommunication grab actually reached out to @nahamsec to join our conversation so that we can clear things up from both sides which was quite fascinating for me.</p>
<p>My Hackerone Profile: <a target="_blank" href="https://hackerone.com/h33t">h33t</a></p>
]]></content:encoded></item></channel></rss>