Linux Kernel "/proc/<pid>/" Permissions Handling Weakness

2011-02-28 / 2011-03-01
Credit: halfdog
Risk: Low
Local: No
Remote: No
CWE: CWE-264


CVSS Base Score: 2.1/10
Impact Subscore: 2.9/10
Exploitability Subscore: 3.9/10
Exploit range: Local
Attack complexity: Low
Authentication: No required
Confidentiality impact: Partial
Integrity impact: None
Availability impact: None

In my reply to FD-post "GNU libc/regcomp(3) Multiple Vulnerabilities" I indicated, that I found and reported the same bug while searching for resource starvation bugs two years ago. So I dug out the programs from back than to test suid binaries on recent linux distro and kernel. While it is still possible to trigger quite a few different flaws, none of them is quite interesting enough to investigate (mostly NULL and -1 derefs). But I got a minor but funny fault: When executing a process as normal user, one can open /proc/[pid]/ entries and keep them open, even after executing a suid binary. Thus it is possible e.g. to * Find stack base even with stack randomization * Modify oom_adj and kill the suid-binary with SIGKILL * Modify the coredump filter * Read limits Damn it, that /proc/self/mem is not rw See http://www.halfdog.net/Security/2011/SuidBinariesAndProcInterface/ Apart from that, ping6 contains a trivial buffer overflow using the size parameter (>128000), but I think it is not exploitable to gain root privileges. See http://www.halfdog.net/Security/2011/Ping6BufferOverflow/

References:

https://lkml.org/lkml/2011/2/9/417
https://lkml.org/lkml/2011/2/7/474
https://lkml.org/lkml/2011/2/7/466
https://lkml.org/lkml/2011/2/7/414
https://lkml.org/lkml/2011/2/7/404
https://lkml.org/lkml/2011/2/7/368
https://lkml.org/lkml/2011/2/10/21
http://www.halfdog.net/Security/2011/SuidBinariesAndProcInterface/
http://secunia.com/advisories/43496
http://seclists.org/fulldisclosure/2011/Jan/421
http://openwall.com/lists/oss-security/2011/02/25/2
http://openwall.com/lists/oss-security/2011/02/24/18


Vote for this issue:
50%
50%


 

Thanks for you vote!


 

Thanks for you comment!
Your message is in quarantine 48 hours.

Comment it here.


(*) - required fields.  
{{ x.nick }} | Date: {{ x.ux * 1000 | date:'yyyy-MM-dd' }} {{ x.ux * 1000 | date:'HH:mm' }} CET+1
{{ x.comment }}

Copyright 2024, cxsecurity.com

 

Back to Top