Sweetcron is really fun modify…

December 25th, 2008

Sweetcron is really fun modifying.

Is quite impressed by http://w…

December 25th, 2008

Is quite impressed by http://www.sweetcron.com/. Lifestreaming > Blogging

Applying NVIDIA Hotfix (KB940105) for Windows Vista

December 27th, 2007

A few friends of mine running Vista have had troubles installing the NVIDIA hotfix described in KB940105. The hotfix is downloadable as Windows6.0-KB940105-x86.msu and can be installed using the following steps:

Unpack the hotfix

expand -f:* "Windows6.0-KB940105-x86.msu" %TEMP%

Apply the hotfix (you will be prompted about whether to allow or not)

pkgmgr.exe /n:%TEMP%Windows6.0-KB940105-x86.xml

PHP: Secure Your Included Files

November 13th, 2007

If you’re anything like me, you heavily rely on splitting things up. Even the simplest application needs to be separated into individual files for functions, database calls and user interface. The files are usually named and placed so that they are easily accessible for the index file and inconvenient to find for the potential attacker.

If the attacker where to reveal their path it would not necessarily pose a serious threat to the application’s security, assuming executing the individual file on its own does not give away any useful debugging information. To avoid helping people exploit your applications you may consider to turn off the standard PHP behaviour of throwing out all possible information as soon as something goes wrong: Either set “error_reporting” to “0” in php.ini or through your .htaccess-file.

Additionally you might consider isolating your files from even executing on their own. The easy way to do this is to:

  • define a function in the main file (index.php)
  • only allow execution of additional files if the defined function is able to execute

index.php

<?php function LoadedCorrectly() { return true; } ?>

database.php

<?php LoadedCorrectly() or die(); ?>

Interesting Photos Taken in Paris

October 14th, 2007

A close friend of mine recently visited Paris, France equipped with his brand new Nikon D40.

Get Sound Working For Quake-based Games

October 7th, 2007

Running games such as Quake III, Enemy Territory or Return To Castle Wolfenstein on Linux will sometimes fail to initialize sound. After modifying a generic fix for this problem I wrote this:


APP="${1}.x86"
echo "${APP} 0 0 disable" > /proc/asound/card0/pcm0c/oss
echo "${APP} 0 0 direct" > /proc/asound/card0/pcm0p/oss
echo "${APP} 0 0 disable" > /proc/asound/card0/pcm1c/oss

To use it, simply run the script with the game binary’s name as an argument:

# Fix sound for RTCW single player
sh sound-fix.sh wolfsp
# Fix sound for Enemy Territory
sh sound-fix.sh et

Possible Future Career

September 30th, 2007

I think I’ve finally figured what I want to do for the rest of my life. My humble dream is to get a Master of Science degree in Chemical Engineering, probably at Lund university or Chalmers (Gothenburg).

Some fields I think would be very fun to research:

  • Bio-fuel: Creating more efficient production methods and cheaper ways to “upgrade” the gas.
  • Nuclear waste management: How to dispose of nuclear waste as safe and reliable as possible.
  • Chemical computing: Initial attempts of creating a computer made out of chemicals has already been done successfully. In the future computers may consist of chemicals replacing the electronic grinds used to perform calculations today.
  • Hydrogen-fuel: Better methods of extracting hydrogen for fuel-cells and engines.

Gmail said: You are currently …

September 19th, 2007

Gmail said: You are currently using 666 MB (22%) of your 2902 MB.

Finally got my terminal server…

September 15th, 2007

Finally got my terminal server back!

Finally online again after mor…

August 27th, 2007

Finally online again after more than a week without a working computer.

Home for lunch, last week on m…

August 13th, 2007

Home for lunch, last week on my summerjob where I’ve mostly been lawn mowing. Mowing the same spots for six weeks is sort of frustrating.

Chatting with blogosphere-king…

August 12th, 2007

Chatting with blogosphere-king MenZa while talking with my girlfriend on the phone.

Just put together http://nlind…

August 12th, 2007

Just put together http://nlindblad.org/projects just to realise I haven’t really done anything impressive. :(

Watching a sweet demo of what …

August 12th, 2007

Watching a sweet demo of what we might expect in the future from *NIX desktops: http://tinyurl.com/2ypxa4

Trying to blog through twitter…

August 12th, 2007

Trying to blog through twitter!