Bug 41648 - slapd failed if line in slapd.conf to long. Affected at least ldap indexes (ldap/index/{eq, approx, etc.})
slapd failed if line in slapd.conf to long. Affected at least ldap indexes (l...
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: UCR
UCS 3.2
Other Linux
: P5 normal (vote)
: UCS 4.1-3-errata
Assigned To: Felix Botner
Stefan Gohmann
:
Depends on:
Blocks: 46743 46747
  Show dependency treegraph
 
Reported: 2016-06-23 10:53 CEST by Michel Smidt
Modified: 2018-03-27 11:55 CEST (History)
3 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 3: Simply Wrong: The implementation doesn't match the docu
Who will be affected by this bug?: 1: Will affect a very few installed domains
How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain: 0.034
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Ticket number:
Bug group (optional): Forked for project
Max CVSS v3 score:
sieverdingbeck: Patch_Available+


Attachments
PoC patch to automatically wrap index lines (1.67 KB, patch)
2016-06-30 22:30 CEST, Ingo Sieverdingbeck
Details | Diff
PoC patch to automatically wrap index lines (1.35 KB, patch)
2016-07-05 11:04 CEST, Ingo Sieverdingbeck
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michel Smidt univentionstaff 2016-06-23 10:53:21 CEST
If lines in slapd.conf are too long (>2048 chars) the slapd.conf do not start.
Error:
"Starting ldap server(s): slapd .../etc/ldap/slapd.conf: line 108: no indexes selected
failed."

This affected at least the indexes section which will be set bei UCR-Variables ldap/index/{eq, approx, etc.}

So, the slapd runs perfectly fine if the line will be wrapped to a newline. e.g.
index attr1,attr2 eq
index attr3,attr4 eq
Comment 1 Ingo Sieverdingbeck univentionstaff 2016-06-30 22:30:43 CEST
Created attachment 7780 [details]
PoC patch to automatically wrap index lines
Comment 2 Ingo Sieverdingbeck univentionstaff 2016-07-05 11:04:39 CEST
Created attachment 7784 [details]
PoC patch to automatically wrap index lines
Comment 3 Felix Botner univentionstaff 2016-08-24 09:43:52 CEST
Fixed conffiles/etc/ldap/slapd.conf.d/40univention-ldap-server_database. If a index line is more than 2000 chars, the remaining attributes (+ the necessary config options ) are put on next line.

univention-ldap.yaml
merged to 4.2
Comment 4 Stefan Gohmann univentionstaff 2016-09-07 07:30:18 CEST
Code review: OK

ucs-test: OK

Tests: OK. It was little bit difficult due to Bug #39501 but I've created new attributes

YAML: I've changed the entry: r72335
Comment 5 Janek Walkenhorst univentionstaff 2016-09-07 18:41:44 CEST
<http://errata.software-univention.de/ucs/4.1/249.html>