summaryrefslogtreecommitdiffstats
path: root/cmd.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2022-04-06 14:28:50 +0100
committerNicholas Marriott <nicholas.marriott@gmail.com>2022-04-06 14:28:50 +0100
commitd6306b634e4a044e3380ed984dc7f5e5d67e69ac (patch)
treeb37630b42c687c2d470529e9c78e3f29d24775e3 /cmd.c
parent6e9a9d265e2c5199566e3890e6763a74b558bf80 (diff)
Add an ACL list for users connecting to the tmux socket. Users may be forbidden
from attaching, forced to attach read-only, or allowed to attach read-write. A new command, server-access, configures the list. tmux gets the user using getpeereid(3) of the client socket. Users must still configure file system permissions manually.
Diffstat (limited to 'cmd.c')
-rw-r--r--cmd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/cmd.c b/cmd.c
index f8027dfe..ed4f9940 100644
--- a/cmd.c
+++ b/cmd.c
@@ -95,6 +95,7 @@ extern const struct cmd_entry cmd_select_pane_entry;
extern const struct cmd_entry cmd_select_window_entry;
extern const struct cmd_entry cmd_send_keys_entry;
extern const struct cmd_entry cmd_send_prefix_entry;
+extern const struct cmd_entry cmd_server_access_entry;
extern const struct cmd_entry cmd_set_buffer_entry;
extern const struct cmd_entry cmd_set_environment_entry;
extern const struct cmd_entry cmd_set_hook_entry;
@@ -187,6 +188,7 @@ const struct cmd_entry *cmd_table[] = {
&cmd_select_window_entry,
&cmd_send_keys_entry,
&cmd_send_prefix_entry,
+ &cmd_server_access_entry,
&cmd_set_buffer_entry,
&cmd_set_environment_entry,
&cmd_set_hook_entry,