2. Sourcecodeorganization

2.1. Structure of the code

Figure 15.1. LDAP source schema


Scripts for the import |
   of certificates     |
                       |
-----------------------| scripts to add
                       | objects to LDAP
   export-import.lib/  |
     ldap-utils.lib    |
                       |
----------------------------------------

                 OpenCA::LDAP
                

2.2. The relevant commands

  • addCertsLDAP (puts all valid certs to LDAP)

  • addCrlLDAP (puts all CRLs to LDAP)

  • importAllFromCA (via export-import.lib)

  • importCRL (via export-import.lib)

  • importCerts (via export-import.lib)

  • importCertsLDAP (puts all certs from the last import to LDAP)

  • importConfig (puts CA-certs to LDAP)

  • updateCACertsLDAP (update the CA-certificates on the ldap server)

  • updateCRLonLDAP (writes the most actual CRL to LDAP)

  • updateCertsLDAP (writes/removes the user-certificates to/from LDAP)

  • updateLDAP (puts all certs from the last import to LDAP)

(oh, we have a redundancy here updateLDAP and addCertsLDAP do the same) (updateLDAP is reserved for the future so set all links etc. to importCertsLDAP) (addCertsUser should not be a function of ldap-utils.lib)

2.3. export-import.lib

eximObjectToLDAP

2.4. ldap-utils.lib

  • LDAP_addCertsUsers (will be moved to importCertsLDAP)

  • LDAP_get_crl (determines the newest CRL)

  • LDAP_get_ca (determines the newest CA certificate)

2.5. OpenCA::LDAP

  • add_object (takes a cert and create the necessary nodes in the LDAP)

  • add_attribute (add certs and CRLs to the LDAP)

  • delete_attribute (remove certificates from LDAP)