As these parameters are not assigned to, make them const.
Const specifiers for non-pointer types, such as in 'const
krb5_principal', don't do anything in function declarations. Remove
them.
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
return ret;
}
-bool samba_princ_needs_pac(struct samba_kdc_entry *skdc_entry)
+bool samba_princ_needs_pac(const struct samba_kdc_entry *skdc_entry)
{
uint32_t userAccountControl;
}
int samba_client_requested_pac(krb5_context context,
- const krb5_pac *pac,
+ const krb5_const_pac pac,
TALLOC_CTX *mem_ctx,
bool *requested_pac)
{
*requested_pac = true;
- ret = krb5_pac_get_buffer(context, *pac, PAC_TYPE_ATTRIBUTES_INFO,
+ ret = krb5_pac_get_buffer(context, pac, PAC_TYPE_ATTRIBUTES_INFO,
&k5pac_attrs_in);
if (ret != 0) {
return ret == ENOENT ? 0 : ret;
NTSTATUS samba_kdc_update_delegation_info_blob(TALLOC_CTX *mem_ctx,
krb5_context context,
- const krb5_pac pac,
+ const krb5_const_pac pac,
const krb5_principal server_principal,
const krb5_principal proxy_principal,
DATA_BLOB *new_blob)
uint32_t flags,
struct samba_kdc_entry *client,
const krb5_principal server_principal,
- struct samba_kdc_entry *server,
- struct samba_kdc_entry *krbtgt,
+ const struct samba_kdc_entry *server,
+ const struct samba_kdc_entry *krbtgt,
const krb5_principal delegated_proxy_principal,
const krb5_pac old_pac,
- krb5_pac new_pac)
+ const krb5_pac new_pac)
{
krb5_error_code code = EINVAL;
NTSTATUS nt_status;
bool requested_pac = false;
code = samba_client_requested_pac(context,
- &old_pac,
+ old_pac,
mem_ctx,
&requested_pac);
if (code != 0 || !requested_pac) {
const DATA_BLOB *device_claims_blob,
krb5_pac pac);
-bool samba_princ_needs_pac(struct samba_kdc_entry *skdc_entry);
+bool samba_princ_needs_pac(const struct samba_kdc_entry *skdc_entry);
int samba_client_requested_pac(krb5_context context,
- const krb5_pac *pac,
+ krb5_const_pac pac,
TALLOC_CTX *mem_ctx,
bool *requested_pac);
NTSTATUS samba_kdc_update_delegation_info_blob(TALLOC_CTX *mem_ctx,
krb5_context context,
- const krb5_pac pac,
- const krb5_principal server_principal,
- const krb5_principal proxy_principal,
+ krb5_const_pac pac,
+ krb5_principal server_principal,
+ krb5_principal proxy_principal,
DATA_BLOB *pac_blob);
krb5_error_code samba_kdc_map_policy_err(NTSTATUS nt_status);
krb5_error_code samba_kdc_validate_pac_blob(
krb5_context context,
const struct samba_kdc_entry *client_skdc_entry,
- const krb5_const_pac pac);
+ krb5_const_pac pac);
/*
* In the RODC case, to confirm that the returned user is permitted to
struct ldb_context *samdb,
uint32_t flags,
struct samba_kdc_entry *client,
- const krb5_principal server_principal,
- struct samba_kdc_entry *server,
- struct samba_kdc_entry *krbtgt,
- const krb5_principal delegated_proxy_principal,
- const krb5_pac old_pac,
+ krb5_principal server_principal,
+ const struct samba_kdc_entry *server,
+ const struct samba_kdc_entry *krbtgt,
+ krb5_principal delegated_proxy_principal,
+ krb5_pac old_pac,
krb5_pac new_pac);
static krb5_error_code samba_wdc_reget_pac2(astgs_request_t r,
const krb5_principal delegated_proxy_principal,
- hdb_entry *client,
- hdb_entry *server,
+ const hdb_entry *client,
+ const hdb_entry *server,
hdb_entry *krbtgt,
krb5_pac *pac,
krb5_cksumtype ctype,