summaryrefslogtreecommitdiff
path: root/source4/auth
diff options
context:
space:
mode:
Diffstat (limited to 'source4/auth')
-rw-r--r--source4/auth/gensec/cyrus_sasl.c20
-rw-r--r--source4/auth/gensec/gensec_gssapi.c6
2 files changed, 15 insertions, 11 deletions
diff --git a/source4/auth/gensec/cyrus_sasl.c b/source4/auth/gensec/cyrus_sasl.c
index 0bce35e1c5..64a0b2f0c7 100644
--- a/source4/auth/gensec/cyrus_sasl.c
+++ b/source4/auth/gensec/cyrus_sasl.c
@@ -101,7 +101,7 @@ static int gensec_sasl_get_password(sasl_conn_t *conn, void *context, int id,
return SASL_NOMEM;
}
secret->len = strlen(password);
- safe_strcpy(secret->data, password, secret->len+1);
+ safe_strcpy((char*)secret->data, password, secret->len+1);
*psecret = secret;
return SASL_OK;
}
@@ -213,8 +213,9 @@ static NTSTATUS gensec_sasl_update(struct gensec_security *gensec_security,
sasl_ret = sasl_client_start(gensec_sasl_state->conn, gensec_security->ops->sasl_name,
NULL, &out_data, &out_len, &mech);
} else {
- sasl_ret = sasl_client_step(gensec_sasl_state->conn,
- in.data, in.length, NULL, &out_data, &out_len);
+ sasl_ret = sasl_client_step(gensec_sasl_state->conn,
+ (char*)in.data, in.length, NULL,
+ &out_data, &out_len);
}
if (sasl_ret == SASL_OK || sasl_ret == SASL_CONTINUE) {
*out = data_blob_talloc(out_mem_ctx, out_data, out_len);
@@ -237,8 +238,9 @@ static NTSTATUS gensec_sasl_unwrap_packets(struct gensec_security *gensec_securi
const char *out_data;
unsigned int out_len;
- int sasl_ret = sasl_decode(gensec_sasl_state->conn,
- in->data, in->length, &out_data, &out_len);
+ int sasl_ret = sasl_decode(gensec_sasl_state->conn,
+ (char*)in->data, in->length, &out_data,
+ &out_len);
if (sasl_ret == SASL_OK) {
*out = data_blob_talloc(out_mem_ctx, out_data, out_len);
*len_processed = in->length;
@@ -260,8 +262,9 @@ static NTSTATUS gensec_sasl_wrap_packets(struct gensec_security *gensec_security
const char *out_data;
unsigned int out_len;
- int sasl_ret = sasl_encode(gensec_sasl_state->conn,
- in->data, in->length, &out_data, &out_len);
+ int sasl_ret = sasl_encode(gensec_sasl_state->conn,
+ (char*)in->data, in->length, &out_data,
+ &out_len);
if (sasl_ret == SASL_OK) {
*out = data_blob_talloc(out_mem_ctx, out_data, out_len);
*len_processed = in->length;
@@ -278,7 +281,8 @@ static bool gensec_sasl_have_feature(struct gensec_security *gensec_security,
struct gensec_sasl_state *gensec_sasl_state = talloc_get_type(gensec_security->private_data,
struct gensec_sasl_state);
sasl_ssf_t ssf;
- int sasl_ret = sasl_getprop(gensec_sasl_state->conn, SASL_SSF, &ssf);
+ int sasl_ret = sasl_getprop(gensec_sasl_state->conn, SASL_SSF,
+ (const void**)&ssf);
if (sasl_ret != SASL_OK) {
return false;
}
diff --git a/source4/auth/gensec/gensec_gssapi.c b/source4/auth/gensec/gensec_gssapi.c
index a0b42db141..bb71a55073 100644
--- a/source4/auth/gensec/gensec_gssapi.c
+++ b/source4/auth/gensec/gensec_gssapi.c
@@ -54,7 +54,7 @@ struct gensec_gssapi_state {
gss_name_t server_name;
gss_name_t client_name;
OM_uint32 want_flags, got_flags;
- const gss_OID_desc *gss_oid;
+ gss_OID gss_oid;
DATA_BLOB session_key;
DATA_BLOB pac;
@@ -82,7 +82,7 @@ static size_t gensec_gssapi_max_wrapped_size(struct gensec_security *gensec_secu
static char *gssapi_error_string(TALLOC_CTX *mem_ctx,
OM_uint32 maj_stat, OM_uint32 min_stat,
- const gss_OID_desc *mech)
+ const gss_OID mech)
{
OM_uint32 disp_min_stat, disp_maj_stat;
gss_buffer_desc maj_error_message;
@@ -448,7 +448,7 @@ static NTSTATUS gensec_gssapi_update(struct gensec_security *gensec_security,
gensec_gssapi_state->client_cred->creds,
&gensec_gssapi_state->gssapi_context,
gensec_gssapi_state->server_name,
- discard_const_p(gss_OID_desc, gensec_gssapi_state->gss_oid),
+ gensec_gssapi_state->gss_oid,
gensec_gssapi_state->want_flags,
0,
gensec_gssapi_state->input_chan_bindings,