Enabling Single Sign On in IIS
Expected Behavior (or desired behavior if a feature request)
Is there any way to enable Single Sign On Trough Windows Authentification in SnipeIT?
I know that the Authentication via REMOTE_USER was introduced in #5142 but I don't know how to set it up, so that I can open the SnipeIT-Page and it will use my Windows Credentials.
When I enable the settings for the REMOTE_USER (I have to enable it through the database because it won't save the settings through the normal backend) and I enable Windows Authentification through the IIS Authentification Tab it won't accept my login details and the login window will popup over and over again.
Please confirm you have done the following before posting your bug report:
- [X] I have enabled debug mode
- [X] I have read checked the Common Issues page
Provide answers to these questions:
- Is this a fresh install or an upgrade?
- Upgrade
- Version of Snipe-IT you're running
- v4.6.5
- Version of PHP you're running
- v7.0.9
- Version of MySQL/MariaDB you're running
- 5.7.17 MySQL Community Server
- What OS and web server you're running Snipe-IT on
- Windows Server 2012 R2 / Microsoft-IIS 8.5
- What method you used to install Snipe-IT (install.sh, manual installation, docker, etc)
- manual installation
- WITH DEBUG TURNED ON, if you're getting an error in your browser, include that error
- What specific Snipe-IT page you're on, and what specific element you're interacting with to trigger the error
- If a stacktrace is provided in the error, include that too.
- Any errors that appear in your browser's error console.
- Confirm whether the error is reproducible on the demo: https://snipeitapp.com/demo.
- Include any additional information you can find in
storage/logsand your webserver's logs. - Include what you've done so far in the installation, and if you got any error messages along the way.
- Indicate whether or not you've manually edited any data directly in the database
Please do not post an issue without answering the related questions above. If you have opened a different issue and already answered these questions, answer them again, once for every ticket. It will be next to impossible for us to help you.
https://snipe-it.readme.io/docs/getting-help
@PascalTr Have you verified that the REMOTE_USER server variable is being passed to the website? Also is the site running behind a proxy? That could create issues.
@jwhulette Could you tell me how I can check if the server variable is being passed? No, we are accessing the site directly without a proxy.
The easiest if it’s not a production site is to just put dd($_SERVER) in the index.php file and see if the variable is there after coming from your other site.
@jwhulette Thanks. I got it working with the Internet Explorer. But when I try to open the website with Firefox it just shows the windows login mask over and over again. I have enabled the NTLM Option in the about:config settings and added the FQDN as one of the Trusted URIS.
I've also enabled the Windows Authentification in IIS and set the provider to NTLM. I'm using an Active Directory-Server to authenticate.
@PascalTr I'm not sure on Firefox. It should work. What do the logs say when you use Firefox.