* Clarify docs of raw_alignment * Set Go and Rust string encoding for binary string search. * Add detailed doxygen about string search in bin plugins. * Add the number string code points as detail to string search hits. * Add helper to check if string encoding needs scanning. * Add helper to generate a string wildcard pattern. The pattern is supposed to match any human readable string. Before the string search refactor there was no explicit definition what characters mark the end of a string and which ones don't. This pattern should match strings of the old interpretation. * Enable the RzBin plugin to search strings with direct matching instead of scanning. This significantly speeds up the string search when a binary is opened. The prerequisite is that the plugin specifies the string encoding. * Enforce UTF-8 for initial string search. * Add custom string search for PE files. * Clean up and document rz_utf8_encode * Don't demote explicit UTF-8 encoding to ASCII. * Increase min JIT stack size due to not reproducable search results. * Simplify wildcard regex pattern.
54 lines
862 B
Text
54 lines
862 B
Text
NAME=test pDj missing newline issue
|
|
FILE==
|
|
CMDS=<<EOF
|
|
e asm.arch=x86
|
|
e asm.bits=64
|
|
wx 4883c768
|
|
pDj 4~{}
|
|
EOF
|
|
EXPECT=<<EOF
|
|
[
|
|
{
|
|
"offset": 0,
|
|
"ptr": 104,
|
|
"val": 104,
|
|
"esil": "104,rdi,+=,63,$o,of,:=,63,$s,sf,:=,$z,zf,:=,63,$c,cf,:=,$p,pf,:=,3,$c,af,:=",
|
|
"refptr": false,
|
|
"fcn_addr": 0,
|
|
"fcn_last": 0,
|
|
"size": 4,
|
|
"opcode": "add rdi, 0x68",
|
|
"disasm": "add rdi, 0x68",
|
|
"bytes": "4883c768",
|
|
"family": "cpu",
|
|
"type": "add",
|
|
"reloc": false,
|
|
"type_num": 17,
|
|
"type2_num": 0
|
|
}
|
|
]
|
|
EOF
|
|
RUN
|
|
|
|
NAME=/zj with backslash
|
|
FILE=bins/pe/ConsoleApplication1.exe
|
|
CMDS=/zj ConsoleApplication1.pdb~{}
|
|
EXPECT=<<EOF
|
|
[
|
|
{
|
|
"address": 4203952,
|
|
"size": 23,
|
|
"flag": "hit.string.ascii.0",
|
|
"detail": 23
|
|
}
|
|
]
|
|
EOF
|
|
RUN
|
|
|
|
NAME=irj without any bin file should print an empty array
|
|
FILE==
|
|
CMDS=irj
|
|
EXPECT=<<EOF
|
|
[]
|
|
EOF
|
|
RUN
|