Can we get a list of all portal sites on sharepoint portal serverprogrammatically
Yup. Use the Sites property from the top level SPSiteCollection. Depends on how you’re getting this list as you can get it from the SPViritualServer (usually if you’re doing this outside of a web part) or though SPControl.GetContextSite.