Share » Forums » Developer » SSO With eZ publish

SSO With eZ publish

SSO With eZ publish

Thursday 10 February 2011 3:14:44 am - 3 replies

Author Message

Matthieu Sévère

Thursday 10 February 2011 3:27:39 am

Hi,

You should have a look at this project : http://projects.ez.no/janrainauth

It doesn't use a SSO handler but you have example code to login and create users.

Cheers

--
eZ certified developer: http://ez.no/certification/verify/346216

Brijesh Tekrawala

Thursday 10 February 2011 4:35:40 am

I have another site available and need to setup SSO from there. can someone please send sample code for SSOHandler ?

B Pierre

Friday 11 February 2011 7:26:31 am

In french : http://www.lolart.net/blog/ez-publish/utilisation-d-un-sso-dans-ez-publish

In english : http://share.ez.no/learn/ez-publish/using-a-sso-in-ez-publish

A simple sample :

public function handleSSOLogin()
{
$currentUser = false; // Valeur par defaut que l'on retourne si l'authentification échoue

//Si un utilisateur est authentifié on le récupère.
if (phpCAS::checkAuthentication())
{
$currentUser = eZUser::fetchByName(phpCAS::getUser());

//Si l'utilisateur n'est pas connu dans eZPublish
if(!is_object( $currentUser ))
{
$currentUser=false;
}
}

return ($currentUser);
}

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu