<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE rss [<!ENTITY % HTMLlat1 PUBLIC "-//W3C//ENTITIES Latin 1 for XHTML//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml-lat1.ent">]>
<rss version="2.0" xml:base="http://sysd.org/stas">
<channel>
 <title>stas&#039;den - linux</title>
 <link>http://sysd.org/stas/taxonomy/term/11/0</link>
 <description></description>
 <language>en</language>
<item>
 <title>&quot;keyboard injection&quot; under Linux</title>
 <link>http://sysd.org/stas/node/151</link>
 <description>&lt;p&gt;
What to do if you want to pass some data into STDIN of some process,
and it doesn&#039;t accepts it?! One of the most (un)famous example is &lt;code&gt;ssh&lt;/code&gt;;
who never tried to do a &lt;code&gt;&quot;echo password | ssh host&quot;&lt;/code&gt;?!
So,&amp;nbsp;you just want to inject characters as there were someone
typing them. Remember: &lt;b&gt;TIOCSTI&lt;/b&gt; ioctl() call is your
friend &lt;img src=&quot;misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; /&gt;&lt;br&gt;
Just &lt;a href=&quot;http://www.google.com/search?q=ioctl+TIOCSTI&quot;
 target=&quot;_blank&quot;&gt;google it&lt;/a&gt; to see what
it&amp;nbsp;does. And now, some actually working code:&lt;br&gt;
&lt;/p&gt;
&lt;p&gt;
&lt;/p&gt;
&lt;pre&gt;#!/usr/bin/perl -w&lt;br&gt;use strict;&lt;br&gt;use Fcntl;&lt;br&gt;use constant TIOCSTI =&amp;gt; 0x5412;&lt;br&gt;&lt;br&gt;unless (@ARGV &amp;gt;= 1) {&lt;br&gt; print &quot;usage: $0 [vt] &amp;lt;input&amp;gt;\n&quot;;&lt;br&gt; exit;&lt;br&gt;}&lt;br&gt;&lt;br&gt;my $vt = shift @ARGV;&lt;br&gt;my $buf = join &#039;&#039;, &amp;lt;&amp;gt;;&lt;br&gt;&amp;amp;writevt ($vt, $buf) || die &quot;can&#039;t write to $vt: $!\n&quot;;&lt;br&gt;exit;&lt;br&gt;&lt;br&gt;&lt;br&gt;sub writevt {&lt;br&gt; my ($vt, $buf) = @_;&lt;br&gt; sysopen (VT, $vt, O_RDONLY) || return 0;&lt;br&gt; for (my $i = 0; $i &amp;lt; length $buf; $i++) {&lt;br&gt; ioctl (VT, TIOCSTI, substr ($buf, $i, 1)) || return 0;&lt;br&gt; }&lt;br&gt; close (VT) || return 0;&lt;br&gt; return 1;&lt;br&gt;} &lt;br&gt;&lt;/pre&gt;
&lt;p&gt;
And this is how it works (Linux-specific!!!):
&lt;/p&gt;
&lt;p&gt;
&lt;/p&gt;
&lt;pre&gt;[stas@home stas]$ echo id | ./catvt.pl /dev/pts/0&lt;br&gt;id&lt;br&gt;[stas@home stas]$ id&lt;br&gt;uid=?????(stas) gid=?????(stas) groups=?????(stas)&lt;br&gt;&lt;/pre&gt;
&lt;p&gt;
Kinda awesome &lt;img src=&quot;misc/smileys/lol.png&quot; title=&quot;Laughing out loud&quot; alt=&quot;Laughing out loud&quot; /&gt;
&lt;/p&gt;
</description>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/18">hack</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/20">perl</category>
 <pubDate>Wed, 15 Aug 2007 21:20:27 -0300</pubDate>
</item>
<item>
 <title>X11 FrontEnd for the Rio Utility</title>
 <link>http://sysd.org/stas/node/107</link>
 <description>&lt;p&gt;&lt;img
 style=&quot;width: 640px; height: 480px;&quot; alt=&quot;XRio FrontEnd&quot;
 src=&quot;http://sysd.org/stas/files/active/0/xrio.jpg&quot;&gt;&lt;/p&gt;
&lt;p&gt;X11 FrontEnd
for the &lt;a href=&quot;http://www.world.co.uk/sba/rio.html&quot;&gt;Rio
Utility v1.07&lt;/a&gt; made by guys from the
&lt;a href=&quot;http://www.world.co.uk/sba/&quot; target=&quot;_blank&quot;&gt;Snowblind
Alliance&lt;/a&gt;.
Surely not the best nor the most beautiful of all GUIs made to manage
the famous Rio MP3 Player,
but I tried to implement some of the ideas that the &quot;real&quot; managers
doesn&#039;t implement.
List of some &quot;interesting&quot; features:
&lt;/p&gt;&lt;ul&gt;&lt;li&gt;2 windows side-by-side like in &lt;i&gt;Norton
Commander&lt;/i&gt; legacy managers&lt;/li&gt;
&lt;li&gt;treats M3U playlists as directories&lt;/li&gt;
&lt;li&gt;displays the&amp;nbsp;space remaining on the device as you
select files to upload&lt;/li&gt;
&lt;li&gt;current file &amp;amp; overall progress bars&lt;/li&gt;
&lt;li&gt;realtime display of the transfer speed&lt;/li&gt;
&lt;/ul&gt;Note that you need&amp;nbsp;Tk8.0 extension for Perl (and
the &lt;a href=&quot;http://www.perl.com/&quot;&gt;Perl&lt;/a&gt; itself)
to get this frontend running! The GUI works under&amp;nbsp;&lt;a
 href=&quot;http://activestate.com/Products/ActivePerl/&quot;&gt;ActivePerl&lt;/a&gt;
Win32 environment out-of-shelf, but I haven&#039;t tested if the interaction
with
the &lt;code&gt;rio.exe&lt;/code&gt; is OK. You can download it &lt;a
 href=&quot;http://sysd.org/stas/node/41&quot;&gt;here&lt;/a&gt; and test
for yourself! However, I would suggest you to use my &lt;a
 href=&quot;http://sysd.org/stas/node/41&quot;&gt;Diamond Rio PMP300
FS-plugin&lt;/a&gt; for &lt;a href=&quot;http://www.ghisler.com/&quot;&gt;Total
Commander&lt;/a&gt;.&lt;p&gt;
&lt;b&gt;P.S. -&lt;/b&gt; if you get problems downloading files with
long names,
apply the patch I provided below on the Rio Utility source (&lt;b&gt;not
XRio itself!&lt;/b&gt;) and recompile it.&lt;/p&gt;
</description>
 <category domain="http://sysd.org/stas/taxonomy/term/9">addon</category>
 <category domain="http://sysd.org/stas/taxonomy/term/13">GUI</category>
 <category domain="http://sysd.org/stas/taxonomy/term/5">hardware</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/20">perl</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <category domain="http://sysd.org/stas/taxonomy/term/12">windows</category>
 <pubDate>Mon, 08 Jan 2007 10:37:08 -0200</pubDate>
</item>
<item>
 <title>ACFTools (for X-Plane)</title>
 <link>http://sysd.org/stas/node/46</link>
 <description>&lt;br&gt;


&lt;div align=&quot;center&quot;&gt;&lt;a href=&quot;http://sysd.org/stas/files/active/0/shot.png&quot;&gt;&lt;img alt=&quot;ACFTools screenshot&quot; src=&quot;http://sysd.org/stas/files/active/0/shot_t.jpg&quot; border=&quot;0&quot; height=&quot;480&quot; width=&quot;640&quot;&gt;&lt;/a&gt;&lt;br&gt;
&lt;/div&gt;


&lt;br&gt;


The &lt;b&gt;Plane-Maker&lt;/b&gt; from &lt;a href=&quot;http://x-plane.com/&quot;&gt;X-Plane&lt;/a&gt;
v7.x is fun and easy to use... Although I found it a bit limited to
edit my planes&#039; fuselage. 20 cross-sections aren&#039;t enough, sometimes.
It would be nice to export the fuselage shape into any 3D-editor and
fine-tune it there... This is exactly what my ACFTools are supposed to
do. Please note that X-Plane v8.x is unsupported, unless you create &amp;amp; edit a v7
model and then import it to Plane-Maker v8. But I believe this isn&#039;t a
problem: X-Plane v8 is able to use OBJ format files (which can be
imported/exported by &lt;a href=&quot;http://scenery.x-plane.com/tools.php&quot;&gt;AC3D&lt;/a&gt; and &lt;a href=&quot;http://marginal.org.uk/x-planescenery/tools.html&quot;&gt;Blender&lt;/a&gt; plugins) as parts of an aircraft, thus, extremely weird shapes are perfectly possible without even touching the ACF file.&lt;br&gt;


Now, what exactly ACFTools does? It is able to process the file that
stores all the aircraft data (except the textures), in the binary ACF
format, and dump all the data in the human-readable TXT format. It is the
same format as for Tony Gondola&#039;s ACF2Text utility, which inspirited my
ACFTools. Then, ACFTools can extract the 3D model of the aircraft from
this data, and export it in the &lt;a href=&quot;http://www.ac3d.org&quot;&gt;AC3D&lt;/a&gt; format. After that you can edit the aircraft&#039;s shape as you want using AC3D and make the inverse process: from &lt;code&gt;.ac&lt;/code&gt; to &lt;code&gt;.txt&lt;/code&gt;, and then from &lt;code&gt;.txt&lt;/code&gt; to &lt;code&gt;.acf&lt;/code&gt;. Here comes the brief set of ACFTools features:&lt;br&gt;


&lt;ul&gt;


  &lt;li&gt;Convert from ACF (aircraft) &amp;amp; WPN (weapon) formats to TXT format and vice-versa.&lt;br&gt;
  &lt;/li&gt;
  &lt;li&gt;Extract AC3D model from TXT file, along with wings and propellers (using the real airfoils!).&lt;/li&gt;
  &lt;li&gt;Import AC3D model into TXT file (fuselage, nacelles, wheel fairings &amp;amp; external fuel tanks only)&lt;br&gt;
  &lt;/li&gt;
&lt;/ul&gt;


3D model extractor is also useful if you want to use X-Plane generated
aircrafts somewhere else; as in your own Computer Graphics compositions.&lt;br&gt;


ACFTools was written in &lt;a href=&quot;http://www.perl.org/get.html&quot;&gt;Perl&lt;/a&gt;,
thus it is able to work under Linux, MacOS &amp;amp; Windows. And it is
Open-Source &amp;amp; highly modular, so you can modify it as you want, or
use my functions for your own needs. When you start ACFTools, this is
what you get at your console:&lt;br&gt;


&lt;pre&gt;##############################################################################&lt;br&gt;[ACFTools v0.62a] Set of tools to play with ACF files outside of Plane-Maker&lt;br&gt;Perl script and modules coded by Stanislaw Pusep &lt;stas @sysd.org=&quot;&quot;&gt;&lt;br&gt;Site of this and another X-Plane projects of mine: http://xplane.sysd.org/&lt;br&gt;&lt;br&gt;Allows you to:&lt;br&gt; * export X-Plane (www.x-plane.com) aircraft data files to human-editable&lt;br&gt;   plaintext format and 3D mesh editable in AC3D modeler (www.ac3d.org).&lt;br&gt; * import plaintext/3D mesh back to ACF file.&lt;br&gt;##############################################################################&lt;br&gt;&lt;br&gt;Usage: acftools.exe &lt;commands&gt; [parameters]&lt;br&gt; o Commands:&lt;br&gt;	-extract [DEF]	: extract TXT from ACF (opt: using DEF definition)&lt;br&gt;        -generate       : generate ACF from TXT&lt;br&gt;        -merge          : merge body from AC3D file to TXT&lt;br&gt; o Parameters:&lt;br&gt;        -acffile FILE   : name of ACF file to process&lt;br&gt;        -txtfile FILE   : name of TXT file to process&lt;br&gt;        -ac3dfile FILE  : name of AC3D file to process&lt;br&gt;        -noorder        : DO NOT sort vertices while merging bodies&lt;br&gt;        -noac3d         : DO NOT generate AC3D&lt;br&gt;        -(min|max)body N: write all bodies in specified range to AC3D&lt;br&gt;        -force LIST     : force extraction of bodies LIST (comma-separated N)&lt;br&gt;        -normalize N    : normalize wings to N vert/surface (N&amp;gt;=2 or no wings!)&lt;br&gt; o Notes:&lt;br&gt;        * You can use abbreviations of commands/parameters (-gen or even -g&lt;br&gt;          instead of -generate).&lt;br&gt;        * The only required parameter for &quot;extract&quot; command is -acffile.&lt;br&gt;          Both -txtfile and -ac3dfile are derivated from it.&lt;br&gt;        * &quot;generate&quot; command and -txtfile has the same relation.&lt;br&gt;        * By default &quot;extract&quot; uses the latest DEF file.&lt;br&gt;        * &quot;generate&quot; doesn&#039;t need DEF at all (it is implicit in TXT)&lt;br&gt;        * If file to be created already exists backup is made automatically.&lt;br&gt; o Examples:&lt;br&gt;        acftools.exe --extract=ACF700 --acffile=&quot;F-22 Raptor.acf&quot;&lt;br&gt;        (extract &#039;F-22 Raptor.txt&#039; from &#039;F-22 Raptor.acf&#039;)&lt;br&gt;&lt;br&gt;        acftools.exe -e -acf &quot;F-22 Raptor.acf&quot;&lt;br&gt;        (same as above)&lt;br&gt;&lt;br&gt;        acftools.exe -me -ac3d ladar.ac -txt &quot;F-22 Raptor.txt&quot;&lt;br&gt;        (merge *single* 3D body from &#039;ladar.ac&#039; to &#039;F-22 Raptor.txt&#039;)&lt;br&gt;&lt;br&gt;        acftools.exe -g -txt &quot;F-22 Raptor.txt&quot;&lt;br&gt;        (reverse operation; generate &#039;F-22 Raptor.acf&#039; from &#039;F-22 Raptor.txt&#039;)&lt;br&gt;&lt;/commands&gt;&lt;/stas&gt;&lt;/pre&gt;


The most important thing you should know is that to convert from the
binary ACF format to TXT, ACFTools uses one of the files stored in the &lt;code&gt;defs&lt;/code&gt; directory. By default, it is a &lt;code&gt;ACF740.def&lt;/code&gt;,
which works for X-Plane v7.40 and later. You can specify any definition
file you want, as shown on the screen above. You can also write your
own definition files, if you have the structure specification. Note
that to convert TXT back to ACF, no definition is necessary, as the TXT
format itself holds all the data necessary to build the binary file.
The second thing is to specify the file that ACFTools should convert.
The name of the converted file and every of the intermediary files will
be generated from this name. When converting from ACF to AC3D formats,
TXT file is generated automatically. Please note that when you want to
put the edited aircraft part back into the &lt;code&gt;.acf&lt;/code&gt; file, you must save this part as a &lt;code&gt;.ac&lt;/code&gt;
separate file, then merge it into the TXT file, and after that convert
it into ACF! Yes, it would be nice to have a GUI to automate the entire
process, but I&#039;m too lazy to do that! Anyway, may the source be with you
&lt;img src=&quot;misc/smileys/wink.png&quot; title=&quot;Eye-wink&quot; alt=&quot;Eye-wink&quot; /&gt;&lt;br&gt;


I strongly recommend you to read the &lt;code&gt;docs\README.txt&lt;/code&gt; file contained in the ACFTools package before you start using it!&lt;br&gt;</description>
 <category domain="http://sysd.org/stas/taxonomy/term/9">addon</category>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/29">game</category>
 <category domain="http://sysd.org/stas/taxonomy/term/18">hack</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/20">perl</category>
 <category domain="http://sysd.org/stas/taxonomy/term/28">simulation</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <category domain="http://sysd.org/stas/taxonomy/term/12">windows</category>
 <pubDate>Wed, 10 May 2006 01:09:12 -0300</pubDate>
</item>
<item>
 <title>&quot;ps auwx&quot; faker</title>
 <link>http://sysd.org/stas/node/37</link>
 <description>&lt;p&gt;
&quot;Process Stack Faker&quot; (&lt;code&gt;psf&lt;/code&gt; for short) is able to hide the real executable name and it&#039;s parameters from the output of &lt;code&gt;&quot;ps auwx&quot;&lt;/code&gt;, &lt;code&gt;&quot;ps -ef&quot;&lt;/code&gt; &amp;amp; &lt;code&gt;&quot;top&quot;&lt;/code&gt;
(on UN*X machines), without any superuser privileges. Why should one
wish to hide the stuff he/she executes is a complete different topic &lt;img src=&quot;misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; /&gt;&lt;br&gt;
Let&#039;s take a look at the options that &lt;code&gt;psf&lt;/code&gt; itself accepts:&lt;br&gt;
&lt;pre&gt;$ ./psf&lt;br&gt;Process Stack Faker (a.k.a. Fucker) v0.03&lt;br&gt;Coded by Stas; (C)opyLeft by SysD Destructive Labs, 1997-2003&lt;br&gt;&lt;br&gt;Usage: psf [options] command arg1 arg2 ...&lt;br&gt;Where options can be:&lt;br&gt;-s string fake process name&lt;br&gt;-p filename file to write PID of spawned process - optional&lt;br&gt;-d try to start as daemon (in background, no tty) - optional&lt;br&gt;-l DO NOT exec through link (detectable by &#039;top&#039;!!!) - optional&lt;br&gt;-u uid[:gid] (format just like in chown(1)) reset UID/GID - optional&lt;br&gt;-n priority renice process - optional&lt;br&gt;&lt;br&gt;Example: psf -s &quot;pine -i&quot; -d -n 19 ./john -session:websrv&lt;br&gt;$&lt;br&gt;&lt;/pre&gt;
I hope this is self-explanatory. &lt;code&gt;psf&lt;/code&gt; will execute &lt;code&gt;&quot;command arg1 arg2&quot;&lt;/code&gt;, and it will appear to &lt;code&gt;&quot;ps&quot;&lt;/code&gt; &amp;amp; &lt;code&gt;&quot;top&quot;&lt;/code&gt; utilities as &lt;code&gt;&quot;string&quot;&lt;/code&gt;. All other options are... Uhm, optional! They are only useful to detach processes not designed to run as daemons. &lt;code&gt;&quot;-l&quot;&lt;/code&gt;
is a &#039;compatibility&#039; switch that disables the weird trick used to
override the detection of the real filename by some process listers
(notably &lt;code&gt;&quot;top&quot;&lt;/code&gt;). The default option may work unexpectingly on some systems (by the way, &lt;code&gt;psf&lt;/code&gt; works fine on FreeBSD 4.3, Linux 2.4, NetBSD 1.5 &amp;amp; Solaris 2.7). To test &lt;code&gt;psf&lt;/code&gt;, try this:&lt;br&gt;
&lt;pre&gt;$ psf -s &quot;pine -i&quot; sleep 30 &amp;amp;&lt;br&gt;[1] 440&lt;br&gt;$ ps auwx&lt;br&gt;...&lt;br&gt;stas 84 0.0 0.6 2012 1232 pts/0 S 19:12 0:00 bash -rcfile .bashrc&lt;br&gt;stas 440 0.0 0.1 1204 376 tty2 S 20:09 0:00 pine -i&lt;br&gt;&lt;br&gt;stas 450 0.0 0.4 2544 816 tty2 R 20:12 0:00 ps auwx&lt;br&gt;...&lt;br&gt;&lt;/pre&gt;
&lt;code&gt;
&quot;sleep 30&quot;&lt;/code&gt; process was spoofed as &lt;code&gt;&quot;pine -i&quot;&lt;/code&gt;. Please note the white line between PIDs 440 and 450. This occurs because &lt;code&gt;psf&lt;/code&gt; uses whitespace (0x20) characters to shift the original process arguments away from the visible area &lt;img src=&quot;misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; /&gt;&lt;br&gt;
To understand how does &lt;code&gt;psf&lt;/code&gt; works and learn how to compile it, just read the comments inside the source.&lt;/p&gt;</description>
 <category domain="http://sysd.org/stas/taxonomy/term/19">C</category>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/18">hack</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <pubDate>Fri, 05 May 2006 01:57:41 -0300</pubDate>
</item>
<item>
 <title>ttysnoop for kernel 2.6</title>
 <link>http://sysd.org/stas/node/35</link>
 <description>&lt;i&gt;This project was made by a friend of mine, Vinicius Anselmo. He
discontinued it&#039;s development (as it showed to be incompatible with
later Linux kernels), so I proposed to host his work on my site.&lt;/i&gt;&lt;br&gt;
&lt;br&gt;

&lt;code&gt;ttysnoop&lt;/code&gt; is a small program made by Carl Declerck that allows an
administrator to snoop on login terminal through another. It worked until kernel 2.4 because they still with BSD-style &lt;code&gt;pty&lt;/code&gt;&#039;s
support. Here it is a solution for 2.6.&lt;br&gt;


&lt;br&gt;
&lt;h3&gt;Screenshot:&lt;/h3&gt;
&lt;center&gt;
&lt;img alt=&quot;ttysnoop usage screenshot&quot; src=&quot;http://sysd.org/stas/files/active/0/ttysnoop.jpg&quot; border=&quot;0&quot; height=&quot;480&quot; width=&quot;640&quot;&gt;
&lt;/center&gt;

&lt;br&gt;
&lt;h3&gt;SSH:&lt;/h3&gt;

Is ttysnoop compatible with &lt;code&gt;sshd&lt;/code&gt;? ttysnoop was created to work with &lt;code&gt;inetd&lt;/code&gt;, however,
there is a way to make it work with &lt;code&gt;sshd&lt;/code&gt;.&lt;br&gt;

First you will need the source code of the &lt;code&gt;sshd&lt;/code&gt;. Edit the file &lt;code&gt;configure&lt;/code&gt; and add these lines:&lt;br&gt;

&lt;pre&gt;LOGIN_PROGRAM=&quot;/sbin/ttysnoops&quot;&lt;br&gt;export LOGIN_PROGRAM&lt;br&gt;&lt;/pre&gt;

Now it is necessary to verify the paths, so that the new executable
uses the same configuration files of your system. For my system I solved making this modification in &lt;code&gt;pathnames.h&lt;/code&gt;:&lt;br&gt;

&lt;pre&gt;// #ifndef SSHDIR&lt;br&gt;#define SSHDIR	ETCDIR &quot;/ssh&quot;&lt;br&gt;// #endif&lt;br&gt;&lt;/pre&gt;

And executing the script configure specifying a null prefix:&lt;br&gt;

&lt;pre&gt;./configure --prefix=&lt;br&gt;&lt;/pre&gt;

Now compile the program. Make a backup copy of your &lt;code&gt;/usr/sbin/sshd&lt;/code&gt; and put your new &lt;code&gt;sshd&lt;/code&gt; in the
place. That should work. If you are using RedHat or Fedora Core you can try to use my
executable (&lt;a href=&quot;http://sysd.org/stas/node/35#attachments&quot;&gt;see below&lt;/a&gt;).&lt;br&gt;

&lt;br&gt;
&lt;h3&gt;Bugs:&lt;/h3&gt;

After log out, it doesn&#039;t remove the pseudo-terminal entry. Meaning
people showed up as still logged in when they weren&#039;t.&lt;br&gt;

I use: &lt;span style=&quot;font-style: italic;&quot;&gt;who -u | grep -v ?&lt;/span&gt;&lt;br&gt;

to see who really is on my system. I don&#039;t know how to solve it.&lt;br&gt;</description>
 <category domain="http://sysd.org/stas/taxonomy/term/19">C</category>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <pubDate>Thu, 04 May 2006 13:09:40 -0300</pubDate>
</item>
<item>
 <title>rockin&#039; PC speaker</title>
 <link>http://sysd.org/stas/node/23</link>
 <description>Well,
good old PC speaker is the only default hardware, easily available on
almost all PC systems, and virtually unmuteable (actually, one can
connect PC speaker output to his/her sound card instead of default
buzzer, but this rarely happens &lt;img src=&quot;misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; /&gt;. Thus, it is perfect for
communicating critical states. But the default system beep is quite
boring, and makes difficult to distinguish different events that are
being communicated. So, here&#039;s my humble attempt to make a highly
portable function that is able to play simple non-polyphonic music on
the PC speaker. I used it originally to advise when someone tried to
log in to my system through SSH daemon (thus the name &quot;daemoniac&quot; - &lt;code&gt;demoniac&lt;/code&gt; &lt;img src=&quot;misc/smileys/wink.png&quot; title=&quot;Eye-wink&quot; alt=&quot;Eye-wink&quot; /&gt;. It was tested (and worked fine!) under:
&lt;ul&gt;

&lt;li&gt;DOS (DJGPP, Turbo C)&lt;/li&gt;
&lt;li&gt;Windows 9x/NT/2K/XP (Borland C, Microsoft Visual C, MinGW)&lt;/li&gt;
&lt;li&gt;Linux (gcc)&lt;/li&gt;
&lt;li&gt;FreeBSD (gcc)&lt;/li&gt;
&lt;/ul&gt;

By default, &lt;code&gt;demoniac&lt;/code&gt; will play &lt;i&gt;Iron Maiden - Fear Of The Dark&lt;/i&gt; beginning. You can also compile it to play the simple &quot;A#4 D#5 G5 A#5 G5 A#5&quot; melody. Note that on UN*X systems, &lt;code&gt;demoniac&lt;/code&gt; accesses hardware directly, and thus requires to run as &lt;code&gt;root&lt;/code&gt; user. It&#039;s safe, through: it
won&#039;t accept any command line arguments and neither process environment
variables, so, at least, it can&#039;t be exploited with some buffer
overflow technique. For detailed instructions about compiling &lt;code&gt;demoniac&lt;/code&gt; on
different compilers/systems, read the comments at the start of the
source. Note that my package provides all the binaries generated on
compilers/systems listed above.&lt;br&gt;</description>
 <category domain="http://sysd.org/stas/taxonomy/term/19">C</category>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/5">hardware</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/30">music</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <category domain="http://sysd.org/stas/taxonomy/term/12">windows</category>
 <pubDate>Thu, 20 Apr 2006 02:06:04 -0300</pubDate>
</item>
<item>
 <title>knuckle cracker</title>
 <link>http://sysd.org/stas/node/9</link>
 <description>&lt;p&gt;
This project is a response to the urge to make small changes to the big binary files. For text files, there are &lt;code&gt;diff/patch&lt;/code&gt; utilities; and for big changes, &lt;code&gt;rsync&lt;/code&gt;
is perfect. Now, if&amp;nbsp; you&#039;re sharing something like a game mod,
where you need to swap a single bit inside a huge data file (just like
in a &lt;a href=&quot;http://en.wikipedia.org/wiki/Hot_coffee&quot; target=&quot;_blank&quot;&gt;Hot Coffee Mod&lt;/a&gt; for &lt;a href=&quot;http://en.wikipedia.org/wiki/Grand_Theft_Auto:_San_Andreas&quot; target=&quot;_blank&quot;&gt;GTA San Andreas&lt;/a&gt; &lt;code&gt;&lt;img src=&quot;misc/smileys/wink.png&quot; title=&quot;Eye-wink&quot; alt=&quot;Eye-wink&quot; /&gt;&lt;/code&gt;, you&#039;re frequently forced to share the entire file. By the other side, if you need to update some
firmware glitch, why should you rewrite the entire flash chip?! So, here&#039;s my proposal.&lt;br&gt;
&lt;code&gt;bin_diff&lt;/code&gt; utility will compare two binary files and output a human-readable (and writable &lt;img src=&quot;misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; /&gt; script file, just like this:&lt;br&gt;
&lt;pre&gt;[bb35cc23dda6737d181a63ea3203f0ff engine.dll]&lt;br&gt;50	&quot;This program must be run under Win32\xd\xa$&quot;&lt;br&gt;d60a	EB&lt;br&gt;d77b	90 90&lt;br&gt;da3f	E9&lt;br&gt;da41	1 0&lt;br&gt;ea44	90&lt;br&gt;# Patch length: 0000007A&lt;br&gt;&lt;/pre&gt;
First line contains a name of the file to be patched, and it&#039;s MD5
checksum value. Following lines start with a hex offset inside this
file, and the new byte(s) value. Note that strings with &lt;b&gt;C&lt;/b&gt;-like escaping style are supported! You may also comment each line, using the hash character (&lt;code&gt;#&lt;/code&gt;).
Several files may be patched by a single patch-script. The last string
in the last line is a hex value of the patch data length. It is useful
to make self-applicable patches.&lt;br&gt;
Then, &lt;code&gt;knuckle_cracker&lt;/code&gt; may be used to parse the
patch-script and apply modifications to the files. It will check the
MD5 checksum for each file automatically (and will refuse to patch unmatched files). You can also make the
self-applicable patches, concatenating the patch-script directly at the
end of the &lt;code&gt;knuckle_cracker&lt;/code&gt; executable (following example works on UN*X systems, for Windows box, use any hex editor, it works just the same):&lt;br&gt;
&lt;pre&gt;cat knuckle_cracker engine.bin_patch &amp;gt; engine_patcher&lt;br&gt;&lt;/pre&gt;
Both &lt;code&gt;bin_diff&lt;/code&gt; &amp;amp; &lt;code&gt;knuckle_cracker&lt;/code&gt; are very portable: I tested them on Linux, FreeBSD (gcc) &amp;amp; Win32 (Borland C/CYGWIN/MinGW/MSVC).
&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;P.S. -&lt;/b&gt; all sources has DOS line endings (CRLF), use&lt;br&gt;
&lt;code&gt;&quot;unzip -aa knuckle_cracker.zip&quot;&lt;/code&gt; to extract on UN*X systems.
&lt;/p&gt;
</description>
 <category domain="http://sysd.org/stas/taxonomy/term/19">C</category>
 <category domain="http://sysd.org/stas/taxonomy/term/14">console</category>
 <category domain="http://sysd.org/stas/taxonomy/term/18">hack</category>
 <category domain="http://sysd.org/stas/taxonomy/term/11">linux</category>
 <category domain="http://sysd.org/stas/taxonomy/term/10">opensource</category>
 <category domain="http://sysd.org/stas/taxonomy/term/4">software</category>
 <category domain="http://sysd.org/stas/taxonomy/term/12">windows</category>
 <pubDate>Wed, 19 Apr 2006 02:42:33 -0300</pubDate>
</item>
</channel>
</rss>
