ntrepid8 / ex_crypto

Wrapper around the Erlang crypto module for Elixir.
MIT License
144 stars 48 forks source link

Loads RSA keys with Passphrase #12

Closed sheharyarn closed 6 years ago

sheharyarn commented 6 years ago

These methods accept an additional passphrase argument (defaults to nil), which if present, tries to decode the entry using the supplied passphrase:

Also converts the passphrase to charlist if it's a string to make it work with the underlying erlang :public_key module.

Closes #11.

sheharyarn commented 6 years ago

This is weird, raises error on String.to_charlist/1. Also doesn't fail locally.

@ntrepid8 Can you restart the build and see if it happens again?


Update: Turns out it used to be String.to_char_list in elixir 1.2.x and previous versions. Updated the minimum elixir requirement to 1.3.

ntrepid8 commented 6 years ago

Mostly this looks great! Thanks for the PR, just had the one question about the Elixir version requirement.

sheharyarn commented 6 years ago

@ntrepid8 Yeah, I'm using String.to_charlist/1 which didn't exist before Elixir 1.3 (it used to be String.to_char_list/1).

ntrepid8 commented 6 years ago

I'll try and get this packaged up and uploaded to hex.pm this afternoon. I think it will go up as v0.6.0.

ntrepid8 commented 6 years ago

Released:

Thanks again!