Commit 3c19cd8a authored by Leigh B. Stoller's avatar Leigh B. Stoller

Add Auditing.

parent 8db30b88
......@@ -27,12 +27,14 @@ my $TB = "@prefix@";
my $DBNAME = "@TBDBNAME@";
my $TBOPS = "@TBOPSEMAIL@";
my $TBLOGS = "@TBLOGSEMAIL@";
my $TBAUDIT = "@TBAUDITEMAIL@";
my $swapexp = "$TB/bin/swapexp";
#
# Testbed Support libraries
#
use lib "@prefix@/lib";
use libaudit;
use libdb;
use libtestbed;
......@@ -111,6 +113,16 @@ if (! TBAdmin($UID)) {
" Only testbed administrators can issue a forcible swap!\n");
}
#
# This script is always audited.
#
if (AuditStart(0)) {
#
# Parent exits normally
#
exit(0);
}
#
# Need to know the creator of the experiment.
#
......@@ -141,6 +153,9 @@ if (! $request) {
die("*** $0:\n".
" No such group $pid/$gid\n");
# Send the email now, which terminates the audit.
AuditEnd();
$EGID = $GID = $unix_gid;
$EUID = $UID = $unix_uid;
$ENV{'USER'} = $creator;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment