Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a standard website (one Web Application and one Site Collection) with some custom pages and webparts.

The issue I'm having is that when I try to switch users, using the "Sign In As a Different User" and entering new credentials (even for another Site Collection admin account), IE tries the account three times, and then it presents a 401 Access Denied screen.

After that, if I erase all the stuff of access denied page from the browser's url, I'm logged as the new account I just had entered and was not accepted.

After researching for a while on google, I found a KB ( http://support.microsoft.com/kb/970814 ) that might relate, but just tested here and it didn't work at all.

The modified method suggested by the KB is the following:

function LoginAsAnother(url, bUseSource) 
{
    document.cookie="loginAsDifferentAttemptCount=0";

    if (bUseSource=="1")
    {
         GoToPage(url);
    }
    else
    {
         //var ch=url.indexOf("?") >=0 ? "&" : "?";
         //url+=ch+"Source="+escapeProperly(window.location.href);
         //STSNavigate(url);
         document.execCommand("ClearAuthenticationCache"); 
    } 
}

But after making this change, it no longer asks for new credentials.

Any ideas?

share|improve this question
    
There is a similar/related question here if it helps sharepointoverflow.com/questions/2026/… –  Charles Lee Apr 5 '10 at 18:32
add comment

1 Answer 1

One of the first things I would do to troubleshoot is to use Fiddler (or other http traffic analyzer) to have a look at the http requests and responses before using the 'Sign in as.." and those after.

It may not give you a direct answer, but by inspecting the headers for each successful request, and comparing with those that are failing with 401 responses, it may give a few clues as to what's going on.

share|improve this answer
    
tks for the info. I had tried that already, but nothing useful came up - or maybe I couldn't see it :) Apparently the browser (IE) caches the credentials, only fixing Sharepoint's js (init.js) to execute the ClearAuthenticationCache fixes it, but I'm not fond of fixing Sharepoint internal files, as I might have troubles deploying it on my customer's servers. I think it's really weird that only IE's (6, 7 and 8) have this issue, after all it's all MS. I was expecting some KB or SP to fix it, but couldn't find any. –  Tiziani Apr 16 '10 at 13:26
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.