Subversion Repositories Applications.papyrus

Rev

Rev 271 | Rev 313 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 271 Rev 307
Line 19... Line 19...
19
// | You should have received a copy of the GNU Lesser General Public                                     |
19
// | You should have received a copy of the GNU Lesser General Public                                     |
20
// | License along with this library; if not, write to the Free Software                                  |
20
// | License along with this library; if not, write to the Free Software                                  |
21
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
21
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
22
// |                                                                                                      |
22
// |                                                                                                      |
23
// +------------------------------------------------------------------------------------------------------+
23
// +------------------------------------------------------------------------------------------------------+
24
// CVS : $Id: pap_initialise_auth.inc.php,v 1.13 2005-02-22 18:27:24 jpm Exp $
24
// CVS : $Id: pap_initialise_auth.inc.php,v 1.14 2005-03-15 14:20:01 jpm Exp $
25
/**
25
/**
26
* Initialisation de l'authentification.
26
* Initialisation de l'authentification.
27
*
27
*
28
* Suite à la recherche des informations depuis la base de données nous initialisons
28
* Suite à la recherche des informations depuis la base de données nous initialisons
29
* l'authentification des utilisateurs si le site l'utilise.
29
* l'authentification des utilisateurs si le site l'utilise.
Line 35... Line 35...
35
//Auteur original :
35
//Auteur original :
36
*@author            Alexandre GRANIER <alex@tela-botanica.org>
36
*@author            Alexandre GRANIER <alex@tela-botanica.org>
37
//Autres auteurs :
37
//Autres auteurs :
38
*@author            Jean-Pascal MILCENT <jpm@tela-botanica.org>
38
*@author            Jean-Pascal MILCENT <jpm@tela-botanica.org>
39
*@copyright         Tela-Botanica 2000-2004
39
*@copyright         Tela-Botanica 2000-2004
40
*@version           $Revision: 1.13 $ $Date: 2005-02-22 18:27:24 $
40
*@version           $Revision: 1.14 $ $Date: 2005-03-15 14:20:01 $
41
// +------------------------------------------------------------------------------------------------------+
41
// +------------------------------------------------------------------------------------------------------+
42
*/
42
*/
Line 43... Line 43...
43
 
43
 
44
// +------------------------------------------------------------------------------------------------------+
44
// +------------------------------------------------------------------------------------------------------+
Line 98... Line 98...
98
            : '';
98
            : '';
99
        $tab_auth_bdd = $resultat_auth_bdd->fetchRow(DB_FETCHMODE_OBJECT) ;
99
        $tab_auth_bdd = $resultat_auth_bdd->fetchRow(DB_FETCHMODE_OBJECT) ;
100
        if ($ligne_auth->gsa_id_auth == $_GEN_commun['info_site']->gs_ce_auth) {
100
        if ($ligne_auth->gsa_id_auth == $_GEN_commun['info_site']->gs_ce_auth) {
101
            $_GEN_commun['info_auth_bdd'] = $tab_auth_bdd ;
101
            $_GEN_commun['info_auth_bdd'] = $tab_auth_bdd ;
102
        }
102
        }
103
        $GLOBALS['_PAPYRUS_']['auth'][$ligne_auth->gsa_id_auth]=array_merge($GLOBALS['_PAPYRUS_']['auth'][$ligne_auth->gsa_id_auth], $tab_auth_bdd);
103
        $GLOBALS['_PAPYRUS_']['auth'][$ligne_auth->gsa_id_auth] = array_merge($GLOBALS['_PAPYRUS_']['auth'][$ligne_auth->gsa_id_auth], $tab_auth_bdd);
104
        $resultat_auth_bdd->free();
104
        $resultat_auth_bdd->free();
105
    
105
        
-
 
106
        // Gestion des arguments de l'authentification
-
 
107
        if (isset($GLOBALS['_GEN_commun']['info_auth_bdd']->gsab_parametres)) {
-
 
108
            $arguments = explode(' ', $GLOBALS['_GEN_commun']['info_auth_bdd']->gsab_parametres);
-
 
109
            for ($i = 0; $i < count($arguments); $i++) {
-
 
110
                $attr = explode('=', $arguments[$i]);
-
 
111
                if ($attr[0] != '') {
-
 
112
                    $GLOBALS['_GEN_commun']['info_auth_bdd']->$attr[0] = (isset($attr[1]) ? $attr[1] : '');
-
 
113
                }
-
 
114
            }
-
 
115
        }
106
    } else if ($ligne_auth->gsa_ce_auth_ldap != 0) {
116
    } else if ($ligne_auth->gsa_ce_auth_ldap != 0) {
107
        //Identification via LDAP :
117
        //Identification via LDAP :
108
        $requete_auth_ldap =    'SELECT * '.
118
        $requete_auth_ldap =    'SELECT * '.
109
                                'FROM gen_site_auth_ldap '.
119
                                'FROM gen_site_auth_ldap '.
110
                                'WHERE gsal_id_auth_ldap = '.$ligne_auth->gsa_ce_auth_ldap;
120
                                'WHERE gsal_id_auth_ldap = '.$ligne_auth->gsa_ce_auth_ldap;
Line 258... Line 268...
258
}
268
}
Line 259... Line 269...
259
 
269
 
260
 
270
 
-
 
271
/* +--Fin du code ---------------------------------------------------------------------------------------+
-
 
272
* $Log: not supported by cvs2svn $
-
 
273
* Revision 1.13  2005/02/22 18:27:24  jpm
261
/* +--Fin du code ---------------------------------------------------------------------------------------+
274
* Changement de nom de variables.
262
* $Log: not supported by cvs2svn $
275
*
263
* Revision 1.12  2004/12/15 15:24:45  alex
276
* Revision 1.12  2004/12/15 15:24:45  alex
264
* suppression d'un notice
277
* suppression d'un notice
265
*
278
*