/usr/share/doc/radare-doc/html/Chapter9.html is in radare-doc 1:1.5.2-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=US-ASCII">
<title>Plugins</title>
<link rel="previous" href="Chapter8.html">
<link rel="ToC" href="contents.html">
<link rel="next" href="Section9.1.html">
</head>
<body>
<h1><a name="plugins"></a>Chapter 9: Plugins</h1>
<p>
Radare can be extended in many ways. The most common is by using stdin/stdout get input from a file an interpret the output of the program execution as radare commands. stderr is used for direct user messaging, because it is not handled by the core and it is directly printed in the terminal.
</p>
<p>
But with this kind of plugins are not directly interactive, because the communication is one-way from the external program to radare. and the only way to get feedback from radare is by using pipes and files. For example:
</p>
<pre><code>$ cat interactive.rsc
#!/bin/sh
addr=$1
if [ -z "${addr}" ]; then
echo "No address given"
exit 1
fi
echo "p8 4 > tmpfile"
sleep 1
bytes=`cat tmpfile`
echo "wx ${bytes} @ ${addr}+4"
</code></pre>
<p>
What this 'dummy' script does is get an address as argument, read 4 bytes from there, and write them at address+4.
</p>
<p>
As you see this simple task becomes quite 'ugly' using this concepts, so its better to write a native plugin to get full access to the radare internals
</p>
<ul>
<li><a href="Section9.1.html#iobackend">9.1 IO backend</a></li>
<li><a href="Section9.2.html#plugins-io">9.2 IO plugins</a></li>
<li><a href="Section9.3.html#plugins-hack">9.3 Hack plugins</a>
<ul>
<li><a href="Section9.3.1.html#jmphacks">9.3.1 Jump hacks</a></li>
</ul></li>
</ul>
<!-- version IDs:
$Id: radare.but 2009-04-25 pancake $
-->
</body>
</html>
|