Skip to content

Commit

Permalink
systemd: Fix systemd_write_notify_socket().
Browse files Browse the repository at this point in the history
The notify socket is SOCK_DGRAM. See sd_notify(3) NOTES section for details.

Signed-off-by: Chris PeBenito <[email protected]>
  • Loading branch information
pebenito committed Oct 18, 2024
1 parent 7c0f511 commit 7f620a5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions policy/modules/system/init.if
Original file line number Diff line number Diff line change
Expand Up @@ -1020,12 +1020,12 @@ interface(`init_unix_stream_socket_connectto',`
## </summary>
## </param>
#
interface(`init_unix_stream_socket_sendto',`
interface(`init_unix_dgram_socket_sendto',`
gen_require(`
type init_t;
')

allow $1 init_t:unix_stream_socket sendto;
allow $1 init_t:unix_dgram_socket sendto;
')

########################################
Expand Down
2 changes: 1 addition & 1 deletion policy/modules/system/systemd.if
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ interface(`systemd_write_notify_socket',`
')

init_list_runtime($1)
init_unix_stream_socket_sendto($1)
init_unix_dgram_socket_sendto($1)
allow $1 systemd_runtime_notify_t:sock_file write_sock_file_perms;
')

Expand Down

0 comments on commit 7f620a5

Please sign in to comment.