Exploit database

GH-14fb583d3d1bd2da10251bb1a37b93d6

gitchw/ghostlock-cve-2026-43499

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2026-43499

168 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source

Repository files354
gitchw/ghostlock-cve-2026-43499Revision 96acd93156f6
Next files →

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

workspace/qemu/diag_mm2.py

Python · 2,275 bytes
#!/usr/bin/env python3
import sys, time, re, subprocess
sys.path.insert(0,'/mnt/d/project/ow/qemu')
from serial_drive import Console
def gdb(script, timeout=300):
    open('/tmp/g.gdb','w').write(script)
    p=subprocess.run(['gdb-multiarch','-batch','-q','/mnt/d/project/ow/qemu/vmlinux.clang',
                      '-x','/tmp/g.gdb'],capture_output=True,text=True,timeout=timeout)
    return p.stdout+p.stderr
c=Console(); time.sleep(1); c.send(''); c.read_some(2)
def run(cmd,t=120):
    rc,out=c.run(cmd,timeout=t); print('### '+cmd[:80]); print(out); return out
run('rm -f /tmp/in3; mkfifo /tmp/in3; (sleep 300 > /tmp/in3 &); (/tmp/forktest 32 1 < /tmp/in3 > /tmp/ft3.log 2>&1 &); echo BG')
time.sleep(4)
out=run('cat /tmp/ft3.log | head -2')
# children pids not printed (forktest prints slabinfo only). Find via gdb: tasks with comm forktest
o=gdb('set pagination off\ntarget remote :1234\n'
      'set $h=&init_task.tasks\n'
      'set $t=(struct task_struct*)$h\n'
      'while $t != (struct task_struct*)$h\n'
      '  if $t->mm && $t->mm != 0\n'
      '    printf "T %d %%08x %%s\\n", $t->pid, $t->mm, $t->comm\n'
      '  end\n'
      '  set $t=(struct task_struct*)$t->tasks.next\n'
      'end\ndetach\nquit\n', timeout=180)
forklines=[l for l in o.splitlines() if l.startswith('T ') and 'forktest' in l]
print('forktest tasks:',len(forklines))
for l in forklines[:5]: print(l)
# snapshot mm addrs
mms=re.findall(r'T (\d+) ([0-9a-f]{8}) forktest',o)
addrs=[a for _,a in mms]
# kill
run('echo > /tmp/in3'); time.sleep(6)
run('grep mm_struct /proc/slabinfo')
# examine freed mm objects
script='set pagination off\ntarget remote :1234\n'
for a in addrs[:8]:
    script+='x/8wx 0x%s\n'%a
script+='detach\nquit\n'
print(gdb(script))
# second: are forktest tasks still present?
o2=gdb('set pagination off\ntarget remote :1234\n'
      'set $h=&init_task.tasks\nset $n=0\n'
      'set $t=(struct task_struct*)$h\n'
      'while $t != (struct task_struct*)$h\n'
      '  if $t->comm[0]==0x66 && $t->comm[1]==0x6f\n'
      '    printf "ALIVE %%d state=%%ld mm=%%08x\\n",$t->pid,$t->__state,$t->mm\n'
      '    set $n=$n+1\n'
      '  end\n'
      '  set $t=(struct task_struct*)$t->tasks.next\n'
      'end\nprintf "n=%%d\\n",$n\ndetach\nquit\n', timeout=180)
print(o2)