<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">This is what I had done and worked on :<br>
<br>
bianchi@ubuntu:~/Documents/Coreboot Column$ r2 i946gz_Edited.bin <br>
[f000:fff0]> s f000:0<br>
[f000:0000]> pD 0xffff<br>
Do you want to print 4401484 chars? (y/N)<br>
; [0] va=0x000f0000 pa=0x00070000 sz=65536 vsz=65536
rwx=-rwx bootblk<br>
;-- section.bootblk:<br>
,=< f000:0000 ead41100f0 jmp word 0xf000:0x11d4<br>
| f000:0005 0000 add [bx+si], al<br>
| f000:0007 0000 add [bx+si], al<br>
| f000:0009 0000 add [bx+si], al<br>
| f000:000b 0000 add [bx+si], al<br>
| f000:000d 0000 add [bx+si], al<br>
| f000:000f 00e8 add al, ch<br>
| f000:0011 0c01 or al, 0x1<br>
,==< f000:0013 745e jz 0xf0073 <br>
and so on until the bottom 4401481 chars...<br>
<br>
<br>
On 9/11/2016 2:32 AM, Zoran Stojsavljevic wrote:<br>
</div>
<blockquote
cite="mid:CAGAf8Lwzs=k92opkXoE1N9QiiLjibh-n0ynEaqbeMrd-c_G+gg@mail.gmail.com"
type="cite">
<div dir="ltr">Hello to all radare2 experienced people,
<div><br>
</div>
<div>From my VM Fedora 25 x86_64 on the top of VMWorkstation
12.5.1, on WIN10 64 Pro!</div>
<div><br>
</div>
<div>Here is my take on radare2... And I am not getting through.
Transcript follows:</div>
<div><br>
</div>
<div>
<div>[zoran@localhost bios]$ radare2 -e asm.bits=16 -e <a
moz-do-not-send="true" href="http://io.va">io.va</a>=true
BIOS_AMI_BIOS.bin </div>
<div> -- attempt to dissasemble Core IVB AMI BIOS</div>
<div>[0000:0000]> S $s-0x10000 0xF000:0x0000 0x10000
0x10000 bootblk rwx</div>
<div>[0000:0000]> e asm.segoff=true</div>
<div>[0000:0000]> e asm.syntax = intel</div>
<div>[0000:0000]> s 0xf000:0xfff0</div>
<div>[f000:fff0]> pd 16</div>
<div> f000:fff0 ff invalid</div>
<div> f000:fff1 ff invalid</div>
<div> f000:fff2 ff invalid</div>
<div> f000:fff3 ff invalid</div>
<div> f000:fff4 ff invalid</div>
<div> f000:fff5 ff invalid</div>
<div> f000:fff6 ff invalid</div>
<div> f000:fff7 ff invalid</div>
<div> f000:fff8 ff invalid</div>
<div> f000:fff9 ff invalid</div>
<div> f000:fffa ff invalid</div>
<div> f000:fffb ff invalid</div>
<div> f000:fffc ff invalid</div>
<div> f000:fffd ff invalid</div>
<div> f000:fffe ff invalid</div>
<div> f000:ffff ff00 inc word [bx +
si]</div>
<div>[f000:fff0]> </div>
</div>
<div><br>
</div>
<div>Help needed/comments appreciated. What am I doing wrong?</div>
<div><br>
</div>
<div>Thank you,</div>
<div>Zoran</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Mon, Nov 7, 2016 at 2:08 AM, Riko Ho
<span dir="ltr"><<a moz-do-not-send="true"
href="mailto:antonius.riko@gmail.com" target="_blank">antonius.riko@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<div class="m_-3512760452593454976moz-cite-prefix">Hi
Zoran,<br>
I reckon that's the right radare, find *.bin or *.rom or
*.hex and run<br>
<br>
[zoran@localhost ~]$ radare2 *.bin<br>
and s command and pD command....for example :<br>
<pre>[f000:fff0]> s f000:0
[f000:0000]> pD 0xffff
more info :
<a moz-do-not-send="true" class="m_-3512760452593454976moz-txt-link-freetext" href="https://radare.gitbooks.io/radare2book/content/disassembling/intro.html" target="_blank">https://radare.gitbooks.io/<wbr>radare2book/content/<wbr>disassembling/intro.html</a>
</pre><div><div class="h5">
On 7/11/2016 5:41 AM, Zoran Stojsavljevic wrote:
</div></div></div><div><div class="h5">
<blockquote type="cite">
<div dir="ltr">
<div>Hello Riko,</div>
<div>
</div>
<div>I recently also became very interested to start using
radare2 (Raphael Machado's dissasembly attempts got involved
me, to set the tool). Since I am very lazy person, the first
was to ask my Fedora 25 distro does the distro have package
radare2?</div>
<div>
</div>
<div>Yes, it does have it, so I have installed it. And for you,
here is the transcript of my CLI for you.</div>
<div>
</div>
<div>CLI traces (radare --help) are worth 1000nd words, don't
you agree? ;-)</div>
<div>
</div>
<div>Best Regards,</div>
<div>Zoran</div>
<div>_______</div>
<div>
</div>
<div>[zoran@localhost ~]$ uname -r</div>
<div>4.8.6-300.fc25.x86_64</div>
<div>[zoran@localhost ~]$ which radare2</div>
<div>/usr/bin/radare2</div>
<div><b><i><u><font color="#ff0000">[zoran@localhost ~]$ radare2
--help</font></u></i></b></div>
<div>radare2: invalid option -- '-'</div>
<div>r_config_get: variable 'lp' not found</div>
<div> -- open radare2 on an empty file</div>
<div> - equivalent of 'r2 malloc://512'</div>
<div> = read file from stdin (use -i and -c to run
cmds)</div>
<div> -= perform !=! command to run all commands
remotely</div>
<div> -0 print \x00 after init and every command</div>
<div> -a [arch] set asm.arch</div>
<div> -A run 'aaa' command to analyze all referenced
code</div>
<div> -b [bits] set asm.bits</div>
<div> -B [baddr] set base address for PIE binaries</div>
<div> -c 'cmd..' execute radare command</div>
<div> -C file is host:port (alias for
-c+=<a moz-do-not-send="true" class="m_-3512760452593454976moz-txt-link-freetext" href="http://%s/cmd/" target="_blank">http://%s/cmd/</a>)</div>
<div> -d debug the executable 'file' or running
process 'pid'</div>
<div> -D [backend] enable debug mode (e cfg.debug=true)</div>
<div> -e k=v evaluate config var</div>
<div> -f block size = file size</div>
<div> -F [binplug] force to use that rbin plugin</div>
<div> -h, -hh show help message, -hh for long</div>
<div> -i [file] run script file</div>
<div> -I [file] run script file before the file is opened</div>
<div> -k [k=v] perform sdb query into core->sdb</div>
<div> -l [lib] load plugin file</div>
<div> -L list supported IO plugins</div>
<div> -m [addr] map file at given address (loadaddr)</div>
<div> -M do not demangle symbol names</div>
<div> -n, -nn do not load RBin info (-nn only load bin
structures)</div>
<div> -N do not load user settings and scripts</div>
<div> -o [OS/kern] set asm.os (linux, macos, w32, netbsd, ...)</div>
<div> -q quiet mode (no prompt) and quit after -i</div>
<div> -p [prj] use project, list if no arg, load if no file</div>
<div> -P [file] apply rapatch file and quit</div>
<div> -R [rarun2] specify rarun2 profile to load (same as -e
dbg.profile=X)</div>
<div> -s [addr] initial seek</div>
<div> -S start r2 in sandbox mode</div>
<div> -t load rabin2 info in thread</div>
<div> -u set bin.filter=false to get raw sym/sec/cls
names</div>
<div> -v, -V show radare2 version (-V show lib versions)</div>
<div> -w open file in write mode</div>
<div> -z, -zz do not load strings or load them even in raw</div>
<div>Scripts:</div>
<div> system /usr/share/radare2/radare2rc</div>
<div> user ~/.radare2rc ${RHOMEDIR}/radare2/radare2rc (and
radare2rc.d/)</div>
<div> file ${filename}.r2</div>
<div>Plugins:</div>
<div> plugins /usr/lib/radare2/last</div>
<div> user ~/.config/radare2/plugins</div>
<div> LIBR_PLUGINS /usr/lib/radare2/0.10.6-git</div>
<div>Environment:</div>
<div> RHOMEDIR /home/zoran/.config/radare2</div>
<div> RCFILE ~/.radare2rc (user preferences, batch script)</div>
<div> MAGICPATH /usr/lib64/radare2/0.10.6-<wbr>git/magic</div>
<div> R_DEBUG if defined, show error messages and crash
signal</div>
<div> VAPIDIR path to extra vapi directory</div>
<div> R2_NOPLUGINS do not load r2 shared plugins</div>
<div>Paths:</div>
<div> PREFIX /usr</div>
<div> INCDIR /usr/include/libr</div>
<div> LIBDIR /usr/lib64</div>
<div> LIBEXT so</div>
<div>[zoran@localhost ~]$ </div>
</div>
<div class="gmail_extra">
<div class="gmail_quote">On Sat, Nov 5, 2016 at 3:55 AM, Riko Ho
<span dir="ltr"><<a moz-do-not-send="true" href="mailto:antonius.riko@gmail.com" target="_blank">antonius.riko@gmail.com</a>></span>
wrote:
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<div class="m_-3512760452593454976m_-2926509009161831238moz-cite-prefix">Hi
Rafael,
For example I want to see the asm code for the whole
512Kbytes....is that possible ?
How ?
Thanks
<div>
<div class="m_-3512760452593454976h5">
On 5/11/2016 3:36 AM, Rafael Machado wrote:
</div>
</div>
</div>
<div>
<div class="m_-3512760452593454976h5">
<blockquote type="cite">
<div dir="ltr">Hi
<div>
</div>
<div>You can use the pd command.</div>
<div>p = Print</div>
<div>d = disassemby</div>
<div>
</div>
<div>You can also add the number of instruction
you whant to see. For example:</div>
<div>
</div>
<div>pd 10</div>
<div>
</div>
<div>Thanks </div>
<div>Rafael Machado</div>
</div>
<div class="gmail_quote">
<div dir="ltr">Em qua, 2 de nov de 2016 às 04:01,
Riko Ho <<a moz-do-not-send="true" href="mailto:antonius.riko@gmail.com" target="_blank">antonius.riko@gmail.com</a>>
escreveu:
</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Everyone, Idwer,
I have radare question :
I played until this point :
c:>radare2 -e asm.bits=16 -e <a moz-do-not-send="true" href="http://io.va" rel="noreferrer" class="m_-3512760452593454976m_-2926509009161831238gmail_msg" target="_blank">io.va</a>=true i946gz.bin
-- radare2 is WYSIWYF - what you see is what
you fix
[f000:fff0]> S $s-0x10000 0xF000:0x0000
0x10000 0x10000 bootblk rwx
[f000:fff0]> e asm.segoff=true
[f000:fff0]> s 0xf000:0xffff0
[f000:ffff]>
How can I see the assembler code from there ?
It's started from
FFFF0....I'm sure the last byte instruction is
jump to 0x00000
Cheers
--
coreboot mailing list: <a moz-do-not-send="true" href="mailto:coreboot@coreboot.org" class="m_-3512760452593454976m_-2926509009161831238gmail_msg" target="_blank">coreboot@coreboot.org</a>
<a moz-do-not-send="true" href="https://www.coreboot.org/mailman/listinfo/coreboot" rel="noreferrer" class="m_-3512760452593454976m_-2926509009161831238gmail_msg" target="_blank">https://www.coreboot.org/mailm<wbr>an/listinfo/coreboot</a>
</blockquote>
</div>
</blockquote>
<p>
</p>
</div>
</div>
<span class="m_-3512760452593454976HOEnZb"><font color="#888888">
<div class="m_-3512760452593454976m_-2926509009161831238moz-signature">--
<b>/*===*/
Kind regards,
Riko Ho
/*===*/ </b></div>
</font></span></div>
--
coreboot mailing list: <a moz-do-not-send="true" href="mailto:coreboot@coreboot.org" target="_blank">coreboot@coreboot.org</a>
<a moz-do-not-send="true" href="https://www.coreboot.org/mailman/listinfo/coreboot" rel="noreferrer" target="_blank">https://www.coreboot.org/mailm<wbr>an/listinfo/coreboot</a>
</blockquote>
</div>
</div>
</blockquote>
<p>
</p>
<div class="m_-3512760452593454976moz-signature">--
<b>/*===*/
Kind regards,
Riko Ho
/*===*/
</b></div>
</div></div></div>
</blockquote></div>
</div>
</blockquote>
<p>
</p><div class="moz-signature">--
<b>/*===*/
Kind regards,
Riko Ho
/*===*/
</b></div></body></html>