1212 ffi as _ffi ,
1313 lib as _lib ,
1414 make_assert as _make_assert ,
15- path_string as _path_string ,
15+ path_bytes as _path_bytes ,
1616 text_to_bytes_and_warn as _text_to_bytes_and_warn ,
1717 no_zero_allocator as _no_zero_allocator ,
1818)
@@ -781,12 +781,12 @@ def load_verify_locations(self, cafile, capath=None):
781781 if cafile is None :
782782 cafile = _ffi .NULL
783783 else :
784- cafile = _path_string (cafile )
784+ cafile = _path_bytes (cafile )
785785
786786 if capath is None :
787787 capath = _ffi .NULL
788788 else :
789- capath = _path_string (capath )
789+ capath = _path_bytes (capath )
790790
791791 load_result = _lib .SSL_CTX_load_verify_locations (
792792 self ._context , cafile , capath
@@ -920,7 +920,7 @@ def use_certificate_chain_file(self, certfile):
920920
921921 :return: None
922922 """
923- certfile = _path_string (certfile )
923+ certfile = _path_bytes (certfile )
924924
925925 result = _lib .SSL_CTX_use_certificate_chain_file (
926926 self ._context , certfile
@@ -940,7 +940,7 @@ def use_certificate_file(self, certfile, filetype=FILETYPE_PEM):
940940
941941 :return: None
942942 """
943- certfile = _path_string (certfile )
943+ certfile = _path_bytes (certfile )
944944 if not isinstance (filetype , int ):
945945 raise TypeError ("filetype must be an integer" )
946946
@@ -998,7 +998,7 @@ def use_privatekey_file(self, keyfile, filetype=_UNSPECIFIED):
998998
999999 :return: None
10001000 """
1001- keyfile = _path_string (keyfile )
1001+ keyfile = _path_bytes (keyfile )
10021002
10031003 if filetype is _UNSPECIFIED :
10041004 filetype = FILETYPE_PEM
@@ -1169,7 +1169,7 @@ def load_tmp_dh(self, dhfile):
11691169
11701170 :return: None
11711171 """
1172- dhfile = _path_string (dhfile )
1172+ dhfile = _path_bytes (dhfile )
11731173
11741174 bio = _lib .BIO_new_file (dhfile , b"r" )
11751175 if bio == _ffi .NULL :
0 commit comments