Skip to content

Instantly share code, notes, and snippets.

radare radare

Block or report user

Report or block radare

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@radare
radare / rsoc2019.md
Created Apr 2, 2019
Radare Summer of Code 2019 Selection Results
View rsoc2019.md

Radare2 Summer of Code 2019 Selection Results

As you might remember radare2 organization was a part of Google Summer of Code for many years already. Sadly this year we weren't selected for participation, thus decided to open our own Radare2 Summer of Code season one more time (we did a few time already too). We want to thank NowSecure and KeenLab of Tencent one more time for helping us to make it happen.

The rules and requirements for the RSoC'19 were very similar to GSoC one, with a slightly shifted schedule, so people would give RSoC selection results before the GSoC deadline, to be able apply to GSoC in case of RSoC rejection. Back to the business, this year we accepted two students:

View gist:3a798ce5f34a11dd6320c372248769a5
╭────────────────────╮ ╭────────────────────╮ ╭────────────────────╮ ╭────────────────────╮
│ entry0 │ │ sym.___muloti4 │ │ sym.___umoddi3 │ │ sym.___umodti3 │
╰────────────────────╯ ╰────────────────────╯ ╰────────────────────╯ ╰────────────────────╯
t t t t t
│ │ │ │ │
│ │ ╰────────╮ │ │
│ ╭────────────╯ │ │ │
│ │ │
View zig-make.log
[ 16%] Built target embedded_lld_lib
[ 63%] Built target embedded_softfloat
[ 69%] Built target embedded_lld_coff
[ 70%] Built target embedded_lld_mingw
[ 86%] Built target embedded_lld_elf
[ 90%] Built target embedded_lld_wasm
[ 91%] Built target zig_cpp
[ 92%] Linking CXX executable zig
Undefined symbols for architecture x86_64:
"_LLVMABIAlignmentOfType", referenced from:
View gist:0427ff4b2abc215b7bf39d556f646188
[pancake@koega radare2]$ r2 /bin/ls
-- Set 'e bin.dbginfo=true' to load debug information at startup.
[0x000050b0]> #!python
*** Error in `r2': malloc(): memory corruption: 0x00005591fd72aae0 ***
======= Backtrace: =========
/usr/lib/libc.so.6(+0x704fb)[0x7fb3dd8ca4fb]
/usr/lib/libc.so.6(+0x76976)[0x7fb3dd8d0976]
/usr/lib/libc.so.6(+0x78949)[0x7fb3dd8d2949]
/usr/lib/libc.so.6(__libc_calloc+0x27b)[0x7fb3dd8d506b]
/usr/lib/python2.7/lib-dynload/_hashlib.so(init_hashlib+0x27d)[0x7fb3d8cf1f3d]
@radare
radare / test-afl.js
Created Feb 5, 2017
radare2 + nodejs function list (1m15s on ntdll.dll)
View test-afl.js
const r2pipe = require("r2pipe");
r2pipe.open('Downloads/ntdll/ntdll.dll', (err, r2) => {
r2.cmd('aa', (err) => {
r2.cmdj('aflj', (err, res) => {
let total = res.length;
for(let f of res) {
r2.cmdj('pdrj @ ' + f.name, (err, res) => {
if (--total < 1) {
r2.quit();
@radare
radare / Dockerfile
Created Jun 23, 2016
Dockerfile for Toxic 0.7
View Dockerfile
FROM ubuntu
RUN apt-get update
RUN apt-get upgrade -y
RUN apt-get install -y wget apt-transport-https
RUN echo deb https://pkg.tox.chat/debian nightly stretch | tee /etc/apt/sources.list.d/tox.list
RUN wget -qO - https://pkg.tox.chat/debian/pkg.gpg.key | apt-key add -
RUN apt-get update
RUN apt-get install -y toxic
@radare
radare / noman
Created Jun 15, 2016
NodeJS man-like tool for module's README
View noman
#!/bin/sh
PATH="$(npm bin):$PATH"
for a in readme ansimd ; do
type $a > /dev/null || npm install $a
done
readme "$1" | ansimd /dev/stdin | less -R
View swift-demangler
1) spawning is slow, so spawning for each symbol is killing the process
2) you can quickly detect which symbols are mangled by just checking the first 2 chars of the symbol, this reduces the time A LOT
3) swift-demangle can be used to demangle more than one symbol at the time
4) swift is opensource, there's no need to spawn anything
5) the swift demangling apis are accessible (not in last release, but yes in git)
6) there's a swift reimplemenation of the c++ one, just google for it
7) i wrote my own demangler in C (totally incomplete, but enough for most needs)
8) spawning is a process that can be done in paralel. but that's something only Node developers know (ssssh!)
9) python is slow
10) opening any real application with this script will kill your machine
@radare
radare / gist:f0e26fbfeba327729e2778c9ca08d40a
Created Apr 14, 2016
python r2pipe script to enumerate all branches (calls and jumps)
View gist:f0e26fbfeba327729e2778c9ca08d40a
# ejecutar asi: r2 -qi calls.py /bin/ls
import r2pipe
r2 = r2pipe.open()
r2.cmd('s $S @ entry0') # ir al principio de la seccion de codigo
# direccion minima y maxima de la seccion de codigo
addr = int(r2.cmd('?v $S'), 16)
addr_end = int(r2.cmd('?v $S + $SS'), 16)
View gist:9403b4fb103b1b589387
# Template file for 'swift'
pkgname=swift
version=2.2
revision=1
build_style=cmake
hostmakedepends="cmake pkg-config"
makedepends="ninja cmake icu swig clang python perl"
short_desc=" The Swift Programming Language"
maintainer="pancake <pancake@nopcode.org>"
license="Apache-2.0"
You can’t perform that action at this time.