Subversion Repositories wimsdev

Rev

Rev 13014 | Blame | Compare with Previous | Last modification | View Log | RSS feed

ldap_find=!sh which ldapsearch
!if $ldap_find issametext $empty
  auth_test=ERROR no_ldap
  !exit
!endif

!default authdef=wimshome/log/classes/$class/.def

ldap_auth=!defof class_ldap_auth in $authdef
!default ldap_auth=!defof ldap_auth in wimshome/log/wims.conf

ldap_port=!defof class_ldap_port in $authdef
!default ldap_port=!defof ldap_port in wimshome/log/wims.conf

ldap_version=!defof class_ldap_version in $authdef
!default ldap_version=!defof ldap_version in wimshome/log/wims.conf

ldap_base=!defof class_ldap_base in $authdef
!default ldap_base=!defof ldap_base in wimshome/log/wims.conf

ldap_branch=!defof class_ldap_branch in $authdef
!default ldap_branch=!defof ldap_branch in wimshome/log/wims.conf

ldap_uid=!defof class_ldap_uid in $authdef
!default ldap_uid=!defof ldap_uid in wimshome/log/wims.conf

#ldap_id=!replace internal " by in $ldap_uid=$(wims_read_parm[1]),$ldap_branch,$ldap_base
ldap_id=!replace internal " by in $ldap_uid=$(wims_read_parm[1])

ldap_login=!defof class_ldap_login in $authdef
!default ldap_login=!defof ldap_login in wimshome/log/wims.conf

ldap_accreditation=!defof class_ldap_accreditation in $authdef
!default ldap_accreditation=!defof ldap_accreditation in wimshome/log/wims.conf

###### specific fields
!set l_regnum=!defof class_ldap_regnum in $authdef
!default l_regnum=!defof ldap_regnum in wimshome/log/wims.conf
!!upsCodeEtu
!set l_photourl=!defof class_ldap_photourl in $authdef
!default l_photourl=!defof ldap_photourl in wimshome/log/wims.conf
!!upsURLPhoto
!set l_email=!defof class_ldap_email in $authdef
!default l_email=!defof ldap_email in wimshome/log/wims.conf
!!eduPersonPrincipalName

##### standard field
!set l_uid=uid
!set l_lastname=sn
!set l_firstname=givenName
!set l_password=password
!set l_login=$ldap_login

###
!set wims_code=lastname,firstname,regnum,photourl,email
!set ldap_code=!makelist $$$$$$$ l_ x for x in $wims_code
!default l_login=$l_uid
!default ldap_identifiant=$l_login
!set ldap_code=!nospace $ldap_code,$l_login
!set ldap_code_=!items2words $ldap_code

!if $ldap_login!=$empty
  !set login_method=$idp_method $ldap_login
!endif