kdc: support for PAC_ATTRIBUTES_INFO

Add PAC_ATTRIBUTES_INFO to the PAC. This info buffer indicates whether the user
explicitly requested a PAC be present or absent.

Note: this changes the windc plugin ABI.
This commit is contained in:
Luke Howard
2021-12-20 15:31:33 +11:00
parent e50033aec2
commit f7964251ff
12 changed files with 268 additions and 95 deletions

View File

@@ -23,13 +23,14 @@ pac_generate(void *ctx, krb5_context context,
struct hdb_entry_ex *client,
struct hdb_entry_ex *server,
const krb5_keyblock *pk_replykey,
const krb5_boolean *pac_request,
uint64_t pac_attributes,
krb5_pac *pac)
{
krb5_error_code ret;
krb5_data data;
if (pac_request != NULL && *pac_request == FALSE) {
if ((pac_attributes & (KRB5_PAC_WAS_REQUESTED |
KRB5_PAC_WAS_GIVEN_IMPLICITLY)) == 0) {
*pac = NULL;
return 0;
}