Active Directory and CMS returning user properties
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > Microsoft Content Management Server > Active Directory and CMS returning user properties




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Active Directory and CMS returning user properties  
Chandima


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-21-05 07:49 AM

Hi There

Our team is working on the company intranet, using ASP.NET and MCMS.  Within
the intranet, we are attempting to use Active Directory to return user
attributes (such as email) for a given Windows account name.

However, we cannot authenticate to Active Directory from within the CMS
context as IIS is presenting the demand as "machinename\ASPNET", instead of
"domain\user".

I have created two projects within the same IIS virtual directory (e.g. with
the same Directory Security settings).  One is a normal Web application, the
other is a CMS Web application.  I'm running the following code in both:

Response.Write(HttpContext.Current.User.Identity.Name + "<br>");

Response.Write(WindowsIdentity.GetCurrent().Name + "<br>");

Response.Write(Thread.CurrentPrincipal.Identity.Name + "<br>");

The web app prints this:

<domainname>\<myname>
<domainname>\<myname>
<domainname>\<myname>

The CMS web app prints this:

<domainname>\<myname>
<machinename>\ASPNET
<domainname>\<myname>

What do we need to get IIS to authenticate to Active Directory using
Integrated Windows security from within a CMS context?

--
Regards
Chandima
++++++++++++++++++++++++
http://www.digitalmelon.com/







[ Post a follow-up to this message ]



    Re: Active Directory and CMS returning user properties  
Stefan [MSFT]


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-21-05 07:49 AM

Hi Chandima,

an MCMS project is just another ASP.NET project.
But I assume that you set impersonate = true for the ASP.NET project where
it works.

If not: please follow up on an ASP.NET related newsgroup as this is not a
MCMS related topic.

Cheers,
Stefan

--
This posting is provided "AS IS" with no warranties, and confers no rights

New to MCMS?
Check out this book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Chandima" <digitalmelon@gmail.com> wrote in message
news:%23iiX9ymvFHA.3152@TK2MSFTNGP12.phx.gbl...
> Hi There
>
> Our team is working on the company intranet, using ASP.NET and MCMS.
> Within the intranet, we are attempting to use Active Directory to return
> user attributes (such as email) for a given Windows account name.
>
> However, we cannot authenticate to Active Directory from within the CMS
> context as IIS is presenting the demand as "machinename\ASPNET", instead
> of "domain\user".
>
> I have created two projects within the same IIS virtual directory (e.g.
> with the same Directory Security settings).  One is a normal Web
> application, the other is a CMS Web application.  I'm running the
> following code in both:
>
> Response.Write(HttpContext.Current.User.Identity.Name + "<br>");
>
> Response.Write(WindowsIdentity.GetCurrent().Name + "<br>");
>
> Response.Write(Thread.CurrentPrincipal.Identity.Name + "<br>");
>
> The web app prints this:
>
> <domainname>\<myname>
> <domainname>\<myname>
> <domainname>\<myname>
>
> The CMS web app prints this:
>
> <domainname>\<myname>
> <machinename>\ASPNET
> <domainname>\<myname>
>
> What do we need to get IIS to authenticate to Active Directory using
> Integrated Windows security from within a CMS context?
>
> --
> Regards
> Chandima
> ++++++++++++++++++++++++
> http://www.digitalmelon.com/
>







[ Post a follow-up to this message ]



    Re: Active Directory and CMS returning user properties  
Chandima


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-21-05 12:48 PM

Hi Stefan

Thanks for your reply, just to clarify what we are trying to do...

What we are trying to get is a posting authors email and user name to be
displayed along with a link to a Posting on a Datagrid as a summary list of
postings for a particular channel.

The idea is to pass the users winnt\\domain\username which MCMS displays and
Search AD for the display name and email as described on your post:

http://blogs.technet.com/stefan_gos...2/21/44902.aspx

However I can get this to work in a normal web app but not in MCMS context
as described in my post. Have i missed something really obvious here? I will
check the web.config to see if Identity impersonate has been set to true.

cheers

Chandima


"Stefan [MSFT]" <stefang@online.microsoft.com> wrote in message
news:uoovTnnvFHA.464@TK2MSFTNGP15.phx.gbl...
> Hi Chandima,
>
> an MCMS project is just another ASP.NET project.
> But I assume that you set impersonate = true for the ASP.NET project where
> it works.
>
> If not: please follow up on an ASP.NET related newsgroup as this is not a
> MCMS related topic.
>
> Cheers,
> Stefan
>
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
>
> New to MCMS?
> Check out this book: Building Websites Using MCMS:
> http://tinyurl.com/6zj44
> ----------------------
>
>
> "Chandima" <digitalmelon@gmail.com> wrote in message
> news:%23iiX9ymvFHA.3152@TK2MSFTNGP12.phx.gbl... 
>
>







[ Post a follow-up to this message ]



    Re: Active Directory and CMS returning user properties  
Stefan [MSFT]


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-21-05 12:48 PM

Hi Chandima,

this code works fine on my boxes with MCMS.
No idea what the differences are in your environment.

Again: this is not a MCMS related topic. Please post to an AD or ASP.NET
related newsgroup.

Cheers,
Stefan

--
This posting is provided "AS IS" with no warranties, and confers no rights

New to MCMS?
Check out this book: Building Websites Using MCMS: http://tinyurl.com/6zj44
----------------------


"Chandima" <chandima.k@xtra.co.nz> wrote in message
news:uRlV1BpvFHA.3500@TK2MSFTNGP09.phx.gbl...
> Hi Stefan
>
> Thanks for your reply, just to clarify what we are trying to do...
>
> What we are trying to get is a posting authors email and user name to be
> displayed along with a link to a Posting on a Datagrid as a summary list
> of postings for a particular channel.
>
> The idea is to pass the users winnt\\domain\username which MCMS displays
> and Search AD for the display name and email as described on your post:
>
> http://blogs.technet.com/stefan_gos...2/21/44902.aspx
>
> However I can get this to work in a normal web app but not in MCMS context
> as described in my post. Have i missed something really obvious here? I
> will check the web.config to see if Identity impersonate has been set to
> true.
>
> cheers
>
> Chandima
>
>
> "Stefan [MSFT]" <stefang@online.microsoft.com> wrote in message
> news:uoovTnnvFHA.464@TK2MSFTNGP15.phx.gbl... 
>
>







[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 07:35 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register