Good afternoon,
I am french and I want to use cas 3 for an intranet.
I wish offer an expired password functionality .

Users, password and dates of password expiration are in a
database.

A french person advise me to do this :

- Create a JDBCAuthenticationHandler extended of :
* SearchModeSearchDatabaseAuthenticationHandler
or
* BindModeSearchDatabaseAuthenticationHandler

In this handler, after the password checking, i have to check
if the passsword was expired :
- if the password is not expiring :
authenticateUsernamePasswordInternal return "true"
- else : throw an exception PasswordExpiredException type of
BadUsernameOrPasswordAuthenticationException

This exception must be catched by an action custom which
replace AuthenticationViaFormAction.
If the exception was catched,the application return an event
"expiredPassword".

Modify "login-webflow" to run password modification


I want to know if you have already done this?


thank you

Jean-Michel


en français :


Bonjour,

Je suis stagiaire et je souhaite mettre en place un serveur
CAS afin de gérer
l'authentification des applications internes de mon entreprise.

Actuellement l'intranet possède un système qui oblige
l'utilisateur à
changer de mot de passe tous les mois et de ne pas redonner un
mot de passe
similaire aux 6 derniers mois.

Pensez vous qu'il est possible d'adapter l'appli CAS afin de
se conformer à ce
fonctionnement.

Je vous remercie.


réponse:

Voici un exemple de solution à partir d'une architecture CAS 3.x :
- Ecrivez votre propre JDBCAuthenticationHandler en étendant
au choix :
* SearchModeSearchDatabaseAuthenticationHandler
* BindModeSearchDatabaseAuthenticationHandler
Dans ce même handler, il vous faudra APRES avoir valider les
credentials de votre utilisateur valider que son mot de passe
n'est pas expiré.
- si le mot de passe n'est pas expiré :
authenticateUsernamePasswordInternal devra retourner "true"
- sinon lever une exception PasswordExpiredException de type
BadUsernameOrPasswordAuthenticationException

Cette exception doit être catchée par une action custom qui
remplacera l'AuthenticationViaFormAction de CAS. Si
l'expiration est lancée, retournez un nouvel event
"expiredPassword".
Modifier le "login-webflow" pour prendre en compte cet event
et démarrer un webflow de modification du mot de passe qu'il
vous faudra écrire.


J'espère avoir répondu à vos questions. D'autre part, je vous
conseille de demander sur la liste de discussion officielle de
CAS ( [email protected]) si des personnes n'ont pas par
hasard déjà effectuées ce travail.


Créez votre adresse électronique [EMAIL PROTECTED] 
1 Go d'espace de stockage, anti-spam et anti-virus intégrés.

_______________________________________________
Yale CAS mailing list
[email protected]
http://tp.its.yale.edu/mailman/listinfo/cas

Reply via email to