Login via HTTPS in Moodle 2.0 after login, loops infinately.

Re: Login via HTTPS in Moodle 2.0 after login, loops infinately.

by Daniel Kaelin -
Number of replies: 0

In order to use sslproxy=true you have to make sure to comment out the following lines in lib/setuplib.php. 

They are typically found around line 822

} /*else {
if ($wwwroot['scheme'] !== 'https') {
throw new coding_exception('Must use https address in wwwroot when ssl proxy enabled!');
}
$rurl['scheme'] = 'https'; // make moodle believe it runs on https, squid or something else it doing it
} */

 

When using sslproxy Moodle expects the wwwroot to be HTTPS. If you are using HTTPS logins only you won't be setting your wwwroot to HTTPS. This suppresses the resulting error.