This tiny series would address a couple of bugs in the recent commits that fixed xdr_buf_trim(), namely: 31c9590ae468 ("SUNRPC: Add "@len" parameter to gss_unwrap()") a7e429a6fa6d ("SUNRPC: Fix GSS privacy computation of auth->au_ralign") 0a8e7b7d0846 ("SUNRPC: Revert 241b1f419f0e ("SUNRPC: Remove xdr_buf_trim()")") Turns out 31c9590ae468 had a couple of problems that were introduced by refactoring late, and therefore were not caught during testing. The client-side problems are documented here: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1886277 The first patch addresses the NFSv4/krb5p failures reported in that bug. It is a straightforward and obvious fix. When this fix is applied on the server, NFSv3/krb5p stops working. Thus the second patch is also needed, but this patch is somewhat more controversial. It's not clear to me how much of the "pad adjustment" logic is still needed in unwrap_priv_data(), so I'm asking for some quick but careful review of this proposed change. --- Chuck Lever (2): SUNRPC: Set rcv_buf->len correctly in gss_unwrap_kerberos_v2() SUNRPC: Fix buf->len calculation in unwrap_priv_data() net/sunrpc/auth_gss/gss_krb5_wrap.c | 2 +- net/sunrpc/auth_gss/svcauth_gss.c | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) -- Chuck Lever