nymous / pydantic-vault

A simple extension to Pydantic BaseSettings that can retrieve secrets from Hashicorp Vault
MIT License
52 stars 13 forks source link

Skip certificate verification or pass vault cert. #16

Closed raider444 closed 1 year ago

raider444 commented 1 year ago

Hi, is it possible to skip vault certificate verification? In hvac library you can pass verify=False or define certificate.

nymous commented 1 year ago

Hello @raider444, sorry for the delay!

That is indeed a cool idea! Would you be ready to submit a PR adding support for this? Maybe adding a vault_certificate_verify field in the Config class could work, with a None default value, but accepting a path to a certificate or False, and forward it to the hvac calls underneath. If you have a better name I'm all ears ^^ Should we also support an environment variable for this? I know there is already REQUESTS_CA_BUNDLE and CURL_CA_BUNDLE, but they would change requests behavior globally which could be too much.

nymous commented 1 year ago

Fixed by #24, and release in 0.8.0.