def setUp(self):
        super(Test_Authentication, self).setUp()

        # load tree from file
        with open(CFG_FILE_PATH) as cfg_file:
            self.config = json.load(cfg_file)

        # local test dir
        self.testing_tmp_dir = '/tmp/irods_Test_Authentication'
        shutil.rmtree(self.testing_tmp_dir, ignore_errors=True)
        os.mkdir(self.testing_tmp_dir)

        # admin sesh
        self.admin = lib.make_session_for_existing_admin()

        # make new user with no password
        self.gsi_username = '******'
        self.gsi_user = lib.mkuser_and_return_session(
            'rodsuser', self.gsi_username, None, lib.get_hostname())

        # set auth scheme for new user (client side)
        self.gsi_user.environment_file_contents[
            'irods_authentication_scheme'] = 'GSI'

        # set auth string for new user (server side)
        #user_DN = '/O=Grid/OU=GlobusTest/OU=simpleCA-gsi1/OU=Globus Simple CA/CN=antoine de torcy'
        self.admin.run_icommand(['iadmin', 'aua', self.gsi_username, self.config['client_user_DN']])
    def setUp(self):
        super(Test_Authentication, self).setUp()

        # load configuration from file
        with open(CFG_FILE_PATH) as cfg_file:
            self.config = json.load(cfg_file)

        # local test dir
        self.testing_tmp_dir = '/tmp/irods_Test_Authentication'
        shutil.rmtree(self.testing_tmp_dir, ignore_errors=True)
        os.mkdir(self.testing_tmp_dir)

        # admin sesh
        self.admin = lib.make_session_for_existing_admin()

        # make new user with no password
        self.krb_username = '******'
        self.krb_user = lib.mkuser_and_return_session(
            'rodsuser', self.krb_username, None, lib.get_hostname())

        # set auth scheme for new user (client side)
        self.krb_user.environment_file_contents[
            'irods_authentication_scheme'] = 'krb'

        # set auth string for new user (server side)
        self.admin.run_icommand(['iadmin', 'aua', self.krb_username, self.config['client_user_principal']])
Esempio n. 3
0
 def setUp(self):
     super(Test_Auth, self).setUp()
     cfg_file = os.path.join(lib.get_irods_top_level_dir(), 'tests/pydevtest/test_framework_configuration.json')
     with open(cfg_file,'r') as f:
         cfg = json.load(f)
         auth_user = cfg['irods_authuser_name']
         auth_pass = cfg['irods_authuser_password']
         self.auth_session = lib.mkuser_and_return_session('rodsuser', auth_user, auth_pass, lib.get_hostname())
Esempio n. 4
0
 def setUp(self):
     super(Test_Auth, self).setUp()
     cfg_file = os.path.join(
         lib.get_irods_top_level_dir(),
         'tests/pydevtest/test_framework_configuration.json')
     with open(cfg_file, 'r') as f:
         cfg = json.load(f)
         auth_user = cfg['irods_authuser_name']
         auth_pass = cfg['irods_authuser_password']
         self.auth_session = lib.mkuser_and_return_session(
             'rodsuser', auth_user, auth_pass, lib.get_hostname())
Esempio n. 5
0
 def setUp(self):
     super(Test_OSAuth_Only, self).setUp()
     self.auth_session = lib.mkuser_and_return_session('rodsuser', 'irods', 'temporarypasswordforci',
                                                       lib.get_hostname())
Esempio n. 6
0
 def setUp(self):
     super(Test_OSAuth_Only, self).setUp()
     self.auth_session = lib.mkuser_and_return_session(
         'rodsuser', 'irods', 'temporarypasswordforci', lib.get_hostname())
Esempio n. 7
0
 def setUp(self):
     super(Test_Auth, self).setUp()
     self.auth_session = lib.mkuser_and_return_session('rodsuser', 'irodsauthuser', 'iamnotasecret',
                                                       lib.get_hostname())
Esempio n. 8
0
 def setUp(self):
     super(Test_Auth, self).setUp()
     self.auth_session = lib.mkuser_and_return_session(
         'rodsuser', 'irodsauthuser', 'iamnotasecret', lib.get_hostname())