File tree Expand file tree Collapse file tree 2 files changed +25
-0
lines changed Expand file tree Collapse file tree 2 files changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -371,6 +371,11 @@ struct curlFileTransfer : public FileTransfer
371371 curl_easy_setopt (req, CURLOPT_SSL_VERIFYHOST, 0 );
372372 }
373373
374+ if (settings.clientCertFile != " " && settings.clientKeyFile != " " ) {
375+ curl_easy_setopt (req, CURLOPT_SSLCERT, settings.clientCertFile .get ().c_str ());
376+ curl_easy_setopt (req, CURLOPT_SSLKEY, settings.clientKeyFile .get ().c_str ());
377+ }
378+
374379 #if !defined(_WIN32) && LIBCURL_VERSION_NUM >= 0x071000
375380 curl_easy_setopt (req, CURLOPT_SOCKOPTFUNCTION, cloexec_callback);
376381 #endif
Original file line number Diff line number Diff line change @@ -1066,6 +1066,26 @@ public:
10661066 // Don't document the machine-specific default value
10671067 false };
10681068
1069+ Setting<Path> clientCertFile{
1070+ this ,
1071+ " " ,
1072+ " client-ssl-cert-file" ,
1073+ R"(
1074+ The path of a file containing a client TLS certificate used
1075+ to authenticate Nix to servers when using `https://`
1076+ downloads.
1077+ )" };
1078+
1079+ Setting<Path> clientKeyFile{
1080+ this ,
1081+ " " ,
1082+ " client-ssl-key-file" ,
1083+ R"(
1084+ The path of a file containing a client TLS private key used
1085+ to authenticate Nix to servers when using `https://`
1086+ downloads.
1087+ )" ,};
1088+
10691089#ifdef __linux__
10701090 Setting<bool > filterSyscalls{
10711091 this , true , " filter-syscalls" ,
You can’t perform that action at this time.
0 commit comments