Map Open Port to Process Id (pid)

Ever wondered which process id is assosiated with an open port on your host? I wrote this little gem a couple of years ago. I use it a lot.