{"id":1329,"date":"2016-12-13T14:45:26","date_gmt":"2016-12-13T13:45:26","guid":{"rendered":"https:\/\/elkano.org\/blog\/?p=1329"},"modified":"2016-12-13T09:16:55","modified_gmt":"2016-12-13T08:16:55","slug":"openldap-como-establecer-la-clave-de-root-del-esquema","status":"publish","type":"post","link":"https:\/\/elkano.org\/blog\/openldap-como-establecer-la-clave-de-root-del-esquema\/","title":{"rendered":"OpenLDAP &#8211; c\u00f3mo establecer la clave de root del esquema"},"content":{"rendered":"<p>Si necesitamos establecer la clave del usuario admin bajo la rama config (<strong>cn=admin,cn=config<\/strong>) podemos seguir los siguientes pasos:<\/p>\n<p>Crear un fichero ldif llamado <strong>rootpw_cnconfig.ldif<\/strong> con el siguiente contenido:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-linenumbers=\"false\" data-enlighter-theme=\"atomic\">\r\ndn: olcDatabase={0}config,cn=config\r\nchangetype: modify\r\nreplace: olcRootPW\r\nolcRootPW: NUEVACLAVE\r\n<\/pre>\n<p>Y ejecutar el siguiente comando:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-linenumbers=\"false\" data-enlighter-theme=\"atomic\">\r\nldapmodify -Y EXTERNAL -H ldapi:\/\/\/ -f rootpw_cnconfig.ldif\r\nSASL\/EXTERNAL authentication started\r\nSASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth\r\nSASL SSF: 0\r\nmodifying entry &quot;olcDatabase={0}config,cn=config&quot;\r\n<\/pre>\n<p>A partir de ahora ya podr\u00edamos usar la clave en los comandos de ldap de la siguiente forma si necesitamos realizar cambios en el esquema:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-linenumbers=\"false\" data-enlighter-theme=\"atomic\">\r\nldapmodify -d &quot;cn=admin,cn=config&quot; -W -f fichero.ldif\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Si necesitamos establecer la clave del usuario admin bajo la rama config (cn=admin,cn=config) podemos seguir los siguientes pasos: Crear un fichero ldif llamado rootpw_cnconfig.ldif con el siguiente contenido: dn: olcDatabase={0}config,cn=config changetype: modify replace: olcRootPW olcRootPW: NUEVACLAVE Y ejecutar el siguiente comando: ldapmodify -Y EXTERNAL -H ldapi:\/\/\/ -f rootpw_cnconfig.ldif SASL\/EXTERNAL authentication started SASL username: gidNumber=0+uidNumber=0,cn=peercred,cn=external,cn=auth SASL [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[3],"tags":[197,198,193,199,94],"_links":{"self":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts\/1329"}],"collection":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/comments?post=1329"}],"version-history":[{"count":0,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts\/1329\/revisions"}],"wp:attachment":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/media?parent=1329"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/categories?post=1329"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/tags?post=1329"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}