RZ-DIFF(1)
π RZ_DIFF β like, the manual page for rz-diff (that's the RZ-DIFF(1) page bestie, section 1) π
okay so picture this: you got two files. two binaries. two whole vibes. and you need to know what's different between them. that's it. that's the whole thing. rz-diff is your girl for this. let's go π¦
β¨ SYNOPSIS β¨
rz-diff [OPTIONS] file0 file1
πΈ DESCRIPTION πΈ
so rz-diff takes two files or binary programs, compares them, and highlights the differences between them. like a glow-up reveal but for bytes. π
and it's not just raw bytes either β it can diff a bunch of different aspects, depending on which options you pass: raw bytes, text lines, functions, sections, strings, etc. etc. pick your fighter.
π the options, bestie π
-Aβ compare virtual addresses from file0 with physical addresses in file1-a [arch]β tell it which architecture plugin to use for analysis (thinkx86,arm)-b [bits]β set the register size for whichever architecture you picked (think16,32,64)-Bβ run'aaa'when loading the binary-Cβ disable colors in the output (no fun allowed mode, but valid)-d [algo]β compute the edit distance between the files with the algorithm you pick:myersβ Eugene W. Myers'O(ND)algorithm (no substitution)levenβ LevenshteinO(N^2)algorithm (with substitution)ssdeepβ Context triggered piecewise hashing comparison
-e [k=v]β set an evaluable config variable-Hβ turn on hexadecimal visual mode so you can compare files in hex format π-hβ display the help message-iβ use command line arguments instead of files (only for-d)-jβ output the comparison results in JSON format-qβ generate quiet output with minimal information-0 [cmd]β input for file0 when option-t 'commands'is given-1 [cmd]β input for file1 when option-t 'commands'is given-S [WxH]β set the width and height of the terminal for visual mode-t [type]β compute the difference between two files based on the type you pick:bytesβ compare raw bytes in the files (only for small files, fr)linesβ compare text filesfunctionsβ compare functions found in the filesclassesβ compare classes found in the filescommandβ compare command output returned when executed in both files. Requires-0 <cmd>,-1 <cmd>is optional.entriesβ compare entries found in the filesfieldsβ compare fields found in the filesgraphsβ compare 2 functions and outputs in graphviz/dot format. Requires-0 <fcnname|offset>,-1 <fcn name|offset>is optional.importsβ compare imports found in the fileslibrariesβ compare libraries found in the filessectionsβ compare sections found in the filesstringsβ compare strings found in the filessymbolsβ compare symbols found in the files
-Tβ show timestamp information in the output-Vβ show version information forrz-diff-vβ be more verbose (stderr output)
palette check!! π you can change the palette colors by adding the following lines inside the $HOME/.rizinrc file:
ec diff.unknown blue
offset color
ec diff.match green
match color
ec diff.unmatch red
mismatch color
β EXAMPLE β
compare two binary files using the default settings:
rz-diff file1.bin file2.bin
compare two text files and display the output in JSON format:
rz-diff -j -t lines file1.txt file2.txt
compare two functions from an architecture plugin:
rz-diff -t graphs -0 function1 -1 function2 binary1 binary2
π SEE ALSO π
rizin(1), rz-find(1), rz-hash(1), rz-bin(1), rz-asm(1), rz-gg(1), rz-run(1), rz-ax(1),
π AUTHORS π
- pancake
<pancake@nopcode.org> - byteninjaa0
and that's the whole page, bestie!! π«Ά this one's from Aug 25, 2023, it's the RZ_DIFF(1) manual, and it ate. go diff something. mwah π
β¨
π¦ where this page comes from
- arch rolling: rizin 0.8.2-2 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND CC-PDDC AND CC0-1.0 AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-only AND GPL-3.0-or-later AND LGPL-2.0-or-later AND LGPL-2.1-only AND LGPL-2.1-or-later AND LGPL-3.0-only AND MIT
- epel 10: rizin 0.7.4-5.el10_1 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- epel 9: rizin 0.7.4-5.el9 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- fedora 43: rizin 0.7.4-9.fc43 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- fedora 43: rizin 0.7.4-9.fc43 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- fedora 44: rizin 0.7.4-9.fc43 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- fedora 44: rizin 0.7.4-9.fc43 Β· LGPL-3.0-or-later AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND Apache-2.0 AND MPL-2.0 AND Zlib
- nixos 26.05: rizin 0.8.2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms