summaryrefslogtreecommitdiff
path: root/contrib/wallet-summary
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/wallet-summary')
-rwxr-xr-xcontrib/wallet-summary33
1 files changed, 17 insertions, 16 deletions
diff --git a/contrib/wallet-summary b/contrib/wallet-summary
index 55501ad..5cbf6e0 100755
--- a/contrib/wallet-summary
+++ b/contrib/wallet-summary
@@ -1,8 +1,23 @@
-#!/usr/bin/perl -w
+#!/usr/bin/perl
#
# Summarize keytabs in the wallet database.
##############################################################################
+# Modules and declarations
+##############################################################################
+
+require 5.005;
+
+use strict;
+use vars qw($ADDRESS $DUMPFILE @PATTERNS $REPORTS);
+use warnings;
+
+use Getopt::Long qw(GetOptions);
+use File::Path qw(mkpath);
+use POSIX qw(strftime);
+use Wallet::Report ();
+
+##############################################################################
# Site configuration
##############################################################################
@@ -30,20 +45,6 @@ $ADDRESS = 'nobody@example.com';
[qr(^service/), 'service/*', 'Service principals']);
##############################################################################
-# Modules and declarations
-##############################################################################
-
-require 5.005;
-
-use strict;
-use vars qw($ADDRESS $DUMPFILE @PATTERNS $REPORTS);
-
-use Getopt::Long qw(GetOptions);
-use File::Path qw(mkpath);
-use POSIX qw(strftime);
-use Wallet::Report ();
-
-##############################################################################
# Database queries
##############################################################################
@@ -145,7 +146,7 @@ if ($mail) {
}
# Run the report.
-my @principals = read_dump;
+my @principals = read_dump ();
report_principals (@principals);
# If -m was given, take the saved report and mail it as well.