From 867e3974db7c48d147f1c2c54899c2834ad3ee3d Mon Sep 17 00:00:00 2001 From: Andreas Schultz Date: Sat, 17 May 2014 15:01:46 +0200 Subject: ssl: implement AES128-GCM suites --- lib/ssl/doc/src/ssl.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index ffee4bd1af..77e24ac952 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -136,7 +136,7 @@

cipher() = rc4_128 | des_cbc | '3des_ede_cbc' - | aes_128_cbc | aes_256_cbc

+ | aes_128_cbc | aes_256_cbc | aes_128_gcm | aes_256_gcm

hash() = md5 | sha

-- cgit v1.2.3 From 69de799fdce1c4cc5a582df6f2a86ccd3e62c3a9 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Mon, 12 Jan 2015 12:15:22 +0100 Subject: ssl: Remove sslv3 from the default supported protocol versions --- lib/ssl/doc/src/ssl.xml | 40 ++++++++++++++++++++++++++++++---------- 1 file changed, 30 insertions(+), 10 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 83e5ed82bb..bd2cb70e3f 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -4,7 +4,7 @@
- 19992014 + 19992015 Ericsson AB. All Rights Reserved. @@ -38,7 +38,9 @@ ssl requires the crypto and public_key applications. Supported SSL/TLS-versions are SSL-3.0, TLS-1.0, TLS-1.1 and TLS-1.2. - For security reasons sslv2 is not supported. + For security reasons SSL-2.0 is not supported. + For security reasons SSL-3.0 is no longer supported by default, + but may be configured. Ephemeral Diffie-Hellman cipher suites are supported but not Diffie Hellman Certificates cipher suites. Elliptic Curve cipher suites are supported if crypto @@ -302,7 +304,7 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo - {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca + {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca } Claim an intermediat CA in the chain as trusted. TLS will then perform the public_key:pkix_path_validation/3 with the selected CA as trusted anchor and the rest of the chain. @@ -311,7 +313,7 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo {versions, [protocol()]} TLS protocol versions that will be supported by started clients and servers. This option overrides the application environment option protocol_version. If the - environment option is not set it defaults to all versions supported by the SSL application. See also + environment option is not set it defaults to all versions, except SSL-3.0, supported by the SSL application. See also ssl(6) @@ -904,19 +906,37 @@ fun(srp, Username :: string(), UserState :: term()) -> - versions() -> - [{SslAppVer, SupportedSslVer, AvailableSslVsn}] + versions() -> [versions_info()] Returns version information relevant for the ssl application. - SslAppVer = string() - SupportedSslVer = [protocol()] - AvailableSslVsn = [protocol()] + versions_info() = {app_vsn, string()} | {supported | available, [protocol()]

Returns version information relevant for the - ssl application.

+ ssl application. +

+ + app_vsn + The application version of the OTP ssl application. + + supported + + TLS/SSL versions supported by default. + Overridden by a versions option on + connect/[2,3,4], listen/2 and ssl_accept/[1,2,3]. For the + negotiated TLS/SSL version see ssl:connection_info/1 + + + available + All TLS/SSL versions that the Erlang ssl application + can support. Note that TLS 1.2 requires sufficient support + from the crypto application. +
-- cgit v1.2.3 From 519b07bca04bdd8585b48f2de6b7124ca6455358 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 13 Jan 2015 15:16:20 +0100 Subject: ssl: Reenable padding check for TLS-1.0 and provide backwards compatible disable option --- lib/ssl/doc/src/ssl.xml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index bd2cb70e3f..d77c6440b0 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -350,11 +350,23 @@ fun(srp, Username :: string(), UserState :: term()) ->

+ {padding_check, boolean()} + +

This option only affects TLS-1.0 connections. + If set to false it disables the block cipher padding check + to be able to interoperate with legacy software. +

+ +

Using this option makes TLS vulnerable to + the Poodle attack

+ +
+ - + - -
+ +
SSL OPTION DESCRIPTIONS - CLIENT SIDE

Options described here are client specific or has a slightly different -- cgit v1.2.3 From 4e0a5e36b38e3f15ed8f7d700d26f2424a47111c Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Wed, 11 Feb 2015 14:53:10 +0100 Subject: ssl: Integrate public_key CRL verification with the ssl application --- lib/ssl/doc/src/ssl.xml | 45 +++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 41 insertions(+), 4 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 7a5f72710a..c9b02d44ec 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -51,9 +51,9 @@ IDEA cipher suites are not supported as they have become deprecated by the latest TLS spec so there is not any real motivation to implement them. - CRL and policy certificate extensions are not supported - yet. However CRL verification is supported by public_key, only not integrated - in ssl yet. + CRL validation is supported. + Policy certificate extensions are not supported + yet. Support for 'Server Name Indication' extension client side (RFC 6066 section 3). @@ -301,10 +301,47 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo Possible such reasons see public_key:pkix_path_validation/3 + + + {crl_check, boolean() | peer | best_effort ) + + Perform CRL (Certificate Revocation List) verification + + public_key:pkix_crls_validate/3, during the + public_key:pkix_path_validation/3 + invokation on all the certificates in the peer certificate chain. Defaults to + false. + +

peer - check is only performed on + the peer certificate.

+ +

best_effort - if certificate revokation status can not be determined + it will be accepted as valid.

+

The CA certificates specified for the connection will be used to + construct the certificate chain validating the CRLs.

+ +

The CRLs will be fetched from a local or external cache + ssl_crl_cache_api(3).

- {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca } + {crl_cache, {Module::atom, {DbHandle::internal | term(), Args::list()}} + +

Module defaults to ssl_crl_cache with DbHandle internal and an + empty argument list. The following arguments may be specified for the internal cache.

+ + {http, timeout()} + + Enables fetching of CRLs specified as http URIs in X509 cerificate extensions. + Requires the OTP inets application. + + +
+ + {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca + Claim an intermediat CA in the chain as trusted. TLS will then perform the public_key:pkix_path_validation/3 with the selected CA as trusted anchor and the rest of the chain. -- cgit v1.2.3 From 2c5ec58cedb6d88ea1ecdee4893bba54d397aeed Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 17 Mar 2015 10:47:42 +0100 Subject: ssl: Improve documentation --- lib/ssl/doc/src/ssl.xml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index c9b02d44ec..47100c0d81 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -94,7 +94,7 @@ {log_alert, boolean()} | {server_name_indication, hostname() | disable}

-

transportoption() = {cb_info, {CallbackModule::atom(), DataTag::atom(), ClosedTag::atom(), ErrTag:atom()}} +

transportoption() = {cb_info, {CallbackModule :: atom(), DataTag :: atom(), ClosedTag :: atom(), ErrTag:atom()}} - defaults to {gen_tcp, tcp, tcp_closed, tcp_error}. Can be used to customize the transport layer. The callback module must implement a reliable transport protocol and behave as gen_tcp and in addition have functions corresponding to @@ -303,20 +303,20 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo - {crl_check, boolean() | peer | best_effort ) + {crl_check, boolean() | peer | best_effort } Perform CRL (Certificate Revocation List) verification - public_key:pkix_crls_validate/3, during the + (public_key:pkix_crls_validate/3) on all the certificates during the path validation public_key:pkix_path_validation/3 - invokation on all the certificates in the peer certificate chain. Defaults to - false. - + marker="public_key:public_key#pkix_path_validation-3">(public_key:pkix_path_validation/3) + + of the certificate chain. Defaults to false. +

peer - check is only performed on the peer certificate.

-

best_effort - if certificate revokation status can not be determined +

best_effort - if certificate revocation status can not be determined it will be accepted as valid.

The CA certificates specified for the connection will be used to @@ -326,7 +326,7 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo ssl_crl_cache_api(3).

- {crl_cache, {Module::atom, {DbHandle::internal | term(), Args::list()}} + {crl_cache, {Module :: atom(), {DbHandle :: internal | term(), Args :: list()}}}

Module defaults to ssl_crl_cache with DbHandle internal and an empty argument list. The following arguments may be specified for the internal cache.

-- cgit v1.2.3 From 7cf85926c11d38ce5ebd181f9f98185f359d64a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Thu, 26 Feb 2015 18:55:16 +0100 Subject: ssl: Add TLS-ALPN support This commit adds support for RFC7301, application-layer protocol negotiation. ALPN is the standard based approach to the NPN extension, and is required for HTTP/2. ALPN lives side by side with NPN and provides an equivalent feature but in this case it is the server that decides what protocol to use, not the client. When both ALPN and NPN are sent by a client, and the server is configured with both ALPN and NPN options, ALPN will always take precedence. This behavior can also be found in the OpenSSL implementation of ALPN. ALPN and NPN share the ssl:negotiated_protocol/1 function for retrieving the negotiated protocol. The previously existing function ssl:negotiated_next_protocol/1 still exists, but has been deprecated and removed from the documentation. The tests against OpenSSL require OpenSSL version 1.0.2+. --- lib/ssl/doc/src/ssl.xml | 38 +++++++++++++++++++++++++++++++++----- 1 file changed, 33 insertions(+), 5 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index c9b02d44ec..3581a487a2 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -89,6 +89,8 @@ |{dh, der_encoded()} | {dhfile, path()} | {ciphers, ciphers()} | {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, {srp_identity, {string(), string()}} | {ssl_imp, ssl_imp()} | {reuse_sessions, boolean()} | {reuse_session, fun()} + {alpn_advertised_protocols, [binary()]} | + {alpn_preferred_protocols, [binary()]} | {next_protocols_advertised, [binary()]} | {client_preferred_next_protocols, {client | server, [binary()]} | {client | server, [binary()], binary()}} | {log_alert, boolean()} | {server_name_indication, hostname() | disable} @@ -425,7 +427,20 @@ fun(srp, Username :: string(), UserState :: term()) -> certificates are used during server authentication and when building the client certificate chain.
- + + {alpn_advertised_protocols, [binary()]} + +

The list of protocols supported by the client to be sent to the + server to be used for an Application-Layer Protocol Negotiation (ALPN). + If the server supports ALPN then it will choose a protocol from this + list; otherwise it will fail the connection with a "no_application_protocol" + alert. A server that does not support ALPN will ignore this value.

+ +

The list of protocols must not contain an empty binary.

+ +

The negotiated protocol can be retrieved using the negotiated_protocol/1 function.

+
+ {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()]}} {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()], Default :: binary()}} @@ -545,12 +560,25 @@ fun(srp, Username :: string(), UserState :: term()) -> and CipherSuite is of type ciphersuite(). + {alpn_preferred_protocols, [binary()]} + +

Indicates the server will try to perform Application-Layer + Protocol Negotiation (ALPN).

+ +

The list of protocols is in order of preference. The protocol + negotiated will be the first in the list that matches one of the + protocols advertised by the client. If no protocol matches, the + server will fail the connection with a "no_application_protocol" alert.

+ +

The negotiated protocol can be retrieved using the negotiated_protocol/1 function.

+
+ {next_protocols_advertised, Protocols :: [binary()]} The list of protocols to send to the client if the client indicates it supports the Next Protocol extension. The client may select a protocol that is not on this list. The list of protocols must not contain an empty binary. If the server negotiates a Next Protocol it can be accessed - using negotiated_next_protocol/1 method. + using negotiated_protocol/1 function. {psk_identity, string()} @@ -1018,15 +1046,15 @@ fun(srp, Username :: string(), UserState :: term()) -> - negotiated_next_protocol(Socket) -> {ok, Protocol} | {error, next_protocol_not_negotiated} - Returns the Next Protocol negotiated. + negotiated_protocol(Socket) -> {ok, Protocol} | {error, protocol_not_negotiated} + Returns the protocol negotiated through ALPN or NPN extensions. Socket = sslsocket() Protocol = binary()

- Returns the Next Protocol negotiated. + Returns the protocol negotiated through ALPN or NPN extensions.

-- cgit v1.2.3 From 1776467988178ff24376499747fed836b1765e1d Mon Sep 17 00:00:00 2001 From: xsipewe Date: Mon, 16 Mar 2015 14:18:41 +0100 Subject: ssl: Editorial updates --- lib/ssl/doc/src/ssl.xml | 1019 ++++++++++++++++++++++++----------------------- 1 file changed, 529 insertions(+), 490 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 47b0dbc206..1e6981f7e5 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -21,245 +21,282 @@ ssl + + + + ssl.xml
ssl Interface Functions for Secure Socket Layer -

This module contains interface functions to the Secure Socket - Layer. -

+

This module contains interface functions for the SSL.

SSL - ssl requires the crypto and public_key applications. + ssl requires the crypto and public_key + applications. Supported SSL/TLS-versions are SSL-3.0, TLS-1.0, - TLS-1.1 and TLS-1.2. + TLS-1.1, and TLS-1.2. For security reasons SSL-2.0 is not supported. For security reasons SSL-3.0 is no longer supported by default, - but may be configured. - Ephemeral Diffie-Hellman cipher suites are supported + but can be configured. + Ephemeral Diffie-Hellman cipher suites are supported, but not Diffie Hellman Certificates cipher suites. - Elliptic Curve cipher suites are supported if crypto - supports it and named curves are used. + Elliptic Curve cipher suites are supported if the crypto + application supports it and named curves are used. Export cipher suites are not supported as the U.S. lifted its export restrictions in early 2000. IDEA cipher suites are not supported as they have - become deprecated by the latest TLS spec so there is not any - real motivation to implement them. + become deprecated by the latest TLS specification so it is not + motivated to implement them. CRL validation is supported. - Policy certificate extensions are not supported - yet. - Support for 'Server Name Indication' extension client side - (RFC 6066 section 3). + Policy certificate extensions are not supported. + 'Server Name Indication' extension client side + (RFC 6066, Section 3) is supported.
- COMMON DATA TYPES -

The following data types are used in the functions below: -

+ DATA TYPES +

The following data types are used in the functions for ssl:

-

boolean() = true | false

+ -

option() = socketoption() | ssloption() | transportoption()

+ boolean() +

= true | false

-

socketoption() = proplists:property() - The default socket options are - [{mode,list},{packet, 0},{header, 0},{active, true}]. -

+ option() +

= socketoption() | ssloption() | transportoption()

+
-

For valid options - see inet(3) and - gen_tcp(3). -

- -

ssloption() = {verify, verify_type()} | - {verify_fun, {fun(), term()}} | - {fail_if_no_peer_cert, boolean()} - {depth, integer()} | - {cert, der_encoded()}| {certfile, path()} | - {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' |'PrivateKeyInfo', der_encoded()}} | - {keyfile, path()} | {password, string()} | - {cacerts, [der_encoded()]} | {cacertfile, path()} | - |{dh, der_encoded()} | {dhfile, path()} | {ciphers, ciphers()} | - {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, {srp_identity, {string(), string()}} | - {ssl_imp, ssl_imp()} | {reuse_sessions, boolean()} | {reuse_session, fun()} - {alpn_advertised_protocols, [binary()]} | - {alpn_preferred_protocols, [binary()]} | - {next_protocols_advertised, [binary()]} | - {client_preferred_next_protocols, {client | server, [binary()]} | {client | server, [binary()], binary()}} | - {log_alert, boolean()} | {server_name_indication, hostname() | disable} -

- -

transportoption() = {cb_info, {CallbackModule :: atom(), DataTag :: atom(), ClosedTag :: atom(), ErrTag:atom()}} - - defaults to {gen_tcp, tcp, tcp_closed, tcp_error}. Can be used to customize - the transport layer. The callback module must implement a reliable transport - protocol and behave as gen_tcp and in addition have functions corresponding to - inet:setopts/2, inet:getopts/2, inet:peername/1, inet:sockname/1 and inet:port/1. - The callback gen_tcp is treated specially and will call inet directly. -

- -

      CallbackModule = - atom() -

      DataTag = - atom() - tag used in socket data message.

-

      ClosedTag = atom() - tag used in - socket close message.

- -

verify_type() = verify_none | verify_peer

- -

path() = string() - representing a file path.

+ socketoption() +

= proplists:property()

+

The default socket options are + [{mode,list},{packet, 0},{header, 0},{active, true}].

+

For valid options, see the + inet(3) and + gen_tcp(3) manual pages + in kernel.

+ + ssloption() +

= {verify, verify_type()}

+

| {verify_fun, {fun(), term()}}

+

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

+

| {cert, der_encoded()}

+

| {certfile, path()}

+

| {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' + | 'PrivateKeyInfo', der_encoded()}}

+

| {keyfile, path()}

+

| {password, string()}

+

| {cacerts, [der_encoded()]}

+

| {cacertfile, path()}

+

| {dh, der_encoded()}

+

| {dhfile, path()}

+

| {ciphers, ciphers()}

+

| {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, + {srp_identity, {string(), string()}}

+

| {ssl_imp, ssl_imp()}

+

| {reuse_sessions, boolean()}

+

| {reuse_session, fun()} {next_protocols_advertised, [binary()]}

+

| {client_preferred_next_protocols, {client | server, + [binary()]} | {client | server, [binary()], binary()}}

+

| {log_alert, boolean()}

+

| {server_name_indication, hostname() | disable}

+ + transportoption() +

= {cb_info, {CallbackModule::atom(), DataTag::atom(), + ClosedTag::atom(), ErrTag:atom()}}

+

Defaults to {gen_tcp, tcp, tcp_closed, tcp_error}. Can be used + to customize the transport layer. The callback module must implement a + reliable transport protocol, behave as gen_tcp, and have functions + corresponding to inet:setopts/2, inet:getopts/2, + inet:peername/1, inet:sockname/1, and inet:port/1. + The callback gen_tcp is treated specially and calls inet + directly.

+ + CallbackModule +

= atom()

+ DataTag +

= atom()

p> +

Used in socket data message.

+ ClosedTag +

= atom()

+

Used in socket close message.

+
+
-

der_encoded() = binary() -Asn1 DER encoded entity as an erlang binary.

- -

host() = hostname() | ipaddress()

- -

hostname() = string()

- -

- ip_address() = {N1,N2,N3,N4} % IPv4 - | {K1,K2,K3,K4,K5,K6,K7,K8} % IPv6

+ verify_type() +

= verify_none | verify_peer

-

sslsocket() - opaque to the user.

- -

protocol() = sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'

- -

ciphers() = [ciphersuite()] | string() (according to old API)

- -

ciphersuite() = - {key_exchange(), cipher(), hash()}

- -

key_exchange() = rsa | dhe_dss | dhe_rsa | dh_anon - | psk | dhe_psk | rsa_psk | srp_anon | srp_dss | srp_rsa - | ecdh_anon | ecdh_ecdsa | ecdhe_ecdsa | ecdh_rsa | ecdhe_rsa -

+ path() +

= string()

+

Represents a file path.

+ + der_encoded() +

= binary()

+

ASN.1 DER-encoded entity as an Erlang binary.

+ + host() +

= hostname() | ipaddress()

+ + hostname() +

= string()

+ + ip_address() +

= {N1,N2,N3,N4} % IPv4 | {K1,K2,K3,K4,K5,K6,K7,K8} % IPv6 +

-

cipher() = rc4_128 | des_cbc | '3des_ede_cbc' - | aes_128_cbc | aes_256_cbc | aes_128_gcm | aes_256_gcm

+ sslsocket() +

Opaque to the user.

-

hash() = md5 | sha -

+ protocol() +

= sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'

-

prf_random() = client_random | server_random -

+ ciphers() +

= [ciphersuite()] | string()

+

According to old API.

-

srp_param_type() = srp_1024 | srp_1536 | srp_2048 | srp_3072 - | srp_4096 | srp_6144 | srp_8192

+ ciphersuite() +

= {key_exchange(), cipher(), hash()}

+ key_exchange() +

= rsa | dhe_dss | dhe_rsa | dh_anon | psk | dhe_psk + | rsa_psk | srp_anon | srp_dss | srp_rsa | ecdh_anon | ecdh_ecdsa + | ecdhe_ecdsa | ecdh_rsa | ecdhe_rsa

+ + cipher() +

= rc4_128 | des_cbc | '3des_ede_cbc' + | aes_128_cbc | aes_256_cbc | aes_128_gcm | aes_256_gcm

+ + hash() +

= md5 | sha

+ + prf_random() +

= client_random | server_random

+ + srp_param_type() +

= srp_1024 | srp_1536 | srp_2048 | srp_3072 + | srp_4096 | srp_6144 | srp_8192

+ +
SSL OPTION DESCRIPTIONS - COMMON for SERVER and CLIENT -

Options described here are options that are have the same - meaning in the client and the server. -

+

The following options have the same meaning in the client and + the server:

- {cert, der_encoded()} - The DER encoded users certificate. If this option - is supplied it will override the certfile option. + {cert, der_encoded()} +

The DER-encoded users certificate. If this option + is supplied, it overrides option certfile.

- {certfile, path()} - Path to a file containing the user's PEM encoded certificate. + {certfile, path()} +

Path to a file containing the user certificate.

- {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' |'PrivateKeyInfo', der_encoded()}} - The DER encoded users private key. If this option - is supplied it will override the keyfile option. + {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' + |'PrivateKeyInfo', der_encoded()}} +

The DER-encoded user's private key. If this option + is supplied, it overrides option keyfile.

- {keyfile, path()} - Path to file containing user's - private PEM encoded key. As PEM-files may contain several - entries this option defaults to the same file as given by - certfile option. - - {password, string()} - String containing the user's password. - Only used if the private keyfile is password protected. - - - {cacerts, [der_encoded()]} - The DER encoded trusted certificates. If this option - is supplied it will override the cacertfile option. - - {ciphers, ciphers()} - The cipher suites that should be supported. The function + {keyfile, path()} +

Path to the file containing the user's + private PEM-encoded key. As PEM-files can contain several + entries, this option defaults to the same file as given by + option certfile.

+ + {password, string()} +

String containing the user's password. Only used if the + private keyfile is password-protected.

+ + {cacerts, [der_encoded()]} +

The DER-encoded trusted certificates. If this option + is supplied it overrides option cacertfile.

+ + {ciphers, ciphers()} +

Supported cipher suites. The function cipher_suites/0 can be used to find all ciphers that are - supported by default. cipher_suites(all) may be called - to find all available cipher suites. - Pre-Shared Key (RFC 4279 and + supported by default. cipher_suites(all) can be called + to find all available cipher suites. Pre-Shared Key + (RFC 4279 and RFC 5487), - Secure Remote Password (RFC 5054) + Secure Remote Password + (RFC 5054), and anonymous cipher suites only work if explicitly enabled by - this option and they are supported/enabled by the peer also. - Note that anonymous cipher suites are supported for testing purposes - only and should not be used when security matters. + this option; they are supported/enabled by the peer also. + Anonymous cipher suites are supported for testing purposes + only and are not be used when security matters.

+ + {ssl_imp, new | old} +

Has no longer any meaning as the old implementation is + removed; it is ignored.

+ + {secure_renegotiate, boolean()} +

Specifies if to reject renegotiation attempt that does + not live up to + RFC 5746. + By default secure_renegotiate is set to false, + that is, secure renegotiation is used if possible, + but it fallback to unsecure renegotiation if the peer + does not support + RFC 5746.

- {ssl_imp, new | old} - No longer has any meaning as the old implementation has - been removed, it will be ignored. - - - {secure_renegotiate, boolean()} - Specifies if to reject renegotiation attempt that does - not live up to RFC 5746. By default secure_renegotiate is - set to false i.e. secure renegotiation will be used if possible - but it will fallback to unsecure renegotiation if the peer - does not support RFC 5746. - - - {depth, integer()} - - The depth is the maximum number of non-self-issued - intermediate certificates that may follow the peer certificate - in a valid certification path. So if depth is 0 the PEER must - be signed by the trusted ROOT-CA directly, if 1 the path can - be PEER, CA, ROOT-CA, if it is 2 PEER, CA, CA, ROOT-CA and so - on. The default value is 1. - + {depth, integer()} +

Maximum number of non-self-issued + intermediate certificates that can follow the peer certificate + in a valid certification path. So, if depth is 0 the PEER must + be signed by the trusted ROOT-CA directly; if 1 the path can + be PEER, CA, ROOT-CA; if 2 the path can be PEER, CA, CA, + ROOT-CA, and so on. The default value is 1.

- {verify_fun, {Verifyfun :: fun(), InitialUserState :: term()}} - -

The verification fun should be defined as:

+ {verify_fun, {Verifyfun :: fun(), InitialUserState :: + term()}} +

The verification fun is to be defined as follows:

-fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revoked, atom()}} | +fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revoked, +atom()}} | {extension, #'Extension'{}}, InitialUserState :: term()) -> {valid, UserState :: term()} | {valid_peer, UserState :: term()} | {fail, Reason :: term()} | {unknown, UserState :: term()}. -

The verify fun will be called during the X509-path - validation when an error or an extension unknown to the ssl - application is encountered. Additionally it will be called +

The verification fun is called during the X509-path + validation when an error or an extension unknown to the ssl + application is encountered. It is also called when a certificate is considered valid by the path validation to allow access to each certificate in the path to the user - application. Note that it will differentiate between the - peer certificate and CA certificates by using valid_peer or - valid as the second argument to the verify fun. See the public_key User's - Guide for definition of #'OTPCertificate'{} and - #'Extension'{}.

- -

If the verify callback fun returns {fail, Reason}, the - verification process is immediately stopped and an alert is - sent to the peer and the TLS/SSL handshake is terminated. If - the verify callback fun returns {valid, UserState}, the - verification process is continued. If the verify callback fun - always returns {valid, UserState}, the TLS/SSL handshake will - not be terminated with respect to verification failures and - the connection will be established. If called with an - extension unknown to the user application, the return value - {unknown, UserState} should be used.

- -

The default verify_fun option in verify_peer mode:

+ application. It differentiates between the peer + certificate and the CA certificates by using valid_peer or + valid as second argument to the verification fun. See the + public_key User's + Guide for definition of #'OTPCertificate'{} and + #'Extension'{}.

+ + +

If the verify callback fun returns {fail, Reason}, + the verification process is immediately stopped, an alert is + sent to the peer, and the TLS/SSL handshake terminates.

+

If the verify callback fun returns {valid, UserState}, + the verification process continues.

+

If the verify callback fun always returns + {valid, UserState}, the TLS/SSL handshake does not + terminate regarding verification failures and the connection is + established.

+

If called with an extension unknown to the user application, + return value {unknown, UserState} is to be used.

+
+ +

Default option verify_fun in verify_peer mode:

{fun(_,{bad_cert, _} = Reason, _) -> @@ -273,7 +310,7 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo end, []} -

The default verify_fun option in verify_none mode:

+

Default option verify_fun in mode verify_none:

{fun(_,{bad_cert, _}, UserState) -> @@ -287,21 +324,24 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo end, []} -

Possible path validation errors are given on the form {bad_cert, Reason} where Reason is:

+

The possible path validation errors are given on form + {bad_cert, Reason} where Reason is:

- unknown_ca - No trusted CA was found in the trusted store. The trusted CA is - normally a so called ROOT CA that is a self-signed cert. Trust may - be claimed for an intermediat CA (trusted anchor does not have to be self signed - according to X-509) by using the option partial_chain - - selfsigned_peer - The chain consisted only of one self-signed certificate. - - PKIX X-509-path validation error - Possible such reasons see public_key:pkix_path_validation/3 + unknown_ca +

No trusted CA was found in the trusted store. The trusted CA is + normally a so called ROOT CA, which is a self-signed certificate. Trust can + be claimed for an intermediat CA (trusted anchor does not have to be + self-signed according to X-509) by using option partial_chain.

+
+ + selfsigned_peer +

The chain consisted only of one self-signed certificate.

+ + PKIX X-509-path validation error +

For possible reasons, see public_key:pkix_path_validation/3 +

@@ -341,32 +381,30 @@ fun(OtpCert :: #'OTPCertificate'{}, Event :: {bad_cert, Reason :: atom() | {revo
- - {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca - - - Claim an intermediat CA in the chain as trusted. TLS will then perform the public_key:pkix_path_validation/3 - with the selected CA as trusted anchor and the rest of the chain. - - {versions, [protocol()]} - TLS protocol versions that will be supported by started clients and servers. - This option overrides the application environment option protocol_version. If the - environment option is not set it defaults to all versions, except SSL-3.0, supported by the SSL application. See also - ssl(6) - + {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | + unknown_ca } +

Claim an intermediate CA in the chain as trusted. TLS then + performs public_key:pkix_path_validation/3 + with the selected CA as trusted anchor and the rest of the chain.

+ + {versions, [protocol()]} +

TLS protocol versions supported by started clients and servers. + This option overrides the application environment option + protocol_version. If the environment option is not set, it defaults + to all versions, except SSL-3.0, supported by the ssl application. + See also ssl(6).

+ + {hibernate_after, integer()|undefined} +

When an integer-value is specified, ssl_connection + goes into hibernation after the specified number of milliseconds + of inactivity, thus reducing its memory footprint. When + undefined is specified (this is the default), the process + never goes into hibernation.

+ + {user_lookup_fun, {Lookupfun :: fun(), UserState :: term()}} +

The lookup fun is to defined as follows:

- {hibernate_after, integer()|undefined} - When an integer-value is specified, the ssl_connection - will go into hibernation after the specified number of milliseconds - of inactivity, thus reducing its memory footprint. When - undefined is specified (this is the default), the process - will never go into hibernation. - - - {user_lookup_fun, {Lookupfun :: fun(), UserState :: term()}} - -

The lookup fun should be defined as:

fun(psk, PSKIdentity ::string(), UserState :: term()) -> {ok, SharedSecret :: binary()} | error; @@ -374,59 +412,55 @@ fun(srp, Username :: string(), UserState :: term()) -> {ok, {SRPParams :: srp_param_type(), Salt :: binary(), DerivedKey :: binary()}} | error. -

For Pre-Shared Key (PSK) cipher suites, the lookup fun will - be called by the client and server to determine the shared - secret. When called by the client, PSKIdentity will be set to the - hint presented by the server or undefined. When called by the - server, PSKIdentity is the identity presented by the client. -

- -

For Secure Remote Password (SRP), the fun will only be used by the server to obtain - parameters that it will use to generate its session keys. DerivedKey should be - derived according to RFC 2945 and - RFC 5054: - crypto:sha([Salt, crypto:sha([Username, <<$:>>, Password])]) +

For Pre-Shared Key (PSK) cipher suites, the lookup fun is + called by the client and server to determine the shared + secret. When called by the client, PSKIdentity is set to the + hint presented by the server or to undefined. When called by the + server, PSKIdentity is the identity presented by the client.

+ +

For Secure Remote Password (SRP), the fun is only used by the server to + obtain parameters that it uses to generate its session keys. + DerivedKey is to be derived according to + RFC 2945 and + RFC 5054: + crypto:sha([Salt, crypto:sha([Username, <<$:>>, Password])])

- {padding_check, boolean()} - -

This option only affects TLS-1.0 connections. - If set to false it disables the block cipher padding check - to be able to interoperate with legacy software. -

- -

Using this option makes TLS vulnerable to - the Poodle attack

- -
- + {padding_check, boolean()} +

Affects TLS-1.0 connections only. + If set to false, it disables the block cipher padding check + to be able to interoperate with legacy software.

+ - + +

Using {padding_check, boolean()} makes TLS + vulnerable to the Poodle attack.

+
SSL OPTION DESCRIPTIONS - CLIENT SIDE -

Options described here are client specific or has a slightly different - meaning in the client than in the server.

+

The following options are client-specific or have a slightly different + meaning in the client than in the server:

- {verify, verify_type()} - In verify_none mode the default behavior will be to - allow all x509-path validation errors. See also the verify_fun - option. - - {reuse_sessions, boolean()} - Specifies if client should try to reuse sessions - when possible. + + {verify, verify_type()} +

In mode verify_none the default behavior is to allow + all x509-path validation errors. See also option verify_fun.

+ + {reuse_sessions, boolean()} +

Specifies if the client is to try to reuse sessions + when possible.

- {cacertfile, path()} - The path to a file containing PEM encoded CA certificates. The CA + {cacertfile, path()} +

Path to a file containing PEM-encoded CA certificates. The CA certificates are used during server authentication and when building the - client certificate chain. - + client certificate chain.

+
{alpn_advertised_protocols, [binary()]} @@ -444,39 +478,44 @@ fun(srp, Username :: string(), UserState :: term()) -> {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()]}} {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()], Default :: binary()}} -

Indicates the client will try to perform Next Protocol +

Indicates that the client is to try to perform Next Protocol Negotiation.

-

If precedence is server the negotiated protocol will be the - first protocol that appears on the server advertised list that is +

If precedence is server, the negotiated protocol is the + first protocol to be shown on the server advertised list, which is also on the client preference list.

-

If precedence is client the negotiated protocol will be the - first protocol that appears on the client preference list that is +

If precedence is client, the negotiated protocol is the + first protocol to be shown on the client preference list, which is also on the server advertised list.

If the client does not support any of the server advertised - protocols or the server does not advertise any protocols the - client will fallback to the first protocol in its list or if a - default is supplied it will fallback to that instead. If the - server does not support Next Protocol Negotiation the - connection will be aborted if no default protocol is supplied.

+ protocols or the server does not advertise any protocols, the + client falls back to the first protocol in its list or to the + default protocol (if a default is supplied). If the + server does not support Next Protocol Negotiation, the + connection terminates if no default protocol is supplied.

- {psk_identity, string()} - Specifies the identity the client presents to the server. The matching secret is - found by calling the user_look_fun. - - {srp_identity, {Username :: string(), Password :: string()} - Specifies the Username and Password to use to authenticate to the server. + {psk_identity, string()} +

Specifies the identity the client presents to the server. + The matching secret is found by calling user_look_fun.

- {server_name_indication, hostname()} - {server_name_indication, disable} + + {srp_identity, {Username :: string(), Password :: string()} + +

Specifies the username and password to use to authenticate + to the server.

+ + {server_name_indication, hostname()} + + {server_name_indication, disable} -

This option can be specified when upgrading a TCP socket to a TLS +

Can be specified when upgrading a TCP socket to a TLS socket to use the TLS Server Name Indication extension.

-

When starting a TLS connection without upgrade the Server Name - Indication extension will be sent if possible, this option may also be + +

When starting a TLS connection without upgrade, the Server Name + Indication extension is sent if possible. This option can also be used to disable that behavior.

{fallback, boolean()} @@ -502,63 +541,58 @@ fun(srp, Username :: string(), UserState :: term()) ->
SSL OPTION DESCRIPTIONS - SERVER SIDE -

Options described here are server specific or has a slightly different - meaning in the server than in the client.

+

The following options are server-specific or have a slightly different + meaning in the server than in the client:

- {cacertfile, path()} - The path to a file containing PEM encoded CA + {cacertfile, path()} +

Path to a file containing PEM-encoded CA certificates. The CA certificates are used to build the server - certificate chain, and for client authentication. Also the CAs - are used in the list of acceptable client CAs passed to the - client when a certificate is requested. May be omitted if there - is no need to verify the client and if there are not any - intermediate CAs for the server certificate. - + certificate chain and for client authentication. The CAs are + also used in the list of acceptable client CAs passed to the + client when a certificate is requested. Can be omitted if there + is no need to verify the client and if there are no + intermediate CAs for the server certificate.

- {dh, der_encoded()} - The DER encoded Diffie Hellman parameters. If this option - is supplied it will override the dhfile option. - - - {dhfile, path()} - Path to file containing PEM encoded Diffie Hellman parameters, - for the server to use if a cipher suite using Diffie Hellman key exchange - is negotiated. If not specified default parameters will be used. - - - {verify, verify_type()} - Servers only do the x509-path validation in verify_peer - mode, as it then will send a certificate request to the client - (this message is not sent if the verify option is verify_none) - and you may then also want to specify the option - fail_if_no_peer_cert. + {dh, der_encoded()} +

The DER-encoded Diffie-Hellman parameters. If specified, + it overrides option dhfile.

+ + {dhfile, path()} +

Path to a file containing PEM-encoded Diffie Hellman parameters + to be used by the server if a cipher suite using Diffie Hellman key + exchange is negotiated. If not specified, default parameters are used. +

+ + {verify, verify_type()} +

A server only does x509-path validation in mode verify_peer, + as it then sends a certificate request to the client + (this message is not sent if the verify option is verify_none). + You can then also want to specify option fail_if_no_peer_cert. +

+ + {fail_if_no_peer_cert, boolean()} +

Used together with {verify, verify_peer} by an SSL server. + If set to true, the server fails if the client does not have + a certificate to send, that is, sends an empty certificate. If set to + false, it fails only if the client sends an invalid + certificate (an empty certificate is considered valid).

- {fail_if_no_peer_cert, boolean()} - Used together with {verify, verify_peer} by an ssl server. - If set to true, the server will fail if the client does not have - a certificate to send, i.e. sends a empty certificate, if set to - false it will only fail if the client sends an invalid - certificate (an empty certificate is considered valid). - + {reuse_sessions, boolean()} +

Specifies if the server is to agree to reuse sessions + when requested by the clients. See also option reuse_session. +

- {reuse_sessions, boolean()} - Specifies if the server should agree to reuse sessions - when the clients request to do so. See also the reuse_session - option. - - - {reuse_session, fun(SuggestedSessionId, - PeerCert, Compression, CipherSuite) -> boolean()} - Enables the ssl server to have a local policy - for deciding if a session should be reused or not, - only meaningful if reuse_sessions is set to true. - SuggestedSessionId is a binary(), PeerCert is a DER encoded - certificate, Compression is an enumeration integer - and CipherSuite is of type ciphersuite(). - + {reuse_session, fun(SuggestedSessionId, + PeerCert, Compression, CipherSuite) -> boolean()} +

Enables the SSL server to have a local policy + for deciding if a session is to be reused or not. + Meaningful only if reuse_sessions is set to true. + SuggestedSessionId is a binary(), PeerCert is + a DER-encoded certificate, Compression is an enumeration integer, + and CipherSuite is of type ciphersuite().

{alpn_preferred_protocols, [binary()]} @@ -573,65 +607,62 @@ fun(srp, Username :: string(), UserState :: term()) ->

The negotiated protocol can be retrieved using the negotiated_protocol/1 function.

- {next_protocols_advertised, Protocols :: [binary()]} - The list of protocols to send to the client if the client indicates - it supports the Next Protocol extension. The client may select a protocol + {next_protocols_advertised, Protocols :: [binary()]} +

List of protocols to send to the client if the client indicates that + it supports the Next Protocol extension. The client can select a protocol that is not on this list. The list of protocols must not contain an empty - binary. If the server negotiates a Next Protocol it can be accessed - using negotiated_protocol/1 function. - + binary. If the server negotiates a Next Protocol, it can be accessed + using the negotiated_next_protocol/1 method.

- {psk_identity, string()} - Specifies the server identity hint the server presents to the client. - - {log_alert, boolean()} - If false, error reports will not be displayed. - {honor_cipher_order, boolean()} - If true, use the server's preference for cipher selection. If false - (the default), use the client's preference. - + {psk_identity, string()} +

Specifies the server identity hint, which the server presents to + the client.

+ + {log_alert, boolean()} +

If set to false, error reports are not displayed.

+ + {honor_cipher_order, boolean()} +

If set to true, use the server preference for cipher + selection. If set to false (the default), use the client + preference.

+ +
General -

When an ssl socket is in active mode (the default), data from the +

When an SSL socket is in active mode (the default), data from the socket is delivered to the owner of the socket in the form of - messages: -

+ messages:

+ - {ssl, Socket, Data} - - {ssl_closed, Socket} - - - {ssl_error, Socket, Reason} - +

{ssl, Socket, Data}

+

{ssl_closed, Socket}

+

{ssl_error, Socket, Reason}

- -

A Timeout argument specifies a timeout in milliseconds. The - default value for a Timeout argument is infinity. -

+ +

A Timeout argument specifies a time-out in milliseconds. The + default value for argument Timeout is infinity.

cipher_suites() -> cipher_suites(Type) -> ciphers() - Returns a list of supported cipher suites + Returns a list of supported cipher suites. Type = erlang | openssl | all -

Returns a list of supported cipher suites. - cipher_suites() is equivalent to cipher_suites(erlang). - Type openssl is provided for backwards compatibility with - old ssl that used openssl. cipher_suites(all) returns + cipher_suites() is equivalent to cipher_suites(erlang). + Type openssl is provided for backwards compatibility with the + old SSL, which used OpenSSL. cipher_suites(all) returns all available cipher suites. The cipher suites not present - in cipher_suites(erlang) but in included in cipher_suites(all) - will not be used unless explicitly configured by the user. -

+ in cipher_suites(erlang) but included in + cipher_suites(all) are not used unless explicitly configured + by the user.

@@ -651,17 +682,17 @@ fun(srp, Username :: string(), UserState :: term()) -> connect(Socket, SslOptions) -> connect(Socket, SslOptions, Timeout) -> {ok, SslSocket} | {error, Reason} - Upgrades a gen_tcp, or - equivalent, connected socket to an ssl socket. + Upgrades a gen_tcp, or + equivalent, connected socket to an SSL socket. - Socket = socket() - SslOptions = [ssloption()] + Socket = socket() + SslOptions = [ssloption()] Timeout = integer() | infinity SslSocket = sslsocket() Reason = term() -

Upgrades a gen_tcp, or equivalent, - connected socket to an ssl socket i.e. performs the +

Upgrades a gen_tcp, or equivalent, + connected socket to an SSL socket, that is, performs the client-side ssl handshake.

@@ -670,7 +701,7 @@ fun(srp, Username :: string(), UserState :: term()) -> connect(Host, Port, Options) -> connect(Host, Port, Options, Timeout) -> {ok, SslSocket} | {error, Reason} - Opens an ssl connection to Host, Port. + Opens an SSL connection to Host, Port. Host = host() Port = integer() @@ -679,72 +710,70 @@ fun(srp, Username :: string(), UserState :: term()) -> SslSocket = sslsocket() Reason = term() -

Opens an ssl connection to Host, Port.

+

Opens an SSL connection to Host, Port.

close(SslSocket) -> ok | {error, Reason} - Close an ssl connection + Closes an SSL connection. SslSocket = sslsocket() Reason = term() -

Close an ssl connection.

+

Closes an SSL connection.

+
+
+ + + connection_info(SslSocket) -> + {ok, {ProtocolVersion, CipherSuite}} | {error, Reason} + Returns the Negotiated Protocol version and cipher suite. + + + CipherSuite = ciphersuite() + ProtocolVersion = protocol() + +

Returns the Negotiated Protocol version and cipher suite.

controlling_process(SslSocket, NewOwner) -> ok | {error, Reason} - Assigns a new controlling process to the - ssl-socket. - + SSL socket. SslSocket = sslsocket() NewOwner = pid() Reason = term() -

Assigns a new controlling process to the ssl-socket. A - controlling process is the owner of an ssl-socket, and receives - all messages from the socket.

+

Assigns a new controlling process to the SSL socket. A + controlling process is the owner of an SSL socket, and receives + all messages from the socket.

- connection_info(SslSocket) -> - {ok, {ProtocolVersion, CipherSuite}} | {error, Reason} - Returns the negotiated protocol version and cipher suite. - - - CipherSuite = ciphersuite() - ProtocolVersion = protocol() - -

Returns the negotiated protocol version and cipher suite.

-
-
- - format_error(Reason) -> string() - Return an error string. + Returns an error string. Reason = term() -

Presents the error returned by an ssl function as a printable string.

+

Presents the error returned by an SSL function as a printable string.

getopts(Socket, OptionNames) -> {ok, [socketoption()]} | {error, Reason} - Get the value of the specified options. + Gets the values of the specified options. Socket = sslsocket() OptionNames = [atom()] -

Get the value of the specified socket options. +

Gets the values of the specified socket options.

@@ -752,34 +781,47 @@ fun(srp, Username :: string(), UserState :: term()) -> listen(Port, Options) -> {ok, ListenSocket} | {error, Reason} - Creates an ssl listen socket. + Creates an SSL listen socket. Port = integer() Options = options() ListenSocket = sslsocket() -

Creates an ssl listen socket.

+

Creates an SSL listen socket.

+
+
+ + + negotiated_next_protocol(Socket) -> {ok, Protocol} | {error, next_protocol_not_negotiated} + Returns the Next Protocol negotiated. + + Socket = sslsocket() + Protocol = binary() + + +

Returns the Next Protocol negotiated.

peercert(Socket) -> {ok, Cert} | {error, Reason} - Return the peer certificate. + Returns the peer certificate. Socket = sslsocket() Cert = binary() -

The peer certificate is returned as a DER encoded binary. - The certificate can be decoded with public_key:pkix_decode_cert/2. -

+

The peer certificate is returned as a DER-encoded binary. + The certificate can be decoded with + public_key:pkix_decode_cert/2.

+ peername(Socket) -> {ok, {Address, Port}} | {error, Reason} - Return peer address and port. + Returns the peer address and port. Socket = sslsocket() Address = ipaddress() @@ -789,12 +831,32 @@ fun(srp, Username :: string(), UserState :: term()) ->

Returns the address and port number of the peer.

+ + + prf(Socket, Secret, Label, Seed, WantedLength) -> {ok, binary()} | {error, reason()} + Uses a session Pseudo-Random Function to generate key material. + + Socket = sslsocket() + Secret = binary() | master_secret + Label = binary() + Seed = [binary() | prf_random()] + WantedLength = non_neg_integer() + + +

Uses the Pseudo-Random Function (PRF) of a TLS session to generate + extra key material. It either takes user-generated values for + Secret and Seed or atoms directing it to use a specific + value from the session security parameters.

+

Can only be used with TLS connections; {error, undefined} + is returned for SSLv3 connections.

+
+
recv(Socket, Length) -> recv(Socket, Length, Timeout) -> {ok, Data} | {error, Reason} - Receive data on a socket. + Receives data on a socket. Socket = sslsocket() Length = integer() @@ -802,63 +864,43 @@ fun(srp, Username :: string(), UserState :: term()) -> Data = [char()] | binary() -

This function receives a packet from a socket in passive - mode. A closed socket is indicated by a return value +

Receives a packet from a socket in passive + mode. A closed socket is indicated by return value {error, closed}.

-

The Length argument is only meaningful when - the socket is in raw mode and denotes the number of +

Argument Length is meaningful only when + the socket is in mode raw and denotes the number of bytes to read. If Length = 0, all available bytes are returned. If Length > 0, exactly Length bytes are returned, or an error; possibly discarding less than Length bytes of data when the socket gets closed from the other side.

-

The optional Timeout parameter specifies a timeout in +

Optional argument Timeout specifies a time-out in milliseconds. The default value is infinity.

- - prf(Socket, Secret, Label, Seed, WantedLength) -> {ok, binary()} | {error, reason()} - Use a sessions pseudo random function to generate key material. - - Socket = sslsocket() - Secret = binary() | master_secret - Label = binary() - Seed = [binary() | prf_random()] - WantedLength = non_neg_integer() - - -

Use the pseudo random function (PRF) of a TLS session to generate - additional key material. It either takes user generated values for - Secret and Seed or atoms directing it use a specific - value from the session security parameters.

-

This function can only be used with TLS connections, {error, undefined} - is returned for SSLv3 connections.

-
-
- renegotiate(Socket) -> ok | {error, Reason} - Initiates a new handshake. + Initiates a new handshake. Socket = sslsocket()

Initiates a new handshake. A notable return value is {error, renegotiation_rejected} indicating that the peer - refused to go through with the renegotiation but the connection + refused to go through with the renegotiation, but the connection is still active using the previously negotiated session.

send(Socket, Data) -> ok | {error, Reason} - Write data to a socket. + Writes data to a socket. Socket = sslsocket() Data = iodata() -

Writes Data to Socket.

+

Writes Data to Socket.

A notable return value is {error, closed} indicating that the socket is closed.

@@ -866,31 +908,31 @@ fun(srp, Username :: string(), UserState :: term()) -> setopts(Socket, Options) -> ok | {error, Reason} - Set socket options. + Sets socket options. Socket = sslsocket() Options = [socketoption]() -

Sets options according to Options for the socket - Socket.

+

Sets options according to Options for socket + Socket.

shutdown(Socket, How) -> ok | {error, Reason} - Immediately close a socket + Immediately closes a socket. Socket = sslsocket() How = read | write | read_write Reason = reason() -

Immediately close a socket in one or two directions.

+

Immediately closes a socket in one or two directions.

How == write means closing the socket for writing, reading from it is still possible.

To be able to handle that the peer has done a shutdown on - the write side, the {exit_on_close, false} option + the write side, option {exit_on_close, false} is useful.

@@ -898,16 +940,16 @@ fun(srp, Username :: string(), UserState :: term()) -> ssl_accept(Socket) -> ssl_accept(Socket, Timeout) -> ok | {error, Reason} - Perform server-side SSL/TLS handshake + Performs server-side SSL/TLS handshake. Socket = sslsocket() Timeout = integer() Reason = term() -

Performs the SSL/TLS server-side handshake Socket is a socket as returned - by ssl:transport_accept/[1,2] +

Performs the SSL/TLS server-side handshake.

+

Socket is a socket as returned by + ssl:transport_accept/[1,2]

@@ -915,7 +957,7 @@ fun(srp, Username :: string(), UserState :: term()) -> ssl_accept(Socket, SslOptions) -> ssl_accept(Socket, SslOptions, Timeout) -> {ok, Socket} | ok | {error, Reason} - Perform server-side SSL/TLS handshake + Performs server-side SSL/TLS handshake. Socket = socket() | sslsocket() SslOptions = ssloptions() @@ -923,17 +965,19 @@ fun(srp, Username :: string(), UserState :: term()) -> Reason = term() -

If Socket is a socket() - upgrades a gen_tcp, or equivalent, socket to an ssl socket - i.e. performs the SSL/TLS server-side handshake and returns the ssl socket. -

+

If Socket is a socket(): upgrades a gen_tcp, + or equivalent, socket to an SSL socket, that is, performs + the SSL/TLS server-side handshake and returns the SSL socket.

-

Note that the listen socket should be in {active, false} mode +

The listen socket is to be in mode {active, false} before telling the client that the server is ready to upgrade - by calling this function, otherwise the upgrade may - or may not succeed depending on timing.

+ by calling this function, else the upgrade succeeds or does not + succeed depending on timing.

-

If Socket is an sslsocket() - provides additional SSL/TLS options to those specified in ssl:listen/2 and then performs the SSL/TLS handshake. +

If Socket is an sslsocket(): provides extra SSL/TLS + options to those specified in + ssl:listen/2 and then performs + the SSL/TLS handshake.

@@ -941,14 +985,14 @@ fun(srp, Username :: string(), UserState :: term()) -> sockname(Socket) -> {ok, {Address, Port}} | {error, Reason} - Return the local address and port. + Returns the local address and port. Socket = sslsocket() Address = ipaddress() Port = integer() -

Returns the local address and port number of the socket +

Returns the local address and port number of socket Socket.

@@ -956,22 +1000,21 @@ fun(srp, Username :: string(), UserState :: term()) -> start() -> start(Type) -> ok | {error, Reason} - Starts the Ssl application. + Starts the sslapplication. - Type = permanent | transient | temporary + Type = permanent | transient | temporary -

Starts the Ssl application. Default type - is temporary. - application(3)

+

Starts the ssl application. Default type + is temporary.

+ stop() -> ok - Stops the Ssl application. + Stops the ssl application. -

Stops the Ssl application. - application(3)

+

Stops the ssl application.

@@ -979,8 +1022,8 @@ fun(srp, Username :: string(), UserState :: term()) -> transport_accept(ListenSocket) -> transport_accept(ListenSocket, Timeout) -> {ok, NewSocket} | {error, Reason} - Accept an incoming connection and - prepare for ssl_accept + Accepts an incoming connection and + prepares for ssl_accept. ListenSocket = NewSocket = sslsocket() Timeout = integer() @@ -989,23 +1032,22 @@ fun(srp, Username :: string(), UserState :: term()) ->

Accepts an incoming connection request on a listen socket. ListenSocket must be a socket returned from - ssl:listen/2. - The socket returned should be passed to + ssl:listen/2. + The socket returned is to be passed to ssl:ssl_accept[2,3] - to complete handshaking i.e + to complete handshaking, that is, establishing the SSL/TLS connection.

The socket returned can only be used with - ssl:ssl_accept[2,3] - no traffic can be sent or received before that call.

+ ssl:ssl_accept[2,3]. + No traffic can be sent or received before that call.

The accepted socket inherits the options set for - ListenSocket in ssl:listen/2.

+ ListenSocket in + ssl:listen/2.

The default value for Timeout is infinity. If - Timeout is specified, and no connection is accepted + Timeout is specified and no connection is accepted within the given time, {error, timeout} is returned.

@@ -1014,34 +1056,31 @@ fun(srp, Username :: string(), UserState :: term()) -> versions() -> [versions_info()] Returns version information relevant for the - ssl application. + ssl application. versions_info() = {app_vsn, string()} | {supported | available, [protocol()] -

- Returns version information relevant for the - ssl application. -

+

Returns version information relevant for the ssl + application.

app_vsn - The application version of the OTP ssl application. + The application version of the ssl application. supported - TLS/SSL versions supported by default. - Overridden by a versions option on - connect/[2,3,4], listen/2 and ssl_accept/[1,2,3]. For the - negotiated TLS/SSL version see connect/[2,3,4], + listen/2, and ssl_accept/[1,2,3]. + For the negotiated TLS/SSL version, see ssl:connection_info/1 - - + .
+ available - All TLS/SSL versions that the Erlang ssl application - can support. Note that TLS 1.2 requires sufficient support - from the crypto application. + All TLS/SSL versions supported by the ssl application. + TLS 1.2 requires sufficient support from the crypto + application.
@@ -1063,8 +1102,8 @@ fun(srp, Username :: string(), UserState :: term()) ->
SEE ALSO -

inet(3) and - gen_tcp(3) +

inet(3) and + gen_tcp(3)

-- cgit v1.2.3 From 7461639d24f5d28e2b43ec10e1aa2376b4ba8936 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 2 Apr 2015 16:48:50 +0200 Subject: ssl: Correct typos --- lib/ssl/doc/src/ssl.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 1e6981f7e5..b8f7501915 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -123,7 +123,7 @@ CallbackModule

= atom()

DataTag -

= atom()

p> +

= atom()

Used in socket data message.

ClosedTag

= atom()

-- cgit v1.2.3 From e6ec11f2c79c1dd51da9750aac6730184a06668b Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 7 Apr 2015 15:51:56 +0200 Subject: ssl: Correct merge error --- lib/ssl/doc/src/ssl.xml | 25 +++++++------------------ 1 file changed, 7 insertions(+), 18 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index b8f7501915..eb31b35e1e 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -793,17 +793,19 @@ fun(srp, Username :: string(), UserState :: term()) -> - negotiated_next_protocol(Socket) -> {ok, Protocol} | {error, next_protocol_not_negotiated} - Returns the Next Protocol negotiated. + negotiated_protocol(Socket) -> {ok, Protocol} | {error, protocol_not_negotiated} + Returns the protocol negotiated through ALPN or NPN extensions. Socket = sslsocket() Protocol = binary() -

Returns the Next Protocol negotiated.

+

+ Returns the protocol negotiated through ALPN or NPN extensions. +

- + peercert(Socket) -> {ok, Cert} | {error, Reason} Returns the peer certificate. @@ -1084,20 +1086,7 @@ fun(srp, Username :: string(), UserState :: term()) -> - - negotiated_protocol(Socket) -> {ok, Protocol} | {error, protocol_not_negotiated} - Returns the protocol negotiated through ALPN or NPN extensions. - - Socket = sslsocket() - Protocol = binary() - - -

- Returns the protocol negotiated through ALPN or NPN extensions. -

-
-
- +
-- cgit v1.2.3 From 7090827c70d21826c66fed092247e3773c318150 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 7 Apr 2015 16:05:41 +0200 Subject: ssl: Align with editorial changes --- lib/ssl/doc/src/ssl.xml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index eb31b35e1e..f357e90526 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -345,7 +345,7 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid - {crl_check, boolean() | peer | best_effort } + {crl_check, boolean() | peer | best_effort } Perform CRL (Certificate Revocation List) verification @@ -368,12 +368,12 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid ssl_crl_cache_api(3).

- {crl_cache, {Module :: atom(), {DbHandle :: internal | term(), Args :: list()}}} + {crl_cache, {Module :: atom(), {DbHandle :: internal | term(), Args :: list()}}}

Module defaults to ssl_crl_cache with DbHandle internal and an empty argument list. The following arguments may be specified for the internal cache.

- {http, timeout()} + {http, timeout()} Enables fetching of CRLs specified as http URIs in X509 cerificate extensions. @@ -462,7 +462,7 @@ fun(srp, Username :: string(), UserState :: term()) -> client certificate chain.

- {alpn_advertised_protocols, [binary()]} + {{alpn_advertised_protocols, [binary()]}

The list of protocols supported by the client to be sent to the server to be used for an Application-Layer Protocol Negotiation (ALPN). @@ -475,8 +475,8 @@ fun(srp, Username :: string(), UserState :: term()) ->

The negotiated protocol can be retrieved using the negotiated_protocol/1 function.

- {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()]}} - {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()], Default :: binary()}} + {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()]}} + {client_preferred_next_protocols, {Precedence :: server | client, ClientPrefs :: [binary()], Default :: binary()}}

Indicates that the client is to try to perform Next Protocol Negotiation.

@@ -518,7 +518,7 @@ fun(srp, Username :: string(), UserState :: term()) -> Indication extension is sent if possible. This option can also be used to disable that behavior.

- {fallback, boolean()} + {fallback, boolean()}

Send special cipher suite TLS_FALLBACK_SCSV to avoid undesired TLS version downgrade. Defaults to false

@@ -594,7 +594,7 @@ fun(srp, Username :: string(), UserState :: term()) -> a DER-encoded certificate, Compression is an enumeration integer, and CipherSuite is of type ciphersuite().

- {alpn_preferred_protocols, [binary()]} + {alpn_preferred_protocols, [binary()]}

Indicates the server will try to perform Application-Layer Protocol Negotiation (ALPN).

@@ -1066,10 +1066,10 @@ fun(srp, Username :: string(), UserState :: term()) ->

Returns version information relevant for the ssl application.

- app_vsn + app_vsn The application version of the ssl application. - supported + supported TLS/SSL versions supported by default. Overridden by a version option on connect/[2,3,4], @@ -1079,7 +1079,7 @@ fun(srp, Username :: string(), UserState :: term()) -> marker="#connection_info-1">ssl:connection_info/1 . - available + available All TLS/SSL versions supported by the ssl application. TLS 1.2 requires sufficient support from the crypto application. -- cgit v1.2.3 From 76943d42da43395f6d3f2dfb7f52e2552a47be26 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Tue, 7 Apr 2015 22:06:39 +0200 Subject: ssl: Document enhancements --- lib/ssl/doc/src/ssl.xml | 56 ++++++++++++++++++++++++------------------------- 1 file changed, 27 insertions(+), 29 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index f357e90526..d070cb4019 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -88,20 +88,19 @@

= {verify, verify_type()}

| {verify_fun, {fun(), term()}}

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

-

| {cert, der_encoded()}

+

| {cert, public_key:der_encoded()}

| {certfile, path()}

| {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' - | 'PrivateKeyInfo', der_encoded()}}

+ | 'PrivateKeyInfo', public_key:der_encoded()}}

| {keyfile, path()}

| {password, string()}

-

| {cacerts, [der_encoded()]}

+

| {cacerts, [public_key:der_encoded()]}

| {cacertfile, path()}

-

| {dh, der_encoded()}

+

| {dh, public_key:der_encoded()}

| {dhfile, path()}

| {ciphers, ciphers()}

| {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, {srp_identity, {string(), string()}}

-

| {ssl_imp, ssl_imp()}

| {reuse_sessions, boolean()}

| {reuse_session, fun()} {next_protocols_advertised, [binary()]}

| {client_preferred_next_protocols, {client | server, @@ -138,7 +137,7 @@

= string()

Represents a file path.

- der_encoded() + public_key:der_encoded()

= binary()

ASN.1 DER-encoded entity as an Erlang binary.

@@ -195,7 +194,7 @@ - {cert, der_encoded()} + {cert, public_key:der_encoded()}

The DER-encoded users certificate. If this option is supplied, it overrides option certfile.

@@ -203,7 +202,7 @@

Path to a file containing the user certificate.

{key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' - |'PrivateKeyInfo', der_encoded()}} + |'PrivateKeyInfo', public_key:der_encoded()}}

The DER-encoded user's private key. If this option is supplied, it overrides option keyfile.

@@ -217,10 +216,6 @@

String containing the user's password. Only used if the private keyfile is password-protected.

- {cacerts, [der_encoded()]} -

The DER-encoded trusted certificates. If this option - is supplied it overrides option cacertfile.

- {ciphers, ciphers()}

Supported cipher suites. The function cipher_suites/0 can be used to find all ciphers that are @@ -229,16 +224,12 @@ (RFC 4279 and RFC 5487), Secure Remote Password - (RFC 5054), + (RFC 5054), RC4 cipher suites, and anonymous cipher suites only work if explicitly enabled by this option; they are supported/enabled by the peer also. Anonymous cipher suites are supported for testing purposes only and are not be used when security matters.

- {ssl_imp, new | old} -

Has no longer any meaning as the old implementation is - removed; it is ignored.

- {secure_renegotiate, boolean()}

Specifies if to reject renegotiation attempt that does not live up to @@ -364,7 +355,7 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid

The CA certificates specified for the connection will be used to construct the certificate chain validating the CRLs.

-

The CRLs will be fetched from a local or external cache +

The CRLs will be fetched from a local or external cache see ssl_crl_cache_api(3).

@@ -455,6 +446,10 @@ fun(srp, Username :: string(), UserState :: term()) -> {reuse_sessions, boolean()}

Specifies if the client is to try to reuse sessions when possible.

+ + {cacerts, [public_key:der_encoded()]} +

The DER-encoded trusted certificates. If this option + is supplied it overrides option cacertfile.

{cacertfile, path()}

Path to a file containing PEM-encoded CA certificates. The CA @@ -462,7 +457,7 @@ fun(srp, Username :: string(), UserState :: term()) -> client certificate chain.

- {{alpn_advertised_protocols, [binary()]} + {alpn_advertised_protocols, [binary()]}

The list of protocols supported by the client to be sent to the server to be used for an Application-Layer Protocol Negotiation (ALPN). @@ -499,7 +494,7 @@ fun(srp, Username :: string(), UserState :: term()) -> {psk_identity, string()}

Specifies the identity the client presents to the server. - The matching secret is found by calling user_look_fun.

+ The matching secret is found by calling user_lookup_fun.

{srp_identity, {Username :: string(), Password :: string()} @@ -508,14 +503,13 @@ fun(srp, Username :: string(), UserState :: term()) -> to the server.

{server_name_indication, hostname()} - - {server_name_indication, disable} - -

Can be specified when upgrading a TCP socket to a TLS - socket to use the TLS Server Name Indication extension.

+

Can be specified when upgrading a TCP socket to a TLS + socket to use the TLS Server Name Indication extension.

+ {server_name_indication, disable} +

When starting a TLS connection without upgrade, the Server Name - Indication extension is sent if possible. This option can also be + Indication extension is sent if possible. This option can be used to disable that behavior.

{fallback, boolean()} @@ -523,7 +517,7 @@ fun(srp, Username :: string(), UserState :: term()) ->

Send special cipher suite TLS_FALLBACK_SCSV to avoid undesired TLS version downgrade. Defaults to false

Note this option is not needed in normal TLS usage and should not be used - to implement new clients. But legacy clients that that retries connections in the following manner

+ to implement new clients. But legacy clients that retries connections in the following manner

ssl:connect(Host, Port, [...{versions, ['tlsv2', 'tlsv1.1', 'tlsv1', 'sslv3']}])

ssl:connect(Host, Port, [...{versions, [tlsv1.1', 'tlsv1', 'sslv3']}, {fallback, true}])

@@ -545,6 +539,10 @@ fun(srp, Username :: string(), UserState :: term()) -> meaning in the server than in the client:

+ + {cacerts, [public_key:der_encoded()]} +

The DER-encoded trusted certificates. If this option + is supplied it overrides option cacertfile.

{cacertfile, path()}

Path to a file containing PEM-encoded CA @@ -555,7 +553,7 @@ fun(srp, Username :: string(), UserState :: term()) -> is no need to verify the client and if there are no intermediate CAs for the server certificate.

- {dh, der_encoded()} + {dh, public_key:der_encoded()}

The DER-encoded Diffie-Hellman parameters. If specified, it overrides option dhfile.

@@ -577,7 +575,7 @@ fun(srp, Username :: string(), UserState :: term()) -> If set to true, the server fails if the client does not have a certificate to send, that is, sends an empty certificate. If set to false, it fails only if the client sends an invalid - certificate (an empty certificate is considered valid).

+ certificate (an empty certificate is considered valid). Defaults to false.

{reuse_sessions, boolean()} -- cgit v1.2.3 From 4025ea36fc731c3bb6898dec5687146e6c372151 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 30 Apr 2015 09:17:09 +0200 Subject: ssl: Keep information in one place only --- lib/ssl/doc/src/ssl.xml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index d070cb4019..c5fe8b69a4 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -37,8 +37,7 @@ SSL - ssl requires the crypto and public_key - applications. + For application dependencies see ssl(6) Supported SSL/TLS-versions are SSL-3.0, TLS-1.0, TLS-1.1, and TLS-1.2. For security reasons SSL-2.0 is not supported. -- cgit v1.2.3 From 0af20bdcfb54a648d4b0c907565171a46afd1457 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 30 Apr 2015 09:47:45 +0200 Subject: ssl: Align with application naming rules ssl SSL crypto Crypto stdlib STDLIB kernel Kernel public_key Public Key --- lib/ssl/doc/src/ssl.xml | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index c5fe8b69a4..14873848d1 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -45,7 +45,7 @@ but can be configured.
Ephemeral Diffie-Hellman cipher suites are supported, but not Diffie Hellman Certificates cipher suites. - Elliptic Curve cipher suites are supported if the crypto + Elliptic Curve cipher suites are supported if the Crypto application supports it and named curves are used. Export cipher suites are not supported as the @@ -63,7 +63,7 @@
DATA TYPES -

The following data types are used in the functions for ssl:

+

The following data types are used in the functions for SSL:

@@ -81,7 +81,7 @@

For valid options, see the inet(3) and gen_tcp(3) manual pages - in kernel.

+ in Kernel.

ssloption()

= {verify, verify_type()}

@@ -261,7 +261,7 @@ atom()}} |

The verification fun is called during the X509-path - validation when an error or an extension unknown to the ssl + validation when an error or an extension unknown to the SSL application is encountered. It is also called when a certificate is considered valid by the path validation to allow access to each certificate in the path to the user @@ -382,7 +382,7 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid

TLS protocol versions supported by started clients and servers. This option overrides the application environment option protocol_version. If the environment option is not set, it defaults - to all versions, except SSL-3.0, supported by the ssl application. + to all versions, except SSL-3.0, supported by the SSL application. See also ssl(6).

{hibernate_after, integer()|undefined} @@ -999,21 +999,21 @@ fun(srp, Username :: string(), UserState :: term()) -> start() -> start(Type) -> ok | {error, Reason} - Starts the sslapplication. + Starts the SSL application. Type = permanent | transient | temporary -

Starts the ssl application. Default type +

Starts the SSL application. Default type is temporary.

stop() -> ok - Stops the ssl application. + Stops the SSL application. -

Stops the ssl application.

+

Stops the SSL application.

@@ -1055,16 +1055,16 @@ fun(srp, Username :: string(), UserState :: term()) -> versions() -> [versions_info()] Returns version information relevant for the - ssl application. + SSL application. versions_info() = {app_vsn, string()} | {supported | available, [protocol()] -

Returns version information relevant for the ssl +

Returns version information relevant for the SSL application.

app_vsn - The application version of the ssl application. + The application version of the SSL application. supported TLS/SSL versions supported by default. @@ -1077,8 +1077,8 @@ fun(srp, Username :: string(), UserState :: term()) -> . available - All TLS/SSL versions supported by the ssl application. - TLS 1.2 requires sufficient support from the crypto + All TLS/SSL versions supported by the SSL application. + TLS 1.2 requires sufficient support from the Crypto application.
@@ -1094,4 +1094,3 @@ fun(srp, Username :: string(), UserState :: term()) ->
- -- cgit v1.2.3 From 4375a9f9ec158c149ccc861b2f736c984fa54ac9 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 30 Apr 2015 10:42:55 +0200 Subject: ssl: Fix links --- lib/ssl/doc/src/ssl.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 14873848d1..78b758226d 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -338,7 +338,7 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid {crl_check, boolean() | peer | best_effort } Perform CRL (Certificate Revocation List) verification - + (public_key:pkix_crls_validate/3) on all the certificates during the path validation (public_key:pkix_path_validation/3) @@ -375,7 +375,8 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid {partial_chain, fun(Chain::[DerCert]) -> {trusted_ca, DerCert} | unknown_ca }

Claim an intermediate CA in the chain as trusted. TLS then - performs public_key:pkix_path_validation/3 + performs public_key:pkix_path_validation/3 with the selected CA as trusted anchor and the rest of the chain.

{versions, [protocol()]} -- cgit v1.2.3 From d3047a56424fc892c551b203286b111bb9205415 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Thu, 30 Apr 2015 14:18:16 +0200 Subject: ssl: Put back marker --- lib/ssl/doc/src/ssl.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 78b758226d..cdf6870c25 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -83,7 +83,7 @@ gen_tcp(3) manual pages in Kernel.

- ssloption() + ssloption()

= {verify, verify_type()}

| {verify_fun, {fun(), term()}}

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

-- cgit v1.2.3 From 0f2d15c95f98e7b271111c9311210a808c624adb Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Fri, 8 May 2015 15:57:15 +0200 Subject: public_key, ssl: Align public_key and ssl doc Make sure that links from ssl to public_key work. OTP-12670 - Ignoring 1.2 extension in 1.0 or TLS-1.1 solved by 5edda23ee854038c9d4bcddd0d676ee0ffd20da5 is mentioned here to make the release scripts happy, as the branch solving this accidently had a name ending 1267 instead of 12670 --- lib/ssl/doc/src/ssl.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index cdf6870c25..46dc93e343 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -268,7 +268,7 @@ atom()}} | application. It differentiates between the peer certificate and the CA certificates by using valid_peer or valid as second argument to the verification fun. See the - public_key User's + public_key User's Guide for definition of #'OTPCertificate'{} and #'Extension'{}.

@@ -364,10 +364,10 @@ marker="public_key:public_key#pkix_path_validation-3">public_key:pkix_path_valid empty argument list. The following arguments may be specified for the internal cache.

{http, timeout()} - +

Enables fetching of CRLs specified as http URIs in X509 cerificate extensions. - Requires the OTP inets application. + marker="public_key:public_key_records"> X509 cerificate extensions. + Requires the OTP inets application.

-- cgit v1.2.3 From be5abeec807ab642881898033a3d23503ec91ce3 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Mon, 11 May 2015 16:54:05 +0200 Subject: ssl: Align "=" sign in type declarations to decided policy --- lib/ssl/doc/src/ssl.xml | 124 ++++++++++++++++++++++++------------------------ 1 file changed, 63 insertions(+), 61 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 46dc93e343..c4651d051c 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -67,15 +67,15 @@ - boolean() -

= true | false

+ boolean() = +

true | false

- option() -

= socketoption() | ssloption() | transportoption()

+ option() = +

socketoption() | ssloption() | transportoption()

- socketoption() -

= proplists:property()

+ socketoption() = +

proplists:property()

The default socket options are [{mode,list},{packet, 0},{header, 0},{active, true}].

For valid options, see the @@ -83,32 +83,34 @@ gen_tcp(3) manual pages in Kernel.

- ssloption() -

= {verify, verify_type()}

-

| {verify_fun, {fun(), term()}}

-

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

-

| {cert, public_key:der_encoded()}

-

| {certfile, path()}

-

| {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' - | 'PrivateKeyInfo', public_key:der_encoded()}}

-

| {keyfile, path()}

-

| {password, string()}

-

| {cacerts, [public_key:der_encoded()]}

-

| {cacertfile, path()}

-

| {dh, public_key:der_encoded()}

-

| {dhfile, path()}

-

| {ciphers, ciphers()}

-

| {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, - {srp_identity, {string(), string()}}

-

| {reuse_sessions, boolean()}

-

| {reuse_session, fun()} {next_protocols_advertised, [binary()]}

-

| {client_preferred_next_protocols, {client | server, - [binary()]} | {client | server, [binary()], binary()}}

-

| {log_alert, boolean()}

-

| {server_name_indication, hostname() | disable}

- - transportoption() -

= {cb_info, {CallbackModule::atom(), DataTag::atom(), + ssloption() = + +

{verify, verify_type()}

+

| {verify_fun, {fun(), term()}}

+

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

+

| {cert, public_key:der_encoded()}

+

| {certfile, path()}

+

| {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' + | 'PrivateKeyInfo', public_key:der_encoded()}}

+

| {keyfile, path()}

+

| {password, string()}

+

| {cacerts, [public_key:der_encoded()]}

+

| {cacertfile, path()}

+

| {dh, public_key:der_encoded()}

+

| {dhfile, path()}

+

| {ciphers, ciphers()}

+

| {user_lookup_fun, {fun(), term()}}, {psk_identity, string()}, + {srp_identity, {string(), string()}}

+

| {reuse_sessions, boolean()}

+

| {reuse_session, fun()} {next_protocols_advertised, [binary()]}

+

| {client_preferred_next_protocols, {client | server, + [binary()]} | {client | server, [binary()], binary()}}

+

| {log_alert, boolean()}

+

| {server_name_indication, hostname() | disable}

+
+ + transportoption() = +

{cb_info, {CallbackModule::atom(), DataTag::atom(), ClosedTag::atom(), ErrTag:atom()}}

Defaults to {gen_tcp, tcp, tcp_closed, tcp_error}. Can be used to customize the transport layer. The callback module must implement a @@ -129,57 +131,57 @@ - verify_type() -

= verify_none | verify_peer

+ verify_type() = +

verify_none | verify_peer

- path() -

= string()

+ path() = +

string()

Represents a file path.

- public_key:der_encoded() -

= binary()

+ public_key:der_encoded() = +

binary()

ASN.1 DER-encoded entity as an Erlang binary.

- host() -

= hostname() | ipaddress()

+ host() = +

hostname() | ipaddress()

- hostname() -

= string()

+ hostname() = +

string()

- ip_address() -

= {N1,N2,N3,N4} % IPv4 | {K1,K2,K3,K4,K5,K6,K7,K8} % IPv6 + ip_address() = +

{N1,N2,N3,N4} % IPv4 | {K1,K2,K3,K4,K5,K6,K7,K8} % IPv6

- sslsocket() -

Opaque to the user.

+ sslsocket() = +

opaque()

- protocol() -

= sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'

+ protocol() = +

sslv3 | tlsv1 | 'tlsv1.1' | 'tlsv1.2'

- ciphers() + ciphers() =

= [ciphersuite()] | string()

According to old API.

- ciphersuite() -

= {key_exchange(), cipher(), hash()}

+ ciphersuite() = +

{key_exchange(), cipher(), hash()}

- key_exchange() -

= rsa | dhe_dss | dhe_rsa | dh_anon | psk | dhe_psk + key_exchange()= +

rsa | dhe_dss | dhe_rsa | dh_anon | psk | dhe_psk | rsa_psk | srp_anon | srp_dss | srp_rsa | ecdh_anon | ecdh_ecdsa | ecdhe_ecdsa | ecdh_rsa | ecdhe_rsa

- cipher() -

= rc4_128 | des_cbc | '3des_ede_cbc' + cipher() = +

rc4_128 | des_cbc | '3des_ede_cbc' | aes_128_cbc | aes_256_cbc | aes_128_gcm | aes_256_gcm

- hash() -

= md5 | sha

+ hash() = +

md5 | sha

- prf_random() -

= client_random | server_random

+ prf_random() = +

client_random | server_random

- srp_param_type() -

= srp_1024 | srp_1536 | srp_2048 | srp_3072 + srp_param_type() = +

srp_1024 | srp_1536 | srp_2048 | srp_3072 | srp_4096 | srp_6144 | srp_8192

-- cgit v1.2.3 From 53ae813221c2dee502e2c114e68c2674c96b89cd Mon Sep 17 00:00:00 2001 From: Qijiang Fan Date: Tue, 30 Dec 2014 22:44:20 +0800 Subject: ssl: docs: SNI server, connection_information/1,2 --- lib/ssl/doc/src/ssl.xml | 47 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 2 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index c4651d051c..77f63dcecf 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -106,7 +106,8 @@

| {client_preferred_next_protocols, {client | server, [binary()]} | {client | server, [binary()], binary()}}

| {log_alert, boolean()}

-

| {server_name_indication, hostname() | disable}

+

| {server_name_indication, hostname() | disable}

+

| {sni_hosts, [{hostname(), ssloptions()}]}

transportoption() = @@ -626,7 +627,10 @@ fun(srp, Username :: string(), UserState :: term()) -> selection. If set to false (the default), use the client preference.

- + {sni_hosts, [{hostname(), ssloptions()}]} +

If the server receives a SNI (Server Name Indication) from the client + matching a host listed in the sni_hosts option, the speicific options for + that host will override previously specified options.

@@ -753,6 +757,45 @@ fun(srp, Username :: string(), UserState :: term()) -> + + connection_information(SslSocket) -> + {ok, Info} | {error, Reason} + Returns all the connection information. + + + Info = [InfoTuple] + InfoTuple = {protocol, Protocol} | {cipher_suite, CipherSuite} | {sni_hostname, SNIHostname} + CipherSuite = ciphersuite() + ProtocolVersion = protocol() + SNIHostname = string() + Reason = term() + +

Return all the connection information containing negotiated protocol version, cipher suite, and the hostname of SNI extension. + Info will be a proplists containing all the connection information on success, otherwise {error, Reason} will be returned.

+
+
+ + + connection_information(SslSocket, Items) -> + {ok, Info} | {error, Reason} + Returns the requested connection information. + + + Items = [Item] + Item = protocol | cipher_suite | sni_hostname + Info = [InfoTuple] + InfoTuple = {protocol, Protocol} | {cipher_suite, CipherSuite} | {sni_hostname, SNIHostname} + CipherSuite = ciphersuite() + ProtocolVersion = protocol() + SNIHostname = string() + Reason = term() + +

Returns the connection information you requested. The connection information you can request contains protocol, cipher_suite, and sni_hostname. + {ok, Info} will be returned if it executes sucessfully. The Info is a proplists containing the information you requested. + Otherwise, {error, Reason} will be returned.

+
+
+ format_error(Reason) -> string() Returns an error string. -- cgit v1.2.3 From db509dd5debcd72d7f1d024d289315274f9b788b Mon Sep 17 00:00:00 2001 From: Qijiang Fan Date: Thu, 16 Apr 2015 22:25:57 +0800 Subject: ssl: add option sni_fun The newly added function sni_fun allows dynamic update of SSL options like keys and certificates depending on different SNI hostname, rather than a predefined rules of SSL options. --- lib/ssl/doc/src/ssl.xml | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 77f63dcecf..8a0bf69be4 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -108,10 +108,12 @@

| {log_alert, boolean()}

| {server_name_indication, hostname() | disable}

| {sni_hosts, [{hostname(), ssloptions()}]}

+

| {sni_fun, SNIfun::fun()}

transportoption() =

{cb_info, {CallbackModule::atom(), DataTag::atom(), + ClosedTag::atom(), ErrTag:atom()}}

Defaults to {gen_tcp, tcp, tcp_closed, tcp_error}. Can be used to customize the transport layer. The callback module must implement a @@ -185,6 +187,9 @@

srp_1024 | srp_1536 | srp_2048 | srp_3072 | srp_4096 | srp_6144 | srp_8192

+ SNIfun::fun() +

= fun(ServerName :: string()) -> ssloptions()

+
@@ -630,7 +635,21 @@ fun(srp, Username :: string(), UserState :: term()) -> {sni_hosts, [{hostname(), ssloptions()}]}

If the server receives a SNI (Server Name Indication) from the client matching a host listed in the sni_hosts option, the speicific options for - that host will override previously specified options.

+ that host will override previously specified options. + + The option sni_fun, and sni_hosts are mutually exclusive.

+ + {sni_fun, SNIfun::fun()} +

If the server receives a SNI (Server Name Indication) from the client, + the given function will be called to retrive ssloptions() for indicated server. + These options will be merged into predefined ssloptions(). + + The function should be defined as: + fun(ServerName :: string()) -> ssloptions() + and can be specified as a fun or as named fun module:function/1 + + The option sni_fun, and sni_hosts are mutually exclusive.

+ -- cgit v1.2.3 From 3b46b3040b82436c904f497bd51cda79a181b500 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Wed, 13 May 2015 16:39:13 +0200 Subject: ssl: Align "=" sign in type declarations to decided policy --- lib/ssl/doc/src/ssl.xml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 8a0bf69be4..18d98e5efb 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -123,13 +123,13 @@ The callback gen_tcp is treated specially and calls inet directly.

- CallbackModule -

= atom()

- DataTag -

= atom()

+ CallbackModule = +

atom()

+ DataTag = +

atom()

Used in socket data message.

- ClosedTag -

= atom()

+ ClosedTag = +

atom()

Used in socket close message.

-- cgit v1.2.3 From 916226427901f40d695d0d7d91106b0188900055 Mon Sep 17 00:00:00 2001 From: Fred Hebert Date: Tue, 2 Jun 2015 10:51:22 -0400 Subject: Add disable client-initiated renegotiation option Client-initiated renegotiation is more costly for the server than the client, and this feature can be abused in denial of service attempts. Although the ssl application already takes counter-measure for these (via cooldown periods between renegotiations), it can be useful to disable the feature entirely. This patch adds the `{client_renegotiation, boolean()}' option to the server-side of the SSL application (defaulting to `true' to be compatible with the current behaviour). The option disables the ability to do any renegotiation at all in the protocol's state, reusing the existing denial code, but without opening the code path that sets up a timed message to eventually reopen it up. --- lib/ssl/doc/src/ssl.xml | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 0c042f8571..923ecdd618 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -514,6 +514,18 @@ fun(srp, Username :: string(), UserState :: term()) -> using negotiated_next_protocol/1 method. + {client_renegotiation, boolean()} + In protocols that support client-initiated renegotiation, the cost + of resources of such an operation is higher for the server than the + client. This can act as a vector for denial of service attacks. The SSL + application already takes measures to counter-act such attempts, + but client-initiated renegotiation can be stricly disabled by setting + this option to false. The default value is true. + Note that disabling renegotiation can result in long-lived connections + becoming unusable due to limits on the number of messages the underlying + cipher suite can encipher. + + {psk_identity, string()} Specifies the server identity hint the server presents to the client. -- cgit v1.2.3 From 738c34d4bb8f1a3811acd00af8c6c12107f8315b Mon Sep 17 00:00:00 2001 From: Bruce Yinhe Date: Thu, 18 Jun 2015 11:31:02 +0200 Subject: Change license text to APLv2 --- lib/ssl/doc/src/ssl.xml | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 9122066787..f23b71e28b 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -8,16 +8,17 @@ Ericsson AB. All Rights Reserved. - The contents of this file are subject to the Erlang Public License, - Version 1.1, (the "License"); you may not use this file except in - compliance with the License. You should have received a copy of the - Erlang Public License along with this software. If not, it can be - retrieved online at http://www.erlang.org/. - - Software distributed under the License is distributed on an "AS IS" - basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See - the License for the specific language governing rights and limitations - under the License. + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. ssl -- cgit v1.2.3 From b71856c612f82a44400f85d8fd2eafcf446202c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Meadows-J=C3=B6nsson?= Date: Thu, 25 Jun 2015 11:29:54 +0200 Subject: Fix formatting of depth option --- lib/ssl/doc/src/ssl.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index f23b71e28b..52d68c1b4a 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -88,7 +88,8 @@

{verify, verify_type()}

| {verify_fun, {fun(), term()}}

-

| {fail_if_no_peer_cert, boolean()} {depth, integer()}

+

| {fail_if_no_peer_cert, boolean()}

+

| {depth, integer()}

| {cert, public_key:der_encoded()}

| {certfile, path()}

| {key, {'RSAPrivateKey'| 'DSAPrivateKey' | 'ECPrivateKey' -- cgit v1.2.3 From 85524e912e645d528ecd601aaaf8b1697ec92114 Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Wed, 19 Aug 2015 17:07:48 +0200 Subject: ssl: Remove duplicate documentation Correct merge that went wrong. --- lib/ssl/doc/src/ssl.xml | 5 ----- 1 file changed, 5 deletions(-) (limited to 'lib/ssl/doc/src/ssl.xml') diff --git a/lib/ssl/doc/src/ssl.xml b/lib/ssl/doc/src/ssl.xml index 52d68c1b4a..6c977bdb74 100644 --- a/lib/ssl/doc/src/ssl.xml +++ b/lib/ssl/doc/src/ssl.xml @@ -664,11 +664,6 @@ fun(srp, Username :: string(), UserState :: term()) -> cipher suite can encipher. - {psk_identity, string()} - Specifies the server identity hint the server presents to the client. - - {log_alert, boolean()} - If false, error reports will not be displayed. {honor_cipher_order, boolean()} If true, use the server's preference for cipher selection. If false (the default), use the client's preference. -- cgit v1.2.3