Loading TOC...

MarkLogic 12 EA 1 Product Documentation
sec.externalSecuritySetLdapCertificate

sec.externalSecuritySetLdapCertificate(
   external-security-name as String,
   ldap-certificate as String,
   ldap-private-key as String
) as null

Summary

This function sets the LDAP certificate and private key for the named external security configuration.

Parameters
external-security-name The name of an external-security configuration.
ldap-certificate The PEM encoded X509 client certificate for MarkLogic server to connect the LDAP server. It can be used for mutual authentication if bind method is MD5 or simple. Or it can be used for external binding.
ldap-private-key The PEM encoded private key corresponding to the certificate.

Required Privileges

http://marklogic.com/xdmp/privileges/external-security-set-ldap-certificate

Usage Notes

This function must be executed against the security database.

Example


declareUpdate();
const sec = require('/MarkLogic/security');

sec.externalSecuritySetLdapCertificate(
       'ldapconfig', 
       sec.externalSecurityGetLdapCertificate('ldapconfig'),
       sec.externalSecurityGetLdapPrivateKey('ldapconfig') 
);
   

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.