PyLoris: A Python implementation of Slowloris

I came across a wonderful idea on Hack a Day recently: a Denial of Service attack that overwhelms only the service under attack. After reading through RSnake's two writeups, I decided to take a swing at the code. Thus PyLoris was born.

A Simple Extension to the Python CSV Object

One of the side effects of working with database driven software is that you eventually find yourself needing to pull in large amounts of information from old and terrible systems. When talking to your counterparts on the other side of the line (the inter-company line, that is), you will invariably be told that you will only receive your data in one of a few straight forward formats. What follows is a small extension to Python's CSV object which streamlines the process of coding these data transformations.

Network RAID Storage: Proof of Concept

I recently discovered a post on Hack a Day linking to a proof of concept how-to on setting up a software RAID on FTP servers. While the guide is a simple approach to running a network based RAID 5 configuration, a number of tools the original developer used are less than optimal. First, the set up requires both Windows and Linux, meaning you will either need two physical machines, or a virtualized machine in your configuration. The second, and larger problem is that it is restricted to RAID 5 and FTP servers. This article is my attempt to alleviate both of these issues.

Security: Perceived Risk versus Potential Damage

All too often, while running the PHP forum on The Scripts, I see students working who are completely ignorant of the security concerns prevalent with the systems that they build. Worse, when alerted to the potential dangers associated with poor programming practices, these coders let loose a variety of excuses why their application doesn't need to implement a security policy. Ranging from "this is a low traffic/internal site" to "I'm doing this as a project for school, so security really isn't an issue." In my eyes all explanations are equally irrelevant. As leaders of the forums, my colleagues and I daily battle assertions about the validity of these concerns.

Daemonizing a Python Script

As my knowledge of Python continues to grow, I find myself using it more in my own systems. This is one of my more useful snippets of code; it allows a Python script to continue running as a daemon even if you log out or your session gets disconnected. A nice side effect of this is that the process is immediately run in the background, returning the user to a command prompt instantly.

Turning on PHP Debugging and Error Messages

Debugging messages are a powerful tool; however, many production systems (and test systems for that matter) have them disabled by default. If your PHP script is crashing horribly and you are not getting any runtime error messages, it is likely that this is the case for you.

Gumstix u-boot 1.2

I took the plunge and, at the risk of bricking my Verdex, updated u-boot. I can only begin to describe the improvements! The process was not nearly as perilous as I anticipated (though I did hold my breath when I rebooted the first time). Noteworthy improvements are the ability to load the kernel directly into the U-Boot environment, and the inclusion of ymodem file transfers over the serial line. The former reduces my boot time to a breathtaking 23 seconds, while the latter reduces rootfs flash time via serial connection by more than half!

Verdex && Belkin 802.11

With a lot of grunting and groaning, a good amount of grepping through forum posts, and gallons of patience (coffee), I have finally got my verdex board to acknowledge my Belkin F5D7050 and bring the interface up. Due to a small bug in the zd1211rw drivers, the device needs to be brought up before an ESSID can be assigned to it. Without doing so, I would receive a permission denied error for a majority of the iwconfig options:

Thinking Outside the Box with Python

I recently came across this job posting in the The Scripts Developer Network forums. It has an interesting brain teaser as a requirement for applying. The brain teaser was stated as: "What is the exponent of the largest power of two whose base seven representation doesn't contain three zeros in a row?" The only stipulation was that the applicant use Python to solve the problem.

Creating a MySQL Data Abstraction Layer in PHP

{EDIT: THIS ARTICLE IS OLD. I HAVE KEPT IT HERE FOR HISTORICAL REASONS, AND IT IS NO LONGER RELEVANT.}

1 2