Single Sign-on redirect loop
Created by: zagriyen
Hi, when i put the single sign-on snippet with my primary domain I've got a redirect loop when i go to a another network
// Cookies
define( 'COOKIEHASH', md5( 'yourdomain.com' ) );
define( 'COOKIE_DOMAIN', 'yourdomain.com' );
define( 'ADMIN_COOKIE_PATH', '/' );
define( 'COOKIEPATH', '/' );
define( 'SITECOOKIEPATH', '/' );
define( 'TEST_COOKIE', 'thing_test_cookie' );
define( 'AUTH_COOKIE', 'thing_' . COOKIEHASH );
define( 'USER_COOKIE', 'thing_user_' . COOKIEHASH );
define( 'PASS_COOKIE', 'thing_pass_' . COOKIEHASH );
define( 'SECURE_AUTH_COOKIE', 'thing_sec_' . COOKIEHASH );
define( 'LOGGED_IN_COOKIE', 'thing_logged_in' . COOKIEHASH );
Imported comments:
By johnjamesjacoby on 2015-08-17 04:29:46 UTC
Hi. Did you replace "yourdomain.com" and "thing_" with yours?
By zagriyen on 2015-08-17 17:26:32 UTC
Hi, i replace them by "jm_" and it doesn't work. but i use 2 diferents domain, network 1 domain1 and network 2 domain2 maybe it's the problem
By johnjamesjacoby on 2015-10-22 21:11:07 UTC
For single-sign-on to work, you'll need more than just cookie sharing. You'll need to do some fancy redirecting to drop & read the appropriate cookies. That's a bit beyond the scope of WPMN for now, but it would be ideal if it were built in.