Lighttpd and dualstack IPv6/IPv4 and SSL

Reading over the internet you can find a lot of information over all kind of related issues. However, nearly no one is, as far I can see, trying to get and a dualstack connection and a SSL connection working. Due to this, you can try to combine all kind of possible configuration issues, but you will find it is hard to get the correct one.

Getting lighttpd to listen on IPv6 and IPv4 (So dualstack) is not hard at all. Once you have SSL working with that together, it is not that difficult, however trying to find the right option is.

After a long try I came up with the next config file, what has a seperate SERVER["socket"] section for both IPv4 and IPv6. Not ideal, but is works, this site is visible via both IPv4 as IPv6, and thats the thing we wanted. For now iam going to use this, and hope there once will be a better solution. (As note, I also have a required redirect here, as I require the full site to be over SSL).

var.confdir  = "/etc/ssl/cert"
$SERVER["socket"] == "91.196.170.37:443" {
    ssl.engine    = "enable"
    ssl.pemfile   = var.confdir + "/www_domain_nl.pem"
    ssl.ca-file   = var.confdir + "/AddTrustExternalCARoot.crt" 
    server.name   = "domain.nl" 
    server.document-root = "/var/www2/"
}
#// 2a02:27f8:1001::2:1
$SERVER["socket"] == "[2a02:27f8:1001::2:1]:443" {
    server.use-ipv6 = "enable"
    ssl.engine    = "enable"
    ssl.pemfile   = var.confdir + "/www_domain_nl.pem"
    ssl.ca-file   = var.confdir + "/AddTrustExternalCARoot.crt"
    server.name   = "domain.nl"
    server.document-root = "/var/www2/"
}
$HTTP["host"] == "www.domain.nl" {
    $HTTP["scheme"] == "http" {
            url.redirect = ("^/(.*)" => "https://www.domain.nl/$1")
    }
}

Android and JSON

This afternoon I needed to create a JSON string in Android. Trying to search this at google I found nearly no results, except for reading/parseing a JSON string. I didnt need that (yet), I just needed to serialize/create a JSON string. At the end I came up with the next class to generate a basic JSON string, and to use it to post to a website.

The class includes a method that returns a HttpEntity, that can be directly used to send to a website via HttpPost.
Read more »

Eigenlijk wil ik ergens over praten…

… maar ik kan het niet.

Fun things you can do with android

Now I bought last week a new phone, with android  2.1 iam kinda having fun with it. As a school project our project is currently to program for android (Whats not that difficult, it basicly is java :))

after playing a bit around with the SDK for android, I discovered a function that you can use to make a screenshot via the computer at your phone. (If you dont know how, its pretty easy. But I will post a bit more explained how later as seperate post).

Now the more weird thing, after some minutes playing around with this function, the phone was gone into sleep modes. So I expect if the phone is asleep, the screen is just black when I make a screenshot. However, it isnt, see the attached screenshot (Iam afraid you will need to trust me that thats the actual screen being displayed, I know :P).

3.0.7PL1 released

You really should upgrade now: http://www.phpbb.com/community/viewtopic.php?f=14&t=2014195&start=0

phpBB 3.0.7 released

finally, its released

Toshiba and ubuntu

Yes, I know I wrote earlier about this problemhere at my blog, however, thats now already a few days ago, and since I actually didnt write anything about it. Looking back at the last week I havent found any solution really yet for my fan problem at my laptop. its still not really working currently. The fan just does nothing, and the temperature raises till around 75C. At this moment (I havent found the exact temperature yet) the fan starts to blow at full speed, and doesnt stop untill I reboot the laptop.

Recompilling the kernel, or the other fixes I mentioned earlier dont work, so there currently is as far I can see not really a solution, except not using ubuntu. Damn. Hopefully its fixed in the next release, but iam afraid it will not be fixed :(. Unless someone else knows a solution ofcourse :P

the process of compile a new kernel(2)

Yesterday I wrote about compiling myself out a new kernel. As everything new, it will not always succeed at the first try :). And the same here. After compiling, what took around 2.5 hours at my laptop (Iam currently considering building a VM to do this kind of things at a hosthuis server, we have enough CPU there to build it instead), there was just at the end one small error. This badly enough resulted in a non work .deb file, that didnt contain a kernel. Read more »

The process of compile a new kernel

Like I said yesterday iam currently having major problems with my toshiba laptop due to the fan not working. Its topping at normale usage (So just some internet and nothing more really) at 70C, what isnt really normal. Read more »

Ubuntu and laptop fan

Since Iam using ubuntu as main main OS for my laptop I noticed that my laptop temperatures are quickly raising in several cases, and no fan is actually spinning up. According to lm-sensors the temperature of my CPU is 70C in some cases, and no fan that is working. Untill I reboot, and the fan is started by the bios. At that moment, the fan is spinning on the max(?) RPM, and isnt slowed down by ubuntu.

Looking at google several people are noticing the same problem, and several solutions are at internet, however, none of these solutions are actually working at my toshiba laptop. Hopefully someone fixes this anytime soon, as iam pretty sure my laptop doesnt like it to be 70C with normal usage…