From ebf990469b79e97bf7046e9a96f20dcf7bec5d78 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 18 Nov 2013 17:46:37 +0100 Subject: m + take ownership of and chmod /dev/vcs and /dev/vcsa MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/security.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/security.h') diff --git a/src/security.h b/src/security.h index 3e12af4..bbc0c4e 100644 --- a/src/security.h +++ b/src/security.h @@ -24,8 +24,26 @@ #include +#ifndef TTY_PERM +#define TTY_PERM 0600 +#endif + +#ifndef FAILURE_SLEEP +#define FAILURE_SLEEP 5 +#endif + + /** * Secure the TTY from spying */ void secure_tty(void); +/** + * Set ownership and mode of the TTY + * + * @param owner The owner + * @param group The group + * @param with_fail Abort on failure + */ +void chown_tty(int owner, int group, int with_fail); + -- cgit v1.2.3-70-g09d2