File: config

package info (click to toggle)
tripwire 2.3.1.2.0-4
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 5,876 kB
  • ctags: 6,896
  • sloc: cpp: 57,709; sh: 1,295; perl: 1,238; yacc: 497; lex: 356; makefile: 269; ansic: 10
file content (71 lines) | stat: -rw-r--r-- 1,644 bytes parent folder | download
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#!/bin/sh -e

# Source debconf library.
. /usr/share/debconf/confmodule

# Does the user wish to upgrade
if [ -f /etc/tripwire/tw.config -o -f /etc/tw.config ]
then
    db_title Tripwire Upgrade
    db_fset tripwire/upgrade seen false
    db_input critical tripwire/upgrade || true
    db_go

    db_get tripwire/upgrade
    case "$RET" in
    false)
	exit 0;
	;;

    esac
fi

# Title for the rest of the questions
db_title Tripwire Configuration

# Warn about chanes to policy file if necessary
release=2.3.1.2-5
version=2.3.1.2-6
current=${2:-$version}

if dpkg --compare-versions "$current" lt "$version"; then
    db_fset tripwire/change-in-default-policy seen false
    db_subst tripwire/change-in-default-policy release ${release}
    db_input critical tripwire/change-in-default-policy
    db_go
fi

# Does the user wish to create a site key file if non exists
db_input high tripwire/use-sitekey || true
db_go

# Does the user wish to create a site key file if non exists
db_input high tripwire/use-localkey || true
db_go

db_get tripwire/use-sitekey
case "$RET" in
true)
    # Does the user wish to regenerate the configuration database
    db_input high tripwire/rebuild-config || true
    db_go

    # Does the user wish to regenerate the policy database
    db_input high tripwire/rebuild-policy || true
    db_go
    ;;
esac

# Does the user wish to recieve emailed reports
db_input medium tripwire/email-reports || true
db_go

# Alert the user about broken packaging
case "$2" in
2.3.0-1)
    db_subst tripwire/broken-passphrase hostname $(uname -n)
    db_input critical tripwire/broken-passphrase || true
    db_go
    ;;

esac