1SSL_alert_type_string(3)            OpenSSL           SSL_alert_type_string(3)
2
3
4

NAME

6       SSL_alert_type_string, SSL_alert_type_string_long,
7       SSL_alert_desc_string, SSL_alert_desc_string_long - get textual
8       description of alert information
9

SYNOPSIS

11        #include <openssl/ssl.h>
12
13        const char *SSL_alert_type_string(int value);
14        const char *SSL_alert_type_string_long(int value);
15
16        const char *SSL_alert_desc_string(int value);
17        const char *SSL_alert_desc_string_long(int value);
18

DESCRIPTION

20       SSL_alert_type_string() returns a one letter string indicating the type
21       of the alert specified by value.
22
23       SSL_alert_type_string_long() returns a string indicating the type of
24       the alert specified by value.
25
26       SSL_alert_desc_string() returns a two letter string as a short form
27       describing the reason of the alert specified by value.
28
29       SSL_alert_desc_string_long() returns a string describing the reason of
30       the alert specified by value.
31

NOTES

33       When one side of an SSL/TLS communication wants to inform the peer
34       about a special situation, it sends an alert. The alert is sent as a
35       special message and does not influence the normal data stream (unless
36       its contents results in the communication being canceled).
37
38       A warning alert is sent, when a non-fatal error condition occurs. The
39       "close notify" alert is sent as a warning alert. Other examples for
40       non-fatal errors are certificate errors ("certificate expired", "unsup‐
41       ported certificate"), for which a warning alert may be sent.  (The
42       sending party may however decide to send a fatal error.) The receiving
43       side may cancel the connection on reception of a warning alert on it
44       discretion.
45
46       Several alert messages must be sent as fatal alert messages as speci‐
47       fied by the TLS RFC. A fatal alert always leads to a connection abort.
48

RETURN VALUES

50       The following strings can occur for SSL_alert_type_string() or
51       SSL_alert_type_string_long():
52
53       "W"/"warning"
54       "F"/"fatal"
55       "U"/"unknown"
56           This indicates that no support is available for this alert type.
57           Probably value does not contain a correct alert message.
58
59       The following strings can occur for SSL_alert_desc_string() or
60       SSL_alert_desc_string_long():
61
62       "CN"/"close notify"
63           The connection shall be closed. This is a warning alert.
64
65       "UM"/"unexpected message"
66           An inappropriate message was received. This alert is always fatal
67           and should never be observed in communication between proper imple‐
68           mentations.
69
70       "BM"/"bad record mac"
71           This alert is returned if a record is received with an incorrect
72           MAC. This message is always fatal.
73
74       "DF"/"decompression failure"
75           The decompression function received improper input (e.g. data that
76           would expand to excessive length). This message is always fatal.
77
78       "HF"/"handshake failure"
79           Reception of a handshake_failure alert message indicates that the
80           sender was unable to negotiate an acceptable set of security param‐
81           eters given the options available. This is a fatal error.
82
83       "NC"/"no certificate"
84           A client, that was asked to send a certificate, does not send a
85           certificate (SSLv3 only).
86
87       "BC"/"bad certificate"
88           A certificate was corrupt, contained signatures that did not verify
89           correctly, etc
90
91       "UC"/"unsupported certificate"
92           A certificate was of an unsupported type.
93
94       "CR"/"certificate revoked"
95           A certificate was revoked by its signer.
96
97       "CE"/"certificate expired"
98           A certificate has expired or is not currently valid.
99
100       "CU"/"certificate unknown"
101           Some other (unspecified) issue arose in processing the certificate,
102           rendering it unacceptable.
103
104       "IP"/"illegal parameter"
105           A field in the handshake was out of range or inconsistent with
106           other fields. This is always fatal.
107
108       "DC"/"decryption failed"
109           A TLSCiphertext decrypted in an invalid way: either it wasn't an
110           even multiple of the block length or its padding values, when
111           checked, weren't correct. This message is always fatal.
112
113       "RO"/"record overflow"
114           A TLSCiphertext record was received which had a length more than
115           2^14+2048 bytes, or a record decrypted to a TLSCompressed record
116           with more than 2^14+1024 bytes. This message is always fatal.
117
118       "CA"/"unknown CA"
119           A valid certificate chain or partial chain was received, but the
120           certificate was not accepted because the CA certificate could not
121           be located or couldn't be matched with a known, trusted CA.  This
122           message is always fatal.
123
124       "AD"/"access denied"
125           A valid certificate was received, but when access control was
126           applied, the sender decided not to proceed with negotiation.  This
127           message is always fatal.
128
129       "DE"/"decode error"
130           A message could not be decoded because some field was out of the
131           specified range or the length of the message was incorrect. This
132           message is always fatal.
133
134       "CY"/"decrypt error"
135           A handshake cryptographic operation failed, including being unable
136           to correctly verify a signature, decrypt a key exchange, or vali‐
137           date a finished message.
138
139       "ER"/"export restriction"
140           A negotiation not in compliance with export restrictions was
141           detected; for example, attempting to transfer a 1024 bit ephemeral
142           RSA key for the RSA_EXPORT handshake method. This message is always
143           fatal.
144
145       "PV"/"protocol version"
146           The protocol version the client has attempted to negotiate is rec‐
147           ognized, but not supported. (For example, old protocol versions
148           might be avoided for security reasons). This message is always
149           fatal.
150
151       "IS"/"insufficient security"
152           Returned instead of handshake_failure when a negotiation has failed
153           specifically because the server requires ciphers more secure than
154           those supported by the client. This message is always fatal.
155
156       "IE"/"internal error"
157           An internal error unrelated to the peer or the correctness of the
158           protocol makes it impossible to continue (such as a memory alloca‐
159           tion failure). This message is always fatal.
160
161       "US"/"user canceled"
162           This handshake is being canceled for some reason unrelated to a
163           protocol failure. If the user cancels an operation after the hand‐
164           shake is complete, just closing the connection by sending a
165           close_notify is more appropriate. This alert should be followed by
166           a close_notify. This message is generally a warning.
167
168       "NR"/"no renegotiation"
169           Sent by the client in response to a hello request or by the server
170           in response to a client hello after initial handshaking.  Either of
171           these would normally lead to renegotiation; when that is not appro‐
172           priate, the recipient should respond with this alert; at that
173           point, the original requester can decide whether to proceed with
174           the connection. One case where this would be appropriate would be
175           where a server has spawned a process to satisfy a request; the
176           process might receive security parameters (key length, authentica‐
177           tion, etc.) at startup and it might be difficult to communicate
178           changes to these parameters after that point. This message is
179           always a warning.
180
181       "UK"/"unknown"
182           This indicates that no description is available for this alert
183           type.  Probably value does not contain a correct alert message.
184

SEE ALSO

186       ssl(3), SSL_CTX_set_info_callback(3)
187
188
189
1900.9.8b                            2001-09-07          SSL_alert_type_string(3)
Impressum