2016-12-23 16:11:45

by Andy Adamson

[permalink] [raw]
Subject: [PATCH] RFC: GSSD changes for RPCSEC_GSS version 3

From: Andy Adamson <[email protected]>

This is a Request for Comment patch set for the GSSv3 prototype.

Requires:

- kernel patches: "RFC: RPCSEC_GSS Version 3 prototype: Full MOde MAC
- libtirpc patches: "RFC: Libtirpc changes for RPCSEC_GSS version 3"

Andy Adamson (1):
GSSD: Add RPCSEC_GSS version to downcall

utils/gssd/gssd_proc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

--
1.8.3.1



2016-12-23 16:11:45

by Andy Adamson

[permalink] [raw]
Subject: [PATCH] GSSD: Add RPCSEC_GSS version to downcall

From: Andy Adamson <[email protected]>

Signed-off-by: Andy Adamson <[email protected]>
---
utils/gssd/gssd_proc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/utils/gssd/gssd_proc.c b/utils/gssd/gssd_proc.c
index d74d372..a045133 100644
--- a/utils/gssd/gssd_proc.c
+++ b/utils/gssd/gssd_proc.c
@@ -150,9 +150,11 @@ do_downcall(int k5_fd, uid_t uid, struct authgss_private_data *pd,
unsigned int timeout = context_timeout;
unsigned int buf_size = 0;

- printerr(2, "doing downcall: lifetime_rec=%u acceptor=%.*s\n",
- lifetime_rec, acceptor->length, acceptor->value);
- buf_size = sizeof(uid) + sizeof(timeout) + sizeof(pd->pd_seq_win) +
+ printerr(1, "doing downcall: lifetime_rec=%u acceptor=%.*s"
+ "gss vers %d\n", lifetime_rec, acceptor->length,
+ acceptor->value, pd->pd_gss_vers);
+ buf_size = sizeof(uid) + sizeof(timeout) +
+ sizeof(pd->pd_gss_vers) + sizeof(pd->pd_seq_win) +
sizeof(pd->pd_ctx_hndl.length) + pd->pd_ctx_hndl.length +
sizeof(context_token->length) + context_token->length +
sizeof(acceptor->length) + acceptor->length;
@@ -167,6 +169,7 @@ do_downcall(int k5_fd, uid_t uid, struct authgss_private_data *pd,
timeout = lifetime_rec;
if (WRITE_BYTES(&p, end, uid)) goto out_err;
if (WRITE_BYTES(&p, end, timeout)) goto out_err;
+ if (WRITE_BYTES(&p, end, pd->pd_gss_vers)) goto out_err;
if (WRITE_BYTES(&p, end, pd->pd_seq_win)) goto out_err;
if (write_buffer(&p, end, &pd->pd_ctx_hndl)) goto out_err;
if (write_buffer(&p, end, context_token)) goto out_err;
--
1.8.3.1