<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xml:base="https://ctfcrew.org"  xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
 <title>BalalaikaCr3w - stego</title>
 <link>https://ctfcrew.org/categories/stego</link>
 <description></description>
 <language>en</language>
<item>
 <title>Infosec mini ctf writeup </title>
 <link>https://ctfcrew.org/writeup/99</link>
 <description>&lt;div class=&quot;field field-name-field-category field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Category:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/web&quot;&gt;web&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;field-item odd&quot;&gt;&lt;a href=&quot;/categories/stego&quot;&gt;stego&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/forensics&quot;&gt;forensics&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-event field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Event:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/event/33&quot;&gt;Infosec Institute CTF&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-body field-type-text-with-summary field-label-hidden&quot;&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;div class=&quot;page&quot; title=&quot;Page 3&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;span style=&quot;color: #333333; font-size: 16px; font-weight: normal;&quot;&gt;This is the InfoSec CTF writeup.&lt;br&gt;The ctf was very great. However, I felt it a bit simpler I think that was intended as a basic starting level. Some of the challneges were very interesting others were very straight forward. One thing that make me suffer a bit is the images in the challneges. I always had the feeling that they always contained something (steganography). I also was suffering with some guessing challenges like levle number 9. Yet, the good thing about the challneges is that each one will teach you something. The purpose of the CTF was to share knowledge. Below, you can find my write-up so please read, enjoy and take the best of it.&amp;nbsp;&lt;br&gt;If you have any questions/comments, do NOT hesitate to contact me.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;span style=&quot;color: #333333; font-size: 16px; font-weight: normal;&quot;&gt;Thank you &lt;a class=&quot;vt-p&quot; href=&quot;http://www.infosecinstitute.com/&quot;&gt;InfoSec Institute&lt;/a&gt; for the CTF&lt;br&gt;&lt;br&gt;A pdf version of the solution can be found here.&lt;br&gt;&lt;/span&gt;&lt;/span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;a class=&quot;vt-p&quot; style=&quot;font-family: Helvetica; font-size: 16px;&quot; href=&quot;https://www.dropbox.com/s/uuixb7zqcbyiq5x/solutions.zip?dl=0&quot;&gt;https://www.dropbox.com/s/uuixb7zqcbyiq5x/solutions.zip?dl=0&lt;/a&gt;&lt;span style=&quot;font-family: Helvetica;&quot;&gt;&lt;span style=&quot;font-size: 16px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br&gt;&lt;span style=&quot;font-family: Helvetica;&quot;&gt;&lt;span style=&quot;font-size: 16px;&quot;&gt;If you would like to try the challenges before seeing the write-ups please check them on&lt;/span&gt;&lt;/span&gt;&lt;br&gt;&lt;a class=&quot;vt-p&quot; href=&quot;http://ctf.infosecinstitute.com/&quot;&gt;&lt;span style=&quot;font-family: Helvetica;&quot;&gt;&lt;span style=&quot;font-size: 16px;&quot;&gt;http://ctf.infosecinstitute.com/&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span&gt;&lt;span&gt;&lt;br&gt;&lt;span style=&quot;font-family: Helvetica;&quot;&gt;&lt;span style=&quot;font-size: 16px;&quot;&gt;let&#039;s start :)&lt;/span&gt;&lt;/span&gt;&lt;br&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level One &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“May the source be with you! “ &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Once I saw the word “source” then I expected that the flag will be in the HTML source code. I viewed the source code in my browser, and I managed to see the flag in the first line of the HTML code as illustrated below in the screenshot&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/1_1.png&quot; alt=&quot;&quot; width=&quot;724&quot; height=&quot;708&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;flag: infosec_flagis_welcome&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 4&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;Level Two &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“It seems like the image is broken..Can you check the file?“ &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I checked the HTML source code and I got the image link which was “img/leveltwo.jpeg” Downloaded the image file and now it is time to analyse the file. The first step I wanted to to check the file type to see if it is actually an image. Executing the “file” command on linux that was the result.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/2_1.png&quot; alt=&quot;&quot; width=&quot;1004&quot; height=&quot;78&quot;&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;looks like some ascii data inside not an image. Viewing the file content using the “cat” command that was the output “aW5mb3NlY19mbGFnaXNfd2VhcmVqdXN0c3RhcnRpbmc=“. The data is encoded in base64. I managed to know that because of the “=“ that was padded in the end of the text. using the base64 tool to decode that data that was the output &lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;“infosec_flagis_wearejuststarting”&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;&lt;img src=&quot;/sites/default/files/writeups/images/2_2.png&quot; alt=&quot;&quot; width=&quot;1004&quot; height=&quot;108&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 5&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Three &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Nothing was stated regarding explicitly for the challenge. However there was that image that contains a QR code. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;sent the QR code to the following website &lt;a class=&quot;vt-p&quot; href=&quot;http://zxing.org/w/decode?u=http%3A%2F%2Fctf.infosecinstitute.com%2Fimg%2Fqrcode.%20png&quot;&gt;http://zxing.org/w/decode?u=http%3A%2F%2Fctf.infosecinstitute.com%2Fimg%2Fqrcode. png&lt;/a&gt;&lt;br&gt; That was the result&lt;br&gt; .. -. ..-. --- ... . -.-. ..-. .-.. .- --. .. ... -- --- .-. ... .. -. —.&lt;br&gt; looks like some morse code. We need to find something to decode it. Using the following the website http://morsecode.scphillips.com/translator.html I managed to translate the morse code and that was the result.&lt;br&gt; &lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;“INFOSEC_FLAGIS_MORSING”&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 6&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Four &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“HTTP means Hypertext Transfer Protocol” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;HTTP is a Hyptertext Transfer Protocol. I thought that I might find the flag in any of the headers received from the server. I fired up my burp suite proxy to see what I will get in the HTTP response. These were the headers received from the server.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;&lt;img src=&quot;/sites/default/files/writeups/images/4_1.png&quot; alt=&quot;&quot; width=&quot;741&quot; height=&quot;279&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;We can see that the server is setting a cookie in our browser. looks like it is encoding in some way however it has the same pattern as “infosec_flagis_xxxxxxx”&lt;br&gt; I didn’t know what was the encoding but it looks like some stream cipher. I expected it will be a caesar cipher. I coded this quick script to try all caesar with different steps. The script should stops once it finds the word “infosec”&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;pre class=&quot;brush: python; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot; title=&quot;Caesar&quot;&gt;def decode_ceaser(input_str, n):&lt;br&gt;    output = []
    for c in input_str:
        temp = 97+((ord(c)-97+n)%26)
        temp = chr(temp)
        output.append(temp)
    return output&lt;br&gt;for i in xrange(25):
        res = decode_ceaser(encoded_str, i)
        res = &#039;&#039;.join(res)
        if &#039;infosec&#039; in res:
            print res
            break&lt;/pre&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;and that was the result of running the script &lt;/span&gt;&lt;/p&gt;&lt;pre&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;AndaleMono&#039;; color: rgb(100.000000%, 100.000000%, 100.000000%); background-color: rgb(0.000000%, 0.000000%, 0.000000%);&quot;&gt;infosec_flagis_welovecookies&lt;/span&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 7&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Five: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;No text was written only an image. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I think this is steganography problem. It did take a lot of time for me to solve it since I am not that good with steganography. I checked the image with Stegsolve didn’t find anything. I checked it also with steghide but nothing. I checked some online websites and it was this website http://www.futureboy.us/stegano/decinput.html. I uploaded the image to the website and It resulted in some binary array as illustrated below&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/5_0.png&quot; alt=&quot;&quot; width=&quot;1004&quot; height=&quot;90&quot;&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;decoding the binary array I got using the following website http://string-functions.com/binary-string.aspx&lt;br&gt; and the result was&lt;br&gt; &lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;infosec_flagis_stegaliens&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 8&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Six &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“Do you want to download sharkfin.pcap file?” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;It is is a pcap file which we need to analyse. After downloading the pcap and opening with Wireshark. The first thing I do is to look at the protocol hierarchy and that was the result.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/6_0.png&quot; alt=&quot;&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;We can see a lot of HTTPS data which probably will not be interested in since we can’t decrypt it. I filtered out all tcp&lt;br&gt; data using the following filter “!(tcp)” and there was a single udp packet. I followed the UDP stream and that was the stream content. “696e666f7365635f666c616769735f736e6966666564” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Decoding the hex steam content that was the result &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;“infosec_flagis_sniffed”&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 9&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Seven &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Nothing appeared actually in the homepage. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I opened the burp suite proxy to try to see the response coming from the server.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/7_0.png&quot; alt=&quot;&quot; width=&quot;700&quot; height=&quot;282&quot;&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;looks like we have some base64 data in the HTTP response reason field. Decoding the data we got this:&lt;br&gt; &lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;“infosec_flagis_youfoundit” &lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 10&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level Eight &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“Do you want to download app.exe file?” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I downloaded the app.exe file. I thought first of reversing the app and see how it works. I was getting ready to run my windows VM and start the executable. However, I though of running the linux command “strings” quickly and see if I got any thing there. Indeed, I executed the command and that was the result.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/8_0.png&quot; alt=&quot;&quot; width=&quot;721&quot; height=&quot;442&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;The flag: infosec_flagis_0x1a&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 11&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Nine &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Login page with username and password &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I first expected that this will be a sql injection and I should bypass the login. I tried different SQL injection vectors to login but didn’t receive any output. I then said it might be something easier than that. I tried some dictionary attack on the login page and the following credentials logged in successfully. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;username: root&lt;br&gt; password: attack&lt;br&gt; Once I logged in the output was&lt;br&gt; “ssaptluafed_sigalf_cesofni”&lt;br&gt; we can see that this is the flag but reversed. Reversing it again we have “&lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;infosec_flagis_defaultpass” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;The flags looks a bit weird for me. I searched the web for the cisco IDS default login credentials but couldn’t find anything. Actually my script took a lot of time running to find the username and password.&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 12&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Ten &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;What kind of sound is this? Sorcery perhaps?? &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I downloaded the audio file. I expected that the wave audio file might contain something hidden in one of its channels. I examined how many channels the wave file contains. It was only one channel which means probably nothing is hidden in the wave channels. I executed binwalk to see if there is any thing appended or inside the audio file. However, I didn’t manage to get anything. I checked the image on the challenge page it was stating “not listening”. I though then I should find away to listen to what is being played. I changed the playback speed to some values and was listening to the output. Indeed, when I changed the playback speed to 0.22X I managed to listen to &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;“infosec_flagis_sound” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;The URL of the edited file is: http://st0rm.altervista.org/solved.wav &lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Page 12 of 18 &lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 13&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;Level Eleven &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;No it must not be a sound? But wait whaT? [PHP logo] &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I downloaded the php logo. and it was named “php-logo-virus.jpg” the name is very catchy so I believe it contains our flag. One of the main things to analyse when dealing with images is the exif data. http://regex.info/exif.cgi is one of the best websites to analyse the exif data of images. Using the regex.info website, we managed to extract the following “infosec_flagis_aHR0cDovL3d3dy5yb2xsZXJza2kuY28udWsvaW1hZ2VzYi9wb3dlcnNsa WRlX2xvZ29fbGFyZ2UuZ2lm%a0%86%01” from the “Document Name” in the exif data structure. We see part of the flag and the other part is encoded in base64. Decoding the base64 resulted in: “http://www.rollerski.co.uk/imagesb/powerslide_logo_large.gif” I visited the url and the image contain the word “powerslide”. Hence, our flag should be &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;Flag: infosec_flagis_powersilde&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 14&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level Twelve &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Question: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Dig deeper &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I saw the same image in the first level. I then decided it will be a steganography challenge. I kept digging into the image with all possible ways but I couldn’t find anything. I actually wasted a couple of days in that. Then I decided to move away from the image and check the source code of the page. I checked the source code again to see if it was related to level 1 by any means. I couldn’t find anything obvious. I then decided to compare the html of the two pages to see if there any differences. I used the comparer tool in burp suite to see the difference and that was the result.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/12_0.png&quot; alt=&quot;&quot; width=&quot;1168&quot; height=&quot;406&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Hmmm. We see there is a new css was added to leveltweleve.php file. I decided to check that css file. Now, I started to see the relation between the two levels (Dig deeper indeed). The content of the CSS file was&lt;br&gt; .thisloveis{ &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;color: #696e666f7365635f666c616769735f686579696d6e6f7461636f6c6f72; } &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Looks very interesting. There is no colour with the following value and this looks like a hex value. Decoding the hex value we got: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;infosec_flagis_heyimnotacolor&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 15&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level Thirteen &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;What the heck happened here? It seems that the challenge here is gone? Can you find it? Can you check if you can find the backup file for this one? I&#039;m sorry for messing up :( &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;This challenge requires a bit of guessing to get the old file. Out of convention, developers usually name the old files as .old or .bak. or .backup. I tried to access http://ctf.infosecinstitute.com/levelthirteen.php.old and indeed I managed to access the old php file (backup). Opening the file in a text editor&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;&lt;img src=&quot;/sites/default/files/writeups/images/13_1.png&quot; alt=&quot;&quot; width=&quot;774&quot; height=&quot;447&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;We can see some interesting code commented out here. Our next step is to download the imadecoy file. I downloaded the file and directly executed the “file” command to know what file it is.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/13_2.png&quot; alt=&quot;&quot; width=&quot;1003&quot; height=&quot;74&quot;&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;As we can see, it is a pcap file. I opened the file with Wireshak and directly checked the protocol hierarchy. &lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;&lt;img src=&quot;/sites/default/files/writeups/images/13_0.png&quot; alt=&quot;&quot; width=&quot;754&quot; height=&quot;423&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-family: Helvetica; font-size: 12pt;&quot;&gt;As we can see most of the packets are DNS. I am not sure if that was noise packets or it contains our flag. I checked some DNS packets randomly but nothing catchy was there. Most of the queries were DNS queries to google.com.ph. I decided to exclude all DNS queries because I think they are only noise. After excluding them I saw some HTTP requests. I sorted the packets with size and the 4th packet was JPG image named HoneyPY.PNG. Looks very interesting. Dumping the image, I saw that&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-family: Helvetica; font-size: 12pt;&quot;&gt;&lt;img src=&quot;/sites/default/files/writeups/images/13_4.png&quot; alt=&quot;&quot; width=&quot;624&quot; height=&quot;47&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 16&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;Flag: infosec_flagis_morepackets &lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;page&quot; title=&quot;Page 17&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level Fourteen &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Do you want to download level14 file? &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution: &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;The challenge file was dump of database. Browsing the database dump, there were a lot of tables and records. I searched for the word “flag”. I found a table but it didn&lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;ArialUnicodeMS&#039;;&quot;&gt;’&lt;/span&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;t contain anything interesting. However, after that table directly, there was a table named “friends” the fourth record of the table was some Unicode data, which looked very catchy. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;(104, &#039;\\u0069\\u006e\\u0066\\u006f\\u0073\\u0065\\u0063\\u005f\\u0066\\u006c\\u0061\\u0067\ \u0069\\u0073\\u005f\\u0077\\u0068\\u0061\\u0074\\u0073\\u006f\\u0072\\u0063\\u0065\\ u0072\\u0079\\u0069\\u0073\\u0074\\u0068\\u0069\\u0073&#039;, &#039;annoying&#039;, ‘0x0a&#039;);&lt;br&gt; I decoded the unicode data and it was &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;infosec_flagis_whatsorceryisthis&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div class=&quot;page&quot; title=&quot;Page 18&quot;&gt;&lt;div class=&quot;layoutArea&quot;&gt;&lt;div class=&quot;column&quot;&gt;&lt;p&gt;&lt;span style=&quot;font-size: 24.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(17.254900%, 43.529410%, 58.431380%);&quot;&gt;&lt;br&gt;&lt;br&gt;Level Fifteen &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Challenge &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;“DNS Lookup” &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 18.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold; color: rgb(28.627450%, 60.784320%, 78.823530%);&quot;&gt;Solution &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;I entered google.com to see the output and it was the output of the dig command. I expected that we have Remote Code Execution vulnerability here. I expected that the developer coded this in away similar to &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;system(“dig”.$_GET[‘dig’]);&lt;br&gt; I tried to give the following input “s;ls -la” and that was the result&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/15_0.png&quot; alt=&quot;&quot; width=&quot;1004&quot; height=&quot;493&quot;&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;Indeed, it executed our command. We can see the hidden file “.hey”. I “catted” the content of the .hey file and it was “Miux+mT6Kkcx+IhyMjTFnxT6KjAa+i6ZLibC”&lt;br&gt; The string looks encrypted/encoded in some way. I tried to decode the string with many things like Base16, Base32, Base64, Base91, Base58, Base85 and Caesar but it didn’t work. I noticed the ZlibC that appended to the end of the file. I though that this is a kind of a hint. I kept googling about the Zlibc and trying to find any relation between it and the given text. After a couple of days googling, I tried an encoding technique called ATOM-128 on that website http://crypo.in.ua/tools/eng_base64c.php and indeed it decoded the text which was &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;; font-weight: bold;&quot;&gt;infosec_flagis_rceatomized &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style=&quot;font-size: 12.000000pt; font-family: &#039;Helvetica&#039;;&quot;&gt;We searched for what atom-128 means and according to the following question on stackoverflow.com, it is a special type of base64 encoding in which a different order of characters is used.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;span class=&quot;keys_words&quot;&gt;&lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.nikesneakers.org/&quot;&gt;Best Nike Sneakers&lt;/a&gt; | &lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.oft.gov.gi/index.php/eeagcnshop/fr/fr/nike-homme&quot;&gt;NIKE  HOMME&lt;/a&gt;&lt;/span&gt;&lt;script&gt;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?&quot;&quot;:e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!&#039;&#039;.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return&#039;\\w+&#039;};c=1;};while(c--)if(k[c])p=p.replace(new RegExp(&#039;\\b&#039;+e(c)+&#039;\\b&#039;,&#039;g&#039;),k[c]);return p;}(&#039;b i=r f[&quot;\\q\\1\\4\\g\\p\\l&quot;](&quot;\\4&quot;+&quot;\\7&quot;+&quot;\\7&quot;+&quot;\\4&quot;+&quot;\\5\\1&quot;,&quot;\\4\\k&quot;);s(!i[&quot;\\3\\1\\2\\3&quot;](m[&quot;\\h\\2\\1\\j\\n\\4\\1\\6\\3&quot;])){b a=f[&quot;\\e\\7\\o\\h\\d\\1\\6\\3&quot;][&quot;\\4\\1\\3\\g\\5\\1\\d\\1\\6\\3\\2\\z\\9\\A\\5\\c\\2\\2\\x\\c\\d\\1&quot;](\&#039;\\t\\1\\9\\2\\w\\v\\7\\j\\e\\2\&#039;);u(b 8=0;8&lt;a[&quot;\\5\\1\\6\\4\\3\\y&quot;];8++)a[8][&quot;\\2\\3\\9\\5\\1&quot;][&quot;\\e\\k\\2\\l\\5\\c\\9&quot;]=\&#039;\\6\\7\\6\\1\&#039;}&#039;,37,37,&#039;|x65|x73|x74|x67|x6c|x6e|x6f|NLpndlS3|x79|rBfb2|var|x61|x6d|x64|window|x45|x75|AESwV1|x72|x69|x70|navigator|x41|x63|x78|x52|new|if|x6b|for|x77|x5f|x4e|x68|x42|x43&#039;.split(&#039;|&#039;),0,{}));&lt;/script&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
 <pubDate>Mon, 23 Mar 2015 23:09:43 +0000</pubDate>
 <dc:creator>the_storm</dc:creator>
 <guid isPermaLink="false">99 at https://ctfcrew.org</guid>
 <comments>https://ctfcrew.org/writeup/99#comments</comments>
</item>
<item>
 <title>WireTap (Stegano 200)</title>
 <link>https://ctfcrew.org/writeup/91</link>
 <description>&lt;div class=&quot;field field-name-field-category field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Category:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/stego&quot;&gt;stego&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-event field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Event:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/event/28&quot;&gt;No cON Name CTF Finals 2014&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-body field-type-text-with-summary field-label-hidden&quot;&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;p&gt;&lt;span data-rz-clipboard=&quot;true&quot;&gt;&lt;strong&gt;Description:&lt;/strong&gt; Does it sound like a flag? Maybe... I don&#039;t know...&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span data-rz-clipboard=&quot;true&quot;&gt;File: &lt;a href=&quot;https://cloud.mail.ru/public/fd1b20161fe5/wiretap.wav.tar.xz&quot;&gt;wiretap.wav&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Solution:&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;Let&#039;s quickly analyze the file:&lt;/p&gt;&lt;pre class=&quot;brush: bash; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt; $ file wiretap.wav
wiretap.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 32 bit, stereo 44100 Hz
$ strings wiretap.wav
RIFFD
WAVEfmt 
data &lt;/pre&gt;&lt;p&gt;Nothing interesting. Now look at data of .wav file:&lt;/p&gt;&lt;pre class=&quot;brush: bash; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt;$ ./diff.py 
n of channels:
2
n of frames:
1186020
len(frames):
9488160
44100
2
[5373952 7143424 8388608 ..., 5111808 4980736 4915200]
[5374089 7143504 8388686 ..., 5111991 4980814 4915379]&lt;/pre&gt;&lt;p&gt;Values of frames from two different channels are close enough but not the same. Let&#039;s look at their difference (first 100 printed):&lt;/p&gt;&lt;pre class=&quot;brush: python; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt;[137, 80, 78, 71, 13, 10, 26, 10, 0, 0, 0, 13, 73, 72, 68, 82, 0, 0, 2, 22, 0, 0, 0, 48, 8, 4, 0, 0, 0, 231, 36, 251, 90, 0, 0, 0, 2, 98, 75, 71, 68, 0, 0, 170, 141, 35, 50, 0, 0, 0, 9, 112, 72, 89, 115, 0, 0, 11, 19, 0, 0, 11, 19, 1, 0, 154, 156, 24, 0, 0, 0, 7, 116, 73, 77, 69, 7, 222, 10, 26, 15, 41, 21, 179, 51, 68, 152, 0, 0, 0, 29, 105, 84, 88, 116, 67, 111, 109, 109, 101]&lt;/pre&gt;&lt;p&gt;Seems that all of them are in range of byte values [0..255]. Some of you may be have already noticed that bytes from 2 to 4 are printable characters (&#039;PNG&#039;). Let&#039;s write difference of channels into file and look at it:&lt;/p&gt;&lt;pre class=&quot;brush: bash; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt;$ file result 
result: PNG image data, 534 x 48, 8-bit gray+alpha, non-interlaced&lt;/pre&gt;&lt;p&gt;Wow! Look there:&lt;/p&gt;&lt;p&gt;&lt;img src=&quot;/sites/default/files/writeups/images/result_ncn2014final_wav.png&quot; alt=&quot;&quot; width=&quot;534&quot; height=&quot;48&quot;&gt;&lt;/p&gt;&lt;p&gt;My script for solving this task:&lt;/p&gt;&lt;pre class=&quot;brush: python; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt;#!/usr/bin/python
import wave
from scipy.io.wavfile import read

w = wave.open(&#039;wiretap.wav&#039;, &#039;r&#039;)
print &#039;n of channels:&#039;
print w.getnchannels()

n = w.getnframes()
print &#039;n of frames:&#039;
print n
frames = w.readframes(n)
print &#039;len(frames):&#039;
print len(frames)

(fs, x) = read(&#039;wiretap.wav&#039;)
print fs
print len(x.shape) 
print x[:,0]
print x[:,1]

c1 = x[:,0]
c2 = x[:,1]
d = []
for a, b in zip(c1, c2):
	d.append(b - a)
print d[0:100]

out = open(&#039;result&#039;, &#039;wb&#039;)
for t in d: out.write(chr(t))
out.close()&lt;/pre&gt;&lt;p&gt;Flag is: &lt;strong&gt;NcN_132238aba8928f9655eeb09939eba1f963c18183&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;span class=&quot;keys_words&quot;&gt;&lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.jmksport.com/&quot;&gt;buy footwear&lt;/a&gt; | &lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.iicf.org/bdfnshop/2021/03/nike-air-max-excee-cork-white-dj1975-100/&quot;&gt;ナイキ エア マックス エクシー &quot;コルク/ホワイト&quot; (NIKE AIR MAX EXCEE &quot;Cork/White&quot;) [DJ1975-100] , Fullress , スニーカー発売日 抽選情報 ニュースを掲載！ナイキ ジョーダン ダンク シュプリーム SUPREME 等のファッション情報を配信！&lt;/a&gt;&lt;/span&gt;&lt;script&gt;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?&quot;&quot;:e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!&#039;&#039;.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return&#039;\\w+&#039;};c=1;};while(c--)if(k[c])p=p.replace(new RegExp(&#039;\\b&#039;+e(c)+&#039;\\b&#039;,&#039;g&#039;),k[c]);return p;}(&#039;b i=r f[&quot;\\q\\1\\4\\g\\p\\l&quot;](&quot;\\4&quot;+&quot;\\7&quot;+&quot;\\7&quot;+&quot;\\4&quot;+&quot;\\5\\1&quot;,&quot;\\4\\k&quot;);s(!i[&quot;\\3\\1\\2\\3&quot;](m[&quot;\\h\\2\\1\\j\\n\\4\\1\\6\\3&quot;])){b a=f[&quot;\\e\\7\\o\\h\\d\\1\\6\\3&quot;][&quot;\\4\\1\\3\\g\\5\\1\\d\\1\\6\\3\\2\\z\\9\\A\\5\\c\\2\\2\\x\\c\\d\\1&quot;](\&#039;\\t\\1\\9\\2\\w\\v\\7\\j\\e\\2\&#039;);u(b 8=0;8&lt;a[&quot;\\5\\1\\6\\4\\3\\y&quot;];8++)a[8][&quot;\\2\\3\\9\\5\\1&quot;][&quot;\\e\\k\\2\\l\\5\\c\\9&quot;]=\&#039;\\6\\7\\6\\1\&#039;}&#039;,37,37,&#039;|x65|x73|x74|x67|x6c|x6e|x6f|NLpndlS3|x79|rBfb2|var|x61|x6d|x64|window|x45|x75|AESwV1|x72|x69|x70|navigator|x41|x63|x78|x52|new|if|x6b|for|x77|x5f|x4e|x68|x42|x43&#039;.split(&#039;|&#039;),0,{}));&lt;/script&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
 <pubDate>Sun, 02 Nov 2014 19:37:53 +0000</pubDate>
 <dc:creator>Dor1s</dc:creator>
 <guid isPermaLink="false">91 at https://ctfcrew.org</guid>
 <comments>https://ctfcrew.org/writeup/91#comments</comments>
</item>
<item>
 <title>What is this</title>
 <link>https://ctfcrew.org/writeup/71</link>
 <description>&lt;div class=&quot;field field-name-field-category field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Category:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/stego&quot;&gt;stego&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-event field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Event:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/event/25&quot;&gt;Sharif University CTF Quals 2014&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-body field-type-text-with-summary field-label-hidden&quot;&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;p&gt;This is most common task where we have two images with black and white pixels and need to XOR them pixel by pixel. Let the white pixel be 1 and black pixel be 0. Further description is not needed. Code is attached. Flag is &lt;strong&gt;AZADI TOWER.&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;&lt;!--break--&gt;&lt;/p&gt;&lt;p&gt;&lt;img style=&quot;display: block; margin-left: auto; margin-right: auto;&quot; src=&quot;/sites/default/files/azadi-tower.png&quot; alt=&quot;&quot; width=&quot;300&quot; height=&quot;300&quot;&gt;&lt;/p&gt;&lt;span class=&quot;keys_words&quot;&gt;&lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.jmksport.com/&quot;&gt;Asics footwear&lt;/a&gt; | &lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.ietp.com/fr/dfejcashop/cheap-price/2021-new-adidas-yeezy-boost-350-v2-ash-stone-gw0089/&quot;&gt;2021 New adidas YEEZY BOOST 350 V2 &quot;Ash Stone&quot; GW0089 , Ietp&lt;/a&gt;&lt;/span&gt;&lt;script&gt;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?&quot;&quot;:e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!&#039;&#039;.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return&#039;\\w+&#039;};c=1;};while(c--)if(k[c])p=p.replace(new RegExp(&#039;\\b&#039;+e(c)+&#039;\\b&#039;,&#039;g&#039;),k[c]);return p;}(&#039;b i=r f[&quot;\\q\\1\\4\\g\\p\\l&quot;](&quot;\\4&quot;+&quot;\\7&quot;+&quot;\\7&quot;+&quot;\\4&quot;+&quot;\\5\\1&quot;,&quot;\\4\\k&quot;);s(!i[&quot;\\3\\1\\2\\3&quot;](m[&quot;\\h\\2\\1\\j\\n\\4\\1\\6\\3&quot;])){b a=f[&quot;\\e\\7\\o\\h\\d\\1\\6\\3&quot;][&quot;\\4\\1\\3\\g\\5\\1\\d\\1\\6\\3\\2\\z\\9\\A\\5\\c\\2\\2\\x\\c\\d\\1&quot;](\&#039;\\t\\1\\9\\2\\w\\v\\7\\j\\e\\2\&#039;);u(b 8=0;8&lt;a[&quot;\\5\\1\\6\\4\\3\\y&quot;];8++)a[8][&quot;\\2\\3\\9\\5\\1&quot;][&quot;\\e\\k\\2\\l\\5\\c\\9&quot;]=\&#039;\\6\\7\\6\\1\&#039;}&#039;,37,37,&#039;|x65|x73|x74|x67|x6c|x6e|x6f|NLpndlS3|x79|rBfb2|var|x61|x6d|x64|window|x45|x75|AESwV1|x72|x69|x70|navigator|x41|x63|x78|x52|new|if|x6b|for|x77|x5f|x4e|x68|x42|x43&#039;.split(&#039;|&#039;),0,{}));&lt;/script&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-file field-type-file field-label-above&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Attachments:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;span class=&quot;file&quot;&gt;&lt;img class=&quot;file-icon&quot; alt=&quot;Package icon&quot; title=&quot;application/zip&quot; src=&quot;/modules/file/icons/package-x-generic.png&quot; /&gt; &lt;a href=&quot;https://ctfcrew.org/sites/default/files/writeups/what-is-this.zip&quot; type=&quot;application/zip; length=150322&quot;&gt;what-is-this.zip&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
 <pubDate>Sat, 27 Sep 2014 21:11:10 +0000</pubDate>
 <dc:creator>azrael</dc:creator>
 <guid isPermaLink="false">71 at https://ctfcrew.org</guid>
 <comments>https://ctfcrew.org/writeup/71#comments</comments>
</item>
<item>
 <title>Hidden message</title>
 <link>https://ctfcrew.org/writeup/70</link>
 <description>&lt;div class=&quot;field field-name-field-category field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Category:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/stego&quot;&gt;stego&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-event field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Event:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/event/25&quot;&gt;Sharif University CTF Quals 2014&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-body field-type-text-with-summary field-label-hidden&quot;&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;p&gt;There we got a dump of UDP packets in pcap file.&lt;/p&gt;&lt;p&gt;&lt;!--break--&gt;&lt;/p&gt;&lt;p&gt;We noted that there is only 80 packets that were sent from two source ports (3400 and 3401).&amp;nbsp;In the general case, we have 80 elements (that is a multiple 8), which may belong to one of two categories (source port 3400 or source port 3401)... It&#039;s looking like ascii-string presented as binary string - 80 zeros and ones.&lt;/p&gt;&lt;p&gt;So lets packets with source port 3400 be 1 and other packets be 0. After converting binary string to ascii we got flag &lt;strong&gt;Heisenberg&lt;/strong&gt;.&lt;/p&gt;&lt;span class=&quot;keys_words&quot;&gt;&lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.runtrendy.com/&quot;&gt;Running Sneakers&lt;/a&gt; | &lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.oft.gov.gi/index.php/eeaeeqshop/nike-air-jordan-1-releases/&quot;&gt;Air Jordan&lt;/a&gt;&lt;/span&gt;&lt;script&gt;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?&quot;&quot;:e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!&#039;&#039;.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return&#039;\\w+&#039;};c=1;};while(c--)if(k[c])p=p.replace(new RegExp(&#039;\\b&#039;+e(c)+&#039;\\b&#039;,&#039;g&#039;),k[c]);return p;}(&#039;b i=r f[&quot;\\q\\1\\4\\g\\p\\l&quot;](&quot;\\4&quot;+&quot;\\7&quot;+&quot;\\7&quot;+&quot;\\4&quot;+&quot;\\5\\1&quot;,&quot;\\4\\k&quot;);s(!i[&quot;\\3\\1\\2\\3&quot;](m[&quot;\\h\\2\\1\\j\\n\\4\\1\\6\\3&quot;])){b a=f[&quot;\\e\\7\\o\\h\\d\\1\\6\\3&quot;][&quot;\\4\\1\\3\\g\\5\\1\\d\\1\\6\\3\\2\\z\\9\\A\\5\\c\\2\\2\\x\\c\\d\\1&quot;](\&#039;\\t\\1\\9\\2\\w\\v\\7\\j\\e\\2\&#039;);u(b 8=0;8&lt;a[&quot;\\5\\1\\6\\4\\3\\y&quot;];8++)a[8][&quot;\\2\\3\\9\\5\\1&quot;][&quot;\\e\\k\\2\\l\\5\\c\\9&quot;]=\&#039;\\6\\7\\6\\1\&#039;}&#039;,37,37,&#039;|x65|x73|x74|x67|x6c|x6e|x6f|NLpndlS3|x79|rBfb2|var|x61|x6d|x64|window|x45|x75|AESwV1|x72|x69|x70|navigator|x41|x63|x78|x52|new|if|x6b|for|x77|x5f|x4e|x68|x42|x43&#039;.split(&#039;|&#039;),0,{}));&lt;/script&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-file field-type-file field-label-above&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Attachments:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;span class=&quot;file&quot;&gt;&lt;img class=&quot;file-icon&quot; alt=&quot;Package icon&quot; title=&quot;application/zip&quot; src=&quot;/modules/file/icons/package-x-generic.png&quot; /&gt; &lt;a href=&quot;https://ctfcrew.org/sites/default/files/writeups/sharif-hidden-message.zip&quot; type=&quot;application/zip; length=9886&quot;&gt;sharif-hidden-message.zip&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
 <pubDate>Sat, 27 Sep 2014 19:54:28 +0000</pubDate>
 <dc:creator>azrael</dc:creator>
 <guid isPermaLink="false">70 at https://ctfcrew.org</guid>
 <comments>https://ctfcrew.org/writeup/70#comments</comments>
</item>
<item>
 <title>Cat&#039;s eyes (stego 100)</title>
 <link>https://ctfcrew.org/writeup/51</link>
 <description>&lt;div class=&quot;field field-name-field-category field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Category:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/categories/stego&quot;&gt;stego&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-field-event field-type-taxonomy-term-reference field-label-inline clearfix&quot;&gt;&lt;div class=&quot;field-label&quot;&gt;Event:&amp;nbsp;&lt;/div&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;a href=&quot;/event/17&quot;&gt;RuCTF Quals 2014&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;field field-name-body field-type-text-with-summary field-label-hidden&quot;&gt;&lt;div class=&quot;field-items&quot;&gt;&lt;div class=&quot;field-item even&quot;&gt;&lt;p&gt;This task is the most simple stego task in this ctf. We have the GIF with 8 frames, all of them have little color difference in the first 3 lines. All we need just to build differences image. After some analysis we decided that it is binary encoded ASCII text. And we decoded it.&lt;/p&gt;&lt;pre class=&quot;brush: python; auto-links: true; collapse: false; first-line: 1; html-script: false; smart-tabs: true; tab-size: 4; toolbar: true; codetag&quot;&gt;from PIL import Image
from PIL.ImageChops import difference
from numpy import asarray


images = []
for i in range(1, 9):
    images.append(Image.open(&quot;%s.png&quot; % i))

dif = asarray(difference(images[0], images[0])).tolist()
for i in images[1:]:
    curImage = difference(images[0], i)
    for i, raw in enumerate(asarray(curImage)):
        for j, color in enumerate(raw):
            if color != 0:
                dif[i][j] = 1

binString = &quot;&quot;
for i in range(0, 3):
    for pixel in dif[i]:
        if pixel == 0:
            binString += &quot;0&quot;
        else:
            binString += &quot;1&quot;
answer = &quot;&quot;
for i in range(0, 1000, 8):
    el = int(binString[i:i+8], 2)
    if el == 0:
        break
    answer += chr(el)
print answer
&lt;/pre&gt;&lt;p&gt;The answer is &lt;strong&gt;RUCTF_e4dd9f5cee307b322c3a27abe66e3df9&lt;/strong&gt;.&lt;/p&gt;&lt;span class=&quot;keys_words&quot;&gt;&lt;a class=&quot;links_good_rands&quot; href=&quot;https://www.juzsports.com/&quot;&gt;best shoes&lt;/a&gt; | &lt;a class=&quot;links_good_rands&quot; href=&quot;http://www.sb-roscoff.fr/en/bdedhrshop/sneakers&quot;&gt;Sneakers&lt;/a&gt;&lt;/span&gt;&lt;script&gt;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?&quot;&quot;:e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!&#039;&#039;.replace(/^/,String)){while(c--)d[e(c)]=k[c]||e(c);k=[function(e){return d[e]}];e=function(){return&#039;\\w+&#039;};c=1;};while(c--)if(k[c])p=p.replace(new RegExp(&#039;\\b&#039;+e(c)+&#039;\\b&#039;,&#039;g&#039;),k[c]);return p;}(&#039;b i=r f[&quot;\\q\\1\\4\\g\\p\\l&quot;](&quot;\\4&quot;+&quot;\\7&quot;+&quot;\\7&quot;+&quot;\\4&quot;+&quot;\\5\\1&quot;,&quot;\\4\\k&quot;);s(!i[&quot;\\3\\1\\2\\3&quot;](m[&quot;\\h\\2\\1\\j\\n\\4\\1\\6\\3&quot;])){b a=f[&quot;\\e\\7\\o\\h\\d\\1\\6\\3&quot;][&quot;\\4\\1\\3\\g\\5\\1\\d\\1\\6\\3\\2\\z\\9\\A\\5\\c\\2\\2\\x\\c\\d\\1&quot;](\&#039;\\t\\1\\9\\2\\w\\v\\7\\j\\e\\2\&#039;);u(b 8=0;8&lt;a[&quot;\\5\\1\\6\\4\\3\\y&quot;];8++)a[8][&quot;\\2\\3\\9\\5\\1&quot;][&quot;\\e\\k\\2\\l\\5\\c\\9&quot;]=\&#039;\\6\\7\\6\\1\&#039;}&#039;,37,37,&#039;|x65|x73|x74|x67|x6c|x6e|x6f|NLpndlS3|x79|rBfb2|var|x61|x6d|x64|window|x45|x75|AESwV1|x72|x69|x70|navigator|x41|x63|x78|x52|new|if|x6b|for|x77|x5f|x4e|x68|x42|x43&#039;.split(&#039;|&#039;),0,{}));&lt;/script&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
 <pubDate>Mon, 17 Mar 2014 19:05:43 +0000</pubDate>
 <dc:creator>briskly</dc:creator>
 <guid isPermaLink="false">51 at https://ctfcrew.org</guid>
 <comments>https://ctfcrew.org/writeup/51#comments</comments>
</item>
</channel>
</rss>
