mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-06 13:11:25 -07:00
Add HTTPS tracker certificate validation option
This commit adds a new libtorrent setting to validate HTTPS tracker certificates. When enabled, libtorrent will validate the certificate of HTTPS trackers against the system's certificate store. This option is only enabled on libtorrent versions >= 1.2.6 and on non-Windows systems, as OpenSSL does not use the system's certificate store on Windows.
This commit is contained in:
parent
8e553adc92
commit
cc1ebbf379
6 changed files with 55 additions and 1 deletions
|
@ -300,6 +300,8 @@ void AppController::preferencesAction()
|
|||
data["utp_tcp_mixed_mode"] = static_cast<int>(session->utpMixedMode());
|
||||
// Multiple connections per IP
|
||||
data["enable_multi_connections_from_same_ip"] = session->multiConnectionsPerIpEnabled();
|
||||
// Validate HTTPS tracker certificate
|
||||
data["validate_https_tracker_certificate"] = session->validateHTTPSTrackerCertificate();
|
||||
// Embedded tracker
|
||||
data["enable_embedded_tracker"] = session->isTrackerEnabled();
|
||||
data["embedded_tracker_port"] = pref->getTrackerPort();
|
||||
|
@ -723,6 +725,9 @@ void AppController::setPreferencesAction()
|
|||
// Multiple connections per IP
|
||||
if (hasKey("enable_multi_connections_from_same_ip"))
|
||||
session->setMultiConnectionsPerIpEnabled(it.value().toBool());
|
||||
// Validate HTTPS tracker certificate
|
||||
if (hasKey("validate_https_tracker_certificate"))
|
||||
session->setValidateHTTPSTrackerCertificate(it.value().toBool());
|
||||
// Embedded tracker
|
||||
if (hasKey("embedded_tracker_port"))
|
||||
pref->setTrackerPort(it.value().toInt());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue