First install the package wpasupplicant
aptitude install wpasupplicant
Then we will configure a network, so we create and modify the configuration file:
Complete the file to make it look like that (replacing wifi_name and wifi_key by their real values of course). Press "i" to be able to edit.
Then exit and save (press escape then :wq)
The wifi network is now configured, we must now tell that we want to connect to it using this configuration file.
wpa_supplicant -B -iwlan0 -c/etc/wpa_supplicant.conf -Dwext
If your interface isn't named wlan0 then replace wlan0 by the real name of your interface.
We must now request an IP adress.