summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ldapd/auth.c
diff options
context:
space:
mode:
authortb <tb@openbsd.org>2019-10-24 12:39:26 +0000
committertb <tb@openbsd.org>2019-10-24 12:39:26 +0000
commit696b58997f75587bd78112ed0b6cdec94a718911 (patch)
tree113a47b65d3d84619d15dd5ba9050be9ee77cc1b /usr.sbin/ldapd/auth.c
parentBackout previous synch.h commit (r1.5, "Use process-private futexes to avoid (diff)
downloadwireguard-openbsd-696b58997f75587bd78112ed0b6cdec94a718911.tar.xz
wireguard-openbsd-696b58997f75587bd78112ed0b6cdec94a718911.zip
The ber_* namespace is used by liblber since time immemorial,
so move our BER API to the unused ober_* prefix to avoid some breakage in ports. Problem diagnosed by jmatthew with ber_free() in samba, but there are many others as pointed out by sthen. tests & ok rob ok sthen (who had an almost identical diff for libutil) "go head hit it" deraadt
Diffstat (limited to 'usr.sbin/ldapd/auth.c')
-rw-r--r--usr.sbin/ldapd/auth.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/ldapd/auth.c b/usr.sbin/ldapd/auth.c
index b61cb9c5bce..f8debff7a2d 100644
--- a/usr.sbin/ldapd/auth.c
+++ b/usr.sbin/ldapd/auth.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: auth.c,v 1.13 2018/05/14 07:53:47 reyk Exp $ */
+/* $OpenBSD: auth.c,v 1.14 2019/10/24 12:39:26 tb Exp $ */
/*
* Copyright (c) 2009, 2010 Martin Hedenfalk <martin@bzero.se>
@@ -259,7 +259,7 @@ ldap_auth_sasl(struct request *req, char *binddn, struct ber_element *params)
char *creds;
size_t len;
- if (ber_scanf_elements(params, "{sx", &method, &creds, &len) != 0)
+ if (ober_scanf_elements(params, "{sx", &method, &creds, &len) != 0)
return LDAP_PROTOCOL_ERROR;
if (strcmp(method, "PLAIN") != 0)
@@ -315,7 +315,7 @@ ldap_auth_simple(struct request *req, char *binddn, struct ber_element *auth)
return LDAP_CONFIDENTIALITY_REQUIRED;
}
- if (ber_scanf_elements(auth, "s", &password) != 0)
+ if (ober_scanf_elements(auth, "s", &password) != 0)
return LDAP_PROTOCOL_ERROR;
if (*password == '\0') {
@@ -349,7 +349,7 @@ ldap_auth_simple(struct request *req, char *binddn, struct ber_element *auth)
if (pw != NULL) {
for (elm = pw->be_next->be_sub; elm;
elm = elm->be_next) {
- if (ber_get_string(elm, &user_password) != 0)
+ if (ober_get_string(elm, &user_password) != 0)
continue;
pwret = check_password(req, user_password, password);
if (pwret >= 1)
@@ -406,7 +406,7 @@ ldap_bind(struct request *req)
++stats.req_bind;
- if (ber_scanf_elements(req->op, "{ise", &ver, &binddn, &auth) != 0) {
+ if (ober_scanf_elements(req->op, "{ise", &ver, &binddn, &auth) != 0) {
rc = LDAP_PROTOCOL_ERROR;
goto done;
}