aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ssl/src/ssl_internal.hrl
diff options
context:
space:
mode:
authorIngela Anderton Andin <[email protected]>2017-10-02 15:17:13 +0200
committerIngela Anderton Andin <[email protected]>2017-11-08 09:33:02 +0100
commit7a0a2e9fa132cba32f4a287d03c04e9ff78a44ec (patch)
tree630fc2ba04dcece98e3c5c94013926899fdf3fab /lib/ssl/src/ssl_internal.hrl
parentd4f61c4e26005740388668f3773871f043366342 (diff)
downloadotp-7a0a2e9fa132cba32f4a287d03c04e9ff78a44ec.tar.gz
otp-7a0a2e9fa132cba32f4a287d03c04e9ff78a44ec.tar.bz2
otp-7a0a2e9fa132cba32f4a287d03c04e9ff78a44ec.zip
ssl: Add private key configuration for crypto engine
Diffstat (limited to 'lib/ssl/src/ssl_internal.hrl')
-rw-r--r--lib/ssl/src/ssl_internal.hrl13
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/ssl/src/ssl_internal.hrl b/lib/ssl/src/ssl_internal.hrl
index 24ac34653e..9bb1cbaeb0 100644
--- a/lib/ssl/src/ssl_internal.hrl
+++ b/lib/ssl/src/ssl_internal.hrl
@@ -95,7 +95,8 @@
certfile :: binary(),
cert :: public_key:der_encoded() | secret_printout() | 'undefined',
keyfile :: binary(),
- key :: {'RSAPrivateKey' | 'DSAPrivateKey' | 'ECPrivateKey' | 'PrivateKeyInfo', public_key:der_encoded()} | secret_printout() | 'undefined',
+ key :: {'RSAPrivateKey' | 'DSAPrivateKey' | 'ECPrivateKey' | 'PrivateKeyInfo',
+ public_key:der_encoded()} | key_map() | secret_printout() | 'undefined',
password :: string() | secret_printout() | 'undefined',
cacerts :: [public_key:der_encoded()] | secret_printout() | 'undefined',
cacertfile :: binary(),
@@ -164,7 +165,15 @@
connection_cb
}).
-
+-type key_map() :: #{algorithm := rsa | dss | ecdsa,
+ %% engine and key_id ought to
+ %% be :=, but putting it in
+ %% the spec gives dialyzer warning
+ %% of correct code!
+ engine => crypto:engine_ref(),
+ key_id => crypto:key_id(),
+ password => crypto:password()
+ }.
-type state_name() :: hello | abbreviated | certify | cipher | connection.
-type gen_fsm_state_return() :: {next_state, state_name(), term()} |
{next_state, state_name(), term(), timeout()} |