pike.git / lib / modules / Protocols.pmod / LDAP.pmod / client.pike

version» Context lines:

pike.git/lib/modules/Protocols.pmod/LDAP.pmod/client.pike:1:   #pike __REAL_VERSION__      // LDAP client protocol implementation for Pike.   // - // $Id: client.pike,v 1.55 2005/04/20 15:37:48 mast Exp $ + // $Id: client.pike,v 1.56 2005/12/16 16:32:18 jonasw Exp $   //   // Honza Petrous, hop@unibase.cz   //   // ----------------------------------------------------------------------   //   // History:   //   // v0.0 1998-05-25 Starting up!   // v1.0 1998-06-21 Core functions (open, bind, unbind, delete, add,   // compare, search), only V2 operations,
pike.git/lib/modules/Protocols.pmod/LDAP.pmod/client.pike:148:       private array _New_decode(array ar) {       array res = ({});    array entry1;    mapping attrs;    object oder;       foreach(ar, string raw1) {    oder = (.ldap_privates.ldap_der_decode(raw1)->elements[1]); -  attrs = (["dn":({ASN1_DECODE_DN(oder)})]); +  string dn = ASN1_DECODE_DN(oder); +  if (ldap_version == 3) +  dn = utf2s(dn); +  attrs = (["dn" : ({ dn }) ]);    if(catch(entry1 = ASN1_GET_ATTR_ARRAY(oder))) continue;    foreach(entry1, object attr1) {    attrs += ([ASN1_GET_ATTR_NAME(attr1):_get_attr_values(ldap_version, attr1)]);    }    res += ({attrs});    }       return (res);    } // _New_decode   
pike.git/lib/modules/Protocols.pmod/LDAP.pmod/client.pike:361:    //! @tt{"ldap://hostname/basedn?attrlist?scope?ext"@}    //!    //! @param context    //! TLS context of connection    //!    //! @seealso    //! @[LDAP.client.bind], @[LDAP.client.search]    void create(string|void url, object|void context)    {    -  info = ([ "code_revision" : ("$Revision: 1.55 $"/" ")[1] ]); +  info = ([ "code_revision" : ("$Revision: 1.56 $"/" ")[1] ]);       if(!url || !sizeof(url))    url = LDAP_DEFAULT_URL;       lauth = parse_url(url);       if(!stringp(lauth->scheme) ||    ((lauth->scheme != "ldap")   #if constant(SSL.sslfile)    && (lauth->scheme != "ldaps")