11
11
12
12
XROOTD_CFG_TEXT = """\
13
13
cms.space min 2g 5g
14
- xrootd.seclib /usr/lib64/libXrdSec-4.so
15
- sec.protocol /usr/lib64 gsi -certdir:/etc/grid-security/certificates \
14
+ xrootd.seclib /usr/lib64/libXrdSec.so
15
+ http.secxtractor /usr/lib64/libXrdLcmaps.so
16
+
17
+ sec.protocol /usr/lib64 gsi -d 2 -certdir:/etc/grid-security/certificates \
16
18
-cert:/etc/grid-security/xrd/xrdcert.pem \
17
19
-key:/etc/grid-security/xrd/xrdkey.pem \
18
- -crl:3 \
20
+ -crl:1 \
21
+ -ca:0 \
19
22
--gmapopt:10 \
20
23
--gmapto:0 \
21
24
%s
22
25
23
26
acc.authdb /etc/xrootd/auth_file
24
27
ofs.authorize
28
+ all.export /
25
29
26
30
if exec xrootd
27
31
http.cadir /etc/grid-security/certificates
36
40
http.header2cgi Authorization authz
37
41
38
42
# Enable Macaroons
39
- ofs.authlib libXrdMacaroons.so libXrdAccSciTokens.so
43
+ ofs.authlib libXrdMacaroons.so
40
44
xrd.port %d
41
45
xrd.protocol http:%d /usr/lib64/libXrdHttp-4.so
42
46
fi
@@ -57,16 +61,14 @@ def test_01_configure_xrootd(self):
57
61
core .state ['xrootd.tpc.backups-exist' ] = False
58
62
59
63
self .skip_ok_unless (core .options .adduser , 'user not created' )
60
- core .skip_ok_unless_installed ('xrootd' , 'xrootd-scitokens' , by_dependency = True )
64
+ core .skip_ok_unless_installed ('globus-proxy-utils' , ' xrootd' , 'xrootd-scitokens' , by_dependency = True )
61
65
62
66
user = pwd .getpwnam ("xrootd" )
63
- core .skip_ok_unless_installed ('globus-proxy-utils' )
64
67
65
68
lcmaps_packages = ('lcmaps' , 'lcmaps-db-templates' , 'xrootd-lcmaps' , 'vo-client' , 'vo-client-lcmaps-voms' )
66
69
if all ([core .rpm_is_installed (x ) for x in lcmaps_packages ]):
67
70
core .log_message ("Using xrootd-lcmaps authentication" )
68
71
sec_protocol = '-authzfun:libXrdLcmaps.so -authzfunparms:--loglevel,5'
69
- #XROOTD_CFG_TEXT += "http.secxtractor /usr/lib64/libXrdLcmaps.so/n"
70
72
sec_protocol += ',--policy,authorize_only'
71
73
else :
72
74
core .log_message ("Using XRootD mapfile authentication" )
@@ -76,7 +78,7 @@ def test_01_configure_xrootd(self):
76
78
XROOTD_CFG_TEXT % (sec_protocol , core .config ['xrootd.tpc.http-port1' ], core .config ['xrootd.tpc.http-port1' ]),
77
79
owner = 'xrootd' , backup = True , chown = (user .pw_uid , user .pw_gid ))
78
80
files .write (core .config ['xrootd.tpc.config-2' ],
79
- XROOTD_CFG_TEXT % (sec_protocol , core .config ['xrootd.tpc.http-port2' ], core .config ['xrootd.tpc.http-port1 ' ]),
81
+ XROOTD_CFG_TEXT % (sec_protocol , core .config ['xrootd.tpc.http-port2' ], core .config ['xrootd.tpc.http-port2 ' ]),
80
82
owner = 'xrootd' , backup = True , chown = (user .pw_uid , user .pw_gid ))
81
83
core .state ['xrootd.tpc.backups-exist' ] = True
82
84
@@ -85,9 +87,9 @@ def test_02_create_secrets(self):
85
87
core .config ['xrootd.tpc.macaroon-secret-1' ] = '/etc/xrootd/macaroon-secret-1'
86
88
core .config ['xrootd.tpc.macaroon-secret-2' ] = '/etc/xrootd/macaroon-secret-2'
87
89
core .check_system (["openssl" , "rand" , "-base64" , "-out" ,
88
- core .config ['xrootd.tpc.macaroon-secret-1' ], "64" ], "Creating simmetric key" )
90
+ core .config ['xrootd.tpc.macaroon-secret-1' ], "64" ], "Creating symmetric key" )
89
91
core .check_system (["openssl" , "rand" , "-base64" , "-out" ,
90
- core .config ['xrootd.tpc.macaroon-secret-2' ], "64" ], "Creating simmetric key" )
92
+ core .config ['xrootd.tpc.macaroon-secret-2' ], "64" ], "Creating symmetric key" )
91
93
files .append (core .config ['xrootd.tpc.config-1' ],
92
94
"macaroons.secretkey %s" % (core .config ['xrootd.tpc.macaroon-secret-1' ]),
93
95
owner = 'xrootd' , backup = False )
@@ -100,8 +102,8 @@ def test_03_start_xrootd(self):
100
102
core .skip_ok_unless_installed ('xrootd' , 'xrootd-scitokens' , by_dependency = True )
101
103
core .config ['xrootd_tpc_service_1' ] = "xrootd@third-party-copy-1"
102
104
core .config ['xrootd_tpc_service_2' ] = "xrootd@third-party-copy-2"
103
- service .check_start (core .config ['xrootd_tpc_service_1' ], logToCheck = '/var/log/xrootd/third-party-copy-1/xrootd.log' )
104
- service .check_start (core .config ['xrootd_tpc_service_2' ], logToCheck = '/var/log/xrootd/third-party-copy-2/xrootd.log' )
105
+ service .check_start (core .config ['xrootd_tpc_service_1' ], log_to_check = '/var/log/xrootd/third-party-copy-1/xrootd.log' )
106
+ service .check_start (core .config ['xrootd_tpc_service_2' ], log_to_check = '/var/log/xrootd/third-party-copy-2/xrootd.log' )
105
107
core .state ['xrootd.started-http-server-1' ] = True
106
108
core .state ['xrootd.started-http-server-2' ] = True
107
109
0 commit comments