Conversation
voltone
left a comment
There was a problem hiding this comment.
Thanks for the proposal! Does GovCloud use these roots for RDS, or also for other things? In the normal RDS environments they use dedicated root CAs for the RDS service, independent of the normal (public) root CA, for things like public host certificates.
There is now quite a lot of duplication in the Mix task, including the bundles variable (which also has some inconsistencies in use of string literals, module attributes and function calls). Do you think you can clean that up a bit, or shall I?
| def ssl_opts(url_or_hostname) when is_list(url_or_hostname) do | ||
| ssl_opts(List.to_string(url_or_hostname)) | ||
| end | ||
|
|
||
| def ssl_opts(url_or_hostname) do | ||
| def ssl_opts(url_or_hostname, opts \\ []) when is_list(url_or_hostname) and is_list(opts) do |
There was a problem hiding this comment.
This now no longer accepts a binary as the first argument, it only accepts a charlist
| file_path(aws). | ||
|
|
||
| file_path(aws) -> | ||
| PrivDir = code:lib_dir(aws_rds_castore, priv), |
There was a problem hiding this comment.
I just merged #18 that changes how the path is built. Can you please rebase on main?
| ssl_opts(Hostname, []). | ||
|
|
||
| %% Returns a set of `:ssl` transport options for certificate verification with options. | ||
| ssl_opts(Hostname, Options) when is_binary(Hostname) -> |
There was a problem hiding this comment.
Ah, so now Erlang supports binaries, but Elixir no longer does :)
Fixes #16
Adds GovCloud bundle and allows choosing between them, e.g. with
AwsRdsCAStore.ssl_opts(database_url, aws_partition: :govcloud)The GovCloud bundle comes from https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.SSL.html