However, looks like in Alfresco 5.0 onwards, the java classes are stored in jar files and these classes are not visible in Eclipse. Which jar file should I include to be able to import org.alfresco.web.site.SlingshotUserFactory?
Ideally, you should not (have to) use this old approach to extend user profile data. Using Surf Extension Modules and customisations to web script controllers / templates, you can enhance the profile page for view / edit mode without having to touch the SlingshotUserFactory. You'd only have to customise the userprofile.get and userprofile.post web scripts to load your additional profile properties, render the display / form markup, and then handle the form submission for storing the user submitted data. At least that is the way I recently went about it for one of my more "legacy" customers who is still on Alfresco 5.1.
But to the actual question: If you are using Maven, you can add the org.alfresco:share:classes:jar as a dependency in your project and should get the SlingshotUserFactory from that.