summaryrefslogtreecommitdiff
path: root/perl/Wallet/Config.pm
blob: 776cc5adb87a1b4d85d6d37eaa61b63d64749295 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# Wallet::Config -- Configuration handling for the wallet server.
# $Id$
#
# Written by Russ Allbery <rra@stanford.edu>
# Copyright 2007 Board of Trustees, Leland Stanford Jr. University
#
# See README for licensing terms.

##############################################################################
# Modules and declarations
##############################################################################

package Wallet::Config;
require 5.006;

use strict;
use vars qw($PATH $VERSION);

# This version should be increased on any code change to this module.  Always
# use two digits for the minor version with a leading zero if necessary so
# that it will sort properly.
$VERSION = '0.01';

# Path to the config file to load.
$PATH = '/etc/wallet.conf';

##############################################################################
# Variables
##############################################################################

# Database configuration.
our $DB_DRIVER;
our $DB_INFO;
our $DB_NAME;
our $DB_HOST;
our $DB_PORT;
our $DB_USER;
our $DB_PASSWORD;

# Configuration for the keytab object type.
our $KEYTAB_FILE;
our $KEYTAB_FLAGS     = '-clearpolicy';
our $KEYTAB_HOST;
our $KEYTAB_KADMIN    = 'kadmin';
our $KEYTAB_PRINCIPAL;
our $KEYTAB_REALM;
our $KEYTAB_TMP;

# Now, load the configuration file so that it can override the defaults.
if (-r $PATH) {
    do $PATH or die (($@ || $!) . "\n");
}

1;
__END__