Solving arcproxy hanging. BUGZ-4100
Begin arcbot message
This merge request is automatically cherrypicked from !1563 (merged) from source branch https://source.coderefinery.org/aleksandr.konstantinov/arc/-/tree/arcproxy_hangs orginally made by @aleksandr.konstantinov .
The original MR went to branch: https://source.coderefinery.org/nordugrid/arc/-/tree/master
End arcbot message
Fix looping through groups while checking for file permissions.