How did Ubuntu know my WPA Key?

Solution 1:

On a standard Ubuntu installation using GNOME and network-manager the WPA key is stored in the GNOME keyring. This will be restored with /home.

You can test if this is so in your settings by temporarily deactivating keyrings in ~/.gnome2 (make a backup before you do so!).

The only other location I can think of where Wicd could get a WPA key from is etc/wpa_supplicant/wpa_supplicant.conf. I have no idea however how this file could have moved to your /home (if that is exclusively what you restored).

I don't use Wicd, therefore I can't check settings but if ~/.wicd is empty then there is no chance that any keys are being stored there. You maybe want to check if wicd_gui has another path to store things.

Solution 2:

If you did not format your system, and installed on top of an old installation, then it is quite likely that your old settings were brought over (including settings in /etc). Whatever is not installed on the live CD would have been left alone, which is explains the apparent magic bunnies result that you experienced. It's less of a mysterious answer :( - but at least it's more realistic :).