Пример #1
0
 def test_06c_xrdcp_download_voms(self):
     self.skip_unless_security("VOMS")
     remote_file = TestXrootd.vo_file_to_download
     remote_url = xroot_url(remote_file)
     command = ('xrdcp', '--nopbar', '--debug', '2', remote_url,
                TestXrootd.download_temp)
     message = "xrdcp download with VOMS"
     with core.no_bearer_token(core.options.username):
         self._test_download(remote_file, command, message)
Пример #2
0
 def test_03a_xrdcp_upload_gsi_authenticated(self):
     self.skip_unless_security("GSI")
     command = ('xrdcp', '--debug', '2', TestXrootd.__data_path,
                xroot_url(TestXrootd.user_copied_file_gsi))
     with core.no_bearer_token(core.options.username):
         core.check_system(command,
                           "xrdcp upload to user dir with GSI auth",
                           user=True)
     self.assert_(os.path.exists(TestXrootd.user_copied_file_gsi),
                  "Uploaded file missing")
Пример #3
0
 def test_03c_xrdcp_upload_voms_authenticated(self):
     self.skip_unless_security("VOMS")
     xrootd_url = xroot_url(TestXrootd.vo_copied_file)
     command = ('xrdcp', '--force', '--debug', '2', TestXrootd.__data_path,
                xrootd_url)
     with core.no_bearer_token(core.options.username):
         core.check_system(command,
                           "xrdcp upload to vo dir with VOMS auth",
                           user=True)
     self.assert_(os.path.exists(TestXrootd.vo_copied_file),
                  "Uploaded file missing")
Пример #4
0
 def test_04a_xrdcp_upload_gsi_authenticated_denied(self):
     self.skip_unless_security("GSI")
     try:
         command = ('xrdcp', '--debug', '2', TestXrootd.__data_path,
                    xroot_url(TestXrootd.rootdir_copied_file))
         with core.no_bearer_token(core.options.username):
             core.check_system(
                 command,
                 "xrdcp upload to dir w/o write access (should be denied)",
                 exit=ERR_PERMISSION_DENIED,
                 user=True)
         self.assertFalse(os.path.exists(TestXrootd.rootdir_copied_file),
                          "Uploaded file wrongly present")
     finally:
         files.remove(TestXrootd.rootdir_copied_file)