RASM2(1)

πŸ“¦
version 6.2.2 Β· 4 versions
, in alpine 3.24, arch rolling, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0, ubuntu stonking

πŸ’– RASM2(1) β€” bestie, you're reading the rasm2(1) manual page πŸ’–

Okay so. Hi. You opened the man page for rasm2, the Radare2 Assembler and Disassembler Tool, and I am about to make this the best part of your day. Grab a lil snack πŸ“, we're going in.


🌸 NAME 🌸

rasm2 β€” the Radare2 Assembler and Disassembler Tool. That's her. That's the whole girl. She assembles, she disassembles, she does both in like forty architectures, no big deal. πŸ’…


✨ SYNOPSIS ✨

rasm2 [-ACdDehHjLvwrNqxp] [-a arch] [-b bits] [-c cpu] [-F parser]
      [-k kernel] [-o ofile] [-s addr] [-@ addr] [-S syntax] [-i len]
      [-l len] [code|hex|-]

Like, that looks like a lot but it's literally just a bunch of little flags vibing next to each other. You got this. 🫢


πŸ¦‹ DESCRIPTION πŸ¦‹

So what does she do? She assembles and disassembles code or hexpair strings for multiple architectures and syntax formats. That's the whole vibe. Type assembly in, get bytes out. Type bytes in, get assembly out. Multiple architectures. Multiple syntaxes. She's versatile, she's booked, she's busy. 😭

Now β€” the flags. Every. Single. One. Because we do not gatekeep here. πŸ‘‘

  • -a arch β€” Set architecture plugin. This is you telling her which CPU family you're flirting with today.
  • -A β€” Show analysis information of given hexpair string. She'll look at your hexpairs and tell you what she thinks. Perceptive queen.
  • -b bits β€” Set architecture bits. Your options are 8, 16, 32, 64.
  • -B β€” Binary input/output. ⚠️ Heads up bestie: -l is mandatory for binary input. Don't skip it, she will not be happy.
  • -c cpu β€” Select specific CPU. Now this one depends on -a arch, so set your arch first, okay? Don't be chaotic.
  • -C β€” Output in C format. If you're a C girlie, this one's for you.
  • -d β€” Disassemble hexpair bytes. Like, rasm2 -d 9090. Run it, it's cute.
  • -D β€” Disassemble showing hexpair and opcode. Both. Because why choose.
  • -e β€” Use big endian instead of little endian. Yes, endianness discourse still exists in 2025, I don't make the rules.
  • -E β€” Output disassembled instructions in ESIL format. ESIL girlies rise up ✨
  • -f file β€” Read data from file instead of ARG. Feeding her from a file instead of the command line, very demure.
  • -F parser β€” Specify parse plugin to be used (here, pseudo).
  • -h β€” Show usage help message. The classic. The og. Use it.
  • -hh β€” Show long help message including supported assembler directives. Double h, double the lore.
  • -H [var] β€” Display variable.
  • -i len β€” Ignore/skip N bytes from the beginning of the input buffer. Just, like, skip past them. Ignore them. As one does. πŸ™ˆ
  • -j β€” Output in json format. For my machine-readable besties.
  • -k kernel β€” Select operating system, like linux, windows, darwin, android, ios, ... β€” yes, the list literally trails off with ..., she's mysterious like that.
  • -l len β€” Input/Output length.
  • -L [name] β€” List RArch plugins: (a=asm, d=disasm, e=esil, p=parse).
  • -LL [name] β€” List RAsm parse plugins. Yeah, two Ls. Different thing. Iconic, honestly.
  • -N β€” Don't load any plugin. Same as R2_NOPLUGINS=1 or r2 -N (iykyk).
  • -o ofile β€” Output to file, for example 'rasm2 -Bf a.asm'. Note how -B and -f are snuggled together there, cute.
  • -p β€” Run SPP over input for assembly.
  • -q β€” Quiet output. Handy for -L, -v, ....
  • -r β€” Show output in r2 script.
  • -s addr β€” Define initial start/seek address. Default is 0.
  • -@ addr β€” Alias for -s. Same thing, different key, we love options.
  • -S syntax β€” Select syntax output, like intel, att, masm, ... again with the mysterious trailing dots. She contains multitudes.
  • -v β€” Show version information.
  • -w β€” Describe opcode (what's op).
  • -x β€” Use hex dwords instead of hexpairs in the assembler output. Dwords! Not hexpairs! Do not confuse them, I'm begging.

🌈 ENVIRONMENT 🌈

The vibes she reads from her environment. Very much "the room she's in shapes who she is." πŸ’œ

  • R2_NOPLUGINS β€” Do not load shared plugins (this speeds up loading).
  • R2_PLUGINS_ORDER β€” Plugin load order: i=internal, e=env, h=home, s=system; default is iehs; ? prints help. Yeah she has a little language for this, it's giving code, it's giving ciphers, obsess.
  • R2_LOG_LEVEL β€” Change the log level.
  • R2_DEBUG β€” If defined, show error messages and crash signal.
  • R2_DEBUG_ASSERT β€” Enables runtime assertions for debugging.
  • RASM2_ARCH β€” Same as rasm2 -a.
  • RASM2_BITS β€” Same as rasm2 -b.

πŸŽ€ DIRECTIVES πŸŽ€

Wanna see the supported assembler and preprocessor directives? Listing them is literally just:

$ rasm2 -hh

That's it. That's the whole flex. ✨


πŸ’… EXAMPLES πŸ’…

Okay this is the fun part, the part where we do things. No cap, just copy-paste.

Assemble opcode:

$ rasm2 -a x86 -b 32 'mov eax, 33'

Disassemble opcode:

$ rasm2 -d 90

Show all supported architectures:

$ rasm2 -L

Assemble with specific syntax:

$ rasm2 -a x86 -b 32 -S att 'mov eax, 33'

Output in JSON format:

$ rasm2 -j -a x86 -b 32 'mov eax, 33'

Use big endian:

$ rasm2 -e -a arm -b 32 'add r0, r0, r1'

Disassemble and show ESIL output:

$ rasm2 -d -E 90

πŸ”₯ SEE ALSO πŸ”₯

  • radare2(1) β€” her big sister, the main character herself πŸ‘‘

🧚 AUTHORS 🧚

pancake <pancake@nopcode.org> β€” the legend who made all of this happen. Respect. πŸ™Œ


πŸ’– that's the whole page bestie, go assemble something iconic

Sign-off time: this was RASM2(1), dated Jul 10, 2025 β€” so if you're reading this way later, that's the version vibe you're on. Slay, bye! πŸŒΈπŸ’–βœ¨

πŸ“¦ where this page comes from