I would like to write an app that allows users to identify songs by putting the mic next to a speaker and listen to the song for a few seconds... so exactly what Shazam does.
Is there any framework or library or service I can use out there to accomplish that in iOS?
You need an API which you can query. An example uf such an API is Gracenote You could also have a look at Musicbrainz