Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Blocked on tiledb cloud update] Remove rest.ignore_ssl_validation config option. #5309

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions tiledb/api/c_api/config/config_api_external.h
Original file line number Diff line number Diff line change
Expand Up @@ -711,9 +711,6 @@ TILEDB_EXPORT void tiledb_config_free(tiledb_config_t** config) TILEDB_NOEXCEPT;
* If true, incomplete queries received from server are automatically
* resubmitted before returning to user control. <br>
* **Default**: "true"
* - `rest.ignore_ssl_validation` <br>
* Have curl ignore ssl peer and host validation for REST server. <br>
* **Default**: false
* - `rest.creation_access_credentials_name` <br>
* The name of the registered access key to use for creation of the REST
* server. <br>
Expand Down
3 changes: 0 additions & 3 deletions tiledb/sm/cpp_api/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -885,9 +885,6 @@ class Config {
* If true, incomplete queries received from server are automatically
* resubmitted before returning to user control. <br>
* **Default**: "true"
* - `rest.ignore_ssl_validation` <br>
* Have curl ignore ssl peer and host validation for REST server. <br>
* **Default**: false
* - `rest.creation_access_credentials_name` <br>
* The name of the registered access key to use for creation of the REST
* server. <br>
Expand Down
16 changes: 0 additions & 16 deletions tiledb/sm/filesystem/ssl_config.cc
Original file line number Diff line number Diff line change
Expand Up @@ -109,20 +109,4 @@ S3SSLConfig::S3SSLConfig(const Config& cfg)
}
}

RestSSLConfig::RestSSLConfig(const Config& cfg)
: SSLConfig(cfg) {
// Only override what was found in `ssl.verify` if
// `rest.ignore_ssl_verification` is non-default (i.e., true, the naming here
// is backwards from all the other ssl verification key names)
auto skip_verify = cfg.get<bool>("rest.ignore_ssl_validation");
if (skip_verify.has_value() && skip_verify.value()) {
LOG_WARN(
"The 'rest.ignore_ssl_validation = false' configuration option "
"has been replaced with 'ssl.verify = true'. Make sure that you update "
"your configuration because 'rest.ignore_ssl_validation' will "
"eventually be removed.");
verify_ = false;
}
}

} // namespace tiledb::sm
5 changes: 0 additions & 5 deletions tiledb/sm/filesystem/ssl_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,6 @@ class S3SSLConfig : public SSLConfig {
S3SSLConfig(const Config& cfg);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about I remove the S3-specific options as well in this PR? They are likewise deprecated and emitting warnings for more than a year.

};

class RestSSLConfig : public SSLConfig {
public:
RestSSLConfig(const Config& cfg);
};

} // namespace tiledb::sm

#endif // TILEDB_SSL_CONFIG_H
2 changes: 1 addition & 1 deletion tiledb/sm/rest/curl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ Status Curl::init(
return LOG_STATUS(Status_RestError(
"Error initializing libcurl; failed to set CURLOPT_HEADERDATA"));

SSLConfig ssl_cfg = RestSSLConfig(*config_);
SSLConfig ssl_cfg(*config_);

if (ssl_cfg.verify() == false) {
curl_easy_setopt(curl_.get(), CURLOPT_SSL_VERIFYHOST, 0);
Expand Down
Loading