windows-authentication

Windows Authentication & MVC: proper way to exclude individual file/route

为君一笑 提交于 2019-12-10 18:03:44
问题 I have an MVC 3 site which is protected via Windows Authentication. However, there is a physical file at the root of the site, along with a controller action method (via a custom route), which need to be available without authenticating. What is the proper way to do this? I want the entire site protected without needing [Authorize] at the top of my controllers (or in a base controller class). On IIS 7, I have both Anonymous and Windows Authentication enabled at the site root. Currently I have

Active Directory authorization: IIS vs Visual Studio Dev server

前提是你 提交于 2019-12-10 17:43:14
问题 I have a web project that uses Active Directory authorization (All controllers marked with AuthorizeAttribute ). In web.config i have following authentification section: <authentication mode="Windows" /> <authorization> <deny users="?" /> </authorization> The problem is: When i run project under Visual Studio Development Server everything goes fine, it pops authorization window, after entering login/password i can see all site contents. But, when i try to run it under IIS (7.5) authorization

SharePoint (WSS) Authentication Across Multiple Domains

喜欢而已 提交于 2019-12-10 17:22:50
问题 First, a little background: We have an intranet site based on WSS 3.0 that is hosted on a server in DOMAIN_A.LOCAL and set up to use Integrated Windows Authentication to authenticate users against Active Directory user accounts of DOMAIN_A.LOCAL . This setup works just fine for users who are logged into Windows using an AD account from DOMAIN_A.LOCAL , but when users try to access the site from a PC logged into Windows using an AD account from a different domain (i.e. DOMAIN_B.LOCAL ) the

How to send mails using SmtpClient and DefaultNetworkCredentials to a distribution list that only allows authenticated senders?

三世轮回 提交于 2019-12-10 16:09:33
问题 I'm trying to send automated emails from a C# console application from machines to clients all on the same domain via our internal Exchange 2007 server (using SMTP), but I'm hitting a snag with distribution lists that only allow authenticated senders. Basically the mails I'm sending are getting rejected by Exchange with: #550 5.7.1 RESOLVER.RST.AuthRequired; authentication required ##rfc822;AuthTESTGroup@example.com I'm using System.Net.Mail.SmtpClient and setting the Credentials property to

Oracle Connection String With Windows Authentication

心已入冬 提交于 2019-12-10 15:53:16
问题 We have a requirement to make our products work on Oracle as well as SQL Server (around which they were originally built). Unfortunately we don't have any in house Oracle development experience to speak of but as a senior dev it has fallen to me to lead the project. So far I have managed to make our app connect to an Oracle database (I'm using Oracle XE 11.2) by using the following connection string: Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=VS010-ORA11GR1)(PORT=1523))(CONNECT

Why does DirectoryServicesCOMException occur querying Active Directory from a machine other than the web server?

笑着哭i 提交于 2019-12-10 15:49:10
问题 My ASP.NET WebForms app running on IIS 7.5 works fine when the request comes from the web server but throws the following error when the same domain user requests the same page from any other machine on the domain: TYPE: System.DirectoryServices.AccountManagement.PrincipalOperationException MSG: An operations error occurred. at System.DirectoryServices.AccountManagement.PrincipalContext.DoLDAPDirectoryInit() at System.DirectoryServices.AccountManagement.PrincipalContext.DoDomainInit() at

ASP.NET Roles with Windows Auth

纵然是瞬间 提交于 2019-12-10 14:43:11
问题 Super simple question from an ASP newb: I've got an internal-only ASP.NET website I'm working on that uses Windows integrated auth across the board. There are essentially three roles I want to associate with the site: user, manager, and admin. The site is open to the entire org, so anyone who is authenticated is a user, unless they are a manager or an admin. The list of admins and managers needs to be in a database, not in the web.config. The role information for this site is not in any way

Pass-through authentication not working. IIS 7

China☆狼群 提交于 2019-12-10 14:15:08
问题 On IIS 7 I set up an application called "XYZ", and an application pool for it. I set the identity of this application pool to a custom user, let's call it "Mario". Mario has NTFS access to the folder/files in which XYZ points to (remote share). In the XYZ authentication settings, only windows authentication is enabled: In the providers for windows authentication, only NTLM is active: Physical path credentials for XYZ are set to application user / pass-through: So the problem is, when I go to

ASP.NET intranet site asking for credentials - Windows Authentication

笑着哭i 提交于 2019-12-10 14:01:12
问题 I created my first website in ASP.Net and I am trying to get it up and running on our intranet here at work. I have got almost everything completed now, and I have come to a roadblock. I need to use Windows Authentication - requirement from my team - so I went through the process of setting up the site. I have everything configured and attempted to access the site (non-localhost) and got a dialog box asking for my login credentials. I cannot figure out for the life of me why that is. I have

WindowsIdentity.Name doesn't return new name from Active Directory

断了今生、忘了曾经 提交于 2019-12-10 12:19:50
问题 Any help on this would be TRULY appreciated. I'll spare you the details, but we have to rename all of our Active Directory users from [First name] [Last Name] to [First Initial][Last Name] to get the space out of the usernames. We have a production web application that uses the following line of code to get the Username from Windows once the user logs in with Windows Authentication: System.Security.Principal.WindowsIdentity.GetCurrent().Name After we update a user's account through Active