Skip to content

Commit 1532612

Browse files
authored
Merge pull request #8259 from DIRACGridBot/cherry-pick-2-915bffece-integration
[sweep:integration] robot cert nicknames
2 parents 47f7282 + cbebaa3 commit 1532612

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/DIRAC/ConfigurationSystem/Client/VOMS2CSSynchronizer.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,15 @@ def _getUserNameFromDN(dn, vo):
8787
return nname
8888
else:
8989
robot = False
90+
# only pop if the remains are sufficient (i.e. not just digits)
9091
if names[0].lower().startswith("robot"):
91-
names.pop(0)
92+
nameok = False
93+
if len(names) > 1:
94+
for name in names[1:]:
95+
if not name.isdigit():
96+
nameok = True
97+
if nameok:
98+
names.pop(0)
9299
robot = True
93100
for name in list(names):
94101
if name[0].isdigit() or "@" in name:

0 commit comments

Comments
 (0)