libnotify over ssh
Posted by bene - 15/02/08 at 09:02:36 pmlibnotify is a nice desktop notification framework, very similar to Growl. It’s basically a client-server architecture: the desktop implements a notification-daemon where the clients send notifications to (via D-Bus).
In my case it’s notification-daemon-xfce and on the client side primarily galarm and pidgin (using a patched pidgin-libnotify plugin).
With notify-send you can also create your own notification. I wrote a little zsh wrapper function to get a notification when the command terminates:
# run some command and notify about the result via the notification-daemon
function run () {
$@
local error=$?
if [[ $error -eq 0 ]]; then
notify-send “`hostname -s` | terminated:” “$1 $2″ -i finish -t 0
else
notify-send “`hostname -s` | aborted:” “$1 $2″ -u critical -i undo -t 0
fi
return $error
}
The usage is quite simple:
# run sudo update-eix
All of this is nice but I decided to need notification of remote events as well.
I hate to wait or poll till a command on my server terminates, instead the server should notify me. ![]()
Additionally I run a WeeChat IRC-client 24/7 in screen and want a notification for (private) IRC messages.
Accomplishing my requirements is a tough task, but after some research I found this nice idea of Jared Quinn: libnotify-with-irssi-over-ssh.
The trick is to tunnel the notification through the terminal using the print pipe.
I adapted his scripts and patched them to fit my needs:
My favorite terminal is rxvt-unicode so the .Xdefaults entry looks a bit different:
URxvt.print-pipe: ~/scripts/unmarshal.pl
My unmarshal script collects the content of the pipe and sends the notification to the daemon:
unmarshal.pl (html)
…the WeeChat plugin (based on growl-notify):
…and finally the drop-in replacement for notify-send:
If notify-send is placed in /usr/local/bin/ on the remote host, you can just type something like run sudo updatedb and get a notification to the desk. ![]()
Blurminal
Posted by Nils - 13/02/08 at 01:02:00 am
Just tripped over this nice Terminal.app (10.5) plugin (via SIMBL) which does nothing else but blur the background of your windows, to let you have transparency in a way that doesn’t confuse you
Grab your copy here - thanks Ciarán!
Root exploit for Linux 2.6.24.1
Posted by micele - 11/02/08 at 12:02:34 pmIt’s time for a new local root exploit on the linux kernel. Two exploits have been reported. Both are based on leaky dealing with pointers regarding the function vmsplice, brought in by kernel release 2.6.17. For this reason one of the exploits works for all kernel versions from 2.6.17 to 2.6.24.1. Kernel Bug Tracker says:
Both exploits cause kernel Oops or (randomly) give root privilegies to the user.
A new kernel version 2.6.24.2 has been released and the regarding changelog reports a kind of fix. But comments like
But we also must check whether we can access the actual memory region pointed to by the struct iovec to fix the access checks properly.
still don’t sound like 100% fixed and reliable…
Fancy Zoom
Posted by Nils - 10/02/08 at 05:02:03 pmFancy Zoom is a great way of adding zoom capabilities to your website in a blink of an eye.
Javascript powered and cross-browser compatible.
Have a look at the demo-site!
To add fancy zoom to your site do the following easy steps:
1. Download Fancy Zoom over at cabel’s place
2. add upload the contents of the package to your webroot
3. add the following javascript files to your html pages:
4. enable the body to load the neccesary javascript stuff:
and you’re done!
from now on, every link to an image becomes zoomed. Even text-links to images!
thank you cabel for this great addition!
- Nils
How fast can you calculate?
Posted by bene - 08/02/08 at 11:02:32 pmHow fast can you calculate the square of a 5 digit number?
Arthur Benjamin does it in a few seconds.
I think this guy is an alien, especially because he has this strange cable behind his ear ![]()

FireGPG: web-based email en-, decrypting & signing
Posted by micele - 06/02/08 at 04:02:43 pmI often run into the problem of receiving encrypted mails but not be able to read it because I only have webmail access at this moment. Installing PGP plugins for webmailer like SquirrelMail always looked like a bad idea to me. Especially SquirrelMail hasn’t been the most secure peace of software out there and a place surrounded by all this php-web-foobar security leaks isn’t the best place for a private key. However there is another possibility of *crypting, signing and verifiying emails using webmail interfaces.
The FireFox extension FireGPG is a simple way to do all this pretty things. FireGPG just extends the FireFox context menu so that you can easily mark text inside textboxes and de- or encrypt it by mouseclick. Unfortunately GnuPG has to be installed.
It’s still a beta release but I suggest it’s stable enough to give it a try in secure enviroments. So get it!
Furthermore maybe this is a good choice for the Mac OS X 10.5 user. Somewhere I read that GPGMail doesn’t work with the toothless Leopard so far?!
Dec 9, 2007 - GPGMail & 10.5 (Leopard)
GPGMail doesn’t work yet on 10.5, and can’t work as-is. I’m currently working on the port, and published a beta version.
- micele
NTFS Alternate Data Streams
Posted by bene - 03/02/08 at 07:02:08 pmBei einer Diskussion auf der Vim Entwickler Mailingliste ist mir aufgefallen, dass ich noch nie etwas von den sogenannten NTFS Alternate Data Streams gehört habe. Kurz zusammengefasst ermöglichen sie das Speichern mehrerer Datenströme in einer Datei. Nun ist NTFS nicht gerade meine Welt aber nichtsdestotrotz scheint dieses Feature allgemein eher unbekannt zu sein. Schade eigentlich, denn ich halte es für eine sinnvolle Idee, die natürlich von Apple’s HFS stammt.
Interessant ist dabei, dass die weiteren Datenströme praktisch unsichtbar sind, wenn man ADS schlicht nicht kennt. Dem ein oder anderen wird jetzt schon ein schöner Nutzen aufgefallen sein und so demonstrierte Don Parker im Jahre 2005, wie man seine Werkzeuge nach einem Einbruch in ein Fremdsystem in einer unscheinbaren Datei versteckt, sodass diese möglichst unentdeckt bleiben.
Und da Programmierer auch nur Menschen sind, scheinen einige Antiviren Programme nicht in diesen Streams zu suchen. Bleibt nur zu hoffen dass die Hersteller inzwischen nachgebessert haben. Will das mal jemand überprüfen? ![]()
benchmarking ejabberd
Posted by bene - 02/02/08 at 05:02:52 am2 years ago friends of mine and I got rid of some horribly lagging public jabber servers like jabber.ccc.de. We decided to run our own “private” server.
We first used jabberd 1.4 which then suddenly stopped working after upgrading to Debian Etch in April ‘07. So we decided to give ejabberd a try. It is written in Erlang and therefore tends to be fault-tolerant and scalable even with hundreds of active users.
After running it for 10 months we’re pretty confident with ejabberd. I can not even remember typing something like /etc/init.d/ejabberd restart a single time
Motivated by a nice talk about Erlang on 24c3 I finally made it to ran a Tsung ejabberd benchmark tonight.
Since Tsung itself is written in Erlang, it can simulate hundreds or thousands of users.
I started setting up a bunch of users which Tsung uses to login:
for i in `seq 1 1000`;
echo $i && ejabberdctl register tsung$i jabber.example.com p4ssw0rd$i
In the next step you configure what and how Tsung benchmarks in ~/.tsung/tsung.xml
In my case I defined 300 users to be logged in at the same time, modifying their roster and of course exchanging some messages: tsung.xml (html).
Furthermore I configured three load levels with the intervals 0.01s, 0.1s and 1s (see the <load> section). You will clearly recognize them in the generated graphs.
So, here they are: the results
I guess the server and the benchmark could be tweaked, but the performance is already much over our needs
PS: ejabberd 2.0 is going to be released soon
PPS: tsung is not yet in portage so I wrote my own ebuild: tsung-1.2.1.ebuild
Microsoft > Yahoo
Posted by micele - 01/02/08 at 01:02:57 pmNow it seems to be official: Microsoft wants to take over Yahoo for about 44.6 Billion Dollar…
crazy shit!
Time moved backwards
Posted by micele - 30/01/08 at 06:01:41 pmHaving a look at certain log files, sometimes brings strange things forward. It seems that today especially one of my mail services has some interesting problems with the time wrap.
Jan 30 17:13:33: Time just moved backwards by 303 seconds. This might cause a lot of problems, so I’ll just kill myself now.
Well… maybe you got some problems with the black hole called NTP!?
Sometimes I really would like some politicians out there to have this kind of understanding.
- micele
Powered by WordPress with GimpStyle Theme design by Horacio Bella. Get Entries and comments.

