forked from huawei/openGauss-server
Update libcomm_client_ssl.cpp
This commit is contained in:
parent
22b3c75a36
commit
3c0a229006
|
@ -236,8 +236,6 @@ char* LibCommErrMessage(void) {
|
|||
|
||||
return errBuf;
|
||||
}
|
||||
|
||||
|
||||
int LibCommClientSSLPasswd(SSL* pstContext, const char * path, const char * userName, LibCommConn * conn) {
|
||||
char* CertFilesDir = NULL;
|
||||
char CertFilesPath[MAXPATH] = {0};
|
||||
|
@ -259,10 +257,10 @@ int LibCommClientSSLPasswd(SSL* pstContext, const char * path, const char * user
|
|||
CertFilesDir = CertFilesPath;
|
||||
get_parent_directory(CertFilesDir);
|
||||
|
||||
/*check whether the cipher and rand files begins with userName exist.
|
||||
/*check whether the cipher and rand files beginning with userName exist.
|
||||
if exist, decrypt it.
|
||||
if not,decrypt the default cipher and rand files begins with client%.
|
||||
Because,for every client user mayown certification and private key*/
|
||||
if not,decrypt the default cipher and rand files begins with client.
|
||||
Because,for every client user may own certification and private key*/
|
||||
if (NULL == userName) {
|
||||
retval = LibCommClientCheckPermissionCipherFile(CertFilesDir, conn, NULL);
|
||||
if (retval != 1)
|
||||
|
|
Loading…
Reference in New Issue