<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>nibs</title>
    <description>Nibs writes about building, hacking, and lifing.
</description>
    <link>https://nibsbin.com/</link>
    <atom:link href="https://nibsbin.com/feed.xml" rel="self" type="application/rss+xml"/>
    <pubDate>Wed, 02 Dec 2026 00:59:50 +0000</pubDate>
    <lastBuildDate>Wed, 02 Dec 2026 00:59:50 +0000</lastBuildDate>
    <generator>Jekyll v3.10.0</generator>
    
      <item>
        <title>happy: OSCP Guide</title>
        <description>&lt;p&gt;On December 1, 2019, I woke up for the the reckoning of my &lt;a href=&quot;https://www.offensive-security.com/pwk-oscp/&quot;&gt;PWK/OSCP&lt;/a&gt; course. A week later, I received the official notification: I am an OSCP certified.&lt;/p&gt;

&lt;p&gt;Reading posts from the beginnining of my pentesting journey like &lt;a href=&quot;http://localhost:4000/2019/06/29/hello-world.html&quot;&gt;Hello World&lt;/a&gt; is a trip. Back then, I had to copy-paste all my bash commands. I couldn’t even use Metasploit at that first capture the flag (CTF) event; I just shift-selected targets and spammed exploits in Armitage! The first time I even installed Linux was a week before the competition. After six months of hacking boxes and slashing exercises, I’ve secured the following competencies in my IT/cybersecurity toolbet:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Pentest Methodology&lt;/li&gt;
  &lt;li&gt;SSH (configuration, port forwarding, death)&lt;/li&gt;
  &lt;li&gt;Wireshark &amp;amp; Tcpdump&lt;/li&gt;
  &lt;li&gt;Google hacking &amp;amp; theharvester&lt;/li&gt;
  &lt;li&gt;Metasploit Frameowrk &amp;amp; Searchsploit workflow&lt;/li&gt;
  &lt;li&gt;Ncat &amp;amp; Nmap&lt;/li&gt;
  &lt;li&gt;Openssl self-signing&lt;/li&gt;
  &lt;li&gt;Burp Suite&lt;/li&gt;
  &lt;li&gt;Basic web exploits (LFI, RFI, XSS, etc.)&lt;/li&gt;
  &lt;li&gt;x86 debugging&lt;/li&gt;
  &lt;li&gt;Password cracking (Hydra, Medusa, John)&lt;/li&gt;
  &lt;li&gt;Linux (file structure, installation, versions)&lt;/li&gt;
  &lt;li&gt;Bash automation&lt;/li&gt;
  &lt;li&gt;LaTeX reporting workflow&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I also picked up a little Python, C, Perl, and Ruby – languages that made me deeply miss PowerShell and C#. Not only am I more comfortable with pentesting/CTF, I also feel more confident as a sysadmin because of the Linux, networking, and cryptography skills I learned from the course. My new skills and fancy certification are 100% worth the $1,000 pricetag. Here’s my perspective about preparing for and passing the OSCP.&lt;/p&gt;

&lt;h2 id=&quot;lifestyle&quot;&gt;Lifestyle&lt;/h2&gt;

&lt;p&gt;I’m currently reading Dr. Matthew Walker’s &lt;a href=&quot;https://www.amazon.com/Why-We-Sleep-Unlocking-Dreams-ebook/dp/B06ZZ1YGJ5&quot;&gt;Why We Sleep&lt;/a&gt; and highly recommend his insights for anybody who values their mind or body. 7-9 hours a night is hard to do with military obligations, personal goals, and OSCP cramming; it didn’t always happen. But when I did fully recharged, I could summon the creativity and attention to detail required to bring down elusive lab boxes. In any long-term cognitive challenge but especially during OSCP prep/exam, do your best to get ample sleep.&lt;/p&gt;

&lt;p&gt;I stayed up for 46 hours with only a three-hour nap when I took the OSCP exam. My circadian clock was obliterated: I couldn’t get a full night’s sleep for days. The aftermath impacted my body, job, and emotional health. I learned an important lesson from the experience: my mind doesn’t solve problems without sleep.&lt;/p&gt;

&lt;p&gt;I managed to solve the three hardest boxes with good flow. I had the minimum required points to pass (70 points) and it was bed time. Instead of going to sleep, the addict/completionist in me decided to bang out the last two boxes. In the end, I couldn’t even solve the easy 10 pointer! I watched my lab time tick down to Zero through a haze of sleep deprivation before passing out for three hours.&lt;/p&gt;

&lt;p&gt;Sleep deprivation didn’t make report-writing any easier, but the progress was at least linear. Concetration happened in bursts after involuntarily microsleep. Logical, grammatical, and formatting errors were pervasive. My only defense was obsessive double-triple-sextuple checking the report. The process was agnonizing – especially because losing one point would prevent me from passing. I don’t like caffeine but I’m sure a Monster would only have made my anxiety worse.&lt;/p&gt;

&lt;p&gt;Everyone has their own habits and balance requirements. Personally, I will never again sacrifice sleep for so little gain.&lt;/p&gt;

&lt;h2 id=&quot;preparation&quot;&gt;Preparation&lt;/h2&gt;

&lt;p&gt;&lt;a href=&quot;https://www.netsecfocus.com/oscp/2019/03/29/The_Journey_to_Try_Harder-_TJNulls_Preparation_Guide_for_PWK_OSCP.html&quot;&gt;TJNull’s guide&lt;/a&gt; provides tons of technical resources for the exam. I will expand on soft skills that helped me learn the course material efficiently.&lt;/p&gt;

&lt;p&gt;Two hours/night over six months was a comfortable amount of time for me to pass the OSCP. Invest your time wisely and you will succeed.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://localhost:4000/2019/06/29/day-1.html&quot;&gt;I started&lt;/a&gt; by following walkthroughs of retired machines on Hack the Box. This gave me familiarity with pentesting tools and methodology. When my course started, I paused my HTB premium account and worked solely in the labs.&lt;/p&gt;

&lt;p&gt;The course exercises were fantastic for bootcamping the large volume of specialized pentesting knowledge. If I could redo my time investment, I would complete all the exercises ASAP instead of fucking around in the lab environment. Completing exercises is a straightforward, stress-free endeavor: just knock them out consecutively and document your answers in a massive Word document.&lt;/p&gt;

&lt;p&gt;I HIGHLY recommend submitting a penetration test report for the lab and exercises. Writing the lab report enabled me to autopilot the exam report when I was drunk on sleep deprivation.&lt;/p&gt;

&lt;p&gt;I also HIGHLY recommend reading &lt;a href=&quot;https://support.offensive-security.com/oscp-exam-guide/&quot;&gt;the official exam rules&lt;/a&gt;. I didn’t read the rules before documenting my lab machines and my screenshots reflected that fact. I risked my bonus points while on the cusp of failing because of carelessness.&lt;/p&gt;

&lt;p&gt;After losing my lab time, I prepared for the exam through Hack the Box. These months were an on-and-off struggle against other priorities. I procrastinated and didn’t boot Kali for about a month before setting a date. Having a concrete deadline forced me to squeeze out some study time for OSCP. With study time, I completed ~50% of TJNull’s boxes before the exam date hit.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/happy/tjnull_boxes.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;In Short:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;2hr/night over 6 months is enough time to go from Windows admin to OSCP&lt;/li&gt;
  &lt;li&gt;Get familiar with pentesting through &lt;a href=&quot;https://www.hackthebox.eu&quot;&gt;Hack the Box&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;Knock out PWK course exercises ASAP&lt;/li&gt;
  &lt;li&gt;Read &lt;a href=&quot;https://support.offensive-security.com/oscp-exam-guide/&quot;&gt;the official exam rules&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;Write a lab report&lt;/li&gt;
  &lt;li&gt;Refine skills through TJNull’s boxes&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;the-exam&quot;&gt;The Exam&lt;/h2&gt;

&lt;p&gt;Mental clarity is incredibly important for the exam which means that you will need:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Nutritive food&lt;/li&gt;
  &lt;li&gt;Sleep (before and during)&lt;/li&gt;
  &lt;li&gt;Mental health breaks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I bought 4 Subway wraps and a pack of cigarrettes for the exam. I usually don’t smoke but it’s a great excuse to leave the room and recover some sanity.&lt;/p&gt;

&lt;p&gt;I hit the exam with a running start, easily rooting three high-point machines for 70 points in 12 hours. I rationed my smoke breaks, took frequent walks, and fueled my body with healthy stuff. Then frustration hit on the fourth box, which quickily turned into obsession.&lt;/p&gt;

&lt;p&gt;Do not get frustrated in the exam. Best case, you crack a box you would’ve gotten more easily after a full night’s sleep. Worst case, you spend your entire night slamming your head against the box, close to tears, with no success – kneecapping your mental clarity for other exam objectives.&lt;/p&gt;

&lt;p&gt;Don’t obsess over a box. Accept the real and high possibility of failing. &lt;a href=&quot;https://markmanson.net/not-giving-a-fuck&quot;&gt;Invest your fucks wisely&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Alex, a good friend, took me to the beach to rebalance my emotions. That made all the difference for the next part of the exam.&lt;/p&gt;

&lt;h3 id=&quot;the-report&quot;&gt;THE REPORT&lt;/h3&gt;
&lt;p&gt;I passed the OSCP exam because my report was decent, not because I’m a great hacker. The report is arguably more difficult than the boxes, which is tragic for people who &lt;a href=&quot;https://www.reddit.com/r/oscp/comments/azf0zt/rooted_4_boxes_failed_exam_80_points_i_thought/&quot;&gt;fail with more points&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Emphasis on the exam report makes complete sense: OSCP is certifying industry professionals, not 1337 hackers for the dark web. In my experience, IT and cybersecurity leaders value communication skills more than technical skills because they easily translate into business objectives.&lt;/p&gt;

&lt;p&gt;Ensure your report is structured and coherent, logically discussing each box’s:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Vulnerabilities&lt;/li&gt;
  &lt;li&gt;Recommendations&lt;/li&gt;
  &lt;li&gt;Proof of Concept&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Also include a &lt;em&gt;high (executive)&lt;/em&gt; and &lt;em&gt;low (technical)&lt;/em&gt; level overview of the report. My high-level overview discussed the penetration test in broad strokes.&lt;/p&gt;

&lt;p&gt;My low-level overview detailed the exam objectives and a list of vulnerabilities for each compromised machine.&lt;/p&gt;

&lt;p&gt;Beautiful type setting, table of contents, and hyper-referencing don’t hurt. I used a custom LaTeX template based on &lt;a href=&quot;https://github.com/whoisflynn/OSCP-Exam-Report-Template&quot;&gt;this one&lt;/a&gt; and highly recommend LaTeX to all OSCP journeymen for its stunning document quality.&lt;/p&gt;

&lt;p&gt;I will create a sanitized template based on my report but too much stuff is going on rn (which is why this guide took so long to publish). The template will be complete by the next blog post and the repo link will be added here.&lt;/p&gt;

&lt;h2 id=&quot;happy&quot;&gt;Happy&lt;/h2&gt;

&lt;p&gt;Welp, one goal down… working on some others behind the scenes. Everything I’ve done so far would not have been possible without Reddit, YouTube, and random blog sites. I appreciate the OSINT community a lot so it’s my pleasure to drop these 2 cents into the sea.&lt;/p&gt;

&lt;p&gt;Happy 2020 btw&lt;/p&gt;
</description>
        <pubDate>Sat, 04 Jan 2020 22:06:00 +0000</pubDate>
        <link>https://nibsbin.com/2020/01/04/happy.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2020/01/04/happy.html</guid>
        
        
      </item>
    
      <item>
        <title>idk</title>
        <description>&lt;p&gt;Ramblethoughts below. I suck at blogging.&lt;/p&gt;

&lt;h1 id=&quot;its-happening&quot;&gt;It’s happening&lt;/h1&gt;

&lt;p&gt;I just set a date for my OSCP test near the end of the month. I have three weeks to review the exercises and break TJNull’s Hack The Box machines. The thrill of finality in scheduling the exam is exhilerating. I’m going to do my best to prepare for the gruelling 48 hours. If I pass, I’m going to take a month off the keyboard to detox from cyber. If I fail, I will try again before New Years 2020.&lt;/p&gt;

&lt;h2 id=&quot;life-and-stuff&quot;&gt;Life and stuff&lt;/h2&gt;

&lt;p&gt;I wish I could tackle OSCP like a full-time job but three obstacles stand in my way: time, college, and laziness. In general, I won’t sacrifice gym or mental health time for career goals because it would defeat me in the long run. I paniced [earlier]/2019/09/04/basictraining.html#life) over the realization of how little time I have but now I feel much less neurotic about this crisis.&lt;/p&gt;

&lt;p&gt;I just vacationed to Kauai for two weeks with my dad. He’s visibly older but still dances and hikes with ease. His parents are not longer lucid and it made me wonder how I would feel when my parents forecast the inevitable effects time will ravage me with. Ernest Becker argued against transferance in a human object because humans are fallible - and resting my hopes, identity, and anxieties about the world in any human (including myself) will wither eventually.&lt;/p&gt;

&lt;p&gt;I was on my way to chuch when Sam offered to give me a ride. He said “I didn’t know you were Christian - you don’t seem like the type.” I’m not the type to follow someone’s direction without asking why but I desperately &lt;em&gt;need&lt;/em&gt; meaning. I told him that intellectually, I don’t agree with organized religion but deep down, I’m still a child who wants God’s grace. I think this is the driving force behind my anxiety: I’m incapable of blindly accepting salvation. I don’t know if there is an evolutionary or psychological explanation but I have sincerely tried to throw myself into organized religion for only temporary satisfaction. Eventually, doubt engulfs the entire venture and drives me into spiritual squalor. If I can’t sustainably worship my parents, myself, or God, who can I love? Who can I marry my life’s meaning to?&lt;/p&gt;

&lt;p&gt;Until I have that answer, I’m going to continue a string of meaningless meaning. At the moment, PWK/OSCP is my church. Next it will be college and math. Let’s throw metrics at work into the mix. But after each of these goals are consumed, I will be left searching for a fling with another goal. Maybe the dynamism of meaning is the driving force behind progress. Maybe the constant search for meaning can be my mistress: I will never have an ultimate transferance object - an overarching constant in life - except for the quest to find one.&lt;/p&gt;

&lt;p&gt;Idk. Cyber bores the fuck out of me so I can’t wait to get this piece of paper and move on with my life.&lt;/p&gt;
</description>
        <pubDate>Mon, 11 Nov 2019 22:40:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/11/11/idk.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/11/11/idk.html</guid>
        
        <category>OSCP</category>
        
        <category>Lifestyle</category>
        
        <category>Workflow</category>
        
        
      </item>
    
      <item>
        <title>Rose</title>
        <description>&lt;p&gt;How has an entire month passed since my last post? I’m about to unload my diary.&lt;/p&gt;

&lt;h2 id=&quot;oscp-progress&quot;&gt;OSCP Progress&lt;/h2&gt;

&lt;p&gt;I finished the final PWK lab exercise today at 10:09 PM. The exercises covered XSS, PTH, buffer overflow, tunnel/port forwarding, and much more. I obsessively followed rabbit holes, diving into the &lt;a href=&quot;https://www.youtube.com/watch?v=fpnE6UAfbtU&quot;&gt;endless abstraction of computer science&lt;/a&gt;, labyrinth of &lt;a href=&quot;https://www.tldp.org/LDP/abs/html/io-redirection.html&quot;&gt;bash I/O&lt;/a&gt;, and thrill of ghettorigged automation.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/basictraining/automation.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;The most terrifying thing I learned: this is all &lt;em&gt;basic&lt;/em&gt;. After a month of crunching new tools, techniques, and concepts, I feel like I’ve mainly achieved the capacity to learn more - and to be honest, I’m very nervous about the exam. I have two weeks left of lab time and have just skimmed the surface. Fortunately, I have a better idea about the rocks I need to smash before I can comfortably take the OSCP exam:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;Kill boxes in the lab.&lt;/strong&gt; As many as possible before my pass expires on 9/20.&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Finalize Reports in VSCode/LaTeX.&lt;/strong&gt; I have &lt;a href=&quot;https://github.com/SnpM/latex-guide-guide&quot;&gt;experience&lt;/a&gt; with LaTeX for college assignments and I really enjoy blogging in VSCode. Mastering this workflow can streamline reports for my career in cybersecurity.&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;Solve &lt;a href=&quot;https://www.reddit.com/r/oscp/comments/cu6jhb/updated_oscplike_boxes_from_hackthebox_by_tjnull/&quot;&gt;TJ_Null’s OSCP-like boxes&lt;/a&gt;.&lt;/strong&gt; Also practice LaTeX reporting and maybe integrate the reports with this Jekyll blog. I want to have a professional presence and documenting my solutions/progress is important.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;After I move past those objectives, I’m going to spend a week of &lt;del&gt;stressing&lt;/del&gt; preparing specifically for the exam by triple reading the official instructions and soaking in online blogs, guides, etc.. I want to go into the exam with not just the necessary skills to solve each box, but also the meta-knowledge to smoothly go through those grueling 48 hours.&lt;/p&gt;

&lt;h2 id=&quot;lifestyle&quot;&gt;Lifestyle&lt;/h2&gt;

&lt;p&gt;My classes at WGU have started but I haven’t done a single assignment yet. Fortunately, the classes are self-paced so I can binge them when I find a good time. The advisors at WGU specifically recommend not binge course work - instead knock a little out every day - but my processor is single-threaded and I charge focus like a void ray.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/basictraining/voidray.jpg&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;During orientation for WGU, I filled out a time management form to help plan my weekly recreation, studying, and other obligations. The intention was to help me fit in 15 hours/week for studying but it did the exact opposite. After entering 8hr/day for sleep, I ended up with 30 hours more than the maximum 168. This terrified me. Apparently I can’t socialize, get swol, study for OSCP, study for college, work a full time job, explore myself/society through literature, practice piano/guitar/singing, and blog without violating universal laws of time.&lt;/p&gt;

&lt;p&gt;I’ve already consumed 25% of my life - over 12,000 hours were wasted in video games. On top of that, each week is worth less than I need it to be? What the actual fuck?&lt;/p&gt;

&lt;h3 id=&quot;life&quot;&gt;Life&lt;/h3&gt;

&lt;p&gt;At the moment, these thought-pieces have the most influence on me.&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;&lt;em&gt;The Subtle Art of Not Giving a F*ck&lt;/em&gt; by Mark Manson:&lt;/strong&gt; Mark showed me how to not be a sycophantic worm.&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;&lt;em&gt;Atomic Attraction: The Psychology of Attraction&lt;/em&gt; by Christopher Canwell:&lt;/strong&gt; A fundamentally sexist perspective on being a man. I love civil rights and social justice, but this book lifted a veil of repression. I bought this audiobook to get girls, but it gave me stark consciousness about my mindset, confidence, and appearance.&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;&lt;em&gt;Denial of Death&lt;/em&gt; by Ernest Becker:&lt;/strong&gt; I picked this book up because Mark talked about it in TSAoNGaF. I’m still working my way through the book and processing the ideas but psychology interests me deeply.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I don’t want to write book reports (though I probably should). This is just a lassoing of all the rambled thoughts I have about my psych, design, and purpose:&lt;/p&gt;

&lt;p&gt;The Air Force is an institution I can no longer fully invest my identity in. Becker’s exploration of social hero systems, symbolic expansion, and castration have planted an awareness about artificial or “cheap heroism” inside me - I don’t think it will ever taste as before. Regarding religion, I fundamentally can’t believe in Christianity and am wary about organized religion in general. I don’t have faith. I don’t have a compass to guide me in the right direction through burly detours or terrain. But I do I hope.&lt;/p&gt;

&lt;p&gt;I Sparknoted some of Kierkegard’s ideas and they inspire me to pursue faith in psychology. I want to achieve my human destiny - embrace despair and cure myself of it - self-actualize. To me, this means uniting the finite (what I am) with the infinite (what I want to be) and ego (what I think I am). Maybe this is what Bhudda did with days of endless meditation - I don’t know. I do know that all three components of my “self” are dynamic. By developing physical/emotional strength, pursuing career goals, and introspecting daily, I’m going to align myself and maybe live in peace? Die in peace?&lt;/p&gt;

&lt;p&gt;If I find the time, I’m going to start putting my philosophical thoughts in separate, categorized posts. Some of my ideas are traumatic and putting them on paper is therapeutic.&lt;/p&gt;

&lt;p&gt;E.g. death is change to an irreversible state (what was can never exist again), and we change every day. By the time we die of old age, the person who loved, grew and accomplished throughout our lives is already mostly dead. Achilles’ death was a blessing: he died a rose at full bloom without the curse of eternal withering.&lt;/p&gt;
</description>
        <pubDate>Wed, 04 Sep 2019 21:41:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/09/04/basictraining.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/09/04/basictraining.html</guid>
        
        <category>OSCP</category>
        
        <category>Lifestyle</category>
        
        <category>Workflow</category>
        
        
      </item>
    
      <item>
        <title>Headsmash</title>
        <description>&lt;p&gt;Hi internet, I missed you! Good to be back…&lt;/p&gt;

&lt;p&gt;I’ve actually been overdosing on internet and I’m still not sick of it. OSCP is fun but cruel. The last two weeks have been a mosh pit of Burp, Curl, and MSF - and yes, I even fucked with shellcode. Every day, I’m learning more about how much I don’t know than things to actually know and it’s &lt;strong&gt;&lt;em&gt;AweSome&lt;/em&gt;&lt;/strong&gt;, like playing vanilla Minecraft for the first time. So far, I’ve rooted 11 boxes and discovered 1 subnet secret in 16 days. My progress has been slower than desired because of two evil machines that sucked up 2-3 days each (they were running incredibly vulnerable services, but sufficiently locked down to prevent simple exploitation tactics).&lt;/p&gt;

&lt;p&gt;As always, I suffer from rabbit chasing, get incredibly obsessed with certain boxes; this disrupts my balance and completion strategy. In fact, I haven’t done a single course exercise yet (but I did read the PDF’s preamble on my phone :D). My goal isn’t to show certain boxes who’s boss with copious volumes of Googling that border on insanity. I need to learn efficient penetration testing practices and pass the PWK/OSCP exam. So I’m redirecting.&lt;/p&gt;

&lt;p&gt;Today and tomorrow are my documentation days. I’m writing up every completed box and possibly re-exploiting them for screenshots/review. After wrapping up those boxes, I am tackling the course guide like finals week on night shift: clock in and out of work, gym, homework, sleep. From now on, I’m not going to rush into Chopin’s Fantasie Impromptu before I know all my scales so that I tackle boxes with a solid foundation to research/enumerate/exploit with. Even though senselessly banging my head against rocks is fun.&lt;/p&gt;

&lt;p&gt;By the way, I literally banged my head on a rock last last Friday. They should call the beach ‘Spikey Deathtrap Plains’ instead of ‘White Plains’.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/headsmash/scar.jpg&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But hey - if you think my scar is bad, go look at the rock’s.&lt;/p&gt;
</description>
        <pubDate>Tue, 06 Aug 2019 06:15:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/08/06/headsmash.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/08/06/headsmash.html</guid>
        
        <category>OSCP</category>
        
        <category>Workflow</category>
        
        <category>Lifestyle</category>
        
        
      </item>
    
      <item>
        <title>Loose Ends</title>
        <description>&lt;p&gt;At 14:02 today, I received my PWK/OSCP course email. It contained a 400 page PDF, 800MB of videos, and a connection pack for the lab VPN. After connecting to the lab environment, the first step was clear: use Nmap. It took a while…&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/nmap_sweep.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/nmap_duration.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Fortunately, this long task could not have happened at a better time. It was like support Shen ulting top while his ADC safely froze the wave at t2. I had to clean up my blog and wrap up the post about my most recent machines (this). In addition, I woke up this morning unprepared for battle because of poor choices last night. I made the proactive decision to invest my fatigued day into completing backlogged/administrative work, knocking out subnet enumeration, and recovering mentally/physically.&lt;/p&gt;

&lt;p&gt;So let’s tie up loose ends. Starting tomorrow, I’m pouring 110% into mastering the PWK lab environment. Today, I’m applying my limited brainpower into the last HTB boxes I’ll be looking at for a while.&lt;/p&gt;

&lt;hr /&gt;

&lt;h2 id=&quot;granny&quot;&gt;Granny&lt;/h2&gt;

&lt;p&gt;Granny was the same thing as &lt;a href=&quot;/2019/07/15/brainfk.html&quot;&gt;Grandpa&lt;/a&gt;. Just ran the same 2 exploits,iis_webdav_scstoragepathfromurl and &lt;code&gt;ms10_015&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/granny_rootexploit.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;h2 id=&quot;bank&quot;&gt;Bank&lt;/h2&gt;

&lt;p&gt;Bank was a brainblast for me: it was completely unfamiliar but not hard enough to leave me in the dust. As a n00b Windows admin, I’d never used Linux before the &lt;a href=&quot;/2019/06/29/hello-world.html&quot;&gt;Cyber Shoot&lt;/a&gt;. It’s a rapidly shrinking weakness of mine, but I’m almost clueless about exploiting the operating system.&lt;/p&gt;

&lt;p&gt;Bank introduced me to exploiting PHP and SETUID special permissions. I also got experience with SSH and DNS chasing rabbits. Unfortunately, Bank was very unfamiliar and CTFy; I didn’t have the experience to complete it without walkthrough clues.&lt;/p&gt;

&lt;p&gt;The Nmap scan came back with several red herrings that I greedily chased.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_nmap.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;As a n00b, I go for known machine/service exploits first because web exploits take some exploration and creativity to find.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_apacheexploits.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Nothing promising for Apache 2.4.7 that I could figure out. Same with ISC BIND 9.9.5. OpenSSH did have a user enumeration exploit that I played with.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_sshuserenum.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_sshusers.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But I found out that Linux doesn’t have default passwords; SSH for these accounts are automatically disabled.&lt;/p&gt;

&lt;p&gt;So I played with DNS.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_dig.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Still nothing. The HTTP website served on http://10.10.10.29 was nothing but a default page. The interesting things were all forbidden.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_serverstatus.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;h3 id=&quot;clue-1-bankhtb&quot;&gt;CLUE 1: bank.htb&lt;/h3&gt;

&lt;p&gt;At this point, I couldn’t squeeze into any attack surface given to me. I peeked into &lt;a href=&quot;https://resources.infosecinstitute.com/hack-the-box-htb-machines-walkthrough-series-bank/#gref&quot;&gt;Infosec’s walkthrough&lt;/a&gt; and found that the server served a different site when accessed through its domain name, &lt;code&gt;bank.htb&lt;/code&gt;. This was a surprise - I thought that host names were just for translation to IP.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_hostfile.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Upon inspection of the packets, I found that the HTTP responses were wildy different:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_hostburp.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;In retrospect, the different is the &lt;code&gt;Host&lt;/code&gt; variable in the HTTP GET request. I’m still communicating the same way over TCP with an IP, but the HTTP layer notably specifies the hostname.&lt;/p&gt;

&lt;p&gt;Running Dirbuster against the newly exposed site discovered many pages.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_balancetransfer.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;balance-transfer was extremely interesting. It reminded me of the exposed databases in the PicoCTF challenge I did in middle school.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_accfile.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;There were hundreds of these in the http://bank.htb/balance-transfer! I pulled them all with Wget then did a bunch of Greping and Googling to see if I could break into one of the accounts.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_wgetaccfiles.png&quot; alt=&quot;&quot; /&gt;
&lt;img src=&quot;/assets/media/looseends/bank_whatisacc.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But this turned out to be a wet, flopping red herring because. Then I tried to exploit these PHP files.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_phpfiles.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;h3 id=&quot;clue-2-http-302&quot;&gt;CLUE 2: HTTP 302&lt;/h3&gt;

&lt;p&gt;I got pretty stuck here because of an information gap. The PHP files would redirect me to the login page because I wasn’t authenticated. I checked Infosec’s walkthrough again for this next step. The PHP pages redirected me to the login pagewith HTTP 302’s, but they still served their pages in the content. I manually edited the response with Burp to prevent the redirection.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_noredirect.png&quot; alt=&quot;&quot; /&gt;
&lt;img src=&quot;/assets/media/looseends/bank_uploadnoredirectpage.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;After a while of trying to upload a reverse PHP shell through crafted HTTP packets in Burp…&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_uploadphptest.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;h3 id=&quot;clue-3-read-the-source-code-comments&quot;&gt;CLUE 3: Read the source code comments&lt;/h3&gt;

&lt;p&gt;I realized I skipped over an incredibly easy exploit that was in the HTML comments. It basically tells us to upload a PHP shell with .htb extension.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_debughtbfile.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/bank_phpmeterpretershellopened.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Whoot! User shell! Normally, I would try my best to take it from here but it was late and I had no idea what to do now.&lt;/p&gt;

&lt;h3 id=&quot;clue-4-look-for-suid-binaries&quot;&gt;CLUE 4: Look for SUID binaries&lt;/h3&gt;

&lt;p&gt;I don’t know why I’m calling the walkthrough assists “clues” when I’m basically following steps :/. Anyways, certain binaries have &lt;a href=&quot;https://linux-audit.com/finding-setuid-binaries-on-linux-and-bsd/&quot;&gt;the SETUID permission to allow normal users to execute at that privilege&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/findemergency.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Lucky us! Free root shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/root.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;h2 id=&quot;popcorn-medium&quot;&gt;Popcorn (Medium!)&lt;/h2&gt;

&lt;p&gt;Popcorn was my first Medium solve! This morning, 3 hours before my OSCP course start, I logged into HTB and saw Popcorn pop up with the default machine filter. I usually filter for Incomplete Easy boxes but Popcorn turned out to be a piece of cake!&lt;/p&gt;

&lt;p&gt;I have a process now for every new box I tackle. Set up box folder:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_newbox.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Run nmap (don’t have screenshots but it was similar to Bank). Then Dirbuster with some interesting results.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_dirbusterroot.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;And found a neat Torrent Hoster site in /torrent:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_torrenthosterindex.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Dirbusting this directory…&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_dirbustertorrent.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;My first thought for a PHP site is ‘can I upload and execute a PHP file?’ &lt;a href=&quot;https://www.exploit-db.com/exploits/11746&quot;&gt;Turns out yes&lt;/a&gt;! I booted up Burp and tried:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_burp.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Accessed denied :(. I spent a while tinkering with PHP uploads until I went back to the front page and, you guessed it… signed up for an account. Then &lt;code&gt;upload.php&lt;/code&gt; worked.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_uploadtorrentsuccess.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But I couldn’t upload anything except actual torrent files. I tried messing around with a legitimate .torrent file’s exif data to potentially run remote code but didn’t get anywhere with that. Changing the content-type also didn’t provide fruits because the website probably validates file content.&lt;/p&gt;

&lt;p&gt;I got kind of stuck here. Learned a lot about basic file upload exploit strategies but nothing that worked.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://www.google.com/search?q=popcorn+walkthrough&amp;amp;oq=popcorn+walkthrough&amp;amp;aqs=chrome..69i57j0l5.3737j1j7&amp;amp;sourceid=chrome&amp;amp;ie=UTF-8&quot;&gt;Clue&lt;/a&gt;: Upload malicious file through the torrent’s Submit Screenshot feature.&lt;/p&gt;

&lt;p&gt;Interestingly, editting the torrent’s website profile exposed another upload feature for its screenshot:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_submitscreenshot.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_submitscreenshotburp.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;It worked! I got Msfvenom PHP code onto the server then found its path by &lt;em&gt;refreshing to see the new screenshot&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_msfvenomphp.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Conveniently, Popcorn hosted a &lt;code&gt;/rename/&lt;/code&gt; page that offered directions on how to rename local files :P. I followed it.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_renaming.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;We’re in boiiiissss&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_metsessionopen.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I couldn’t find any exploitable SETUID files so I started trying stuff from Exploit DB that might work. I got lucky with 15285.c.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/looseends/popcorn_run15285.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Popcorn was awesome because it showed that I was getting e1337er; it built on Bank and heavily reinforced my PHP and Linux. I’m proud to have this Medium box in my trophy drawer.&lt;/p&gt;

&lt;hr /&gt;

&lt;p&gt;&lt;em&gt;Note: Picking up this blog post after four days of OSCP. Writing about a past event relative to a past moment in present tense for continuity is weird.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;My plan for OSCP is to prioritize balance. If I keep my room clean, body fueled, and mind clear, I’ll be able to absorb all the hard trying by just throwing hours into the course material. Happy hack1ng.&lt;/p&gt;
</description>
        <pubDate>Sat, 20 Jul 2019 17:56:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/07/20/loose-ends.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/07/20/loose-ends.html</guid>
        
        <category>OSCP</category>
        
        <category>Exploit</category>
        
        <category>Web</category>
        
        <category>Lifestyle</category>
        
        
      </item>
    
      <item>
        <title>Brainfk</title>
        <description>&lt;p&gt;My brain was raw and spongey after &lt;a href=&quot;https://www.hackthebox.eu/home/machines/profile/9&quot;&gt;Arctic&lt;/a&gt;. I gained insight into the following topics:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;RPC, NETBIOS, SMB&lt;/li&gt;
  &lt;li&gt;Endpoint Mapper&lt;/li&gt;
  &lt;li&gt;Coldfusion&lt;/li&gt;
  &lt;li&gt;Local File Inclusion&lt;/li&gt;
  &lt;li&gt;.cfm, .jsp&lt;/li&gt;
  &lt;li&gt;Msfvenom&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All it cost was my sanity. I also tackled &lt;a href=&quot;https://www.hackthebox.eu/home/machines/profile/13&quot;&gt;Grandpa&lt;/a&gt; and gained experience with the following skills:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Burp Suite&lt;/li&gt;
  &lt;li&gt;Nikto&lt;/li&gt;
  &lt;li&gt;HTTP requests &amp;amp; crafting&lt;/li&gt;
  &lt;li&gt;Frontpage RPC&lt;/li&gt;
  &lt;li&gt;UAC Circumvention&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id=&quot;ok-lets-dive-into-madness&quot;&gt;Ok, let’s dive into madness.&lt;/h2&gt;
&lt;h3 id=&quot;arctic&quot;&gt;Arctic&lt;/h3&gt;

&lt;p&gt;The NMAP came back with interesting results.
&lt;img src=&quot;/assets/media/brainfk/scan.png&quot; alt=&quot;scan.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Port 135 (RPC) but 445 (SMB) and 137-139 (NETBIOS) are filtered. MS17 and other SMB exploits would not work. Only a couple of modules could run on port 135.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/search_135.png&quot; alt=&quot;search_135.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;ms03_26_dcom&lt;/code&gt; didn’t create a session but &lt;code&gt;endpoint_mapper&lt;/code&gt; returned interesting information.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/endpoint_mapper.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I desperately tried to find the relevancy of port 49154 by comping endpoint_mapper. I read on &lt;a href=&quot;https://serverfault.com/questions/526607/what-is-msrpc-needed-for-on-a-windows-7-workstation&quot;&gt;SE&lt;/a&gt; that it “allows remote viewing and administration of Scheduled Tasks”. This led me to installing Windows 10 Pro for RSAT tools. Ultimately, I couldn’t find a way to exploit port 49154; it was probably a red herring.&lt;/p&gt;

&lt;p&gt;After two days of showering RPC and other ports with remote exploits, I decided to read:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/port8500.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I can’t believe I didn’t try accessing port 8500 as an HTTP service. I even looked into Flight Message Transfer Protocol (FMTP) before Coldfusion web administration! I tried the Coldfusion &lt;a href=&quot;https://jumpespjump.blogspot.com/2014/03/attacking-adobe-coldfusion.html&quot;&gt;Local File Inclusion&lt;/a&gt;…&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/arctic_administrator.png&quot; alt=&quot;arctic_administrator&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/arctic_localfileinclusion.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;And logged in as &lt;code&gt;admin&lt;/code&gt; and navigated to Task Scheduler. From here, I could upload and run files, managed to get a backdoor .cfm shell.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/task_schedule.png&quot; alt=&quot;task_schedule&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/arctic_backdoor.png&quot; alt=&quot;arctic_backdoor&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But it didn’t work! After a lot of testing and trying different .cfm shells, I found out that the &lt;code&gt;&amp;lt;cfexecute&amp;gt;&lt;/code&gt; functionality was broken/disabled, preventing my .cfm shells from starting any program. I couldn’t easily run Cmd.exe or uploaded Msfvenom payloads.&lt;/p&gt;

&lt;p&gt;This is where I got stuck. I frankly didn’t have the knowledge base to move forward. &lt;a href=&quot;https://github.com/Hackplayers/hackthebox-writeups/blob/master/machines/Arctic/fiti-arctic.pdf&quot;&gt;Ippsec’s writeup&lt;/a&gt; pointed me in the right direction. Instead of using a .cfm shell, I could run more privileged code with a .jsp backdoor.&lt;/p&gt;

&lt;p&gt;I had upload access through web administration login, but I followed their Burp Repeater method of uploading the file. Seeing the data going through HTTP and crafting it was very interesting.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/arctic_burp_repeater.png&quot; alt=&quot;arctic_burp_repeater&quot; /&gt;&lt;/p&gt;

&lt;p&gt;BOOM! We got a Meterpreter shell. I can take it from here.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/arctic_shell.png&quot; alt=&quot;arctic_shell&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I had to get an x64 shell to run certain 2012.1 R2 x64 exploits; &lt;code&gt;inject_payload&lt;/code&gt; did the trick. After that, ms13_081 gave me the root shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/root_exploit.png&quot; alt=&quot;root_exploit&quot; /&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/rooted.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;After…&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;&lt;em&gt;Installing scouring the internet for RPC exploits&lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;&lt;em&gt;Installing Windows 10 Pro + Kali on Hyper-v&lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;Using Coldfusion LFI&lt;/li&gt;
  &lt;li&gt;Debugging my .cfm shell&lt;/li&gt;
  &lt;li&gt;Finding out about .jsp shells&lt;/li&gt;
  &lt;li&gt;Crafting a packet exploiting upload.cfm&lt;/li&gt;
  &lt;li&gt;Pivoting from x86 to x64 Meterpreter shell&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I did it.&lt;/p&gt;

&lt;h3 id=&quot;grandpa&quot;&gt;Grandpa&lt;/h3&gt;
&lt;p&gt;Grandpa was easy unlike Arctic. The Nmap scan came back with just port 80 open so no red herrings.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/grandpa_scan.png&quot; alt=&quot;grandpa_scan&quot; /&gt;&lt;/p&gt;

&lt;p&gt;A Nikto scan discovered that dangerous HTTP methods were available and the server was hosting Frontpage with potential RPC exploits.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/grandpa_nikto.png&quot; alt=&quot;grandpa_nikto.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I played with these vulnerabilities but the permissions seemed to be locked down, so I went the IIS 6.0 route:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/grandpa_search.png&quot; alt=&quot;grandpa_search.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Easy user shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/grandpa_userexploit.png&quot; alt=&quot;grandpa_userexploit.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I think the shell was degraded by UAC. I couldn’t run &lt;code&gt;getuid&lt;/code&gt; or any exploits suggested by &lt;code&gt;local_exploit_suggester&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/brainfk/grandpa_accessdenied.png&quot; alt=&quot;grandpa_accessdenied&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Injecting a payload with &lt;code&gt;payload_inject&lt;/code&gt; for a new shell fixed this. &lt;code&gt;ms10_015&lt;/code&gt; worked from this new shell.&lt;/p&gt;

&lt;hr /&gt;
&lt;p&gt;Overall, I feel much more familiar with the Kali/hacking environment. I have many knowledge gaps but they are getting steadily getting patched with every completed box. I’m optimistic: after I get more “Easy” boxes under my belt and read the PWK course materials, I might be able to solo some Medium and Hard boxes.&lt;/p&gt;
</description>
        <pubDate>Mon, 15 Jul 2019 23:03:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/07/15/brainfk.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/07/15/brainfk.html</guid>
        
        <category>OSCP</category>
        
        <category>Exploit</category>
        
        <category>Web</category>
        
        
      </item>
    
      <item>
        <title>Try Harder Next Time</title>
        <description>&lt;p&gt;I spent the last three days on an “easy” box called Optimum To give an idea of how much I struggled, here’s the folder I threw everything Optimum-related into. Note to self: work on folder organization.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/messy_folder.png&quot; alt=&quot;sinkorswim_messy_folder.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Yesterday, I finally rooted and looted Optimum for a chestful of XP. Here’s what happened.&lt;/p&gt;

&lt;p&gt;The Nmap scan discovered that only port 80 was open.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/scan.png&quot; alt=&quot;scan.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Webpage: 
&lt;img src=&quot;/assets/media/sinkorswim/webpage.png&quot; alt=&quot;webpage.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;The server hosts HTTPFileServer 2.3. Searchsploit showed the following vulnerabilities:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/hfs_vuln.png&quot; alt=&quot;hfs_vuln.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Score! An exploit existed in Metasploit.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/hfs_metasploit.png&quot; alt=&quot;hfs_metasploit.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But it didn’t work :(.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/hfs_metasploitfail.png&quot; alt=&quot;hfs_metasploitfail.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;In retrospect, the exploit didn’t work because I didn’t set the local IP to my VPN address. Instead of realizing that, I decided to take the Metasploit training wheels off. I had to use a custom exploit and even understand it potentially. I dug into many exploits but eventually found the ticket: &lt;code&gt;39719.py&lt;/code&gt;. Getting &lt;code&gt;39719.py&lt;/code&gt; to work was hard.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/39719.py.png&quot; alt=&quot;39719.py.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;The next day, a n00b like me from work helped me pull off the exploit with the power of teamwork. Sam and I decoded the url-encoded VBS payload that &lt;code&gt;39719.py&lt;/code&gt; injected into the site’s unsanitized REGEX query and discovered it was attempting to download nc.exe from an HTTP server.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/decodedVBS.png&quot; alt=&quot;decodedVBS.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Then Sam did the unthinkable: he actually read the developer’s comments. Soon we had a Python HTTP server ready to go on port 80 and Netcat server on port 1234 - like what the comments said to do. Houston, we have a shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/ncshell.png&quot; alt=&quot;ncshell.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Rooting the machine through this shell turned out to be even more difficult. I didn’t know where to go from a shell so I Googled for ways to upgrade to a Meterpreter session. Msfvenom generated the reverse_tcp payload but how do I run it on the machine? Thanks to &lt;a href=&quot;https://superuser.com/questions/25538/how-to-download-files-from-command-line-in-windows-like-wget-or-curl&quot;&gt;Stack Exchange&lt;/a&gt;, I found out that certutil.exe can do the job.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/certutildownload.png&quot; alt=&quot;certutildownload.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;It worked! I ran &lt;code&gt;local_exploit_suggester&lt;/code&gt; in Metasploit but neither of the two results worked. I still don’t know what to look for when enumerating a system so I desperately need these automated exploit suggesters. Fortunately, I found GDSSecurity\Windows-Exploit-Suggester which suggested &lt;a href=&quot;/assets/media/sinkorswim/windows-exploit-suggester_results.txt&quot;&gt;these vulnerabilities&lt;/a&gt; based on the target’s systeminfo.&lt;/p&gt;

&lt;p&gt;Unfortunately, many of them were proof-of-concepts. I spent several hours trying to use &lt;a href=&quot;https://www.exploit-db.com/exploits/39719/&quot;&gt;Local Privilege Escalation (MS16-032) (PowerShell)&lt;/a&gt; because I’m familiar with PowerShell, but did not succeed. On Monday evening, I gave up. All the tools and information were in front of me but I didn’t want to “try harder” to figure out the solution myself.&lt;/p&gt;

&lt;p&gt;After Googling the box, I discovered that other players experienced the same issue of Metasploit modules not working as expected against Optimum. I found the solution on &lt;a href=&quot;https://www.hackingarticles.in/hack-the-box-challenge-optimum-walkthrough/&quot;&gt;Raj Chandel’s blog&lt;/a&gt;: use &lt;a href=&quot;https://www.exploit-db.com/exploits/41020/&quot;&gt;Microsoft Windows 8.1 (x64) - RGNOBJ Integer Overflow (MS16-098)&lt;/a&gt; manually to escalate privileges; rooting with this exploit was as easy as uploading the binary then running it in a cmd shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/sinkorswim/rooting.png&quot; alt=&quot;rooting.png&quot; /&gt;&lt;/p&gt;

&lt;hr /&gt;

&lt;p&gt;I tried swimming on my own but ultimately, I didn’t believe myself and sank into the cold embrace of &lt;del&gt;failure&lt;/del&gt; walkthroughs. I learned a lot about the basics - using common tools like Netcat,  deploying Msfvenom payloads, dissecting exploit scripts, and working outside of Metasploit - but I will believe in myself more in the future. At the moment, giving up means using a walkthrough. On the OSCP exam, giving up means losing points. I had the solution staring at me from the Windows-Exploit-Suggester output. If I tried harder and iterated down the list, I could have solved this box without the answer.&lt;/p&gt;
</description>
        <pubDate>Tue, 09 Jul 2019 23:11:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/07/09/sink-or-swim.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/07/09/sink-or-swim.html</guid>
        
        <category>OSCP</category>
        
        <category>Exploit</category>
        
        <category>Web</category>
        
        
      </item>
    
      <item>
        <title>Dragonborn</title>
        <description>&lt;p&gt;Like many video games, learning how to hack boxes is a progressive grind. The thing I’m most starved for is experience: hours of hands-on keyboard-mashing information dump. No more rabbit holes. I’m going to work down the list of Easy boxes and use walkthroughs whenever I exhaust my limited knowledge cache.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/htb_list.png&quot; alt=&quot;htb_list.png&quot; /&gt;&lt;/p&gt;

&lt;h3 id=&quot;legacy&quot;&gt;Legacy&lt;/h3&gt;
&lt;p&gt;My first solo attempt was an easy kill. I ran Nmap and discovered that ports 139 and 445 open - it’s probably a Windows device running SMB.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/scan.png&quot; alt=&quot;scan.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;In the 24 AF Cyber Shoot, ms17_10 External Blue vulnerabilities were littered across the environment so I’m familiar with exploiting this vulnerability. &lt;code&gt;exploit/windows/smb/ms17_010_psexec&lt;/code&gt; in Metasploit did the trick and gave me root access. Unfortunately, I forgot to take a screenshot of my work in my rush to take advantage of something I know. I’ll try to be more conscious about documentation for future exploits.&lt;/p&gt;

&lt;h3 id=&quot;devel&quot;&gt;Devel&lt;/h3&gt;
&lt;p&gt;This box taught me foundational lessons in web backdooring.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/devel_scan.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I played around with PHP backdoors in the Cyber Shoot but never got anywhere. Devel allowed me to upload a reverse TCP shell through FTP.&lt;/p&gt;

&lt;p&gt;Msfvenom, Metasploit’s &lt;code&gt;exploit/multi/handler&lt;/code&gt;, and .aspx files were unfamiliar territory for me but &lt;a href=&quot;https://www.youtube.com/watch?v=2LNyAbroZUk&quot;&gt;IppSec’s walkthrough&lt;/a&gt; guided me through smoothly.&lt;/p&gt;

&lt;h3 id=&quot;beep&quot;&gt;Beep&lt;/h3&gt;
&lt;p&gt;So far, this is the most interesting box I can comprehend. Beep is an Elastix (PBX, email, faxing, etc.) server with a variety of attack surfaces exposed.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/beep_scan.png&quot; alt=&quot;beep_scan.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I didn’t see any familiar services so I visited the website and ran Dirbuster. The index had nothing interesting but Dirbuster found a subdirectory called ‘Admin’.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/beep_dirbuster.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Navigating here led me to an admin login page with the software version conveniently displayed.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/beep_admin.png&quot; alt=&quot;beep_admin.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I found a variety of vulnerabilities that could apply to FreePBX 2.8.1.4 with Searchsploit. This is where I got stuck. At this point, I still didn’t understand Searchsploit - I thought it was an extension for Metasploit but it’s actually a tool to search the independent &lt;a href=&quot;https://www.exploit-db.com/&quot;&gt;exploit-db&lt;/a&gt; database of independent tools and proof-of-concepts. I didn’t know what a local file inclusion was and the &lt;code&gt;exploits/php/webapps/40614.py&lt;/code&gt; script kept returning an SSL unsupported error even when SSLVerify was disabled.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/beep_sslerror.png&quot; alt=&quot;beep_sslerror.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Screw it, I turned to &lt;a href=&quot;https://www.youtube.com/watch?v=XJmBpOd__N8&quot;&gt;IppSec’s Beep walkthrough&lt;/a&gt; to patch my knowledge gaps and accomplish that grind.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/dragonborn/beep_completed.png&quot; alt=&quot;beep_completed.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;The result was a little too convenient. Vtiger revealed a page with cleartext passwords that happened to be reused for the root account. Still, learning about LFI’s was pretty neat so I gave myself an easy pat on the back.&lt;/p&gt;

&lt;p&gt;The video also went showed the source of Vtiger’s LFE. I’ve never done web development but the URL string fitting into the unsanitized PHP script clicked instantly. Even though I only used for the first exploit, I learned a lot from the entire video.&lt;/p&gt;

&lt;h2 id=&quot;overall&quot;&gt;Overall&lt;/h2&gt;
&lt;p&gt;The grind has been very fruitful so far. I don’t think the boxes will feel repetitive any time soon and extra practice is very welcome. Taking down these boxes feels very similar to the dragon battles in Skyrim: I scramble around button mashing, take down the target in stages, then absorb its essence after it dies. Hacking in real life is just like Hacking (and Slashing) in Skyrim, with a similarly vast world and sophisticated but intuitive battle mechanics. The graphics are retro af. I’ll give it 5/7.&lt;/p&gt;
</description>
        <pubDate>Sun, 07 Jul 2019 05:01:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/07/07/dragonborn.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/07/07/dragonborn.html</guid>
        
        <category>OSCP</category>
        
        <category>Exploit</category>
        
        <category>Web</category>
        
        
      </item>
    
      <item>
        <title>The Rabbit Hole</title>
        <description>&lt;p&gt;Last Sunday evening, I fell into a rabbit hole. My original plan was to attack another host with a service vulnerability without using a walkthrough. Instead of scanning each host one-by-one, I decided to that running a mass scan against all the IPs would be more efficient. So I started to generate the list.&lt;/p&gt;

&lt;details&gt;&lt;summary&gt;Unfortunately I have a fatal flaw.&lt;/summary&gt;
  I have a hamartia when it comes to tedious tasks: if there is an interface to automate what would normally be done with hundreds of manual actions, I will attempt to automate the task. It&apos;s not that I hate clicking buttons; I just can&apos;t resist the allure of finding a more efficient way of solving a problem - even if the process of finding it is significantly less efficient. Xkcd&apos;s graphic has been a good guide for me to find balance, but sometimes I let loose a little and slide down the rabbit hole.

  ![is_it_worth_the_time.png](/assets/media/therabbithole/is_it_worth_the_time.png)
&lt;/details&gt;

&lt;p&gt;I attempted to mine Hack The Box’s website for IPs to scan. I saved the machine list webpage, beautified it, then ran something like &lt;code&gt;grep -E -O &apos;([0-9]{1,3}\.){3}[0-9]{1,3}&apos; machinelist.html&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/therabbithole/early_machinelist_grep.png&quot; alt=&quot;An early attempt to mine target IPs&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Easy enuff. But what if one of the machines’ change? Then all that time spent scanning would be wasted without correlating it to a live target. I needed a way to link the IP back its name on the website. Unfortunately, Grep does not like HTML. I explored Sed and followed &lt;a href=&quot;http://www.grymoire.com/Unix/Sed.html&quot;&gt;this guide&lt;/a&gt;) halfway before attempting to use Sed for extracting the machine name and IP from the downloaded HTML file.&lt;/p&gt;

&lt;p&gt;It turned into something of a clusterfk.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/therabbithole/playing_with_sed.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;So I tried awk but quickly noped out on this route.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/therabbithole/playing_with_awk.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Finally Python saved the day!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/therabbithole/playing_with_python2.png&quot; alt=&quot;playing_with_python2.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Then Hack The Box updated their machine list page, so I had to dig through the HTML again to find Grepabble patterns. Eventually, Frankenstein’s monster lived: &lt;code&gt;cat machinelist.html | grep -E -B 4 &quot;([0-9]{1,3}[\.]){3}[0-9]{1,3}&quot; | grep -A 4 &quot;Created by&quot; | grep -E &quot;(Created by)|(([0-9]{1,3}[\.]){3}[0-9]{1,3})&quot; | python strip_html.py | grep -E &apos;.+&apos;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/therabbithole/parse_machinelist.png&quot; alt=&quot;&quot; /&gt;&lt;/p&gt;

&lt;p&gt;But as luck would have it, Hack The Box just updated their VM system to automatically expire. So I lost my window to scan all the boxes. On the bright side, I learned a bit of Bash, Sed, and Python and might be able to shave 20 minutes off on the OSCP exam.&lt;/p&gt;

&lt;p&gt;Time to get back to hacking.&lt;/p&gt;
</description>
        <pubDate>Wed, 03 Jul 2019 06:53:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/07/03/the-rabbit-hole.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/07/03/the-rabbit-hole.html</guid>
        
        
      </item>
    
      <item>
        <title>Day 1</title>
        <description>&lt;p&gt;Today is go day! I had started fasting early Friday afternoon; this morning, I broke it with the most delicious apple and bread. By 10:00 am, I finished my workout, enjoyed wasabi poke for breakfast, and secured the standing table at Starbucks (my roommate moved out with his WiFi last week). I’m physically, mentally, and spiritually ready to hack. Today is GO DAY.&lt;/p&gt;

&lt;p&gt;I first purchased my VIP subscription on [www.hackthebox.eu]. The retired machines have writeups and video walkthroughs - prime fodder for sponging in some experience. Yesterday, I watched Hackersploit’s &lt;a href=&quot;https://www.youtube.com/watch?v=Ru8YxARNS7M&amp;amp;t=676s&quot;&gt;Lame walkthrough&lt;/a&gt; so I wanted to start there. Logging in, connecting via VPN, then finding the Lame host was straightforward. I began by running an Nmap scan with service detection:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;nmap -sS -sV -A 10.10.10.3 -oX scan0.xml&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Then importing scan0.xml into Zenmap:&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/day1/lame_zenmap.png&quot; alt=&quot;lame_zenmap.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I don’t fully understand the workflow between Searchsploit and Metasploit yet (I need to look into this more), but I found the usermap_script that Hackersploit used. It gave me a shell!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/day1/lame_usermap_script.png&quot; alt=&quot;lame_usermap_script.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I spent the next 30 minutes exploring the machine like a Zork map until I found &lt;code&gt;/root/root.txt&lt;/code&gt; and &lt;code&gt;/home/user/makis/user.txt&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/day1/lame_user.txt.png&quot; alt=&quot;lame_user.txt.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;Searching for the hash files taught me a lot about Linux directory navigation but in retrospect, finding the hash with &lt;code&gt;find . -name &quot;*.txt&quot;&lt;/code&gt; would’ve been a lot faster than combing through each subdirectory. It worked out in the end. Thanks to Hackersploit, I owned my first box!&lt;/p&gt;

&lt;p&gt;&lt;img src=&quot;/assets/media/day1/lame_user_owned.png&quot; alt=&quot;lame_user_owned.png&quot; /&gt;&lt;/p&gt;

&lt;p&gt;I spent the next 3 hours figuring out how to fix my blog :/.
On the bright side, this is really good practice for documentation/reporting.&lt;/p&gt;

</description>
        <pubDate>Sun, 30 Jun 2019 23:05:00 +0000</pubDate>
        <link>https://nibsbin.com/2019/06/30/day-1.html</link>
        <guid isPermaLink="true">https://nibsbin.com/2019/06/30/day-1.html</guid>
        
        <category>OSCP</category>
        
        <category>Lifestyle</category>
        
        
      </item>
    
  </channel>
</rss>
