summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLibravatar Drew DeVault <sir@cmpwn.com>2016-12-02 08:10:03 -0500
committerLibravatar Drew DeVault <sir@cmpwn.com>2016-12-02 08:10:03 -0500
commitf23880b1fdd70a21b04317c18208a1f3ce356839 (patch)
tree51a54d43531ac28ef014193abef8f4ccd7a78332 /include
parentEnforce mouse permissions (diff)
downloadsway-f23880b1fdd70a21b04317c18208a1f3ce356839.tar.gz
sway-f23880b1fdd70a21b04317c18208a1f3ce356839.tar.zst
sway-f23880b1fdd70a21b04317c18208a1f3ce356839.zip
Add support for command policies in config file
Diffstat (limited to 'include')
-rw-r--r--include/sway/commands.h10
-rw-r--r--include/sway/security.h1
2 files changed, 10 insertions, 1 deletions
diff --git a/include/sway/commands.h b/include/sway/commands.h
index 1d5d56ac..ccc3cf58 100644
--- a/include/sway/commands.h
+++ b/include/sway/commands.h
@@ -18,7 +18,10 @@ enum cmd_status {
18 CMD_BLOCK_MODE, 18 CMD_BLOCK_MODE,
19 CMD_BLOCK_BAR, 19 CMD_BLOCK_BAR,
20 CMD_BLOCK_BAR_COLORS, 20 CMD_BLOCK_BAR_COLORS,
21 CMD_BLOCK_INPUT 21 CMD_BLOCK_INPUT,
22 CMD_BLOCK_COMMANDS,
23 CMD_BLOCK_IPC,
24 CMD_BLOCK_IPC_EVENTS,
22}; 25};
23 26
24/** 27/**
@@ -58,6 +61,10 @@ struct cmd_results *handle_command(char *command);
58 * Do not use this under normal conditions. 61 * Do not use this under normal conditions.
59 */ 62 */
60struct cmd_results *config_command(char *command, enum cmd_status block); 63struct cmd_results *config_command(char *command, enum cmd_status block);
64/*
65 * Parses a command policy rule.
66 */
67struct cmd_results *config_commands_command(char *exec);
61 68
62/** 69/**
63 * Allocates a cmd_results object. 70 * Allocates a cmd_results object.
@@ -93,6 +100,7 @@ sway_cmd cmd_client_unfocused;
93sway_cmd cmd_client_urgent; 100sway_cmd cmd_client_urgent;
94sway_cmd cmd_client_placeholder; 101sway_cmd cmd_client_placeholder;
95sway_cmd cmd_client_background; 102sway_cmd cmd_client_background;
103sway_cmd cmd_commands;
96sway_cmd cmd_debuglog; 104sway_cmd cmd_debuglog;
97sway_cmd cmd_exec; 105sway_cmd cmd_exec;
98sway_cmd cmd_exec_always; 106sway_cmd cmd_exec_always;
diff --git a/include/sway/security.h b/include/sway/security.h
index ae2de0d8..aa51fd81 100644
--- a/include/sway/security.h
+++ b/include/sway/security.h
@@ -7,5 +7,6 @@ enum secure_feature get_feature_policy(pid_t pid);
7enum command_context get_command_policy(const char *cmd); 7enum command_context get_command_policy(const char *cmd);
8 8
9struct feature_policy *alloc_feature_policy(const char *program); 9struct feature_policy *alloc_feature_policy(const char *program);
10struct command_policy *alloc_command_policy(const char *command);
10 11
11#endif 12#endif