Thursday, June 25, 2009

VPNC with Firestarter

I had been using vpnc to connect to work for a while now. I was using Ubuntu 8.0.4 and recently upgraded to 8.10. Suddenly my vpnc would not work. I couldn't ping any of the target computers without getting this error:
sendmsg: Operation not permitted
After googling around I found the answer here and here.

Basically what you need to do is:

1. Make the /etc/firestarter/user-pre file editable with chmod 600 or equivalent.
2. Edit the user-pre file as sudo and add the following replacing xxx.xxx.xx.xxx with the ip of your gateway:
iptables -A INPUT -j ACCEPT -s xxx.xxx.xx.xxx -p esp
iptables -A INPUT -j ACCEPT -s xxx.xxx.xx.xxx -p udp -m multiport --sports isakmp,10000
iptables -A INPUT -j ACCEPT -i tun+
iptables -A OUTPUT -j ACCEPT -d xxx.xxx.xx.xxx -p esp
iptables -A OUTPUT -j ACCEPT -d xxx.xxx.xx.xxx -p udp -m multiport --dports isakmp,10000
iptables -A OUTPUT -j ACCEPT -o tun+

3. Save and exit
4. Restart firestarter with sudo ./etc/init.d/firestarter restart.

That should make it all work again.

Friday, June 12, 2009

Pondskum Lives!

After recently having moved to Bigpond (no thanks to IINET not getting their sh*t together) I wanted to install a linux widget that displayed my current Internet usage. It's easy enough to log into Bigpond but it's cumbersome and involves multiple clicks when all you want to know is your usage.

With Pondskum, I've created a small opensource Java API that logs into your Bigpond account and screen-scrapes (yukk!) data and gives it back to you in a bean. If only Bigpond had a webservice that provided usage information!

I've created 2 guis from the API. One command-line which gives you basic usage information like totals etc and a Swing version that gives you a day-by-day usage table for the current billing month.























This will work until the Bigpond site is redesigned. Have a look if you need an easy way to find out your Internet usage data.