Radare2: v4.0 – Codename Kràmpack – vifino edition

10/28/2019 3:52 pm

Radare2: v4.0 – Codename Kràmpack – vifino edition

Radare2: v4.0 – Codename Kràmpack – vifino edition

  • Version: 4.0.0
  • From: 3.9.0
  • To: 4.0.0
  • Commits: 299
  • Contributors: 48

Changes

anal

  • Bring back the MASK_DISASM because not all nanal plugins support it yet ##anal
  • Select default var type based on its size
  • Fix- Improve af- like its done in Vdu
  • Deprecate anal.jmp.eob /refs
  • Fix – honor asm.var.sub in ao/aoj
  • Fix- Honor RAnalOp.disp in aar and ao
  • Update 8051 plugin
  • Avoid reloading of cc sdb – huge speedup
  • Implement ESIL for arm64 UBFX
  • Make RAnalFunction.cc come from RAnal String Pool
  • Deprecate the use of anal plugins that doesnt handle mask.disasm
  • Add jumptable support for main() in bins/elf/analysis/ls-alxchk
  • Add jumptable support for main() in bins/elf/ls.odd
  • add afoj and afdj
  • Fix – push [mem] not handled in /r
  • Add initial reg profile for sysz arch
  • Don’t propagate noret to fcn if fcn jmps outside itself
  • Fix: Make meta.min rbtree more robust
  • Fix memleak in r_core_anal_propagate_noreturn()
  • Minor speedup/cleanup/refactor of the RAnal
  • Implement ESIL control-flow-graph and further dfg analysis
  • Add anal.delay to disable delay slot analysis for testing
  • Fix pc-rel movs in sh’s esil
  • Delay execution debug messages are now available via anal.verbose
  • Fix: Disambiguate using fcn addr also in meta.min rbtree

api

  • Add r_strbuf_copy API

asm

  • Fix post-indexed memory access for str instructions on ARM
  • Fix  [rasm2/armass] Correctly propagate errors from thumb_assemble
  • Add additional [indirect] access syntax for 8051
  • Fix sub sp, sp, 0x1000 not correctly assembled for ARM
  • Fix arm64 assembler const value
  • Add 8051 assembler plugin
  • Z80’s LD opcodes assembly
  • Fix parsing of floating point instructions in x86_64 assembler
  • Fix x86 assembler output for some memory loads

bin

  • On AArch64 there is a new special symbol $x
  • Fix – Support old Java attribute format
  • Simplify r_bin_open_io function
  • Support > 4GB ELF files
  • Add support for RTable.query in i
  • Fix : Integrate table to iS,ia,ir,iz,is (RBin info) based commands
  • Implement support for the RISCV PLT ELF relocs
  • Fixes for MSVC demangling
  • Format the .rela. sections in ELF
  • Add NES ROM mirroring map

build

  • sys/asan.sh: Use -fsanitize=… instead of -lasan when linking
  • Link sdb fully into r_util in meson
  • Fix  – *BSD builds
  • Fix macOS build with latest XCode
  • Add MSVC 2019 for AppVeyor
    • Try MSVC 2019 for AppVeyor
  • Set rpath if non-Windows Meson shared
  • Debian package fixes
  • Fix function key handling in visual/panels
  • For utf-8 locale, check LC_ALL, LC_CTYPE and LANG in sequence instead
  • Also use LANG env var to check for UTF-8 output support
  • Move UTF-8 setting logic to scr.utf8 config callback on Windows
  • Implement ‘str’ operation in RTable queries

core

  • Fix  – fn.j/fnj. show all flags in current offset, not just one
  • Few compiler watning fixes here and there
  • Fix  – Implement r_sys_info() and uname
  • Add kitty clippy replacement :3
  • Add possibility to specify time zone with rax2 -t
  • Implement cj command using the PJ api
  • Add support for the V programming language
  • Fix- Support octal numbers like 0o666
  • Implement function-based plugin loading method
  • Add omt and help message for RTableQuery + add format column api
  • Move Lib already loaded check before dlopen Call
  • Replace r_str_const* with RStrConstPool
  • Kill r_sys_get_osinfo () ##core

debug

  • Use RTable for Windows heap info output
  • Add support for setting xmm registers on linux
  • Fixed continue not being associated with the current thread in unix
  • Added a way to break while in dbg_wait (continue, step etc)
  • Fixed dpk
  • Fixed opcodes not being associated with the current thread in gdbr
  • Fix drm[bwdq] command, add xmm0h/l and xmm8-15 registers
  • Fix the way linux debugging options are set
  • r_reg_get_pack/r_reg_set_pack are not able to deal with 128 packbits
  • Added support to thread switching in linux and fix r_debug_select
  • Fixed ptrace ‘Operation not permitted’ errors
  • Fix debugger build for native GNU/Linux on RISC-V
  • Fix incomplete drr/drrj formatting when r_core_anal_hasrefs fails
  • Added “dptj” and “dptj “
  • Enhance drm command, add drm xmm0 functionality
  • Fix drf output formatting
  • Implementing debug info per pid on NetBSD
  • Using unused map debug field on macOS
  • Rebase fcn/bbs, flags , comments, meta, refs when ood
  • Fix issues in windows thread switching ##debug

diff

  • Implement radiff2 -X for hexII diffing
  • Fix: Support radare2_rc in radiff2 for graphs

disasm

  • Better pdi output when Cd is involved
  • Implement ‘pdt’ – print disasm in table, supports queries
  • Make asm.fcnsig more compact
  • Do not resolve the strings pointed by ADRP on arm64
  • Improve (change) sh4 disasm (lowercase regs…)

emu

  • anal_x86_cs fix esil expr for neg instruction
  • Fix – Honor the ‘u’ suffix in PPC instructions in ESIL

esil

  • Fix  – Update ESIL help message
  • Improve registers handling in ESIL dfg
  • Simplify ESIL code for ARM str instructions
  • Add a parameter to $s and $o

io

  • Setting the upper address limit for OpenBSD
  • Improve omt and implement RTable.filterSum

io_self

  • Setting the upper address limit for OpenBSD

json

  • Show flagname and realname in json format for fnj and such
  • Add current thread field to dptj

lang

  • Rewrite hashbang command parser, use argc & argv in hashbang

panel

  • Fix – Handle ‘O’ key to rotate asm.pseudo/asm.esil
  • Another const pointer to be free fix
  • Handle / highlight in panels for zoom and window modes
  • Fix const address freeing
  • fix – Add xrefs and xrefs here in visual
  • Fix  – Honor scr.fps

panels

  • Fix  – Handle ‘O’ key to rotate asm.pseudo/asm.esil
  • Handle / highlight in panels for zoom and window modes
  • Fix const address freeing
  • fix  – Add xrefs and xrefs here in visual
  • Fix  – Honor scr.fps

print

  • Fix  – Implement pcy command to print hexpairs in Yara format

r2pie

  • Implement r2pipe_open_dl() to use dlopen/dlsym

rasm2

  • Freeing main assembly object

script

  • Fix vlang plugin to run scripts and add example

search

  • Fix  – Support stdin slurping in rafind2 –
  • Add support for hex escaped litterals in regular expressions
  • Fix RCALL and RJMP in aop and /at
  • Refactor Search to use less Global State

table

  • Add :json,:quiet,strlen,minlen,maxlen,sortlen in table queries
  • Integrate table API for p-h

util

  • Fix rop inline assembly form

visual

  • Run .dr* in visual prompt in cfg.debug is set
  • Fix for VV going to V (issue 15181)
  • Fix : truncate long function names in Vv

wasm

  • Further wasm memory leak fixes
  • Memory leak fixes in error code paths

windows

  • Print child output in pipe lang plugin

zign

  • Integrate types field in zignature operations

To Review

  • Release v4.0.0 – Codename Krampack
  • Fixed issues in windows thread switching by implementing thread attach for w32dbg =!pid
  • Previously the function attempted to OpenProcess even though the main
  • pid is already opened by __open and the fact that re-opening the main
  • pid wouldn’t do anything. This way it attaches to new threads when
  • called by r_debug_select.
  • Modified w32_continue to update rio->pi.dwThreadId after switching to the requested thread\xa0##debug
  • Manually changing iop->pi.dwThreadId in io_w32dbg’s =!pid created a
  • problematic scenario when w32_continue is called with the last event’s
  • tid from dbg_wait. This solution makes sure iop->pi.dwThreadId keeps
  • being updated after events on other threads arrive and that w32_continue
  • actually uses the given tid.
  • Modified w32_continue return values
  • Fix build