I have a client handshake SSL implementation using the following functions: SSL_CTX_load_verify_locations SSL_CTX_use_certificate_chain_file SSL_CTX_use_PrivateKey_file
All functions get char * type for the file name parameter. How can I change it to support file location in Unicode?
Thank!
On which platform? OpenSSL under Posix supports UTF-8 paths, but not on other platforms. Most likely, you will have to manually upload the certificate files yourself, using standard input / output functions of OS files that support Unicode paths, and then analyze the raw data and load it into OpenSSL, for example, via PEM_read_bio_X509with sk_X509_NAME_push, PEM_read_bio_PrivateKey/d2i_PrivateKey_biowith SSL_CTX_use_PrivateKey, d2i_X509_bio/PEM_read_bio_X509with SSL_CTX_use_certificate, etc. .
PEM_read_bio_X509
sk_X509_NAME_push
PEM_read_bio_PrivateKey/d2i_PrivateKey_bio
SSL_CTX_use_PrivateKey
d2i_X509_bio/PEM_read_bio_X509
SSL_CTX_use_certificate
, , , . SSL_CTX_load_verify_locations openssl, openssl utf-8 , Windows. BIO_new_file, , utf-8 , _WIN32, CP_UTF8. . openssl ANSI-, utf-8. , openssl utf-8, ANSI- Windows.
Source: https://habr.com/ru/post/1735911/More articles:xml invalid character in this encoding - c #SharePoint - Cannot complete this operation. Contact your administrator - sharepointQuestion Qt Qbrush - colorsShould I store TcpClient, although I only care about its stream? - garbage-collectionmod_rewrite and relative urls - apache(JQuery) Find td contents from selected tr - javascriptWhy does this python queue code process elements multiple times? - python.net equivilent functions Delphi QuotedStr - c #OWC11 Date formatting ignored - dateDownload external SWF application in new Air window with resize function - flexAll Articles