https://bugs.openldap.org/show_bug.cgi?id=10389
Issue ID: 10389
Summary: mdb_opinfo_get: Assertion `!rc' failed. And data got
lost.
Product: OpenLDAP
Version: 2.6.9
Hardware: x86_64
OS: Linux
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: backends
Assignee: bugs(a)openldap.org
Reporter: 3049720393(a)qq.com
Target Milestone: ---
Hi All,
Don't know whether this problem is related to this bug or not, but want to
share it here as we still do not know the reason ;)
We're using version 2.6.9 now and started up by docker container. It works very
well when installing and starting it on a server instance.
But recently, we try to create it on Azure Container Apps service (which is a
service supporting to start docker containers), but found out that when two
openldap containers(openldap processes) run at the same time with same data
volume mounted, well, one is normally started, and another one is looping to
try to start but always failed.
The failed one shows errors:
```
mdb_db_open: database "dc=xxx,dc=exmple,dc=com" cannot be opened: Resource
temporarily unavailable (11). Restore from backup!
backend_startup_one (type=mdb, suffix="dc=xxx,dc=exmple,dc=com"): bi_db_open
failed! (11)
```
I think this is OK, because the started one is occupying the resources. And the
started up one is working well for some time, BUT suddenly at some point, it
went down to exit with the following error messages:
```
slapd: id2entry.c:828: mdb_opinfo_get: Assertion `!rc' failed.
/usr/local/bin/entrypoint.sh: line 160: 50 Aborted (core
dumped) slapd -d 32768 -u openldap -g openldap -F /etc/ldap/slapd.d
```
And as the previous normal one is exit, the other one can start up normally. So
we bash into it and ran `ldapsearch` command and found out that some of the
people entries were gone!!! But until now we still do not know the reason...
try to get some help here ;) thanks.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10358
Issue ID: 10358
Summary: syncrepl can revert an entry's CSN
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: ondra(a)mistotebe.net
Target Milestone: ---
Created attachment 1080
--> https://bugs.openldap.org/attachment.cgi?id=1080&action=edit
Debug log of an instance of this happening
There is a sequence of operations which can force a MPR node to apply changes
out of order (essentially reverting an operation). Currently investigating
which part of the code that should have prevented this has let it slip.
A sample log showing how this happened is attached.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10360
Issue ID: 10360
Summary: delta-sync can apply old mods
Product: OpenLDAP
Version: 2.6.9
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: hyc(a)openldap.org
Target Milestone: ---
This might be related to #10358, but not sure.
In delta MPR, if an older mod is received on an entry after a newer mod has
already been applied by a local user, the older mod is applied and the newer
mod is lost.
The incoming replication ops are checked for freshness by check_csn_age() but
that only checks the incoming cookieCSN against contextCSNs of the same SID.
I.e., that check only prevents duplicate mods being replicated multiple times
from the same remote provider. If check_csn_age() passes, then
syncrepl_message_to_op() is invoked which just applies the mod. It doesn't
check the mod or cookieCSN against the entry's current entryCSN.
The code in syncrepl_op_mod() performs the checks we need. The code just needs
to be pulled into a new function so it can be used in both places.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10384
Issue ID: 10384
Summary: str2entry2() leaks attributes on error
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: ondra(a)mistotebe.net
Target Milestone: ---
If there's error processing attribute values, the attribute list in ahead is
not freed.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10380
Issue ID: 10380
Summary: file logger doesn't emit slapd startup/version info
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: ondra(a)mistotebe.net
Target Milestone: ---
When using syslog, a startup message is emitted which is useful in many
different contexts:
- signals a slapd restart to the admin
- shows the actual version used
- if a crash happened just before, there is no "stopped" message, this is a
hint to anyone looking that something was not right and the slapd is not the
same process
- people writing log processing scripts (incident response) know when it's
necessary to reset their state, again as it's a new process
Because of the above, it feels like a regression to me.
I guess we can just emit this info on logfile config handlers? This means
startups and logfile switches are still handled as they used to in syslog and
log rotation doesn't emit anything (making it easy and safe to just concatenate
files).
Yes, slapd logs its PID in most formats so restarts can be detected that way,
but that's considerably harder to search for.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10379
Issue ID: 10379
Summary: lastbind change prevents ppolicy response from
reaching accesslog
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: ondra(a)mistotebe.net
Target Milestone: ---
When "lastbind on" and ppolicy are configured together, the pwdLastSuccess
update triggers an accesslog entry (using op->o_time, op->o_tincr), then
ppolicy_bind_response issues its own modification and since the time was copied
in lastbind, an entry of the same name already exists. This means the ppolicy
change is lost (and e.g. won't replicate).
Note that slapo-lastbind (=the contrib overlay) probably has the same impact.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10385
Issue ID: 10385
Summary: syncprov should use accesslog's rootDN when reading it
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: overlays
Assignee: bugs(a)openldap.org
Reporter: ondra(a)mistotebe.net
Target Milestone: ---
When replaying accesslog, syncprov runs a be_search, it should switch to using
the appropriate rootDN for the database.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10387
Issue ID: 10387
Summary: Reverse lookup does not work for IPv6 addresses
proxied over IPv4
Product: OpenLDAP
Version: 2.6.10
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: slapd
Assignee: bugs(a)openldap.org
Reporter: +openldap(a)Eero.xn--Hkkinen-5wa.fi
Target Milestone: ---
I have an IPv4/IPv6 reverse proxy server which listens for ldap[s]://
connections and forwards them using the proxy procotol to an IPv4-only slapd
server which listens for pldap[s]:// connections. The slapd server has the
global olcReverseLookup setting set to TRUE.
The reverse lookup works as expected if an LDAP client connects to the reverse
proxy using IPv4. However, if the LDAP client connects to the reverse proxy
using IPv6, the reverse lookup does not work.
The slap_listener function in the servers/slapd/daemon.c file accepts a
connection
(https://git.openldap.org/openldap/openldap/-/blob/OPENLDAP_REL_ENG_2_6_10/s…).
Because the reverse proxy connects to the slapd server using the proxy protocol
over IPv4, this fills the from variable with an IPv4 address and sets the len
variable to the size of the struct sockaddr_in. This is correct.
The slap_listener function detects that the connection is proxied
(https://git.openldap.org/openldap/openldap/-/blob/OPENLDAP_REL_ENG_2_6_10/s…)
and uses the proxyp function to get the address of the LDAP client. This fills
the from variable with an IPv4 or an IPv6 address (depending on whether the
LDAP client used IPv4 or IPv6 to connect the reverse proxy) but does not update
the len variable.
The slap_listener function detects that reverse lookup is to be used
(https://git.openldap.org/openldap/openldap/-/blob/OPENLDAP_REL_ENG_2_6_10/s…)
and used the ldap_pvt_get_hname function to get the reverse name
(https://git.openldap.org/openldap/openldap/-/blob/OPENLDAP_REL_ENG_2_6_10/s…)
passing the address of the from variable, which may contain either an IPv4 or
an IPv6 address, and the value of the len variable, which is equal to the size
of the struct sockaddr_in. This is correct for IPv4 but not for IPv6.
Either the slap_listener function or the proxyp function should update the
value of the len variable.
--
You are receiving this mail because:
You are on the CC list for the issue.
https://bugs.openldap.org/show_bug.cgi?id=10254
Issue ID: 10254
Summary: Allow upgrading password hash on bind
Product: OpenLDAP
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Keywords: needs_review
Severity: normal
Priority: ---
Component: overlays
Assignee: bugs(a)openldap.org
Reporter: me(a)floriswesterman.nl
Target Milestone: ---
Many OpenLDAP installations are likely to contain relatively old password
hashes such as SSHA and CRYPT, as modern alternatives such as Argon are only
recent additions. Due to the nature of password hashes, it is of course not
possible to "unhash" the old values and rehash them with a more modern
algorithm. The presence of these old password hashes poses a liability in case
of information leaks or hacks.
Currently, the only way to upgrade a password hash is to wait for the user to
change their password. This can be sped up by expiring passwords and forcing
users to change them. However, this can be slow and frequent password rotation
is no longer considered a best practice.
It would be a very helpful addition to add support for upgrading a password
hash on bind. This is implemented in the 389 directory server:
https://www.port389.org/docs/389ds/design/pwupgrade-on-bind.html
Essentially, when a user binds, the password is checked like normal. In case of
a successful bind, the proposed feature would check the hash algorithm used for
the password; and in case it is not equal to the current `olcPasswordHash`
value, the user-provided password is rehashed using the new algorithm and
stored. This way, the old hashes are phased out more quickly, without being a
disturbance to users.
--
You are receiving this mail because:
You are on the CC list for the issue.