This project has moved. For the latest updates, please go here.

SPGetCurrentUser Permissions

May 23, 2011 at 11:50 AM

I am hoping to get more information on if my issue is my environment or this is the normal/expected behavior of the SPGetCurrentUser function in WSS 3 only.

If I run the function as a Site Owner or SCA it works fine for me. Other users can not get this function to run. I have a workaround, but not sure if it makes sense.

All users have the permission to edit their personal information. Even setting the "Browse User Information" permission does not work.

My workaround is to go to the actual User Information List and under the permissions, select All Authenticated Users and give them read access. This then allows the function to work fine.

Is this really a viable option or am I missing something entirely?

May 23, 2011 at 1:09 PM

Sometimes it helps if you really really understand Sharepoint :) 

This function uses the layouts page to get information. If the user does not have the "View Application Pages" permission set, this function will not work.

I did not see this as a requirement so I am not sure if I missed it, but setting this permission allows all users to have the feature working!

May 23, 2011 at 1:28 PM

Wouldn't it be pretty unusual for a user in a collaboration environment to no have the "View Application Pages" permission? For instance _layouts/upload.aspx.


May 23, 2011 at 1:43 PM

It certainly would be! Not sure how it ended up that way, but it is working now. No idea why I did not see it before :)