As Seb
points out, it is necessary to point out how awesome native
last.fm support is. It is.
One (as-yet unintegrated feature, it will probably be put in shortly after the string freeze ends) great feature of Last.fm is the custom
radio station. Just enter some of your favorite artists and it puts together a stream of those artists and their related artists. Feel free to try a
couple of
mine, though of course its better if you pick your own artists.

Leo Franchi added a .protocol file to be installed with Amarok to support the lastfm:// protocol for Konqueror, like the links in the previous paragraph. Though Makefile.am isn't ever fun, it was a straightforward task: an app installing support for new protocols is obviously an issue that KDE decided to provide a solution for.
I immediately got to thinking it would be cool to add such protocol support to Firefox as well. In Windows a registry edit is all that is required. After some help from irc.mozilla.org and Google, it appears to be completely impossible for a application to install a protocol into vanilla Linux Firefox. The user has to go in and add an entry to about:config manually. One suggestion I got was to write an extension, I asked if an extension could be installed from outside Firefox - no. Obviously not useful (though perhaps something last.fm should look into).
If you have a Firefox built with Gnome support (eg, not a Firefox binary downloaded from mozilla.org), you can use gconftool-2 to add the necessary settings. Gconftool-2 is hardly ideal for what should probably be an install-time operation, it doesn't appear to do settings for all users (though I could be wrong).