Skip to content

Commit

Permalink
Confine the ktls service
Browse files Browse the repository at this point in the history
The ktls-utils package provides a TLS handshake user agent that listens
for kernel requests and then materializes a user space socket endpoint
on which to perform these handshakes. The resulting negotiated session
parameters are passed back to the kernel via standard kTLS socket
options.
  • Loading branch information
zpytela committed Oct 23, 2024
1 parent 785a086 commit 3b83877
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 0 deletions.
8 changes: 8 additions & 0 deletions dist/targeted/modules.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3036,3 +3036,11 @@ powerprofiles = module
#
#
pcm = module

# Layer: contrib
# Module: ktls
#
# Policy for ktls - TLS handshake agent for kernel sockets
#
#
ktls = module
1 change: 1 addition & 0 deletions policy/modules/contrib/ktls.fc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/usr/sbin/tlshd -- gen_context(system_u:object_r:ktlshd_exec_t,s0)
1 change: 1 addition & 0 deletions policy/modules/contrib/ktls.if
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
## <summary>ktls - TLS handshake agent for kernel sockets</summary>
13 changes: 13 additions & 0 deletions policy/modules/contrib/ktls.te
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
policy_module(ktls, 1.0)

########################################
#
# Declarations
#

type ktlshd_t;
type ktlshd_exec_t;
init_daemon_domain(ktlshd_t, ktlshd_exec_t)

permissive ktlshd_t;

0 comments on commit 3b83877

Please sign in to comment.