Yippie! My patch to the rails routing routines was accepted. It adds a feature similar to one that I have made extensive use of at work in Java servlets.
Posted by rayners | Comments (0) | TrackBack
Yippie! My patch to the rails routing routines was accepted. It adds a feature similar to one that I have made extensive use of at work in Java servlets.
Posted by rayners | Comments (0) | TrackBack
Recently, I have finally found some time to play around with some new geeky toys. Specifically, I brought SQLite up at work, which brought me to playing with it at home, which lead into finally starting to futz around with a Ruby on Rails application to see how it works. I have to say, I am more astonished with each day that I work with Rails. I'm always stumbling across something new each time I sit down and play with it some more.
Rails then lead me into an interesting new web server: lighttpd. I am so impressed with that, that I am planning on trying to migrate off Apache entirely and onto lighttpd instead (a problem with the most recent Apache, or at least the Debian apache2-mpm-prefork package, contributed to that as well somewhat). The only problem that I have with lighttpd currently is that it lacks something like mod-security, so I am writing my own plugin for lighttpd. It is currently working (just barely), and when I finally get more completely implemented (at the moment, it is only a blacklist for POST data), tested thorougly, and cleaned up, I will go ahead and release it to the public.
Posted by rayners | Comments (0) | TrackBack
I like to goof around with the email I send to my wife while she is at work. Mainly, I just switch the name her client displays to any number of our inside jokes. Yesterday, I implemented a way for mutt to pick one randomly.
First, I setup the send-hook:
send-hook "~C jenn@email.address" source ~/.mutt/for-jenn
Then, in ~/.mutt/for-jenn:
unmy_hdr From:
my_hdr From: \
`/usr/bin/perl /home/rayners/.mutt/from-names.pl` \
<my-home@email.address>
And, finally, the from-names.pl script:
#!/usr/bin/perl
@names = (
'Name 1',
'Name 2',
'Name 3',
);
print $names[rand @names];
So now whenever I start writing an email to her, the From: line of the email pops up with a different name.
Now, to make sure that normal emails from me are not affected, I placed the following send-hook before the earlier one:
send-hook . source ~/.mutt/from-rayners
And the ~/.mutt/from-rayners file:
unmy_hdr From:
my_hdr From: David Raynes <rayners@rayners.org>
Posted by rayners | Comments (0) | TrackBack
While I was speaking with Joi on IRC today, BitchX kept ignoring him (in all honesty though, he was pasting some stuff into messages to me, so they were coming in pretty quick). Anyways, after some digging, I found an undocumented command for turning off auto-ignore for a given nick:
/addnoflood nickname
Unfortunately, it appears that setting is not saved with the /save command, so I will need to add it to my ~/.bitchxrc file.
Posted by rayners | Comments (0) | TrackBack
I have been on IRC quite a bit lately, and I have been having some fun getting my current client, BitchX, working nicely. I have not done too much so far, but I have got a few more tricks up my sleeve.
First of all, the following in my ~/.bitchxrc file automatically validates me with NickServ on Freenode and Wyldryde:
# My "passwords"
assign FREENODE_PASSWORD password
assign WYLDRYDE_PASSWORD password
# Command to register with NickServ
# Sending the appropiate password to the network
alias nsreg {
userhost NickServ -cmd {
if ( rmatch($3@$4 NickServ@services.) ) {
echo NSREG: Sending FreeNode Credentials
^msg nickserv identify $FREENODE_PASSWORD
}
if ( rmatch($3@$4 services@wyldryde.net) ) {
echo NSREG: Sending WyldRyde Credientials
^msg nickserv identify $WYLDRYDE_PASSWORD
}
}
}
# Catch the notice from NickServ that the nick is registered
on ^notice 'NickServ This nickname is \\[owned registered\\]*' {
^nsreg
}
And finally, since there are many people who refer to me without using my nick (rayners), I put in the following code to catch other words and highlight those messages:
assign AR_WORDLIST david raynes dave rayners
on ^public '% % *\\[$AR_WORDLIST\\]*' {
echo $fparse(PUBLIC_AR "" $0 "" $2-)
}
I will probably add some more words later, but that is working well enough so far.
Posted by rayners | Comments (0) | TrackBack
As I have mentioned before, the Plugin Manager made it into the FreeBSD ports system. The update to the port that I submitted has been incorporated, and (as I did request it) I have been assigned to maintain the port (view the commit message if you're curious). So, for all you FreeBSD MT users:
cd /usr/ports/www/MT-PM/ && sudo make build install clean
Or, like I like to do:
sudo portinstall MT-PM
Enjoy!
Posted by rayners | Comments (1) | TrackBack
It would appear that I have achieved a new level in geekhood. I discovered this week that my little pet project, the Plugin Manager has been added to the FreeBSD ports system. It is an older version, but I have already tried to notify the port maintainers. Hopefully it will be updated soon.
So, for all you FreeBSD + MT users, enjoy!
(Oh, and there is a MT port as well)
Posted by rayners | Comments (1) | TrackBack
Normally, I cryptographically sign all my outgoing emails with GnuPG. Unfortunately, Outlook Express does not handle those signature attachments all too well. It has even gone so far as to mark those attachments as unsafe (as relayed to me in a recent email).
So, I have come up with the following additions to my mutt config file to handle this situation:
message-hook ~A "set pgp_autosign"
message-hook "~h 'X-Mailer: Microsoft Outlook Express'" "set nopgp_autosign"
Unfortunately, to make sure this is used, I need to be reading the message when I reply to it, instead of just hitting the reply key in the header list.
True, I could tell mutt to use the old-style cryptographic signatures (with pgp_create_traditional), but I feel like I am trying to make a point here. :)
Posted by rayners | Comments (3) | TrackBack
It is done. I have setup a subversion repository for the Plugin Manager.
I will not be posting the URL to the general public, as it is just my server machine sitting on my cable connection, but if you wish to keep up with the bleeding edge of Plugin Manager development, get in touch with me and I will send you the address.
Next: my plugins repository.
Posted by rayners | Comments (0) | TrackBack
After having some weird hang-ups in Subversion today, I tracked down a question and answer in the FAQ:
On FreeBSD, certain operations (especially svnadmin create) sometimes hang. Why?
This is usually due to a lack of available entropy on the system. You probably need to configure the system to gather entropy from sources such as hard-disk and network interrupts. Consult your system manpages, specifically random(4) and rndcontrol(8) on how to effect this change.
I was not sure initially if that was the problem I was having (mostly it was the mentioning of svnadmin create that threw me off). The thing was that everything was working fine on my server machine, which has almost the exact same setup as my personal machine. Commits were working just fine on the server, and hanging on my machine. Eventually, after futzing around with a few other thoughts, I decided to give it a try.
So, I read the rndcontrol manpage, and it said that:
Then I look at my dmesg output and discovered that my ethernet card was sitting on IRQ 11, so that is what I handed off to rndcontrol. Suddenly, things were working just fine again.
Minor Update (2003-12-31 09:58)
I forgot to mention the config file changes I made when I finally got all this working. I just added the following to my /etc/rc.conf file:
rand_irqs="11"
Posted by rayners | Comments (1) | TrackBack
Before I go and do anything drastic, I thought I would pose this question to the community at large: would anybody out there be interested in gaining read-only access to my plugin source code repository (including the Plugin Manager)?
Right now, I am just using CVS on my personal machine, but I have been thinking about setting up Subversion (CVS's successor) on my server machine.
So, does anybody out there want access?
Posted by rayners | Comments (1) | TrackBack
Recently I decided to tinker with my email paradigm on my network here at home. I used to run fetchmail on my main machine to gather all the email from my various accounts (passing it through procmail of course). Unfortunately, when I boot into Windows, I completely lose access to my mail. So, I installed dovecot on my extra/server machine, and copied over my fetchmail/procmail setup. Now I can access my email in both operating systems, and using practically any mail client I feel like using (usually mutt, but sometimes evolution or thunderbird).
Unfortunately, the little trick I used to let mutt know about all the mailboxes my procmail recipies create no longer works, as the folders are not physically located on my machine. I could do it manually, but IMAP already allows for something like this with its folder subscibing feature. Mutt supports this somewhat, but not to the extent that I would like (i.e. it can list subscribed folders, but it will not look for new mail in them, which is what I really want). So, I took a few minutes and threw together a quick perl script to list all my subsctibed folders in a mutt-compatible format.
Here's the code:
#!/usr/bin/perl
use Mail::IMAPClient;
my $server = shift;
my $user = shift;
my $pass = shift;
my $imap = Mail::IMAPClient->new (
Server => $server,
User => $user,
Password => $pass,
) or die "Cannot connect to $server as $user: $@";
my @subscribedFolders = $imap->subscribed
or warn "Could not find subscribed folders: $@\n";
map { print " =$_"; } @subscribedFolders;
It is certainly not robust, but it gets the job done for the time being. And besides, it gave me a good excuse to play around with Mail::IMAPClient.
Here is the line in my ~/.muttrc file that uses the script:
mailboxes `/usr/bin/perl ~/imapFolders.pl server rayners mypassword`
Posted by rayners | Comments (1) | TrackBack
Bill writes about the usefulness of list header metadata, so I thought I'd put up the procmail recipies I use to catch mailing list emails.
# Yahoo Groups
# (e.g. Mailing-List: list mt-dev@yahoogroups.com)
:0:
* ^Mailing-List: list \/[^@]+
lists/$MATCH
# Mailman and other intelligent software lists
# (e.g. List-Post: <mailto:Pluginmanager-l@rayners.org>)
:0:
* ^List-Post: \<mailto:\/[^@]+
lists/$MATCH
# Other list software?
# (e.g. X-Mailing-List: <ftjava-test@firedrake.org>)
:0:
* ^X-Mailing-List: \<\/[^@]+
lists/$MATCH
# Mojo Lists
# (e.g. List: lug)
:0:
* ^List-Software: Mojo Mail
* ^List: \/[^@]+
lists/$MATCH
# ListProc (all those UMBC lists)
# (e.g. Sender: owner-umbclinux@listproc.umbc.edu)
:0:
* ^Sender: owner-\/[^@]+
lists/$MATCH
# More lists (realms-l)
# (e.g. From owner-realms-l@ORACLE.WIZARDS.COM)
:0:
* ^From owner-\/[^@]+
lists/$MATCH
Most of the mailing list software out there adds the headers and I can catch them relatively easily. With others, however, I have to do a little digging. And the realms-l list drives me insane. Here's how it identifies itself within the email:
Sender: The Forgotten Realms Mailing List <REALMS-L@ORACLE.WIZARDS.COM>
I suppose I could look for that specifically, but that's exactly the point. I shouldn't have to write filters for specific mailing lists. It defeats the whole purpose of putting the list data in the email headers.
Anyways, for all you procmail/regexp experts out there, how do you think I could handle this odd case:
Sender: port-sgimips-owner@NetBSD.org
Posted by rayners | Comments (2) | TrackBack
I love procmail. I just spent a few minutes playing around with my ~/.procmailrc file and now any bug reports I get from the MT Plugin Directory Bug Tracker are now placed into ~/Mail/bugs/Project Name.
Here is the relevant portion of my ~/.procmailrc file:
# Catch bug reports from bugs.mt-plugins.org
:0:
* ^From: plugins@mt-plugins\.org
{
:0 B
* ^Proje[ck]t: \/.+
bugs/`echo "$MATCH" | sed -e 's/ /_/g'`
}
And from my ~/.muttrc file to see all those mailboxes:
mailboxes `for file in ~/Mail/bugs/*; do echo -n "=bugs/$(basename $file) "; done`
Update: (2003-06-08 18:14)
Thanks go to Mike for the suggestion. So, here's the updated recipe:
# Catch bug reports from bugs.mt-plugins.org
:0:
* ^From: plugins@mt-plugins\.org
* B ?? ^Proje[ck]t: \/.+
bugs/`echo "$MATCH" | sed -e 's/[^-_A-Za-z0-9]/_/g'`
Posted by rayners | Comments (0) | TrackBack
I've been playing around with my setup at home tonight. I decided to switch window managers again, and finally settled on pekwm which has impressed me quite a bit so far. It's got just enough functionality to make me happy (nice config/menu setup, virtual desktops, etc) while remaining quite speedy so far. I've just gotten tired of the whole Gnome thing lately. It's too much for me, I think. I prefer a much more minimal setup, with hot-keys-a-plenty. :)
I posted a screen shot with this entry as well just to give you an idea of what I'm working with now. What can I say? I was bored.
Posted by rayners | Comments (0) | TrackBack
As seen on the Nmap Hackers list today from the author of Nmap :
...
Like almost any self-respecting geek, I bought tickets to 'Matrix:
Reloaded' several weeks back (no spoilers, I promise). After all, who
can resist the combination of philosophical mind games and Trinity
(Carrie-Anne Moss) in that tight leather bodysuit?So after waiting an hour in a line snaking out of the theatre to the
parking lot, I finally got in to my 10pm Wednesday showing. All was
going well until Trinity needed to do some hacking. Oh, no! I was
sure we'd see a silly "Hackers"-esque 3D animated "hacking scene".
Not so! Trinity is as smart as she is seductive! She whips out
Nmap (!!!), scans her target, finds 22/tcp open, and proceeds with an
über ssh technique! I was so surprised, I almost jumped out of my
seat and did the "r00t dance" right there in the theatre!There can be only one explanation: Carie-Anne has the hots for me!
...
I'm not sure how to qualify that one. Does that count as product placement? :)
Posted by rayners | Comments (3) | TrackBack
Woo hoo! I just got it upand running on my machine (mostly). The final push was that FreeBSD-5.0 comes with GCC 3.2, as opposed to 2.95 which 4.7 was using. Since my class is targetting GCC 3.2, it was a no-brainer. Without it locally, working on the class projects would be a real hassle.
Posted by rayners | Comments (0) | TrackBack
It seems that a number of people already took it, so I figured I'd give it a shot. And I certainly got an interesting response, don't you think?
Posted by rayners | Comments (2) | TrackBack
I've got an old 486 lying around (and a Celeron if I really feel like it), along with enough NICS to supply a small army (of about 3-4 people or so). I want to setup a firewall of my very own to replace the Netgear RT314 I've got working right now.
So far, I've found the following options:
I'm leaning towards SmoothWall at the moment, but I'll probably end up installing more than a couple of them before I finally settle on one.
Posted by rayners | Comments (1) | TrackBack
Well, now that I've gotten my BSD box running X again, and put together a reasonable setup, I thought I'd take me a little screenshot. Enjoy!
Posted by rayners | Comments (0) | TrackBack
The FreeBSD NVIDIA Driver Initiative made an announcment a few days ago
I've had a few bits and pieces trickle down to me in the past few days, and finally got them confirmed from other sources, so they should be pretty reliable.
Basically, the latest Linux drivers were released not too long ago, which means the *NIX driver team at NVIDIA now has time to concentrate on getting the FreeBSD driver out the door. Apparently they still have some polishing to do, which I suppose is a Good Thing (TM).
Maybe I can finally run one of my favorite games, Railroad Tycoon II (the Linux version), with my GeForce4 in the computer (when I get my current one replaced). Currently, I cannot run XFree86 while I' in FreeBSD unless I've got my older Voodoo3 card installed.
Crossing my fingers. :)
Posted by rayners | Comments (0) | TrackBack
I took the bad DIMM back to Best Buy and got a new one. No problem there. Took it home, tested it out, and everything was working fine.
Then I went ahead and installed Icewind Dale. Bad idea. I lost track of how much time I was playing that last night. At least a couple hours. And I fear I will be forced to play it again tonight, and the next, and so on.
I'm in trouble. :)
Posted by rayners | Comments (0) | TrackBack
Well, it seems my suspicions were correct. When the new DIMM was the only memory in my machine, it would not boot. Seems I've got a trip to Best Buy in my future.
Posted by rayners | Comments (0) | TrackBack