Difference between pages "Main Page" and "Tutorials/Reverse engineering embedded software using Radare2"

From LCA2015 Delegate wiki
(Difference between pages)
Jump to: navigation, search
(Changing Informal to Other)
 
 
Line 1: Line 1:
<strong>Welcome to the Linux.conf.au 2015 wiki</strong>
+
This page describes preparation for [http://linux.conf.au/schedule/30102/view_talk?day=thursday Reverse engineering embedded software using Radare2]
  
This wiki is provided for those attending linux.conf.au 2015 in Auckland New Zealand to add information that would be useful for other attendees.
+
== Outline ==
  
If you are attending LCA2015 feel free to add and share information here for the benefit of all delegates.
+
We will try and get through all the following:
  
To use this wiki, please [[Special:Userlogin|login]] using your ID from http://linux.conf.au<br/>
+
* Introduction to Radare2 reverse engineering tool
 +
* The Radare2 utilities
 +
* Basics of using the Radare to examine a binary you probably have on your laptop
 +
* Looking at an arduino binary
 +
* Introduction to MIPS architecture and disassembly
 +
* Extracting firmware images
  
<!-- Map of College Accommodation and University https://mapsengine.google.com/map/edit?mid=zF52JBvjZpOU.k_aH0N3I0eE8 -->
+
You might like to bring your own binary to play with as well instead!
  
== About ==
+
==Important - please make an rc file ==
: <small>''Main article: [[About]]''</small>
+
=== [[LCA|About linux.conf.au]] ===
+
{{#lst:About|lca}}
+
=== [[LCA2015|About LCA2015]] ===
+
{{#lst:About|lca2015}}
+
=== [[Venue|About our venue]] ===
+
{{#lst:About|venue}}
+
=== [[Auckland|About Auckland]] ===
+
{{#lst:About|auckland}}
+
=== [[New Zealand|About New Zealand]] ===
+
{{#lst:About|nz}}
+
  
== Programme ==
+
Radare2 was created by other, many people. Radare2 will by default print fortune cookies. Please, turn this feature off, by making the following file, in case there is a possibility of NSFW output.
: <small>''Main article: [[Programme]]''</small>
+
=== [[Programme#Formal|Formal activities during the conference]] ===
+
{{#lst:Programme|formal}}
+
=== [[Programme#Informal|Other activities during the conference]] ===
+
{{#lst:Programme|informal}}
+
  
== Delegate Information ==
+
Instructions for Linux/Unix systems:
: <small>''Main article: [[Delegate Information]]''</small>
+
=== [[Accommodation]] ===
+
{{#lst:Delegate Information|accom}}
+
=== [[Childcare]] ===
+
{{#lst:Delegate Information|child}}
+
=== [[Eating and Drinking]] ===
+
{{#lst:Delegate Information|food}}
+
  
=== [[Shops and Supplies]] ===
+
    echo 'e cfg.fortunes=false' > ~/.radare2rc
{{#lst:Delegate Information|shops}}
+
=== [[Communication]] ===
+
{{#lst:Delegate Information|comms}}
+
  
=== [[Medical Care]] ===
+
== Prerequisites ==
{{#lst:Delegate Information|medical}}
+
  
<!-- This is where I'm up to with the reorganisation of the Main Page - ᏜᏠᎶᏠᏑ -->
+
If during the tutorial you are planning to follow the examples and/or try your own ideas, you really want to get this sorted before the event.
  
==Before and after the conference==
+
Minimum requirements:
* [[Events before and after the conference]]
+
* a C compiler and libraries needed to build radare2 - the "apt-gettable" version is out of date
* [[Attractions]] - Tourist attractions around Auckland
+
* xdot for viewing callgraphs
* [[Local Restaurants]]
+
* binwalk and srecord for firmware hacking
* [[Geeks on a Train]] -- Auckland to Wellington, January 17
+
  
==Other stuff==
+
Various other tools may be helpful, and indeed needed (e.g. an editor) to complete some of the examples
* [[Maps]]
+
* [[Job Board]]
+
* [[Partners' Programme]]
+
  
== Photos and Video from the conference ==
+
If you are using a Debian-derived distro, for example:
* Online Streaming of the conference
+
 
* [[Photos]]
+
    sudo apt-get install build-essential git xdot eog ghex binwalk vim gedit srecord
* Official Videos of talks (uploaded as they become available)
+
 
 +
It should be possible to build radare2 on Linux, FreeBSD/NetBSD etc, Max OS/X and Windows and possibly on Android if you try hard enough (using a Debian root, for example)
 +
 
 +
However, the tutorial examples have only been tested using Debian Wheezy.
 +
 
 +
=== Clone & build radare2 ===
 +
 
 +
Note, changing to the lca2015_tutorial branch is important, because the software is under active development there could be breakage in master upstream
 +
 
 +
    git clone http://github.com/pastcompute/radare2
 +
    cd radare2
 +
    git checkout tutorial_branch
 +
    ./configure
 +
    make -j
 +
    sudo make symstall
 +
 
 +
Note, you can install as a normal user if you need to:
 +
 
 +
    ./configure --prefix=$HOME/path/to/wherever
 +
    make -j
 +
    sudo make symstall
 +
    export PATH=$HOME/path/to/wherever:$PATH
 +
 
 +
Clone the examples repository, ready for use during the tutorial
 +
 
 +
    cd
 +
    git clone http://github.com/pastcompute/lca2015-radare2-tutorial
 +
 
 +
I have already added prebuilt examples to git but there are instructions for building them in git, you will need the arduino IDE or an openwrt buildroot.
 +
 
 +
==Troubleshooting==
 +
 
 +
The tutorial is not until Thursday afternoon. If you need help with the above ping me on Twitter, preferably before the day! [https://twitter.com/pastcompute @pastcompute]

Revision as of 22:35, 10 January 2015

This page describes preparation for Reverse engineering embedded software using Radare2

Outline

We will try and get through all the following:

  • Introduction to Radare2 reverse engineering tool
  • The Radare2 utilities
  • Basics of using the Radare to examine a binary you probably have on your laptop
  • Looking at an arduino binary
  • Introduction to MIPS architecture and disassembly
  • Extracting firmware images

You might like to bring your own binary to play with as well instead!

Important - please make an rc file

Radare2 was created by other, many people. Radare2 will by default print fortune cookies. Please, turn this feature off, by making the following file, in case there is a possibility of NSFW output.

Instructions for Linux/Unix systems:

   echo 'e cfg.fortunes=false' > ~/.radare2rc

Prerequisites

If during the tutorial you are planning to follow the examples and/or try your own ideas, you really want to get this sorted before the event.

Minimum requirements:

  • a C compiler and libraries needed to build radare2 - the "apt-gettable" version is out of date
  • xdot for viewing callgraphs
  • binwalk and srecord for firmware hacking

Various other tools may be helpful, and indeed needed (e.g. an editor) to complete some of the examples

If you are using a Debian-derived distro, for example:

   sudo apt-get install build-essential git xdot eog ghex binwalk vim gedit srecord

It should be possible to build radare2 on Linux, FreeBSD/NetBSD etc, Max OS/X and Windows and possibly on Android if you try hard enough (using a Debian root, for example)

However, the tutorial examples have only been tested using Debian Wheezy.

Clone & build radare2

Note, changing to the lca2015_tutorial branch is important, because the software is under active development there could be breakage in master upstream

   git clone http://github.com/pastcompute/radare2
   cd radare2
   git checkout tutorial_branch
   ./configure
   make -j
   sudo make symstall

Note, you can install as a normal user if you need to:

   ./configure --prefix=$HOME/path/to/wherever
   make -j
   sudo make symstall
   export PATH=$HOME/path/to/wherever:$PATH

Clone the examples repository, ready for use during the tutorial

   cd
   git clone http://github.com/pastcompute/lca2015-radare2-tutorial

I have already added prebuilt examples to git but there are instructions for building them in git, you will need the arduino IDE or an openwrt buildroot.

Troubleshooting

The tutorial is not until Thursday afternoon. If you need help with the above ping me on Twitter, preferably before the day! @pastcompute