Kwort 3... The big change

Posted on: Sep 2009

Hello everybody. This is just a flashlight of what Kwort 3 will be. Kwort 3 brings a whole new era of Kwort Linux, Kwort public might change now, I'm not focusing anymore in inexperienced users, but on intermediate-advanced users and up.

Why is that? Well, kinda I'm forced to do that. Kwort's most important problem was always the kernel, not because Linux is bad, but because some drivers are. For example, wireless drivers tend to suck... I mean, WTH is that closed source microcode needed for most drivers? That's just plain wrong. I'm not talking here about making it free software, but open source would help everybody to make better drivers. Also there are tons of wireless cards out there unsupported (or half supported) because companies not releasing specifications, we are not even talking about open source anything here. COME ON! I'm not going to take this to the free software vs. open source vs. closed software, people who know me, knows that I hate those topics and I leave those to politicians and software philosophers.

Despite of that, some other things are not easy (as it should be) to support, and inexperienced users tend to not know what they want (first they want a desktop, then they want to be able to configure a web server with a GUI (that I'm not going to write) for some php scripting , then they want to create a RAID or LVM). Kwort was always meant to be for the desktop, and the desktop only, not a web server not a redundant file server, etc. And the funny part is: If you don't provide packages for what they want, they get pissed off and I've also got insults because of this. People, what is going on here? It's not like you're paying me (and if you would, that doesn't even give you the right to insult me), you can ask for something. I develop Kwort in my free time. So, advanced users tend to know a lot more, from the work that takes to do something like Kwort, to how to check logs and write or hack some script to do what they want (for example a network configuration script).

So... Kwort 3 is now based on CRUX which will make it more advanced. I'm not changing it to CRUX because I want it to be hard and for truly advanced users, but because Slackware has become a really multi-purpose distribution, and strip out all the "unneeded" stuff for Kwort would take me a lot of time. Also the init system has changed and the way it is configured too. Don't worry about all this, it is already well documented in the new website (this new one is really cool, with tons of information as it always should be but never was). There's no more wizards tools like knm (Kwort network manager) and kum (Kwort user manager), but a console and the chosen editor. Despite of that kum and knm will still be maintained and developed (kind of).

Anyways, Kwort 3 is almost ready be released. There's a beta release already that everyone can test (there are some testers already doing a great job that helped me a lot).

Sorry for not having you all up to date related to Kwort, but I've been working a lot and in my free time I try to develop Kwort. For example, now, I'm in my lunch time, and I passed out lunch in order to write something for you about the new direction of this project.


Thunar and hard drive partitions

Posted on: Jul 2009

Hello everybody, It's been so long since my last post here. There's so much to talk about, but today I'm going to talk about Thunar. As some of you might know, thunar is the file manager used in Xfce, written by Benedikt Meurer, and nowadays maintained by Jannis Pohlmann. I really like thunar, but the fact that hard drive partitions are left to the distribution itself when hal can manage them and because of that the file manager also can, isn't really nice, as you can browse your partitions in newer versions of GTK's (with Gvfs) GtkFileChooser. An ugly workaround would be to mount them and add some gtk bookmarks, but you would like to set an emblem to differentiate them from normal bookmarks, and emblems are not part of the gtk library, so you wouldn't see emblems in a GtkFileChooser. Another issue would be that isn't dynamic, so if someone change partitions that would be a total mess. So IMHO the best solution to this is: Hard Drive partitions managed by hal (DeviceKit in the future) and let Thunar show them in the left pane. And this is what I actually did.

So, as everybody loves screenshots and you probably want to see how this looks:

Thunar and partitions

And finally, the patch:


Kwort Linux 2.4.1 released

Posted on: Apr 2009

I'm happy to announce that Kwort 2.4.1 final is here!

This version took a year to develop and provides a lot of changes from 2.4 release, including a new, more cleaned up than usual, base system, whole new tool chain, new configuration tools and lots of new things.

Good things in this new version:

  • Kwort's init system: From 2.4, the init system has evolved keeping its simplicity but providing some new features.
  • Linux A lot of hardware support was included since the kernel included in Kwort 2.4.
  • Kpkg: The new version of kpkg include several new features as the adoption of multi-mirror support.
  • Kwort User Manager: Re-written from scratch it Provides a simple way to create and remove users with a new interface.
  • Kwort Network Manager: Also re-written from scratch, allows you to configure your network (wired and wireless), as manage your dns and hostname system. It also allows you to switch wireless drivers.
  • Xfce: This new version brings a lot of changes under the hood making the desktop more extensible.
  • Audacious: This is the default music player since Kwort 2.4.1 allowing you to play your music in a very simple way.
  • Our new Google group Ok, this has nothing to do with something included in the release, but it allows the developers behind Kwort to communicate between them and also with the users (who are what Kwort is all about).

As in every old version now comes the things that I look forward to improving:

  • Thunderbird: It's kind of sad, but thunderbird isn't yet full "xulrunnized", so starting firefox+thundebird brings two copies of xulrunner up to memory, which as we all know, is kinda in the chubby side.
  • Audacious: Although audacious is pretty good doing its job, I think a jukebox is more needed these days, as people needs more information while playing their music. It is known that using gstreamer would take out some of the features audacious brings, but we have a full-featured media-handling components and using those frameworks would allow the Linux desktop to improve, communicate between applications and to remain simple.

People who I would like to thank: Andreas Schipplock as always for making and maintaining the website, mirroring the Kwort iso image, and kind of playing a role of resources manager that allows me to develop easily Kwort. Sebastian Reisse for writing the kpkg manpage, and for taking a lot of his time testing every release candidate, if it wasn't for him, this release would come with several bugs. The Aircable people for their donations as they helped me to buy some hardware I was needing for develop Kwort. The mirror providers as usual, the people from PGHosting and Ricardo Brisighelli for the package mirror in the UNR. Finally, but not less important a very big THANKS to Patrick Volkerding for Slackware Linux, the system Kwort is based on. The Xfce developers (core and goodies) who made 4.6 a lot more simple to configure for distributions and provided help when needed. The people who develop every project Kwort includes. I hope I didn't forget anyone.

As usual, if you need support, help, or you just feel like talking about Kwort (or anything else), or you just want to meet the people who is behind Kwort, you can join us on IRC or our Google group:

IRC: irc://

Google Group:

Lots of stuff going on

Posted on: Feb 2009

Well, it's been 3 months since my last post, and I've been doing a lot...

Let's start with Kwort. Well we're just there from the release, lots of new improvements are being done around it, and something really interesting is the new network manager and the new user manager I wrote from scratch with a completely new design using gtkdialog.

The new network manager allows you to configure your ethernet and wireless network, supporting static and dhcp, for wireless network, support for several encryption mode are available, from wep to wpa2:

Network manager

The user manager stills very simple but with a very simple and smooth interface:

User manager

So, as you can see we have almost everything, since looking at the screenshot the Xfce settings manager is in it, so Xfce is kinda there, so you might be questioning "What are you waiting for a release?" Well, Xfce 4.6 is in release candidate time, so when they release it final we'll see how's the Mozilla people going with Firefox 3.1, since it would be really cool to ship it with Kwort 2.4.1. I wouldn't matter to ship a beta 3 with 2.4.1, but we'll see, since beta 3 should be released already according to Mozilla's Firefox schedule, and their delivery meeting is schedule to the end of the month (February 25th), which is just around the corner.

Resuming, lots of improvements are going on and I'm trying to make it pretty cool and easy for the end user.

That's just for Kwort, now... Some friends saw I was migrating to git, and yeah, I did, since in the past I used git with which didn't convinced me, I came back to darcs. But now, I discovered GitHub which is really cool, fast and easy to use and with lots of guides around, so you can see and follow my work at:

I have to admit here that I was influenced at work by warlock, which is the author of the wbar, to move from darcs to git, so I found a darcs2git python script and it was like charm.

Also, I implemented lots of cool new features for kpkg, and I merged kpkg with the kwort network manager and user manager making a "big" project called kwtools. Looking right now at the master tree page, you'll see this: "Implemented kpkg search /all with csv support" and you might be asking "What the hell is this guy making with kpkg implementing stuff like this?", well, I hope this feature is just enough, but basically, it is because a friend, x-ip, and I we are writing a graphical interface for kpkg, at the moment the interface is pretty rough but does show the idea, of course, icons and all that stuff is going to be implemented with also a more eye-candy interface, so you can see a preview of the application here:

kpkg graphical

As I said before and as you can see, the interface looks pretty rough, but give us some time and you'll see how cool it looks. I doubt we get in time to include this new tool in Kwort 2.4.1, we'll try, but I really doubt it since I'm just learning python, which is the language we use to write this, and x-ip is just learning wxPython with me, which is the framework we use for this.

Please, if you have any ideas for Kwort or any of the tools/applications I write, please write me, it would be nice to hear (read) about you and your ideas, and also, I don't know... help maybe? :-)

We'll, this post is already becoming large so I'm off to bed now. Have a nice week and see you around guys.


Posted on: Nov 2008

Well, it's been a long time in the road since my last post here. This weblog isn't over, but I been doing a lot of things and didn't got the time to write something.

Ok, things I've been doing: * I wrote a new network manager for Kwort 2.4.2 (I'm already working on a new Kwort version), screenshots are coming * I also wrote a new user manager for next Kwort also. Screenshots are ON the way. :-D * A friend of mine (Jp) is working on a new init system which is very cool, so Kwort will use it. * Bought a pretty cool (4 cores) new computer (Desktop). I would like to thank to the people who helped me to buy my new computer with a donation. (A BIG THANKS TO YOU GUYS) * Working... :-)

Anyways, I want here to point this link from my good old friend Andreas Schipplock, he made a small list of interesting links to read and/or hear.

Online video lectures

Btw, I took a position at iProgrammers and I'm working at Accenture now as a Senior Programmer.

NQqueue 0.3b

Posted on: Aug 2008

I'm just releasing NQqueue 0.3 beta. This is just a bug fix release and it is beta because of the new spamassassin plugin; I wrote this one on sunday, but since I don't use spamassassin (I have servers running dspam), I can't test it.

This is just a release asking for people to flood my inbox with feedback on the spamassassin plugin, the configuration parameters are the same used with the dspam plugin, so only "pass" parameter is allowed, or empty.

So, get latest NQqueue release here:

ktsuss 1.4 released

Posted on: Jul 2008

Well, the people of wicd asked me for some modifications in ktsuss so they could support it as they do with gksu. These modifications were made in the weekend; also bug fixes has been done, and as it looks very stable I'm writing a post release announce here. :-)

Changelog can be found here

Also, you can follow ktsuss development in my darcs server here

Latest ktsuss download link here

Bugs and feature requests are always welcome :-)


NQqueue 0.2

Posted on: Jul 2008

Well, I just tagged NQqueue as 0.2. Several changes has been done from 0.1. For those who doesn't know, NQqueue is a threaded queue for qmail with support for plugins. Full details of what nqqueue is can be found here:

Download the latest release version here:

Changelog can be found here:

If you want to get nightly builds packages. Use this link:

Darcs repository:

NQqueue stills in development, it is stable enough, but there are some things that must be fixed before the next release.

Plugins included:

  1. General plugins:

    • black - Parameters:

      • user@domain - email address to put in the blacklist.
    • clamav - Parameters:

      • "pass" - will make the email pass even if it contains a virus (used to send it to a quarantine).
      • None parameter given will block a containing virus mail.
  2. User plugins:

    • dspam - Parameters:

      • "pass" - will make the email pass even if it considered spam (used to send it to a quarantine).
      • None parameter given will block a spam considered email.
    • quarantine - Parameters:

      • "all" - will send to quarantine any email that was considered spam or that contains a virus.
      • "dspam" will send to quarantine any email that was considered spam.
      • "clamav" - will send to quarantine any email that contains a virus.
      • "q=" - allow the administrator to set the quarantine type. Allowed types of quarantines are:
      • general - will put the email in /var/qmail/nqqueue/quarantine.
      • vquad(VHOME) - will put the email in your vpopmail home (ex: vquad(.Spam), will put your email in Maildir/.Spam/cur). [vpopmail support must be given in configure script]

Example of common usage: This example shown here will block an incoming email from, put emails containing virus to general quarantine (in /var/qmail/nqqueue/quarantine/domain/user), and deliver spam considered emails in Maildir/.Spam/new (which is the personal user spam directory in his vpopmail home).

  • /var/qmail/control/general.cfb
  • /var/qmail/control/

I hope people start using nqqueue, since it is fast, secure, flexible and very easy to use.

NQqueue? What is that?

Posted on: Jun 2008

As some people asked me the last few weeks what I've been doing I've decided to take some time to write this and explain what NQqueue (aka nqq) is all about. Well, some of you maybe listened (or read) me telling that queues for qmail are bloated. We don't have several choices, there is just plain qmail-queue which is unfeatured, qmail-scanner (aka give me my CPU back) which is the bloatest one, and simscan which is kind of featured, fast, but not extensible at all, both of the last ones are buggy when getting an email with several Rcpts (they only analyze one. Which is a big bug). So, because of all this, I've been using simscan, I actually extended it from those 2000 lines to 4000 adding features. But it became so big, that it is hard to maintain and to trace errors in it. This situation drove me nuts the last year so I decided "Why I don't just write my own qmail queue?". Well, NQqueue is the result of this self asked question.

Let me show you and tell you some of the features of NQq:

  • Modular - not like simscan with a big file with all the problem.
  • Pluggable - this is what NQq is all about, it support the addition of plugins. There are some now in the darcs server.
  • Threaded - this is quite a nice feature for mails with several Rcpts, nqqueue triggers a thread for every Rcpt to be analyzed.
  • Fast - This is like simscan. But it improves it when analyzing more than one Rcpt because of the threads.
  • Secure and reliable - I been working quite a lot on this, since simscan has several bugs, and I didn't want this on NQq.

Plugins: Well, some of you might be asking "Dude, nice, but how do I write a plugin for NQq?". Well, first of all, I have to tell you that there are two types of plugins: 1st. we have the general plugins. Those plugins are run to an email before to trigger all the threads for every rcpt. Why is this? Well, it would be dumb to call for example a clamav plugin for every user (in every thread). So for example we can write a plugin that should not care about the Rcpts and/or From, like clamav, since it depends on a general database. 2nd. besides of general plugins, there are also per user plugins. These plugins are run in every thread. This is the example of a spam plugin, since it depends on a special per user database.

So now I can show you a small general plugin to block a Sender:

/* vim: set sw=4 sts=4 : */

#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <nqqueue.h>

#define PLUGIN_VERSION "1.0"
#define PLUGIN_NAME "black"
#define REJECTED_MESSAGE "Message rejected because of black list"

char *plugin_name()
    return strdup(PLUGIN_NAME);

char *plugin_version()
    return strdup(PLUGIN_VERSION);

/* Parameters:
 * params = a char pointer with parameters used to call the module (in this case, the email address to block).
 * mail = It's a char pointer to the filename that contains the email.
 * From = a char pointer with the From email address. (if it matchs the param, the mail would be blocked)
 * Rcpt = an union that contains space for a char pointer (if user pluing) or a pointer to a PUStruct
 *        struct (if general plugin).
 * general = a pointer to a RSStruct struct, which is structure with all the plugins and its return values
 *           already runned by general plugins
 * peruser = a pointer to a RSStruct struct, which is structure with all the plugins and its return values
 *           already runned by per user plugins
struct ModReturn *plugin_init(char *params, const char *mail, const char *From, const union Tos Rcpt, \
                              struct RSStruct *general, struct RSStruct *peruser)
    struct ModReturn *ret = malloc(sizeof(struct ModReturn));

    ret->NewFile = NULL;
    if (!strcmp(params, From)) {
        ret->ret = 1;
        ret->rejected = 1;
        ret->message = strdup(REJECTED_MESSAGE);
    else {
        ret->ret = 0;
        ret->rejected = 0;
        ret->message = NULL;
    return ret;

Looks easy don't you think? So, how do we make NQqueue to load our plugin? Simple: in /var/qmail/control/general.cfb put a line like this:

That will set the sender as a blocked server. In fact, this plugin acts just like a black list. Now your question might be: And how can I block more? Well, you can call the plugin several times, like this:;

Or you can modify the plugin_init function to allow more than one email (like, and do some simple parsing with strtok.

As you can see it is very easy to write plugins for NQqueue. I know it stills need a lot of documentation, since at it is now, it's very poor in this aspect. The only documentation in NQqueue so far is a configuration scheme in the NQqueue darcs in case you want to know how to configure it right (it's very easy).

So, those are some of the features in NQqueue there are more of course, but those are enough to mention. NQqueue needs a lot of testing, so I'm counting with all of you to run tests. Also documentation is needed, and it will take some time to me to write it, so people wanting to write documentation are welcome. Also people writing plugins, I wrote some which are already in my darcs server (a dspam, clamav, blacklist and quarantine) modules.

You can follow NQqueue's development in my darcs server at:

Hanging up switches and bridges

Posted on: Apr 2008

This issue came up today with some people and I did affirmed that you can hang up your switch with some funny code... How this come? Well, very simple, switches and bridges has a small stack (10 bytes per host connected to it) where they save IP and MAC addresses to know where to send a package once the sender and the receiver are known. So, once the first package is sent, a new entry in the stack was made. So now you know the "theory" I'll leave you to think how could this help you to hang it (Let me give you a hint: OVERFLOW).

Anyways, get the code you'll need to produce this overflow from here:

Keep in mind that you'll need the pktgen kernel module to run this. See also that I did this 3 years ago with bash, not even C code, so it shows how easy is to generate network packages to produce this effect, which isn't a big deal when it comes to reproduce it, but to create a security policy to avoid it.

Have fun.