This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
d = open('report2.xls', 'rb').read() | |
data_chunk = -1 | |
start_address = [0xace1, | |
0xcc88, | |
0xecac, | |
0x10cd0, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def decrypt(text, alphabet): | |
l = 0x66 | |
cnt = len(text) | |
i = 0 | |
res = [] | |
while i < cnt: | |
res.append(chr(text[i] ^ ord(alphabet[i%l]))) | |
i += 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def decode_flag(frob): | |
last_value = frob | |
encoded_flag = [1135, 1038, 1126, 1028, 1117, 1071, 1094, 1077, 1121, 1087, 1110, 1092, 1072, 1095, 1090, 1027, | |
1127, 1040, 1137, 1030, 1127, 1099, 1062, 1101, 1123, 1027, 1136, 1054] | |
decoded_flag = [] | |
for i in range(len(encoded_flag)): | |
c = encoded_flag[i] | |
val = (c - ((i%2)*1 + (i%3)*2)) ^ last_value | |
decoded_flag.append(val) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#armageddon | |
from ghidra.program.model.listing import CodeUnitFormat, CodeUnitFormatOptions | |
from ghidra.program.model.symbol import RefType | |
codeUnitFormat = CodeUnitFormat(CodeUnitFormatOptions(CodeUnitFormatOptions.ShowBlockName.ALWAYS,CodeUnitFormatOptions.ShowNamespace.ALWAYS,"",True,True,True,True,True,True,True)) | |
addr = toAddr('<start address>') | |
limiter = 0 | |
limit = 50 | |
instruction = currentProgram.getListing().getInstructionAt(addr) | |
while True: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#exceptional | |
from ghidra.program.model.listing import CodeUnitFormat, CodeUnitFormatOptions | |
from ghidra.program.model.symbol import RefType | |
codeUnitFormat = CodeUnitFormat(CodeUnitFormatOptions(CodeUnitFormatOptions.ShowBlockName.ALWAYS,CodeUnitFormatOptions.ShowNamespace.ALWAYS,"",True,True,True,True,True,True,True)) | |
addr = toAddr('<start_address>') | |
limiter = 0 | |
instruction = currentProgram.getListing().getInstructionAt(addr) | |
while True: | |
t = instruction.getFlowType() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File "/c/temp/ctf/ropemporium/task-write4/gdb-frontend/api/debug.py", line 61, in _exec__mT | |
output = callback(*args, **kwargs) | |
File "/c/temp/ctf/ropemporium/task-write4/gdb-frontend/api/debug.py", line 679, in serializableType | |
serializable["alignof"] = ctype.alignof | |
AttributeError: 'gdb.Type' object has no attribute 'alignof' | |
Traceback (most recent call last): | |
File "/c/temp/ctf/ropemporium/task-write4/gdb-frontend/api/debug.py", line 349, in getState | |
variable["type"]["terminal"] = serializableType(terminalType) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(gdb) [GDBFrontend] ('127.0.0.1', 36958) is connected. | |
(gdb) file ./write4 | |
Reading symbols from ./write4...(no debugging symbols found)...done. | |
[GDBFrontend] gdb_on_clear_objfiles() | |
[GDBFrontend] gdb_on_new_objfile() | |
(gdb) break main |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# It looks like -multiwindow mode triggers the static color visual in both the internal x2go xserver and the external vcxsrv | |
# But it also looks like -multiwindow mode is how x2go client allows resizing of the remote desktop | |
# ...so I'm looking for a way to allow resizing of remote desktop w/out triggering static color visual. | |
# | |
# ...output of vcxsrv.exe's usage note: | |
Usage... | |
Vcxsrv [:<display>] [option] | |
:display-number |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pwn import * | |
t = process('./ret2win32') | |
context.terminal = ['/c/tools/wsl-terminal/open-wsl.exe','-e'] | |
gdb.attach(t) | |
t.interactive() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pwn import * | |
t = process('./ret2win32') | |
gdb.attach(t) | |
t.interactive() |