windows-authentication

Impersonate using Forms Authentication

I have an ASP.NET site that must use Forms Authentication and not Windows Authentication to access a ActiveDirectoryMembershipProvider. The site must use forms because they need a designed input form instead of the browser authentication popup that Windows authentication uses. The site needs to impersonate the user logged in via Active...

ASP.NET Windows Authentication logout

How do you logout when using Windows authentication in ASP.NET like this web.config? <authentication mode="Windows" /> I've already tried the following unsuccessfully. It redirects, but does not log out the user. void logoutButton_Click(object sender, EventArgs e) { HttpContext.Current.Session.Clear(); HttpContext.Current.Se...

ASP.Net site using Windows Authentication pops up "Authentication Required Window" a lot in Firefox

I have an ASP.Net application where I am using Windows authentication to deny access to some components via roles. When using IE, the site pops up the "Authentication Required" box once, allows the user to enter their username/password for Active Directory, and all is fine. HOWEVER, when using Firefox, it's "Authentication Required" bo...

ASP.NET > SqlServer; trust and delegation

Hello all, we have a system where they client wants integrated Windows authentication. This is an ASP.NET 3.5 application, connecting to Sql Server 2005. The web server is Server 2003 R2 SP2. The db server is Server 2003 SP2 (not R2). In the db server, I ran the following script exec sp_grantlogin 'myDomain\myUserGroup' USE myDbNam...

IIS7 hangs on AuthenticateRequest state in the module WindowsAuthentication

Hello All, I am running an ASP.NET application with a custom module registered under IIS7. Until two days back, everything was running fine. Now I notice that the requests started to hang at the AuthenticateRequest state and in the WindowsAuthentication module. My custom module intercepts at the BeginRequest state and processes the req...

User.IsInRole fails when using VS 2008's debugging web server on Windows 7 using Windows Auth

When the following line is called when running a website from the VS2008's web server i get a "The trust relationship between this workstation and the primary domain failed." exception. if (User.IsInRole("SomeRole")) ... I have turned UAC off, and set VS 2008, and it's built-in webserver, to run as an Administrator, and i have also re...

What goes behind the scene when we create System.DirectoryServices.DirectoryEntry instance?

Can you elaborate what goes behind the scene when we create DirectoryEntry instance? Code snippet: DirectoryEntry dirEntry = new DirectoryEntry("LDAP://CN=jsmith,DC=fabrikam,DC=Com", userName, password); I mean, how authentication works? Who talks with whom? Assume the code above is in a console application. ...

Secure WCF Service hosted in IIS 7 using the windows authentication restricted by defined group or users

How to configure a wcf service hosted in IIS 7 to enable access for only defined users / groups to. Existing configuration: <authentication mode="Windows"/> <services> <service name="MyService.Test" behaviorConfiguration="MyService.TestBehavior"> <endpoint address="" binding="wsHttpBinding" contract="MyService.ITest"> <ide...

Run Code as a different user (C#)

Is there a way to tell my code to run as a different user? I am calling NetUserSetInfo via a PInvoke and I need to call it as a different user. Is there a way to do that? ...

Windows Authentication, Custom permissions, WCF, Active Directory

Hello, I have a client/server project, communicating with WCF (Named Pipes for now, but that can change - but I cannot use IIS). This project is integrated with Active Directory. This program is designed to give users permissions that normally don't have permissions, by acting as a sort of proxy. The user uses the client to "request"...

MS Access 2003 + linked tables to SQL Server 2005 + Windows Authentication = slow

Our MS Access application with linked tables to SQL Server 2005 is slow when using Windows Authentication from Windows XP clients. We've been running it successfully using SQL Server authentication, but now we want to move to Windows Authentication for better security control. Setup: Database server: Windows 2003 Server, SQL Server...

Missing windows authentication IIS component because of Windows Vista Home Premium edition... any fixes out there?

Apparently Windows Vista Home Basic and Premium both do not ship with integrated windows authentication for IIS (You need Business edition)... so does anyone know how to get windows authentication installed for IIS? I went into Programs and Features > Turn Windows Features on or off. Then in the Windows Features popup I navigated to... ...

HttpContext.Current.User not populated with Windows Authentication enabled

I have an asp.net intranet application using windows authentication. I created the application years ago with VS 2005, and the windows authentication bit was working perfectly. My web.config has the following (inside configuration -> system.web element): <authentication mode="Windows" /> <authorization> <deny users="?"/> ...

Authentication in a SharePoint environment

We are developing a Intranet portal that uses integrated authentication, but a few sections of the site will be exposed to users who are not in the domain. For those users we plan to use anonymous access. However, our display logic for the entire application is based on the user logged into the portal, so we are not fully comfortable wit...

Windows Authentication on Novell network

I'm currently architecting a .NET 3.5 application for a customer with a preference for Single Sign-On from Windows, but whom is running in a Novell Netware 6 environment (WinXP desktops). Am I correct in thinking that this rules out the use of Integrated Windows Authentication inside a .NET application as a way of avoiding prompting the...

asp.net via kerberos integrated windows authentication to sql server

Please, can someone PLEASE give a simple, straight-forward way to enable ASP.NET > Kerberos > Sql Server? We have clientMachine > webServer > databaseServer. The client is insistent that the site must pull the windows login and not prompt, hence the need for Kerberos and Integrated Authentication. It also MUST impersonate the user onto...

Windows Authentication in IIS 7.5 Fails with Trust Relationship Exception

I have an ASP.Net 2.0 application that uses integrated Windows Authentication to authenticate/authorize users. The application works fine on Windows XP/IIS 5.1, Windows Server 2008/IIS 7, and Windows Vista/IIS 7. When I try to run this application on Windows 7/IIS 7.5, I get the following exception: The trust relationship between this ...

Why does an authentication mode of "Forms" result in an empty LOGON_USER server variable?

Is it possible to: Disallow anonymous access in IIS AND Have... <authenticate mode="Forms"/> ...in the Web config? We need both access to the ASP.Net Membership provider and access to the Windows username in the LOGON_USER server variable. What we've found is that disallowing anonymous access in IIS will only populate LOGON_USER ...

Cross-browser windows forms logoff?

Looking for a cross-browser way to log a user off a webpage which uses windows authentication. ...

IIS running as service Account with AzMan

Hi Guys I have a requirement to have a website running as a service accout for IP reasons, I also want to be able to use AzMan for Auth/Auth of the users. For some reason I cant seeem to get these working together. I have set up a sample app to test the waters that basically spits out some user credentials. Other than Azman and the web c...