slen = server->length;
trunc_name(&slen, &sdots);
+ /* okay to cast lengths to int because trunc_name limits max value */
return krb5_klog_syslog(LOG_NOTICE,
"Unauthorized request: %s, %.*s%s, "
"client=%.*s%s, service=%.*s%s, addr=%s",
- op, tlen, target, tdots,
- clen, client->value, cdots,
- slen, server->value, sdots,
+ op, (int)tlen, target, tdots,
+ (int)clen, (char *)client->value, cdots,
+ (int)slen, (char *)server->value, sdots,
inet_ntoa(rqstp->rq_xprt->xp_raddr.sin_addr));
}
log_done(
char *op,
char *target,
- char *errmsg,
+ const char *errmsg,
gss_buffer_t client,
gss_buffer_t server,
struct svc_req *rqstp)
slen = server->length;
trunc_name(&slen, &sdots);
+ /* okay to cast lengths to int because trunc_name limits max value */
return krb5_klog_syslog(LOG_NOTICE,
"Request: %s, %.*s%s, %s, "
"client=%.*s%s, service=%.*s%s, addr=%s",
- op, tlen, target, tdots, errmsg,
- clen, client->value, cdots,
- slen, server->value, sdots,
+ op, (int)tlen, target, tdots, errmsg,
+ (int)clen, (char *)client->value, cdots,
+ (int)slen, (char *)server->value, sdots,
inet_ntoa(rqstp->rq_xprt->xp_raddr.sin_addr));
}
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
restriction_t *rp;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
restriction_t *rp;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
restriction_t *rp;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
restriction_t *rp;
- char *errmsg;
+ const char *errmsg;
size_t tlen1, tlen2, clen, slen;
char *tdots1, *tdots2, *cdots, *sdots;
} else
ret.code = KADM5_AUTH_INSUFFICIENT;
if (ret.code != KADM5_OK) {
+ /* okay to cast lengths to int because trunc_name limits max value */
krb5_klog_syslog(LOG_NOTICE,
"Unauthorized request: kadm5_rename_principal, "
"%.*s%s to %.*s%s, "
"client=%.*s%s, service=%.*s%s, addr=%s",
- tlen1, prime_arg1, tdots1,
- tlen2, prime_arg2, tdots2,
- clen, client_name.value, cdots,
- slen, service_name.value, sdots,
+ (int)tlen1, prime_arg1, tdots1,
+ (int)tlen2, prime_arg2, tdots2,
+ (int)clen, (char *)client_name.value, cdots,
+ (int)slen, (char *)service_name.value, sdots,
inet_ntoa(rqstp->rq_xprt->xp_raddr.sin_addr));
} else {
ret.code = kadm5_rename_principal((void *)handle, arg->src,
else
errmsg = krb5_get_error_message(handle ? handle->context : NULL, ret.code);
+ /* okay to cast lengths to int because trunc_name limits max value */
krb5_klog_syslog(LOG_NOTICE,
"Request: kadm5_rename_principal, "
"%.*s%s to %.*s%s, %s, "
"client=%.*s%s, service=%.*s%s, addr=%s",
- tlen1, prime_arg1, tdots1,
- tlen2, prime_arg2, tdots2, errmsg,
- clen, client_name.value, cdots,
- slen, service_name.value, sdots,
+ (int)tlen1, prime_arg1, tdots1,
+ (int)tlen2, prime_arg2, tdots2, errmsg,
+ (int)clen, (char *)client_name.value, cdots,
+ (int)slen, (char *)service_name.value, sdots,
inet_ntoa(rqstp->rq_xprt->xp_raddr.sin_addr));
}
free_server_handle(handle);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_gprinc_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_gprincs_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_chrand_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_chrand_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_generic_ret, &ret);
kadm5_policy_ent_t e;
kadm5_principal_ent_rec caller_ent;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_gpol_ret, &ret);
service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_gpols_ret, &ret);
gss_buffer_desc client_name, service_name;
OM_uint32 minor_stat;
kadm5_server_handle_t handle;
- char *errmsg;
+ const char *errmsg;
xdr_free(xdr_getprivs_ret, &ret);
service_name;
kadm5_server_handle_t handle;
OM_uint32 minor_stat;
- char *errmsg = 0;
+ const char *errmsg = NULL;
size_t clen, slen;
char *cdots, *sdots;
trunc_name(&clen, &cdots);
slen = service_name.length;
trunc_name(&slen, &sdots);
+ /* okay to cast lengths to int because trunc_name limits max value */
krb5_klog_syslog(LOG_NOTICE, "Request: %s, %.*s%s, %s, "
"client=%.*s%s, service=%.*s%s, addr=%s, flavor=%d",
(ret.api_version == KADM5_API_VERSION_1 ?
"kadm5_init (V1)" : "kadm5_init"),
- clen, client_name.value, cdots, errmsg,
- clen, client_name.value, cdots,
- slen, service_name.value, sdots,
+ (int)clen, (char *)client_name.value, cdots, errmsg,
+ (int)clen, (char *)client_name.value, cdots,
+ (int)slen, (char *)service_name.value, sdots,
inet_ntoa(rqstp->rq_xprt->xp_raddr.sin_addr),
rqstp->rq_cred.oa_flavor);
gss_release_buffer(&minor_stat, &client_name);