Strech / avrora

A convenient Elixir library to work with Avro messages, schemas and Confluent® Schema Registry
https://hexdocs.pm/avrora
MIT License
97 stars 33 forks source link

Pass verify: verify_none ssl setting explicitly to httpc calls to get rid of warnings when HTTPS and OTP 25 are used #97

Closed goozzik closed 2 years ago

goozzik commented 2 years ago

Hi. I recently upgraded to OTP 25 and started getting these warnings when avrora was trying to fetch schemas from confluent schema registry:

iex(1)>  Avrora.HTTPClient.get("https://example.com")
Failed to serialize event. error: {:invalid, &:ssl_logger.format/1}, event: %{"@timestamp": "2022-09-05T14:05:34.391+02:00", depth: 20, message: "Description: 'Authenticity is not established by certificate path validation'\n     Reason: 'Option {verify, verify_peer} and cacertfile/cacerts is missing'\n", report_cb: &:ssl_logger.format/1}
Failed to serialize event. error: {:invalid, &:ssl_logger.format/1}, event: %{"@timestamp": "2022-09-05T14:05:34.629+02:00", depth: 20, message: "Description: 'Authenticity is not established by certificate path validation'\n     Reason: 'Option {verify, verify_peer} and cacertfile/cacerts is missing'\n", report_cb: &:ssl_logger.format/1}

(Please ignore serializing error part, this is about 'Option {verify, verify_peer} and cacertfile/cacerts is missing path).

In this PR I add missing options to :httpc calls to get rid of these warnings.

Strech commented 2 years ago

Thanks for the finding @goozzik, I've release v0.24.1 💙