|
24 | 24 | from re import compile as regex |
25 | 25 | import gc |
26 | 26 | import six |
| 27 | +from irods.test.setupssl import create_ssl_dir |
27 | 28 |
|
28 | 29 | # |
29 | 30 | # Allow override to specify the PAM password in effect for the test rodsuser. |
@@ -511,18 +512,16 @@ def test_ssl_with_server_verify_set_to_none_281(self): |
511 | 512 | with helpers.file_backed_up(env_file): |
512 | 513 | with open(env_file) as env_file_handle: |
513 | 514 | env = json.load( env_file_handle ) |
514 | | - create_ssl_dir(ssl_dir='./some') |
515 | | - env.update({ |
516 | | - #"irods_ssl_ca_certificate_file": "./some/irods.crt", # does not need to match server cert |
517 | | - # "irods_client_server_negotiation": "request_server_negotiation", |
518 | | - # "irods_client_server_policy": "CS_NEG_REQUIRE", |
519 | | - # "irods_ssl_ca_certificate_file": "/path/to/some/file.crt", # does not need to exist |
520 | | - "irods_ssl_verify_server": "none", |
521 | | - # "irods_encryption_key_size": 32, |
522 | | - # "irods_encryption_salt_size": 8, |
523 | | - # "irods_encryption_num_hash_rounds": 16, |
524 | | - # "irods_encryption_algorithm": "AES-256-CBC" |
525 | | - }) |
| 515 | + my_ssl_directory = os.path.expanduser("~/some") |
| 516 | + create_ssl_dir(ssl_dir = my_ssl_directory) |
| 517 | + keys_to_update = {key:value.replace("/etc/irods/ssl",my_ssl_directory) |
| 518 | + for key,value in env.items() if type(value) is str and value.startswith("/etc/irods/ssl")} |
| 519 | + keys_to_update["irods_ssl_verify_server"] = "none" |
| 520 | + env.update( keys_to_update ) |
| 521 | + # --- TODO: remove these lines |
| 522 | + import pprint |
| 523 | + print ("Updated = \n", pprint.pformat(env)) |
| 524 | + # --- |
526 | 525 | with open(env_file,'w') as f: |
527 | 526 | json.dump(env,f) |
528 | 527 | with helpers.make_session() as session: |
|
0 commit comments