Skip to content

Commit

Permalink
Warning in docs about :crypto usage
Browse files Browse the repository at this point in the history
  • Loading branch information
voltone committed Feb 20, 2019
1 parent fda856f commit 8360ae1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/x509/private_key.ex
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ defmodule X509.PrivateKey do
iex> :public_key.verify(message, :sha256, signature, public_key)
true
Note that in practice it is not a good idea to directly encrypt a message
with asymmetrical cryptography, and signatures should be calculated over
message hashes rather than raw messages. The examples above are deliberate
over-simpliciations intended to highlight the `:crypto` API calls.
"""

@typedoc "RSA or EC private key"
Expand Down

0 comments on commit 8360ae1

Please sign in to comment.