File apache-20-22-upgrade of Package apache2
1
#!/bin/bash
2
3
# obsolete 2.0 modules -> 2.2 modules
4
5
echo 'looking for old 2.0 modules to be renamed...'
6
7
if a2enmod -q auth; then
8
echo 'auth -> auth_basic authn_file'
9
10
a2dismod auth
11
a2enmod auth_basic
12
a2enmod authn_file
13
a2enmod authz_groupfile
14
a2enmod authz_default
15
a2enmod authz_user
16
17
cat <<-EOF
18
19
20
!!!ATTENTION!!!
21
22
If you use basic authentication, you will need to update your
23
configuration. Typically, you need to add
24
AuthBasicProvider file
25
(example for file-based authentication) below "AuthType Basic".
26
27
!!!ATTENTION!!!
28
29
30
EOF
31
32
fi
33
34
if a2enmod -q access; then
35
echo 'access -> authz_host'
36
a2dismod access
37
a2enmod authz_host
38
fi
39
40
if a2enmod -q auth_dbm; then
41
echo 'auth_dbm -> authn_dbm'
42
a2dismod auth_dbm
43
a2enmod authn_dbm
44
fi
45
46
if a2enmod -q imap; then
47
echo 'imap -> imagemap'
48
a2dismod imap
49
a2enmod imagemap
50
fi
51
52
if a2enmod -q image_map; then
53
echo 'image_map -> imagemap'
54
a2dismod image_map
55
a2enmod imagemap
56
fi
57
58
if a2enmod -q auth_ldap; then
59
echo 'auth_ldap -> mod_authnz_ldap'
60
a2dismod auth_ldap
61
a2enmod mod_authnz_ldap
62
fi
63
64
echo 'Done.'
65