Author Archives: hexelpdkk

Life behind the corporate firewall

Many things seems to get upset once you shove them behind a corporate NTLM firewall. Our main workaround for this is to install the cntlm proxy on a local linux box, and use it as a proxy. This is great, and many applications will obey the http_proxy and https_proxy environment variables. However, git doesn’t, and it gets worse when you are given a git: url

To configure git to use a proxy, use:

git config --global http.proxy
git config --global https.proxy

To resolve the git: url, you can set git to automatically use https instead of git

git config --global url."https://".insteadOf git://

Thanks to StackOverflow and google generally.


I finally set myself up a virtual server. As soon as I did that, it started getting hit by probes from across the world. To handle this, I installed fail2ban, which will ban source addresses based on log file entries, for a certain amount of time. This certainly helped, but I noticed that some of these were persistent offenders.

Fortunately, Phil Hagen’s Scratch Pad had a ready rolled solution: 21 offences and you are out permanently. I have just set this up, so will monitor over the week.

Building Pi Modules Without Building the Kernel

Every now and then I get back to my Raspberry Pi, and realise that I have completely rebuilt my image. That makes it pretty hard to find my module building instructions, so here they are:


tar xvfz rpi-3.6.y.tar.gz


mv linux-rpi-3.6.y /usr/src

ln -s /usr/src/linux-rpi-3.6.y /lib/modules/3.6.11+/build

cd /lib/modules/3.6.11+/build

make mrproper

gzip -dc /proc/config.gz > .config

make modules_prepare



Then my makefile for the actual module is

obj-m := kcrDriver.o


$(MAKE) -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules


$(MAKE) -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean

What is particularly useful about this is that I don’t need to compile the entire kernel just to build my one module.