From f67727e2d6e019246b445a8b6f5d5890aee2d568 Mon Sep 17 00:00:00 2001 From: "Alan T. DeKok" Date: Sun, 19 Sep 2010 08:49:51 +0200 Subject: [PATCH] Multiple calls to ber_printf seem to work better. Closes #106 --- src/modules/rlm_ldap/edir_ldapext.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/modules/rlm_ldap/edir_ldapext.c b/src/modules/rlm_ldap/edir_ldapext.c index 8b4b7f5..0c48ee8 100644 --- a/src/modules/rlm_ldap/edir_ldapext.c +++ b/src/modules/rlm_ldap/edir_ldapext.c @@ -434,7 +434,11 @@ int berEncodeAuthData( } /* BER encode the NMAS Version, the objectDN, and the password */ - rc = ber_printf(requestBer, "{ioooo", RADAUTH_LDAP_EXT_VERSION, utf8ObjPtr, utf8ObjSize, utf8PwdPtr, utf8PwdSize, utf8SeqPtr, utf8SeqSize, utf8NasIPPtr, utf8NasIPSize); + rc = ber_printf(requestBer, "{i", RADAUTH_LDAP_EXT_VERSION); + rc = ber_printf(requestBer, "o", utf8ObjPtr, utf8ObjSize); + rc = ber_printf(requestBer, "o", utf8PwdPtr, utf8PwdSize); + rc = ber_printf(requestBer, "o", utf8SeqPtr, utf8SeqSize); + rc = ber_printf(requestBer, "o", utf8NasIPPtr, utf8NasIPSize); if( *auth_state == -2) { -- 2.1.4