<?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 Mahmoud Adel on Medium]]></title>
        <description><![CDATA[Stories by Mahmoud Adel on Medium]]></description>
        <link>https://medium.com/@mahmoudadel0x?source=rss-75f4feae12f9------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*jOCUAtkRp6ReE7a5.</url>
            <title>Stories by Mahmoud Adel on Medium</title>
            <link>https://medium.com/@mahmoudadel0x?source=rss-75f4feae12f9------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 14:22:26 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mahmoudadel0x/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[computer security & binary hacking concepts and basics]]></title>
            <link>https://medium.com/@mahmoudadel0x/computer-security-binary-hacking-concepts-and-basics-fae791a80c49?source=rss-75f4feae12f9------2</link>
            <guid isPermaLink="false">https://medium.com/p/fae791a80c49</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[computer-security]]></category>
            <category><![CDATA[computer-science]]></category>
            <category><![CDATA[cpu]]></category>
            <category><![CDATA[kernel]]></category>
            <dc:creator><![CDATA[Mahmoud Adel]]></dc:creator>
            <pubDate>Fri, 20 Jul 2018 09:00:56 GMT</pubDate>
            <atom:updated>2020-06-01T07:11:39.562Z</atom:updated>
            <content:encoded><![CDATA[<p>hey ! , i am 16 years old egyptian computer hacker and i wanted to share knowledge about binary hacking for you all</p><p>facebook url : <a href="https://www.facebook.com/mahmoudadel0x">https://www.facebook.com/mahmoudadel0x</a></p><p>lets start , i will talk about three topics:</p><p>three for now and next session i will continue</p><p>1- computer memory and virtual addressing</p><p>2- OS functionality and control overview</p><p>3- buffer overflows</p><h4>computer memory and virtual addressing:</h4><p>every program get executed by already running program and it inherits environment variables from it , this how the algorithms work the already running program is the interface for you it maybe the GUI or TTY login shell etc ..</p><p>once program get executed by a kernel<em> systemcall </em>responsible for this we will talk about that later , the program moves into the physical ram and its instructions get executed line by line</p><p>the program can call any function within its segment by its address like 0x774ffffffffff so how could the kernel manage that access by this any program can accesss any other programs segment and stole data ! for here there is virtual addressing its a kernel job to create a managed pages contain virtual address space and corresponding physical ram address space if the program tried to access out of its page it get itself in an interrupt handler</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/617/1*InRNgTh3lgN_DF47TWHsZg.jpeg" /><figcaption>image explain the management operation</figcaption></figure><h4>Cpu modes and OS functionality , control overview:</h4><p>now lets talk about how actually a program works in a programmatically way , example of write to a file</p><p>when you write to a file in C or PHP or other language actually when the code get compiled/interpretered it just calls a defined functionality in OS to do the operation it is called a system call you can read about systemcalls more further in google/wiki or linux man pages , that call just get handled by the kernel — its possible in diffrent ways for example i will explain an assembly progam :</p><p>`</p><p>mov eax, 4<br> mov ebx, 1<br> mov ecx, dispMsg<br> mov edx, lenDispMsg<br> int 80h</p><p>`</p><p>the following instructions is adding number 4 in eax cpu register which is a system call number has corresponding function in the kernel its is sys_write call , move 1 to ebx register which is a file descriptor number which is her STDOUT ( the terminal virtual device in this situation to show you the message in the screen )</p><p>and the length to ecx and the actual message to the edx and now most important part int 80h which is equal to int 0x80 this is a software interrupt search for google for further info this interrupt already has a defined section the kernel interrupt handle table ans so once cpu execute this it direct execution to the kernel and kernel do the rest and take arguments from cpu registers !</p><p>now to finish the control part , probably u asked is the application itself able to access that file on the disk ! , no because of cpu modes ! kernel is running in a different hardware execution level that allows to communicate with hardware and BIOS , kernel has access to the hardware but the application cannot so the application in cpu protected mode actually cannot do anything further than what the kernel offers by syscalls ! controling this modes by cpu register called cr0 search in google/wiki for it this cr0 is a cpu control register as i said its give u control so you cannot use it from user application ( user space) you can write kernel space code and insert module into the kernel )</p><h3>buffer_Overflows:</h3><p>now you have basics lets go in the targeted topic the buffer overflow what actually happen is using dangerous syscalls without bound checking or any limit ! calls like gets() for example , not in every situation you can exploit the buffer overflow no you cannot always and you just can just denial of service only ! next session i will explain the exploitation way now lets understand first</p><p>when program calls a function it use call and ret cpu instruction when call happen cpu switch the next instruction to be executed to the first instruction in the called function after function is finished ret get executed which means return to the caller how the cpu know the caller address ! by saving it in the STACK ! ex (save eip=0xcaller) when buffer overflow occurs the data in the stack segment get overwritten so that address be changed to a new address simple C program :</p><p>char buffer[4];<br> int var = 0;</p><p>scanf(“%s”, &amp;buffer);<br>printf(“overflowed var = 0x%x\n”, var);</p><p>this program declare an array of 4 type characters and variable named var of type integer and equal to zero and call kernel by scanf syscall to take user input with no bound checking lets see result in the debugger</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PmxshFjj6reqAdrMsWoExw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*e148Y7S35L5LDucdD9SMKA.png" /><figcaption>look for segmentaion fault and see the stack we overwritten the stack !</figcaption></figure><p>now this is enough to be able to understand that things hope you are now understand what happens well next session i will take you deeper in binary hacking protections and bypasses, and dont forget to support me by following me in facebook and twitter i am at <a href="https://twitter.com/buff3r_overflow">https://twitter.com/</a>gnuabi</p><p>, thanks</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fae791a80c49" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[evade network scanners with firewall]]></title>
            <link>https://medium.com/@mahmoudadel0x/evade-network-scanners-with-firewall-e43f597055a7?source=rss-75f4feae12f9------2</link>
            <guid isPermaLink="false">https://medium.com/p/e43f597055a7</guid>
            <category><![CDATA[great-firewall]]></category>
            <category><![CDATA[hacking]]></category>
            <category><![CDATA[networking]]></category>
            <category><![CDATA[network-security]]></category>
            <dc:creator><![CDATA[Mahmoud Adel]]></dc:creator>
            <pubDate>Mon, 18 Jun 2018 07:19:32 GMT</pubDate>
            <atom:updated>2023-01-16T17:51:08.009Z</atom:updated>
            <content:encoded><![CDATA[<p>we all know most common network scanner NMAP , the mechanism that all network scanner work with is testing kernel net transport layer protocol response [ICMP / TCP /UDP/SCTP] in the whole 65 thousand ports</p><p>now how scanners know if port is open / closed /filtered , if you dont know i will explain in TCP layer for example if there is a socket is listening in kernel in machine 192.168.1.15 if 192.168.1.10 send syn packet the kernel will response with ack and now nmap knows port is open and detecting common app layers is easy if ssh response will be ssh handshake and if http for example you will see response with http headers , you can see this yourself with wireshark</p><p>if port is filtered in common ways kernel net filters (firewalls) check Internet protocol layer if ip is not match the allowed rule it wont accept data and for then if nmap send syn the kernel will not respond at all so nmap tells you port is filtered</p><p>now if you have a sensitive port like ssh 22 and want to hide that service there is good technique in TCP/IP mechanism if kernel found no proccess listening on a socket and it recevies syns from outside it will respond with TCP-RST flag which refers to RESET connection to tell the agent that no service here</p><p>here is how can we use TCP-RST to protect your company</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HZhqDc6vzyRfp8j401_-YQ.png" /><figcaption>here is NC listening on port 22</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ixJOiwKTOXKybRwWgWA1Tw.png" /><figcaption>here is the technique</figcaption></figure><p>to accept the connnection from only a specified source ip addr an iptables rule will be like</p><p>`iptables -A INPUT ! -s 192.168.1.40 -p tcp -m tcp — dport 22 -j REJECT — reject-with`</p><p>the command above will set that rule to respond with reset flag to anyone except 192.168.1.40</p><p>hope this was useful for you , follow me on twitter <a href="https://twitter.com/buff3r_overflow">https://twitter.com</a>/0xvdso</p><p>, thanks</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e43f597055a7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Two captcha bypasses — IDOR and token reuse]]></title>
            <link>https://medium.com/@mahmoudadel0x/two-captcha-bypasses-idor-and-token-reuse-3ccc385236b?source=rss-75f4feae12f9------2</link>
            <guid isPermaLink="false">https://medium.com/p/3ccc385236b</guid>
            <category><![CDATA[captcha]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[Mahmoud Adel]]></dc:creator>
            <pubDate>Fri, 27 Apr 2018 23:18:28 GMT</pubDate>
            <atom:updated>2018-04-27T23:18:28.486Z</atom:updated>
            <content:encoded><![CDATA[<p>thats my first write up here , i will talk about how i bypassed captcha on two companies</p><p>first one (captcha token reuse):</p><p>while testing a site.example.com i found that sign up on their site have captcha i solved captcha challenged and captured request with credentials and i saw captcha response token</p><p>it was like</p><p>&amp;g-recaptcha-response=03AJpayVGwtrg6bOlwaMCLZ9-vHQcM0jxbgdU_JcPyQI4e4QZlBbj7WrWHw8I13IW5qT6yd-g8txCFoThxlzDB8b-aGvX16idgAktxU5459HNgVFC5n8h0-aHGPH1eOCWJuw5c0mo5sGI9DflNPGfnK5Rq90Zj4gFtCU9y5IGks4SWLH2iA0OGIQ9gISptqd8QuMqKcYROgNQ3huLb-gikJX7VQBvfR2Tw24TAP8OX5LQofNYaFE8sDx77Smtrf7fF9pVvqwVYoETDkoeA8exu2V90YMAw0apTtNhVy2SCikb3aTZI5bt7ZYJVgdObNDDwFTU3nonAJM88GRMA-vmX3atBhGGoQw56QaooPGjVMcJnly-LK154RoBh4R8S-BBNqLZfk4ivJH7K</p><p>i tried the same request at burp repeater with another mail and password and woow wtf ! web app just not terminate the valid token after it be used i sent POST request to intruder and launch an attack and i made 100 accounts i less than a 40 seconds i send POC video to company but unfortunately its duplicate !</p><p>Hi mahmoud,</p><p>Thank you for your report.</p><p>The ability to bypass our signup controls is a known issue that our engineers are currently working to addres</p><p>another hacker reported it 5 months ago and problem not fixed !</p><p>bad luck , but i didnt gave up and i found a second way to bypass captcha but at different application</p><p>second one (IDOR):</p><p>it was insecure direct object while testing example.com i found that when sign in if i typed credentials three times fault it show up a captcha</p><p>i found that on url there is fail=1&amp;captcha=1 parameters i put 0 instead of 1 and i bypassed the captcha i have found that captcha turned off</p><p>and i able to bruteforce now !</p><p>and report is triaged (open)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3ccc385236b" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>