I'm assuming you want to share an internet connection from your iMac through your iMac's AirPort?
To do so, go into System Preferences:
- Sharing
- Internet Sharing
- Share your connection from: Ethernet
- To computers using AirPort
If you're using AirPort to connect to your network, it won't be possible to share through AirPort and your friend or whoever would need to connect to your iMac through the Ethernet port to gain internet access.