We’ve run into a problem with VOMS-based user authorization in EOS
Everything works just fine with an RFC proxy generated on our UI.
Client:
-bash-4.2$ rpm -qf `which voms-proxy-info`
voms-clients-cpp-2.0.16-1.el7.x86_64
-bash-4.2$ rpm -qf `which xrdcp`
xrootd-client-5.2.0-1.el7.x86_64
-bash-4.2$ rpm -qf `which eos`
eos-client-4.8.63-20210924154237git449f2b2.el7.cern.x86_64
-bash-4.2$ voms-proxy-info --all
subject : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev/CN=579999927
issuer : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
identity : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
type : RFC compliant proxy
strength : 1024 bits
path : /tmp/x509up_u1947400056
timeleft : 9:24:35
key usage : Digital Signature, Key Encipherment, Data Encipherment, Key Agreement
=== VO spd.nica.jinr extension information ===
VO : spd.nica.jinr
subject : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
issuer : /C=RU/O=RDIG/OU=hosts/OU=jinr.ru/CN=lcgvoms01.jinr.ru
attribute : /spd.nica.jinr/Role=NULL/Capability=NULL
timeleft : 9:24:35
uri : lcgvoms01.jinr.ru:15003
-bash-4.2$
-bash-4.2$ export EOS_MGM_URL=root://alice21.spbu.ru
-bash-4.2$ eos whoami
Virtual Identity: uid=1219200014 (1219200014) gid=7000 (7000) [authz:gsi] host=v009.pnpi.nw.ru domain=pnpi.nw.ru
-bash-4.2$
-bash-4.2$ xrdcp /etc/passwd root://alice21.spbu.ru//eos/spbcloud/spd/mainpool/file$RANDOM
[2.572kB/2.572kB][100%][==================================================][2.572kB/s]
-bash-4.2$ eos ls -l /eos/spbcloud/spd/mainpool/
-rw-r--r-- 1 spd spd 2634 Jan 24 16:36 file18225
-bash-4.2$
Server:
[root@alice21 ~]# rpm -qf `which eos`
eos-client-4.8.62-1.el7.cern.x86_64
[root@alice21 ~]#
[root@alice21 ~]# tail -4 /etc/grid-security/grid-mapfile
"/mpd.nica.jinr/Role=NULL/Capability=NULL" mpd
"/mpd.nica.jinr" mpd
"/spd.nica.jinr/Role=NULL/Capability=NULL" spd
"/spd.nica.jinr" spd
[root@alice21 ~]#
[root@alice21 ~]# grep gsi /etc/xrd.cf.mgm
sec.protocol gsi -gridmap:/etc/grid-security/grid-mapfile -certdir:/etc/grid-security/certificates -cert:/etc/grid-security/hostcert.pem -key:/etc/grid-security/hostkey.pem -d:3 -crl:0 -vomsfunparms:dbg|certfmt=x509 -gmapopt:11 -gmapto:60 -vomsat:1 -moninfo:1
sec.protbind * only krb5 gsi sss
[root@alice21 ~]#
From log /var/log/eos/mgm/xrdlog.mgm:
……………………………………………………………………
220124 16:36:43 11795 cryptossl_X509GetVOMSAttr: ret: 1 - vat: /spd.nica.jinr/Role=NULL/Capability=NULL
220124 16:36:43 11795 cryptossl_X509GetVOMSAttr: found extension '2.5.29.15'
220124 16:36:43 11795 cryptossl_X509GetVOMSAttr: found extension '2.5.29.19'
220124 16:36:43 11795 cryptossl_X509GetVOMSAttr: found extension '2.5.29.35'
220124 16:36:43 11795 cryptossl_X509GetVOMSAttr: found extension '1.3.6.1.5.5.7.1.14'
220124 16:36:43 11795 secgsi_Authenticate: VOMS: Entity.vorg: spd.nica.jinr
220124 16:36:43 11795 secgsi_Authenticate: VOMS: Entity.grps: /spd.nica.jinr
220124 16:36:43 11795 secgsi_Authenticate: VOMS: Entity.role: <none>
220124 16:36:43 11795 secgsi_Authenticate: VOMS: Entity.endorsements: /spd.nica.jinr/Role=NULL/Capability=NULL
220124 16:36:43 11795 sut_Buffer::~XrdSutBuffer: type: 3000
220124 16:36:43 11795 sut_Buffer::~XrdSutBuffer: type: 3001
…………………………………………………………………………
220124 16:36:43 11795 XrootdXeq: zar.14333:122@v009.pnpi.nw.ru pub IPv4 login as /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
220124 16:36:43 time=1643031403.866960 func=IdMap level=INFO logid=static.............................. unit=mgm@alice21.spbu.ru:1094 tid=00007f0874afa700 source=Mapping:1042 tident= sec=(null) uid=99 gid=99 name=- geo="" sec.prot=gsi sec.name="/C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev" sec.host="v009.pnpi.nw.ru" sec.vorg="spd.nica.jinr" sec.grps="/spd.nica.jinr" sec.role="" sec.info="/C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev" sec.app="" sec.tident="zar.14333:122@v009.pnpi.nw.ru" vid.uid=1219200014 vid.gid=7000
Here we can clearly see properly filled VOMS attributes: sec.vorg=“spd.nica.jinr” sec.grps="/spd.nica.jinr"
However, if we do exactly the same from the job on the worker node, which uses a proxy certificate delegated by ARC, we face a problem:
-bash-4.2$ cat eostest.sh
#/bin/sh!
DST=$1
voms-proxy-info -all;
rpm -qf `which xrdcp`;
rpm -qa `which voms-proxy-info`
echo $DST
OUTFILE=fileb$RANDOM
xrdcp -f -p /etc/passwd ${DST}/$OUTFILE;
echo END;
-bash-4.2$ cat eostestspb_spd.xrsl
&( executable = "eostest.sh" )(runTimeEnvironment = "ENV/PROXY")(Arguments = "root://alice21.spbu.ru://eos/spbcloud/spd/mainpool/")( jobname = "eos test" )( stdout = "std.out" )( join = "yes" )( gmlog = "gmlog" )(outputFiles = ("std.out" ""))
-bash-4.2$
-bash-4.2$ arcsub eostestspb_spd.xrsl -c v012.pnpi.nw.ru
Job submitted with jobid: gsiftp://v012.pnpi.nw.ru:2811/jobs/QgxKDm1qEW0nHpSrzpghF0noABFKDmABFKDmxEKKDmABFKDmPN9fNo
-bash-4.2$
Result:
-bash-4.2$ cat QgxKDm1qEW0nHpSrzpghF0noABFKDmABFKDmxEKKDmABFKDmPN9fNo/std.out
subject : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev/CN=579999927/CN=1413062767
issuer : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev/CN=579999927
identity : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev/CN=579999927
type : RFC compliant proxy
strength : 1024 bits
path : /scratch/localscratch/QgxKDm1qEW0nHpSrzpghF0noABFKDmABFKDmxEKKDmABFKDmPN9fNo/user.proxy
timeleft : 9:12:53
key usage : Digital Signature, Key Encipherment, Data Encipherment, Key Agreement
=== VO spd.nica.jinr extension information ===
VO : spd.nica.jinr
subject : /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
issuer : /C=RU/O=RDIG/OU=hosts/OU=jinr.ru/CN=lcgvoms01.jinr.ru
attribute : /spd.nica.jinr/Role=NULL/Capability=NULL
timeleft : 9:12:53
uri : lcgvoms01.jinr.ru:15003
xrootd-client-5.2.0-1.el7.x86_64
root://alice21.spbu.ru://eos/spbcloud/spd/mainpool/
[0B/0B][100%][==================================================][0B/s]
Run: [ERROR] Server responded with an error: [3010] Unable to open file /eos/spbcloud/spd/mainpool/fileb30315; Operation not permitted (destination)
END
-bash-4.2$
Transfer fails with permission error, and on a server side VOMS attributes are empty.
Server:
from /var/log/eos/mgm/xrdlog.mgm:
…………………………
220124 16:46:45 15113 secgsi_XrdOucGMap::load: map information up-to-date: no need to load
220124 16:46:45 15113 secgsi_XrdOucGMap::dn2user: no valid match found for DN '/C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev'
220124 16:46:45 15113 secgsi_Authenticate: username(s) associated with this DN:
220124 16:46:45 15113 secgsi_Authenticate: WARNING: user mapping lookup failed - use DN or DN-hash as name
220124 16:46:45 15113 cryptossl_X509GetVOMSAttr: found extension '2.5.29.15'
220124 16:46:45 15113 cryptossl_X509GetVOMSAttr: found extension '1.3.6.1.5.5.7.1.14'
220124 16:46:45 15113 secgsi_ExtractVOMS: No VOMS attributes in proxy chain
220124 16:46:45 15113 secgsi_Authenticate: VOMS: Entity.vorg: <none>
220124 16:46:45 15113 secgsi_Authenticate: VOMS: Entity.grps: <none>
220124 16:46:45 15113 secgsi_Authenticate: VOMS: Entity.role: <none>
220124 16:46:45 15113 secgsi_Authenticate: VOMS: Entity.endorsements: <none>
……………………………………………
220124 16:46:45 15113 XrootdXeq: nicaspd0.16881:121@v014.pnpi.nw.ru pub IPv4 login as /C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev
220124 16:46:45 time=1643032005.727642 func=IdMap level=INFO logid=static.............................. unit=mgm@alice21.spbu.ru:1094 tid=00007f08749f9700 source=Mapping:1042 tident= sec=(null) uid=99 gid=99 name=- geo="" sec.prot=gsi sec.name="/C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev" sec.host="v014.pnpi.nw.ru" sec.vorg="" sec.grps="" sec.role="" sec.info="/C=RU/O=RDIG/OU=users/OU=spbu.ru/CN=Andrey Zarochentsev" sec.app="" sec.tident="nicaspd0.16881:121@v014.pnpi.nw.ru" vid.uid=99 vid.gid=99
voms-proxy-info does not complain, but for some reason EOS fails to locate VOMS extension in a delegated proxy. Could you please help us to resolve this issue?