Commit 3a214844 authored by Volodymyr Yurchenko's avatar Volodymyr Yurchenko
Browse files

Set default path for loading client's CA's

parent 11732e7a
Pipeline #872014 passed with stage
in 2 minutes
......@@ -1692,16 +1692,14 @@ int TJAlien::ws_service_callback(struct lws *wsi, enum lws_callback_reasons reas
{
if (gDebug > 1) printf("[Websocket Callback] LOAD_EXTRA_CLIENT_VERIFY_CERTS is called\n");
std::string homedir; // local home directory
if (getenv("HOME") == NULL)
homedir = "~";
else
homedir = getenv("HOME");
//SSL_CTX_set_verify((SSL_CTX*)user, SSL_VERIFY_PEER, NULL);
//SSL_set_verify(wsi->ssl, SSL_VERIFY_PEER, NULL);
std::string location = homedir + "/.j/trusts/";
std::string location = "/etc/grid-security/certificates/";
struct stat info;
if (stat("/cvmfs/alice.cern.ch", &info) == 0)
location = "/cvmfs/alice.cern.ch" + location;
std::string capath = std::getenv("X509_CERT_DIR") ? : location;
size_t pos = 0;
std::string token;
......
......@@ -61,6 +61,7 @@ typedef char int8_t;
#include <stdlib.h>
#include <string>
#include <signal.h>
#include <sys/stat.h>
#if !defined(__CINT__) && !defined(__MAKECINT__)
#include <libwebsockets.h>
#include "lws_config.h"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment