max op length assumed

master
JoYo 2019-02-24 06:38:33 +00:00
parent ad6277c0ee
commit 38706feff6
1 changed files with 3 additions and 1 deletions

View File

@ -60,7 +60,9 @@ def growth(*, shellcode: bytes, length: int) -> bytes:
opcodes = disasm(shellcode) opcodes = disasm(shellcode)
if len(shellcode) > len(opcodes) * 8: max_op_len = 15
if len(shellcode) > len(opcodes) * max_op_len:
return bytes(shellcode) return bytes(shellcode)
for mnemonic, op_str in opcodes: for mnemonic, op_str in opcodes: