Category Archives: Random random

SpareBank 1 SMN har sikkerhetshull i nettbanken

Update 9. april: Hullet er fikset. Det tok 70 dager. Jeg finner sikkerhetshull overalt og bruker å sifra til eier av nettsiden eller de som har utviklet nettsiden. Som regel sender jeg epost til den første epostadressen jeg finner på nettstedet. Jeg får i de fleste tilfeller positiv respons fra en eller annen seniorutvikler som [...]

Creating funny md5 hashes

This is useless, but funny. I want to generate md5 hashes which have english words in them. So I grab a wordlist and start grepping for words which only contain the characters [abcdef], since these characters are the only output letters from md5 when displayed as hex. grep -E "^[abcdef]{6,10}$" ~/Downloads/tbswordlist1.txt The longest and coolest [...]

Last ned alle utgaver av under dusken

Under dusken har ny webside og har lagt ut alle gamle utgaver i pdf form fra 2000 til i dag. Last ned alle sånn her; #!/bin/bash for year in `seq 2001 2012`;do for i in `seq 1 16`;do wget -P pdfs http://dusken.no/media/publications/2012/$i-${year}_1.pdf done done Eventuelt last ned herfra; https://github.com/dvikan/underduskengrabber

Glemt truecrypt passord

Jeg glemte plutselig truecrypt passordet mitt og tenkte jeg skulle sjekke ut truecrack som bruteforcer truecrypt passord. Jeg visste at den første delen av passordet var “d94kf5″ og at den neste delen var et ord som fins i den norske ordboka. Så først trengte jeg å laste ned den norske ordboka, og den fins her; [...]

How to run bash script which ssh into box and runs commands

I needed to make a bash script which logs onto box with ssh, and then runs some commands. Here is how it is done: ssh user@host "touch foobar123 && echo hello"

Ultra fast upload script for screenshots

I wanted to take a screenshot of a region of my screen, and upload it as fast as possible, so I can share it instantly. With this bash script, I have a shareable url to the screenshot in a matter of seconds. You need ssh access to a host where you can store files in [...]

Rickrolling through spotify

When firefox loads spotify urls such as spotify:track:6JEK0CvvjDjjMUBFoXShNZ, spotify automatically starts playing it, because I have told it to do so instead of asking me each time. This is an excellent oppurtunity to rick roll me like this: <iframe src=’spotify:track:6JEK0CvvjDjjMUBFoXShNZ’ width=’0′ height=’0′></iframe>

Opening spotify urls in firefox, ubuntu 10.04

This is how I made firefox open spotify urls such as: spotify:track:2uHWZXTngyea3xFEXFrdfP I am using the native spotify client for linux, and not spotify under wine. Also my firefox version is 3.6.24 and my ubuntu is 10.04. gconftool-2 -s /desktop/gnome/url-handlers/spotify/command ‘/usr/bin/spotify /uri %s’ –type String gconftool-2 -s /desktop/gnome/url-handlers/spotify/enabled –type Boolean true

Found myself an amazing new algorithm

My new favorite algorithm is the Ostrich algorithm to stick your head in the sand and pretend that there is no problem

How to crack HTTP Digest access authentication

I was playing around with my dlink router and decided to explore one of HTTP’s authentication methods: http://en.wikipedia.org/wiki/Digest_Access_Authentication. You know, those boxes that pop up in your browser, asking for username and password: In contrast to http://en.wikipedia.org/wiki/Basic_access_authentication, HTTP Digest access authentication doesn’t send password in cleartext, but hashed together with some other values. I accessed [...]

RC4 implementation in C

RC4 is a very fast and easy to implement stream cipher which uses xor to produce a pseudorandom output keystream. #include <stdio.h> #include <string.h> #include <stdlib.h> /* * RC4 implementation. usage: rc4 <plaintext> <key> * */ unsigned char S[256]; /* S-box */ unsigned int len; void swap(unsigned char *a, unsigned char *b) { unsigned char [...]

How to fix: could not be installed because it is not compatible with firefox 6.0

When you update firefox, some addons will not install because the max version is set to something lower in the xpi archive. To force firefox to try to install anyway; unzip the .xpi archive edit install.rdf and change max version to something higher than yours remove the folder META-INF zip it, and rename to something.xpi [...]

Packet sniffing through a Firefox extension

In a course I am taking, we had to write a 3 page long text on a subject of our choosing from a list of suggestions. I decided to write about Firesheep, which is an extension to Firefox which sniffs out session cookies from various websites. The first “serious” text I have ever written! Why [...]