RE: How to get the login from IIS in C#

From: DJe (dje@perso.be)
Date: 08/01/02


From: "DJe" <dje@perso.be>
Date: Thu, 1 Aug 2002 05:34:43 -0700


Excellent! Magnifique de beautée! ;-)
Merci beaucoup!
¡Muchas gracias!
Dank u well!
Thank you very much!

There is my solution with your help:

{
 String pass;

 pass=Context.User.Identity.Name.ToString();

 edt_Login.Text=pass.Substring(pass.LastIndexOf('\\')+1);
}

Context.User.Identity.Name give the "domain\login"

Have a nice day!

Jérôme

>-----Original Message-----
>Hello,
>
>Based on my understanding, you want to use Windows
authentication instead
>of Form Authentication. If it is, you need to change your
web.config file
>to the following
>
> <authentication mode="Windows">
> </authentication>
>
>At the same time, client need to login to domain to avoid
message box from
>pop up in IE window.
>
>If you want to get the identity of the user, you can use
>context.User.Identity to return the login domain and name.
>
>Jason Jing
>Microsoft Support
>This posting is provided "AS IS", with no warranties, and
confers no rights.
>
>
>
>| Content-Class: urn:content-classes:message
>| From: "DJe" <dje@perso.be>
>| Sender: "DJe" <dje@perso.be>
>| Subject: How to get the login from IIS in C#
>| Date: Mon, 29 Jul 2002 10:09:29 -0700
>| Lines: 30
>| Message-ID: <1e3a01c23722$b36baff0
$a4e62ecf@tkmsftngxa06>
>| MIME-Version: 1.0
>| Content-Type: text/plain;
>| charset="iso-8859-1"
>| Content-Transfer-Encoding: 7bit
>| X-Newsreader: Microsoft CDO for Windows 2000
>| X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
>| Thread-Index: AcI3IrNrqtppdoIcQbCuQJfI1SLVfA==
>| Newsgroups:
microsoft.public.dotnet.framework.aspnet.security
>| Path: cpmsftngxa07
>| Xref: cpmsftngxa07
microsoft.public.dotnet.framework.aspnet.security:1735
>| NNTP-Posting-Host: TKMSFTNGXA06 10.201.232.165
>| X-Tomcat-NG:
microsoft.public.dotnet.framework.aspnet.security
>|
>| Hi all!
>|
>| I made my webconf like this :
>| <authentication mode="Forms">
>| <forms name="blabla!!!" LoginUrl="AccessOK.aspx"/>
>| </authentication>
>| <authorization>
>| <deny users="?"/>
>| </authorization>
>|
>|
>| So i need to make the cookie. But i'm asking a login
from
>| windows under IIS...
>| (under IIS right click, properties, secure directory,
>| uncheck the first checkbox and check the last one -
Anonym
>| access and Integrated Win authentification -> sorry for
>| the spelling my win is in french)
>|
>| I'm asking this login from Windows(NT PDC) because it's
>| for a LAN...And it should be more easy to manage than
make
>| a User DB...
>|
>|
>| There is a couple of hours, i'm looking to solve this
>| problem.
>|
>| Is it possible to take it under C#?
>|
>| If someone can help me. Thank you!
>|
>|
>
>.
>



Relevant Pages

  • Re: IIS Start up errors
    ... provide the detailed steps to reinstall the IIS server in SBS 2003 server. ... For example, programs such as Microsoft ... In the Currently installed programs list, click Windows Small Business ...
    (microsoft.public.windows.server.sbs)
  • RE: SBS Web Remote Webworkplace Login
    ... I checked the IIS log and Metadata, I found IIS setting are not correctly ... Microsoft CSS Online Newsgroup Support ... SBS Web Remote Webworkplace Login ...
    (microsoft.public.windows.server.sbs)
  • Re: Login to Windows opens the Shutdown Event Tracker
    ... You will see the Shutdown Event Tracker after the server reboot unexpectly. ... Products Designed for Microsoft Windows - Windows Catalog and HCL ... Login to Windows opens the Shutdown Event Tracker ...
    (microsoft.public.windows.server.sbs)
  • Re: Expiring inactive acounts
    ... Microsoft took that option away with 2K due to various implementation issues. ... Joe Richards Microsoft MVP Windows Server Directory Services ... In Windows NT 4.0 I used to enable the checkbox "User must login to ... change password" and had a password expiry of 60 days. ...
    (microsoft.public.win2000.security)
  • RE: no OWA
    ... Correct the settings in IIS: ... Tick Integrated Windows authentication option. ... click to check the "Hide All Microsoft Services" ... Please note that the Exchange services could be marked as ...
    (microsoft.public.windows.server.sbs)