select * from section<?xml version='1.0' encoding='iso-8859-1' ?>
<article>
<id><![CDATA[9]]>></id>
<author><nick><![CDATA[Juan M. Casillas]]>></nick>
<email><![CDATA[juanm.casillas@jmcresearch.com]]>></email>
></author>
<title><![CDATA[Adding software to Jail]]>></title>
<subtitle><![CDATA[Or how to invoke addjailsw]]>></subtitle>
<body><![CDATA[&lt;p&gt;
addjailsw will copy the programs and the dependencies (libraries, auxiliar files,
special devices) into the right places in the chrooted environment.
addjailsw has been written in perl script. This are the command line arguments:
&lt;/p&gt;

&lt;p&gt;
&lt;b&gt;addjailsw&lt;/b&gt; chrootdir [-D] [-P program args]

&lt;table  border=1 width=100% cellpadding=5 class=thinborder&gt;

&lt;tr bgcolor=&quot;#f0f0f0&quot;&gt;
   &lt;td class=thinborder_title&gt;&lt;b&gt;Argument&lt;/b&gt;&lt;/td&gt;
   &lt;td class=thinborder_title width=60%&gt;&lt;b&gt;Description&lt;/b&gt;&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
 &lt;td&gt;chrootdir&lt;/td&gt;
 &lt;td&gt;
     The directory where the chrooted environment will live. It its the home
     entry in the non-chrooted /etc/passwd file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
 &lt;td&gt;-P program args (optional)&lt;/td&gt;
 &lt;td&gt;
     installs the specific program &quot;program&quot; into the chrooted environment. The script
     uses the &quot;args&quot; parameter to launch the program where doing the strace command,
     to allows the program exit nicely, so the strace can do its work. If this parameter
     isn?t specified, the standard programs included in the file will be installed. See
     addjailsw?s code for in-deep details.
&lt;/td&gt;
&lt;/tr&gt;


&lt;/table&gt;
&lt;p&gt;
&lt;b&gt;Invocation examples: &lt;/b&gt;
&lt;p&gt;&lt;pre&gt;addjailsw /var/chroot&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre&gt;addjailsw /var/chroot -D&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre&gt;addjailsw /var/chroot -P vi &quot;-c q&quot;&lt;/pre&gt;&lt;/p&gt;


&lt;p&gt;
The first invocation will add the standard programs under the /var/choot
directory. The second invocation will do the same that first?s but also
will show what files are going to be copied in /var/chroot. Last, the
third invocation will install only the program vi, and when launched in
the strace call, the arguments &quot;-c q&quot; will be passed to it (so vi will
exit inmediatly).
&lt;/p&gt;
&lt;/p&gt;
]]>></body>
<keywords><![CDATA[Jail configuration add software]]>></keywords>
<stamp><![CDATA[1061910648]]>></stamp>
<updated><![CDATA[1070911507]]>></updated>
<language><![CDATA[0]]>></language>
<sections><section><![CDATA[Jail]]></section>
></sections>
<site><![CDATA[http://www.jmcresearch.com]]>></site>
<url><![CDATA[http://www.jmcresearch.com//src/articlehelper.php?action=preview&amp;id=9]]>></url>
</article>