when use windows authentication, the user did not auto be added to the userlist.

This is the place to report bugs and get support. When posting in this forum, please always provide as much detail as possible.

Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum, do not report it as a bug.

This is the place to report bugs and get support

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.
Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum.
This thread is closed to new posts. You must sign in to post in the forums.
7/20/2009 10:04:33 PM
Gravatar
Total Posts 59

when use windows authentication, the user did not auto be added to the userlist.

OS: Win2003
DB:MSSQL
Version:2.3.1.0

Hi, Joe:

When I use windows authentication, the login user did not be added to the user list. I login use the domain Administrator user.

So when i view a thread in forums, error occurs:

below code in Thread.aspx.cs

//////////////////////////////////////////////////////////////

private void Page_Load(object sender, EventArgs e)
{

...

if(User.Identity.IsAuthenticated)
{
SiteUser u = SiteUtils.GetCurrentSiteUser();
this.userID = u.UserId; //Because u is null, so u.UserId error.
}

...

}

//////////////////////////////////////////////////////////////

I did not find the code to add the windows authentication user to the mp_Users table.

Thanks!

7/21/2009 5:04:34 AM
Gravatar
Total Posts 18439

Re: when use windows authentication, the user did not auto be added to the userlist.

Hi mjohn,

It "should" create a user for you. The relevant code is in Web/Components/AuthHandlerHttpModule.cs, you can step through that code and see what is going wrong. Let me know if you find the problem/solution.

Best,

Joe 

7/22/2009 1:39:43 AM
Gravatar
Total Posts 59

Re: when use windows authentication, the user did not auto be added to the userlist.

Hi, joe

You are right, when i clear the cookies, it is ok.

I try all authentication types, include form authentication、windows authentication、ldap authentication.

I have ever cleared the users from table mp_Users by hand,  so when I use back windows authentication again, the ie cookie is already exist, so the user will not be added to the system again.

When read Web/Components/AuthHandlerHttpModule.cs,I clear the cookie, it works!

It is my problem.

Thanks for your help!

 

You must sign in to post in the forums. This thread is closed to new posts.