Quantcast
Channel: Authentication
Viewing all articles
Browse latest Browse all 8256

SSO via HTTP header

$
0
0
by David Bolger.  

Hi all!

I have linked Moodle 2.4 with my LDAPserver and it is working perfectly to create new users and allow users log in. I am now trying to set up Single Sign-on using Open AM.

I have the username being delivered as part of the HTTP header ($_SERVER['REMOTE_USER']) but can't figure out how to force Moodle to accept this as a login authentication.

I tried editing the auth.php file, removing the SSO check from the user_login function and just replacing it with a "return true;". I also tried replacing the $username variable in the get_userinfo function with $_SERVER['REMOTE_USER'];

However after these changes, all I've managed to do is force Moodle to ignore the username/password passed to it by the Login button and instead to create an entirely new user every time the Login button is pressed, with the REMOTE_USER value as the username.

Obviously this isn't the right way to go about this. Can anybody suggest a simpler way to have Moodle automate logins using the REMOTE_USER header as the username?

Thanks!

David


Viewing all articles
Browse latest Browse all 8256

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>