From 1e6aae4bb28c1934879d5d362db636a344c7fd6b Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 7 Apr 2014 04:25:30 +0200 Subject: add module that revokes the user's access after she logs out MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- gotrc-examples/revoke-access | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 gotrc-examples/revoke-access (limited to 'gotrc-examples') diff --git a/gotrc-examples/revoke-access b/gotrc-examples/revoke-access new file mode 100644 index 0000000..5ac9b27 --- /dev/null +++ b/gotrc-examples/revoke-access @@ -0,0 +1,16 @@ +# -*- shell-script -*- + +# This module removes access to the TTY after +# the user logs out. + + +display_function_revoke_access=$display_function +display_function=_display_revoke_access + +_display_revoke_access () +{ + chmod 640 "$(tty)" + chown 0:0 "$(tty)" + $display_function_revoke_access +} + -- cgit v1.2.3-70-g09d2