<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Sqli on Rio Blog</title><link>https://phucrio.me/tags/sqli/</link><description>Recent content in Sqli on Rio Blog</description><generator>Hugo -- 0.150.0</generator><language>en</language><lastBuildDate>Sun, 31 May 2026 17:38:09 -0400</lastBuildDate><atom:link href="https://phucrio.me/tags/sqli/index.xml" rel="self" type="application/rss+xml"/><item><title>HTB - CCTV Write-Up</title><link>https://phucrio.me/posts/htb-cctv-write-up/</link><pubDate>Sun, 31 May 2026 16:48:47 -0400</pubDate><guid>https://phucrio.me/posts/htb-cctv-write-up/</guid><description>&lt;h2 id="summary"&gt;Summary&lt;/h2&gt;
&lt;p&gt;CCTV is a Linux HackTheBox machine exposing SSH and a ZoneMinder web application on HTTP. The key foothold is an authenticated SQL injection in ZoneMinder 1.37.63, specifically the &lt;code&gt;removetag&lt;/code&gt; action affected by &lt;strong&gt;CVE-2024-51482&lt;/strong&gt;. After authenticating to the panel, the SQLi can be exploited with &lt;code&gt;sqlmap&lt;/code&gt; to dump &lt;code&gt;zm.Users&lt;/code&gt;, recover password hashes, and crack the &lt;code&gt;mark&lt;/code&gt; account password.&lt;/p&gt;
&lt;p&gt;Once on the box as &lt;code&gt;mark&lt;/code&gt;, privilege escalation comes from a second service: &lt;strong&gt;motionEye&lt;/strong&gt;. A world-readable &lt;code&gt;/etc/motioneye/motion.conf&lt;/code&gt; exposes the motionEye admin credential hash. That hash is sufficient to compute valid request signatures for the localhost-only motionEye API on &lt;code&gt;127.0.0.1:8765&lt;/code&gt;. By updating camera configuration and setting &lt;code&gt;command_storage_exec&lt;/code&gt;, it is possible to trigger root command execution through the snapshot action.&lt;/p&gt;</description></item></channel></rss>