log: Add more info about DN mapping during bind (info log)

This commit is contained in:
selfhoster selfhoster 2026-08-28 11:32:17 +02:00
commit 39c70d297e

View file

@ -90,7 +90,7 @@ pub async fn bind<W: AsyncWrite + Unpin>(
);
dn.set_hostname(&mapping.to, false);
lbr.dn = dn.to_dn_string();
let dn = lbr.dn.clone();
let backend_dn = lbr.dn.clone();
// We need the client to connect *and* bind to proceed here!
let mut client = match BasicLdapClient::build(&mapping.backend).await {
@ -136,10 +136,10 @@ pub async fn bind<W: AsyncWrite + Unpin>(
};
if valid {
info!("Successful bind for {}", dn);
info!("Successful bind for `{request_dn}` -> `{backend_dn}`");
Ok(Some(ClientState::Authenticated {
request_dn,
backend_dn: dn,
backend_dn,
client,
}))
} else {