Obtaining the user identity on My Profile page

May 28, 2008 at 6:40 AM
I am accessing MyProfile page of My site.I want to retrieve  the user name whose My profile page is being accessed.One option is I can retrieve 'account name' parameter from url.Whenever I access the owner of My Profile page in a webpart placed on it,I get user as NT AUTHORITY.Whenever I access the owner of My Home page in a webpart,I get proper currently logged in user. Is there any SharePoint API - or other mechanism - which exists from which one can obtain the identity of the user who's SharePoint My Site/My Profile page is being visited ?