summaryrefslogtreecommitdiffstats
path: root/userprefs.cgi
diff options
context:
space:
mode:
authorDylan William Hardison <dylan@hardison.net>2015-10-16 00:58:09 +0200
committerDylan William Hardison <dylan@hardison.net>2015-10-16 00:58:09 +0200
commita0fcc8ff20fe57bf442402ba227954ffb33a2175 (patch)
tree9a3ee457971d8c8654d1a085d2c7261b54535621 /userprefs.cgi
parentb21167f4de2d29d7ce4a7cd07266783032099568 (diff)
downloadbugzilla-a0fcc8ff20fe57bf442402ba227954ffb33a2175.tar.gz
bugzilla-a0fcc8ff20fe57bf442402ba227954ffb33a2175.tar.xz
Bug 1196626 - log all authenticated requests
Diffstat (limited to 'userprefs.cgi')
-rwxr-xr-xuserprefs.cgi9
1 files changed, 9 insertions, 0 deletions
diff --git a/userprefs.cgi b/userprefs.cgi
index 6c6a246ff..bd1bb8ab7 100755
--- a/userprefs.cgi
+++ b/userprefs.cgi
@@ -853,6 +853,12 @@ sub SaveApiKey {
revoked => $revoked,
});
$api_key->update();
+ if ($revoked) {
+ Bugzilla->log_user_request(undef, undef, 'api-key-revoke')
+ }
+ else {
+ Bugzilla->log_user_request(undef, undef, 'api-key-unrevoke')
+ }
}
}
}
@@ -912,6 +918,7 @@ sub MfaApiKey {
revoked => 0,
});
$api_key->update();
+ Bugzilla->log_user_request(undef, undef, 'api-key-unrevoke');
$dbh->bz_commit_transaction;
}
}
@@ -926,6 +933,8 @@ sub _create_api_key {
description => $description,
});
+ Bugzilla->log_user_request(undef, undef, 'api-key-create');
+
# As a security precaution, we always sent out an e-mail when
# an API key is created
my $template = Bugzilla->template_inner($user->setting('lang'));