summaryrefslogtreecommitdiff
path: root/source4/utils
diff options
context:
space:
mode:
Diffstat (limited to 'source4/utils')
-rw-r--r--source4/utils/ntlm_auth.c31
1 files changed, 2 insertions, 29 deletions
diff --git a/source4/utils/ntlm_auth.c b/source4/utils/ntlm_auth.c
index 34f79715ff2..a3701f88224 100644
--- a/source4/utils/ntlm_auth.c
+++ b/source4/utils/ntlm_auth.c
@@ -142,33 +142,6 @@ static bool parse_ntlm_auth_domain_user(const char *domuser, char **domain,
return true;
}
-/**
- * Decode a base64 string into a DATA_BLOB - simple and slow algorithm
- **/
-static DATA_BLOB base64_decode_data_blob(TALLOC_CTX *mem_ctx, const char *s)
-{
- DATA_BLOB ret = data_blob_talloc(mem_ctx, s, strlen(s)+1);
- ret.length = ldb_base64_decode((char *)ret.data);
- return ret;
-}
-
-/**
- * Encode a base64 string into a talloc()ed string caller to free.
- **/
-static char *base64_encode_data_blob(TALLOC_CTX *mem_ctx, DATA_BLOB data)
-{
- return ldb_base64_encode(mem_ctx, (const char *)data.data, data.length);
-}
-
-/**
- * Decode a base64 string in-place - wrapper for the above
- **/
-static void base64_decode_inplace(char *s)
-{
- ldb_base64_decode(s);
-}
-
-
/* Authenticate a user with a plaintext password */
@@ -291,7 +264,7 @@ static void manage_gensec_get_pw_request(enum stdio_helper_mode stdio_helper_mod
}
if (strlen(buf) > 3) {
- in = base64_decode_data_blob(NULL, buf + 3);
+ in = base64_decode_data_blob(buf + 3);
} else {
in = data_blob(NULL, 0);
}
@@ -433,7 +406,7 @@ static void manage_gensec_request(enum stdio_helper_mode stdio_helper_mode,
mux_printf(mux_id, "OK\n");
return;
}
- in = base64_decode_data_blob(NULL, buf + 3);
+ in = base64_decode_data_blob(buf + 3);
} else {
in = data_blob(NULL, 0);
}