diff options
author | Emilia Kasper <emilia@openssl.org> | 2014-12-04 15:00:11 +0100 |
---|---|---|
committer | Emilia Kasper <emilia@openssl.org> | 2014-12-05 18:31:21 +0100 |
commit | 376e2ca3e3525290619602dc6013c97c9653c037 (patch) | |
tree | 86374b2fee2a0e6e75525bf00cc800a4eed464c1 /doc | |
parent | 740580c2b2b86c2ffdc4a2d36850248c6091d6a0 (diff) | |
download | openssl-376e2ca3e3525290619602dc6013c97c9653c037.tar.gz |
Clarify the return values for SSL_get_shared_curve.
Reviewed-by: Matt Caswell <matt@openssl.org>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/ssl/SSL_CTX_set1_curves.pod | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/doc/ssl/SSL_CTX_set1_curves.pod b/doc/ssl/SSL_CTX_set1_curves.pod index 0c9be25156..18d0c9ac39 100644 --- a/doc/ssl/SSL_CTX_set1_curves.pod +++ b/doc/ssl/SSL_CTX_set1_curves.pod @@ -45,11 +45,12 @@ B<curves> array is in the form of a set of curve NIDs in preference order. It can return zero if the client did not send a supported curves extension. -SSL_get1_shared_curve() returns shared curve B<n> for B<ssl>. If B<n> is --1 then the total number of shared curves is returned, which may be -zero. Other than for diagnostic purposes, most applications will only -be interested in the first shared curve so B<n> is normally set to zero. -If the value B<n> is out of range zero is returned. +SSL_get_shared_curve() returns shared curve B<n> for a server-side +SSL B<ssl>. If B<n> is -1 then the total number of shared curves is +returned, which may be zero. Other than for diagnostic purposes, +most applications will only be interested in the first shared curve +so B<n> is normally set to zero. If the value B<n> is out of range, +NID_undef is returned. SSL_CTX_set_ecdh_auto() and SSL_set_ecdh_auto() set automatic curve selection for server B<ctx> or B<ssl> to B<onoff>. If B<onoff> is 1 then @@ -84,8 +85,12 @@ return 1 for success and 0 for failure. SSL_get1_curves() returns the number of curves, which may be zero. -SSL_get1_shared_curve() returns the NID of shared curve B<n> of zero if there -is no shared curve B<n> or the number of shared curves if B<n> is -1. +SSL_get_shared_curve() returns the NID of shared curve B<n> or NID_undef if there +is no shared curve B<n>; or the total number of shared curves if B<n> +is -1. + +When called on a client B<ssl>, SSL_get_shared_curve() has no meaning and +returns -1. =head1 SEE ALSO |