From: David Howells <dhowells@redhat.com>
To: netdev@vger.kernel.org
Cc: David Howells <dhowells@redhat.com>,
Marc Dionne <marc.dionne@auristor.com>,
Jakub Kicinski <kuba@kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
Christian Brauner <brauner@kernel.org>,
Chuck Lever <chuck.lever@oracle.com>,
linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH net-next v3 00/14] rxrpc, afs: Add AFS GSSAPI security class to AF_RXRPC and kafs
Date: Fri, 11 Apr 2025 10:52:45 +0100 [thread overview]
Message-ID: <20250411095303.2316168-1-dhowells@redhat.com> (raw)
Here's a set of patches to add basic support for the AFS GSSAPI security
class to AF_RXRPC and kafs. It provides transport security for keys that
match the security index 6 (YFS) for connections to the AFS fileserver and
VL server.
Note that security index 4 (OpenAFS) can also be supported using this, but
it needs more work as it's slightly different.
The patches also provide the ability to secure the callback channel -
connections from the fileserver back to the client that are used to pass
file change notifications, amongst other things. When challenged by the
fileserver, kafs will generate a token specific to that server and include
it in the RESPONSE packet as the appdata. The server then extracts this
and uses it to send callback RPC calls back to the client.
It can also be used to provide transport security on the callback channel,
but a further set of patches is required to provide the token and key to
set that up when the client responds to the fileserver's challenge.
This makes use of the previously added crypto-krb5 library that is now
upstream (last commit fc0cf10c04f4).
This series of patches consist of the following parts:
(0) Update kdoc comments to remove some kdoc builder warnings.
(1) Push reponding to CHALLENGE packets over to recvmsg() or the kernel
equivalent so that the application layer can include user-defined
information in the RESPONSE packet. In a follow-up patch set, this
will allow the callback channel to be secured by the AFS filesystem.
(2) Add the AF_RXRPC RxGK security class that uses a key obtained from the
AFS GSS security service to do Kerberos 5-based encryption instead of
pcbc(fcrypt) and pcbc(des).
(3) Add support for callback channel encryption in kafs.
(4) Provide the test rxperf server module with some fixed krb5 keys.
David
The patches can be found on this branch also:
http://git.kernel.org/cgit/linux/kernel/git/dhowells/linux-fs.git/log/?h=rxrpc-next
CHANGES
=======
ver #3)
- Fixed a leak in an error return path.
- Added a patch to remove/adjust some __acquires() and __releases()
annotations to remove some checker warnings[*].
- Removed the additional __releases() notifications from oob.c.
[*] Note that lock_sock() and release_sock() should probably have some
sort of lock annotation so they can be checked.
ver #2)
- Fix use of %zx instead of %lx.
- Add a patch to add 'Return:' descriptions into existing kdoc comments.
- Add 'Return:' descriptions into new kdoc comments.
- Add a function API ref at the end of rxrpc.rst.
David Howells (14):
rxrpc: kdoc: Update function descriptions and add link from rxrpc.rst
rxrpc: Pull out certain app callback funcs into an ops table
rxrpc: Remove some socket lock acquire/release annotations
rxrpc: Allow CHALLENGEs to the passed to the app for a RESPONSE
rxrpc: Add the security index for yfs-rxgk
rxrpc: Add YFS RxGK (GSSAPI) security class
rxrpc: rxgk: Provide infrastructure and key derivation
rxrpc: rxgk: Implement the yfs-rxgk security class (GSSAPI)
rxrpc: rxgk: Implement connection rekeying
rxrpc: Allow the app to store private data on peer structs
rxrpc: Display security params in the afs_cb_call tracepoint
afs: Use rxgk RESPONSE to pass token for callback channel
rxrpc: Add more CHALLENGE/RESPONSE packet tracing
rxrpc: rxperf: Add test RxGK server keys
Documentation/networking/rxrpc.rst | 15 +
fs/afs/Kconfig | 1 +
fs/afs/Makefile | 1 +
fs/afs/cm_security.c | 340 +++++++
fs/afs/internal.h | 20 +
fs/afs/main.c | 1 +
fs/afs/misc.c | 27 +
fs/afs/rxrpc.c | 40 +-
fs/afs/server.c | 2 +
include/crypto/krb5.h | 5 +
include/keys/rxrpc-type.h | 17 +
include/net/af_rxrpc.h | 51 +-
include/trace/events/afs.h | 11 +-
include/trace/events/rxrpc.h | 163 +++-
include/uapi/linux/rxrpc.h | 77 +-
net/rxrpc/Kconfig | 23 +
net/rxrpc/Makefile | 6 +-
net/rxrpc/af_rxrpc.c | 93 +-
net/rxrpc/ar-internal.h | 82 +-
net/rxrpc/call_accept.c | 34 +-
net/rxrpc/call_object.c | 24 +-
net/rxrpc/conn_event.c | 134 ++-
net/rxrpc/conn_object.c | 2 +
net/rxrpc/insecure.c | 13 +-
net/rxrpc/io_thread.c | 12 +-
net/rxrpc/key.c | 187 ++++
net/rxrpc/oob.c | 379 ++++++++
net/rxrpc/output.c | 60 +-
net/rxrpc/peer_object.c | 22 +-
net/rxrpc/protocol.h | 20 +
net/rxrpc/recvmsg.c | 132 ++-
net/rxrpc/rxgk.c | 1367 ++++++++++++++++++++++++++++
net/rxrpc/rxgk_app.c | 285 ++++++
net/rxrpc/rxgk_common.h | 139 +++
net/rxrpc/rxgk_kdf.c | 288 ++++++
net/rxrpc/rxkad.c | 296 +++---
net/rxrpc/rxperf.c | 78 +-
net/rxrpc/security.c | 3 +
net/rxrpc/sendmsg.c | 25 +-
net/rxrpc/server_key.c | 42 +
40 files changed, 4272 insertions(+), 245 deletions(-)
create mode 100644 fs/afs/cm_security.c
create mode 100644 net/rxrpc/oob.c
create mode 100644 net/rxrpc/rxgk.c
create mode 100644 net/rxrpc/rxgk_app.c
create mode 100644 net/rxrpc/rxgk_common.h
create mode 100644 net/rxrpc/rxgk_kdf.c
next reply other threads:[~2025-04-11 9:53 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-11 9:52 David Howells [this message]
2025-04-11 9:52 ` [PATCH net-next v3 01/14] rxrpc: kdoc: Update function descriptions and add link from rxrpc.rst David Howells
2025-04-11 9:52 ` [PATCH net-next v3 02/14] rxrpc: Pull out certain app callback funcs into an ops table David Howells
2025-04-11 9:52 ` [PATCH net-next v3 03/14] rxrpc: Remove some socket lock acquire/release annotations David Howells
2025-04-11 9:52 ` [PATCH net-next v3 04/14] rxrpc: Allow CHALLENGEs to the passed to the app for a RESPONSE David Howells
2025-04-11 9:52 ` [PATCH net-next v3 05/14] rxrpc: Add the security index for yfs-rxgk David Howells
2025-04-11 9:52 ` [PATCH net-next v3 06/14] rxrpc: Add YFS RxGK (GSSAPI) security class David Howells
2025-04-11 9:52 ` [PATCH net-next v3 07/14] rxrpc: rxgk: Provide infrastructure and key derivation David Howells
2025-04-11 9:52 ` [PATCH net-next v3 08/14] rxrpc: rxgk: Implement the yfs-rxgk security class (GSSAPI) David Howells
2025-04-11 9:52 ` [PATCH net-next v3 09/14] rxrpc: rxgk: Implement connection rekeying David Howells
2025-04-11 9:52 ` [PATCH net-next v3 10/14] rxrpc: Allow the app to store private data on peer structs David Howells
2025-04-11 9:52 ` [PATCH net-next v3 11/14] rxrpc: Display security params in the afs_cb_call tracepoint David Howells
2025-04-11 9:52 ` [PATCH net-next v3 12/14] afs: Use rxgk RESPONSE to pass token for callback channel David Howells
2025-04-11 9:52 ` [PATCH net-next v3 13/14] rxrpc: Add more CHALLENGE/RESPONSE packet tracing David Howells
2025-04-11 9:52 ` [PATCH net-next v3 14/14] rxrpc: rxperf: Add test RxGK server keys David Howells
2025-04-15 0:50 ` [PATCH net-next v3 00/14] rxrpc, afs: Add AFS GSSAPI security class to AF_RXRPC and kafs patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250411095303.2316168-1-dhowells@redhat.com \
--to=dhowells@redhat.com \
--cc=brauner@kernel.org \
--cc=chuck.lever@oracle.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-afs@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marc.dionne@auristor.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).