tls1.h 71 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237
  1. /*
  2. * Copyright 1995-2019 The OpenSSL Project Authors. All Rights Reserved.
  3. * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
  4. * Copyright 2005 Nokia. All rights reserved.
  5. *
  6. * Licensed under the OpenSSL license (the "License"). You may not use
  7. * this file except in compliance with the License. You can obtain a copy
  8. * in the file LICENSE in the source distribution or at
  9. * https://www.openssl.org/source/license.html
  10. */
  11. #ifndef HEADER_TLS1_H
  12. # define HEADER_TLS1_H
  13. # include <openssl/buffer.h>
  14. # include <openssl/x509.h>
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. /* Default security level if not overridden at config time */
  19. # ifndef OPENSSL_TLS_SECURITY_LEVEL
  20. # define OPENSSL_TLS_SECURITY_LEVEL 1
  21. # endif
  22. # define TLS1_VERSION 0x0301
  23. # define TLS1_1_VERSION 0x0302
  24. # define TLS1_2_VERSION 0x0303
  25. # define TLS1_3_VERSION 0x0304
  26. # define TLS_MAX_VERSION TLS1_3_VERSION
  27. /* Special value for method supporting multiple versions */
  28. # define TLS_ANY_VERSION 0x10000
  29. # define TLS1_VERSION_MAJOR 0x03
  30. # define TLS1_VERSION_MINOR 0x01
  31. # define TLS1_1_VERSION_MAJOR 0x03
  32. # define TLS1_1_VERSION_MINOR 0x02
  33. # define TLS1_2_VERSION_MAJOR 0x03
  34. # define TLS1_2_VERSION_MINOR 0x03
  35. # define TLS1_get_version(s) \
  36. ((SSL_version(s) >> 8) == TLS1_VERSION_MAJOR ? SSL_version(s) : 0)
  37. # define TLS1_get_client_version(s) \
  38. ((SSL_client_version(s) >> 8) == TLS1_VERSION_MAJOR ? SSL_client_version(s) : 0)
  39. # define TLS1_AD_DECRYPTION_FAILED 21
  40. # define TLS1_AD_RECORD_OVERFLOW 22
  41. # define TLS1_AD_UNKNOWN_CA 48/* fatal */
  42. # define TLS1_AD_ACCESS_DENIED 49/* fatal */
  43. # define TLS1_AD_DECODE_ERROR 50/* fatal */
  44. # define TLS1_AD_DECRYPT_ERROR 51
  45. # define TLS1_AD_EXPORT_RESTRICTION 60/* fatal */
  46. # define TLS1_AD_PROTOCOL_VERSION 70/* fatal */
  47. # define TLS1_AD_INSUFFICIENT_SECURITY 71/* fatal */
  48. # define TLS1_AD_INTERNAL_ERROR 80/* fatal */
  49. # define TLS1_AD_INAPPROPRIATE_FALLBACK 86/* fatal */
  50. # define TLS1_AD_USER_CANCELLED 90
  51. # define TLS1_AD_NO_RENEGOTIATION 100
  52. /* TLSv1.3 alerts */
  53. # define TLS13_AD_MISSING_EXTENSION 109 /* fatal */
  54. # define TLS13_AD_CERTIFICATE_REQUIRED 116 /* fatal */
  55. /* codes 110-114 are from RFC3546 */
  56. # define TLS1_AD_UNSUPPORTED_EXTENSION 110
  57. # define TLS1_AD_CERTIFICATE_UNOBTAINABLE 111
  58. # define TLS1_AD_UNRECOGNIZED_NAME 112
  59. # define TLS1_AD_BAD_CERTIFICATE_STATUS_RESPONSE 113
  60. # define TLS1_AD_BAD_CERTIFICATE_HASH_VALUE 114
  61. # define TLS1_AD_UNKNOWN_PSK_IDENTITY 115/* fatal */
  62. # define TLS1_AD_NO_APPLICATION_PROTOCOL 120 /* fatal */
  63. /* ExtensionType values from RFC3546 / RFC4366 / RFC6066 */
  64. # define TLSEXT_TYPE_server_name 0
  65. # define TLSEXT_TYPE_max_fragment_length 1
  66. # define TLSEXT_TYPE_client_certificate_url 2
  67. # define TLSEXT_TYPE_trusted_ca_keys 3
  68. # define TLSEXT_TYPE_truncated_hmac 4
  69. # define TLSEXT_TYPE_status_request 5
  70. /* ExtensionType values from RFC4681 */
  71. # define TLSEXT_TYPE_user_mapping 6
  72. /* ExtensionType values from RFC5878 */
  73. # define TLSEXT_TYPE_client_authz 7
  74. # define TLSEXT_TYPE_server_authz 8
  75. /* ExtensionType values from RFC6091 */
  76. # define TLSEXT_TYPE_cert_type 9
  77. /* ExtensionType values from RFC4492 */
  78. /*
  79. * Prior to TLSv1.3 the supported_groups extension was known as
  80. * elliptic_curves
  81. */
  82. # define TLSEXT_TYPE_supported_groups 10
  83. # define TLSEXT_TYPE_elliptic_curves TLSEXT_TYPE_supported_groups
  84. # define TLSEXT_TYPE_ec_point_formats 11
  85. /* ExtensionType value from RFC5054 */
  86. # define TLSEXT_TYPE_srp 12
  87. /* ExtensionType values from RFC5246 */
  88. # define TLSEXT_TYPE_signature_algorithms 13
  89. /* ExtensionType value from RFC5764 */
  90. # define TLSEXT_TYPE_use_srtp 14
  91. /* ExtensionType value from RFC5620 */
  92. # define TLSEXT_TYPE_heartbeat 15
  93. /* ExtensionType value from RFC7301 */
  94. # define TLSEXT_TYPE_application_layer_protocol_negotiation 16
  95. /*
  96. * Extension type for Certificate Transparency
  97. * https://tools.ietf.org/html/rfc6962#section-3.3.1
  98. */
  99. # define TLSEXT_TYPE_signed_certificate_timestamp 18
  100. /*
  101. * ExtensionType value for TLS padding extension.
  102. * http://tools.ietf.org/html/draft-agl-tls-padding
  103. */
  104. # define TLSEXT_TYPE_padding 21
  105. /* ExtensionType value from RFC7366 */
  106. # define TLSEXT_TYPE_encrypt_then_mac 22
  107. /* ExtensionType value from RFC7627 */
  108. # define TLSEXT_TYPE_extended_master_secret 23
  109. /* ExtensionType value from RFC4507 */
  110. # define TLSEXT_TYPE_session_ticket 35
  111. /* As defined for TLS1.3 */
  112. # define TLSEXT_TYPE_psk 41
  113. # define TLSEXT_TYPE_early_data 42
  114. # define TLSEXT_TYPE_supported_versions 43
  115. # define TLSEXT_TYPE_cookie 44
  116. # define TLSEXT_TYPE_psk_kex_modes 45
  117. # define TLSEXT_TYPE_certificate_authorities 47
  118. # define TLSEXT_TYPE_post_handshake_auth 49
  119. # define TLSEXT_TYPE_signature_algorithms_cert 50
  120. # define TLSEXT_TYPE_key_share 51
  121. /* Temporary extension type */
  122. # define TLSEXT_TYPE_renegotiate 0xff01
  123. # ifndef OPENSSL_NO_NEXTPROTONEG
  124. /* This is not an IANA defined extension number */
  125. # define TLSEXT_TYPE_next_proto_neg 13172
  126. # endif
  127. /* NameType value from RFC3546 */
  128. # define TLSEXT_NAMETYPE_host_name 0
  129. /* status request value from RFC3546 */
  130. # define TLSEXT_STATUSTYPE_ocsp 1
  131. /* ECPointFormat values from RFC4492 */
  132. # define TLSEXT_ECPOINTFORMAT_first 0
  133. # define TLSEXT_ECPOINTFORMAT_uncompressed 0
  134. # define TLSEXT_ECPOINTFORMAT_ansiX962_compressed_prime 1
  135. # define TLSEXT_ECPOINTFORMAT_ansiX962_compressed_char2 2
  136. # define TLSEXT_ECPOINTFORMAT_last 2
  137. /* Signature and hash algorithms from RFC5246 */
  138. # define TLSEXT_signature_anonymous 0
  139. # define TLSEXT_signature_rsa 1
  140. # define TLSEXT_signature_dsa 2
  141. # define TLSEXT_signature_ecdsa 3
  142. # define TLSEXT_signature_gostr34102001 237
  143. # define TLSEXT_signature_gostr34102012_256 238
  144. # define TLSEXT_signature_gostr34102012_512 239
  145. /* Total number of different signature algorithms */
  146. # define TLSEXT_signature_num 7
  147. # define TLSEXT_hash_none 0
  148. # define TLSEXT_hash_md5 1
  149. # define TLSEXT_hash_sha1 2
  150. # define TLSEXT_hash_sha224 3
  151. # define TLSEXT_hash_sha256 4
  152. # define TLSEXT_hash_sha384 5
  153. # define TLSEXT_hash_sha512 6
  154. # define TLSEXT_hash_gostr3411 237
  155. # define TLSEXT_hash_gostr34112012_256 238
  156. # define TLSEXT_hash_gostr34112012_512 239
  157. /* Total number of different digest algorithms */
  158. # define TLSEXT_hash_num 10
  159. /* Flag set for unrecognised algorithms */
  160. # define TLSEXT_nid_unknown 0x1000000
  161. /* ECC curves */
  162. # define TLSEXT_curve_P_256 23
  163. # define TLSEXT_curve_P_384 24
  164. /* OpenSSL value to disable maximum fragment length extension */
  165. # define TLSEXT_max_fragment_length_DISABLED 0
  166. /* Allowed values for max fragment length extension */
  167. # define TLSEXT_max_fragment_length_512 1
  168. # define TLSEXT_max_fragment_length_1024 2
  169. # define TLSEXT_max_fragment_length_2048 3
  170. # define TLSEXT_max_fragment_length_4096 4
  171. int SSL_CTX_set_tlsext_max_fragment_length(SSL_CTX *ctx, uint8_t mode);
  172. int SSL_set_tlsext_max_fragment_length(SSL *ssl, uint8_t mode);
  173. # define TLSEXT_MAXLEN_host_name 255
  174. __owur const char *SSL_get_servername(const SSL *s, const int type);
  175. __owur int SSL_get_servername_type(const SSL *s);
  176. /*
  177. * SSL_export_keying_material exports a value derived from the master secret,
  178. * as specified in RFC 5705. It writes |olen| bytes to |out| given a label and
  179. * optional context. (Since a zero length context is allowed, the |use_context|
  180. * flag controls whether a context is included.) It returns 1 on success and
  181. * 0 or -1 otherwise.
  182. */
  183. __owur int SSL_export_keying_material(SSL *s, unsigned char *out, size_t olen,
  184. const char *label, size_t llen,
  185. const unsigned char *context,
  186. size_t contextlen, int use_context);
  187. /*
  188. * SSL_export_keying_material_early exports a value derived from the
  189. * early exporter master secret, as specified in
  190. * https://tools.ietf.org/html/draft-ietf-tls-tls13-23. It writes
  191. * |olen| bytes to |out| given a label and optional context. It
  192. * returns 1 on success and 0 otherwise.
  193. */
  194. __owur int SSL_export_keying_material_early(SSL *s, unsigned char *out,
  195. size_t olen, const char *label,
  196. size_t llen,
  197. const unsigned char *context,
  198. size_t contextlen);
  199. int SSL_get_peer_signature_type_nid(const SSL *s, int *pnid);
  200. int SSL_get_signature_type_nid(const SSL *s, int *pnid);
  201. int SSL_get_sigalgs(SSL *s, int idx,
  202. int *psign, int *phash, int *psignandhash,
  203. unsigned char *rsig, unsigned char *rhash);
  204. int SSL_get_shared_sigalgs(SSL *s, int idx,
  205. int *psign, int *phash, int *psignandhash,
  206. unsigned char *rsig, unsigned char *rhash);
  207. __owur int SSL_check_chain(SSL *s, X509 *x, EVP_PKEY *pk, STACK_OF(X509) *chain);
  208. # define SSL_set_tlsext_host_name(s,name) \
  209. SSL_ctrl(s,SSL_CTRL_SET_TLSEXT_HOSTNAME,TLSEXT_NAMETYPE_host_name,\
  210. (void *)name)
  211. # define SSL_set_tlsext_debug_callback(ssl, cb) \
  212. SSL_callback_ctrl(ssl,SSL_CTRL_SET_TLSEXT_DEBUG_CB,\
  213. (void (*)(void))cb)
  214. # define SSL_set_tlsext_debug_arg(ssl, arg) \
  215. SSL_ctrl(ssl,SSL_CTRL_SET_TLSEXT_DEBUG_ARG,0,arg)
  216. # define SSL_get_tlsext_status_type(ssl) \
  217. SSL_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_TYPE,0,NULL)
  218. # define SSL_set_tlsext_status_type(ssl, type) \
  219. SSL_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_TYPE,type,NULL)
  220. # define SSL_get_tlsext_status_exts(ssl, arg) \
  221. SSL_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_EXTS,0,arg)
  222. # define SSL_set_tlsext_status_exts(ssl, arg) \
  223. SSL_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_EXTS,0,arg)
  224. # define SSL_get_tlsext_status_ids(ssl, arg) \
  225. SSL_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_IDS,0,arg)
  226. # define SSL_set_tlsext_status_ids(ssl, arg) \
  227. SSL_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_IDS,0,arg)
  228. # define SSL_get_tlsext_status_ocsp_resp(ssl, arg) \
  229. SSL_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_OCSP_RESP,0,arg)
  230. # define SSL_set_tlsext_status_ocsp_resp(ssl, arg, arglen) \
  231. SSL_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_OCSP_RESP,arglen,arg)
  232. # define SSL_CTX_set_tlsext_servername_callback(ctx, cb) \
  233. SSL_CTX_callback_ctrl(ctx,SSL_CTRL_SET_TLSEXT_SERVERNAME_CB,\
  234. (void (*)(void))cb)
  235. # define SSL_TLSEXT_ERR_OK 0
  236. # define SSL_TLSEXT_ERR_ALERT_WARNING 1
  237. # define SSL_TLSEXT_ERR_ALERT_FATAL 2
  238. # define SSL_TLSEXT_ERR_NOACK 3
  239. # define SSL_CTX_set_tlsext_servername_arg(ctx, arg) \
  240. SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TLSEXT_SERVERNAME_ARG,0,arg)
  241. # define SSL_CTX_get_tlsext_ticket_keys(ctx, keys, keylen) \
  242. SSL_CTX_ctrl(ctx,SSL_CTRL_GET_TLSEXT_TICKET_KEYS,keylen,keys)
  243. # define SSL_CTX_set_tlsext_ticket_keys(ctx, keys, keylen) \
  244. SSL_CTX_ctrl(ctx,SSL_CTRL_SET_TLSEXT_TICKET_KEYS,keylen,keys)
  245. # define SSL_CTX_get_tlsext_status_cb(ssl, cb) \
  246. SSL_CTX_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_CB,0,(void *)cb)
  247. # define SSL_CTX_set_tlsext_status_cb(ssl, cb) \
  248. SSL_CTX_callback_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_CB,\
  249. (void (*)(void))cb)
  250. # define SSL_CTX_get_tlsext_status_arg(ssl, arg) \
  251. SSL_CTX_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_CB_ARG,0,arg)
  252. # define SSL_CTX_set_tlsext_status_arg(ssl, arg) \
  253. SSL_CTX_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_CB_ARG,0,arg)
  254. # define SSL_CTX_set_tlsext_status_type(ssl, type) \
  255. SSL_CTX_ctrl(ssl,SSL_CTRL_SET_TLSEXT_STATUS_REQ_TYPE,type,NULL)
  256. # define SSL_CTX_get_tlsext_status_type(ssl) \
  257. SSL_CTX_ctrl(ssl,SSL_CTRL_GET_TLSEXT_STATUS_REQ_TYPE,0,NULL)
  258. # define SSL_CTX_set_tlsext_ticket_key_cb(ssl, cb) \
  259. SSL_CTX_callback_ctrl(ssl,SSL_CTRL_SET_TLSEXT_TICKET_KEY_CB,\
  260. (void (*)(void))cb)
  261. # ifndef OPENSSL_NO_HEARTBEATS
  262. # define SSL_DTLSEXT_HB_ENABLED 0x01
  263. # define SSL_DTLSEXT_HB_DONT_SEND_REQUESTS 0x02
  264. # define SSL_DTLSEXT_HB_DONT_RECV_REQUESTS 0x04
  265. # define SSL_get_dtlsext_heartbeat_pending(ssl) \
  266. SSL_ctrl(ssl,SSL_CTRL_GET_DTLS_EXT_HEARTBEAT_PENDING,0,NULL)
  267. # define SSL_set_dtlsext_heartbeat_no_requests(ssl, arg) \
  268. SSL_ctrl(ssl,SSL_CTRL_SET_DTLS_EXT_HEARTBEAT_NO_REQUESTS,arg,NULL)
  269. # if OPENSSL_API_COMPAT < 0x10100000L
  270. # define SSL_CTRL_TLS_EXT_SEND_HEARTBEAT \
  271. SSL_CTRL_DTLS_EXT_SEND_HEARTBEAT
  272. # define SSL_CTRL_GET_TLS_EXT_HEARTBEAT_PENDING \
  273. SSL_CTRL_GET_DTLS_EXT_HEARTBEAT_PENDING
  274. # define SSL_CTRL_SET_TLS_EXT_HEARTBEAT_NO_REQUESTS \
  275. SSL_CTRL_SET_DTLS_EXT_HEARTBEAT_NO_REQUESTS
  276. # define SSL_TLSEXT_HB_ENABLED \
  277. SSL_DTLSEXT_HB_ENABLED
  278. # define SSL_TLSEXT_HB_DONT_SEND_REQUESTS \
  279. SSL_DTLSEXT_HB_DONT_SEND_REQUESTS
  280. # define SSL_TLSEXT_HB_DONT_RECV_REQUESTS \
  281. SSL_DTLSEXT_HB_DONT_RECV_REQUESTS
  282. # define SSL_get_tlsext_heartbeat_pending(ssl) \
  283. SSL_get_dtlsext_heartbeat_pending(ssl)
  284. # define SSL_set_tlsext_heartbeat_no_requests(ssl, arg) \
  285. SSL_set_dtlsext_heartbeat_no_requests(ssl,arg)
  286. # endif
  287. # endif
  288. /* PSK ciphersuites from 4279 */
  289. # define TLS1_CK_PSK_WITH_RC4_128_SHA 0x0300008A
  290. # define TLS1_CK_PSK_WITH_3DES_EDE_CBC_SHA 0x0300008B
  291. # define TLS1_CK_PSK_WITH_AES_128_CBC_SHA 0x0300008C
  292. # define TLS1_CK_PSK_WITH_AES_256_CBC_SHA 0x0300008D
  293. # define TLS1_CK_DHE_PSK_WITH_RC4_128_SHA 0x0300008E
  294. # define TLS1_CK_DHE_PSK_WITH_3DES_EDE_CBC_SHA 0x0300008F
  295. # define TLS1_CK_DHE_PSK_WITH_AES_128_CBC_SHA 0x03000090
  296. # define TLS1_CK_DHE_PSK_WITH_AES_256_CBC_SHA 0x03000091
  297. # define TLS1_CK_RSA_PSK_WITH_RC4_128_SHA 0x03000092
  298. # define TLS1_CK_RSA_PSK_WITH_3DES_EDE_CBC_SHA 0x03000093
  299. # define TLS1_CK_RSA_PSK_WITH_AES_128_CBC_SHA 0x03000094
  300. # define TLS1_CK_RSA_PSK_WITH_AES_256_CBC_SHA 0x03000095
  301. /* PSK ciphersuites from 5487 */
  302. # define TLS1_CK_PSK_WITH_AES_128_GCM_SHA256 0x030000A8
  303. # define TLS1_CK_PSK_WITH_AES_256_GCM_SHA384 0x030000A9
  304. # define TLS1_CK_DHE_PSK_WITH_AES_128_GCM_SHA256 0x030000AA
  305. # define TLS1_CK_DHE_PSK_WITH_AES_256_GCM_SHA384 0x030000AB
  306. # define TLS1_CK_RSA_PSK_WITH_AES_128_GCM_SHA256 0x030000AC
  307. # define TLS1_CK_RSA_PSK_WITH_AES_256_GCM_SHA384 0x030000AD
  308. # define TLS1_CK_PSK_WITH_AES_128_CBC_SHA256 0x030000AE
  309. # define TLS1_CK_PSK_WITH_AES_256_CBC_SHA384 0x030000AF
  310. # define TLS1_CK_PSK_WITH_NULL_SHA256 0x030000B0
  311. # define TLS1_CK_PSK_WITH_NULL_SHA384 0x030000B1
  312. # define TLS1_CK_DHE_PSK_WITH_AES_128_CBC_SHA256 0x030000B2
  313. # define TLS1_CK_DHE_PSK_WITH_AES_256_CBC_SHA384 0x030000B3
  314. # define TLS1_CK_DHE_PSK_WITH_NULL_SHA256 0x030000B4
  315. # define TLS1_CK_DHE_PSK_WITH_NULL_SHA384 0x030000B5
  316. # define TLS1_CK_RSA_PSK_WITH_AES_128_CBC_SHA256 0x030000B6
  317. # define TLS1_CK_RSA_PSK_WITH_AES_256_CBC_SHA384 0x030000B7
  318. # define TLS1_CK_RSA_PSK_WITH_NULL_SHA256 0x030000B8
  319. # define TLS1_CK_RSA_PSK_WITH_NULL_SHA384 0x030000B9
  320. /* NULL PSK ciphersuites from RFC4785 */
  321. # define TLS1_CK_PSK_WITH_NULL_SHA 0x0300002C
  322. # define TLS1_CK_DHE_PSK_WITH_NULL_SHA 0x0300002D
  323. # define TLS1_CK_RSA_PSK_WITH_NULL_SHA 0x0300002E
  324. /* AES ciphersuites from RFC3268 */
  325. # define TLS1_CK_RSA_WITH_AES_128_SHA 0x0300002F
  326. # define TLS1_CK_DH_DSS_WITH_AES_128_SHA 0x03000030
  327. # define TLS1_CK_DH_RSA_WITH_AES_128_SHA 0x03000031
  328. # define TLS1_CK_DHE_DSS_WITH_AES_128_SHA 0x03000032
  329. # define TLS1_CK_DHE_RSA_WITH_AES_128_SHA 0x03000033
  330. # define TLS1_CK_ADH_WITH_AES_128_SHA 0x03000034
  331. # define TLS1_CK_RSA_WITH_AES_256_SHA 0x03000035
  332. # define TLS1_CK_DH_DSS_WITH_AES_256_SHA 0x03000036
  333. # define TLS1_CK_DH_RSA_WITH_AES_256_SHA 0x03000037
  334. # define TLS1_CK_DHE_DSS_WITH_AES_256_SHA 0x03000038
  335. # define TLS1_CK_DHE_RSA_WITH_AES_256_SHA 0x03000039
  336. # define TLS1_CK_ADH_WITH_AES_256_SHA 0x0300003A
  337. /* TLS v1.2 ciphersuites */
  338. # define TLS1_CK_RSA_WITH_NULL_SHA256 0x0300003B
  339. # define TLS1_CK_RSA_WITH_AES_128_SHA256 0x0300003C
  340. # define TLS1_CK_RSA_WITH_AES_256_SHA256 0x0300003D
  341. # define TLS1_CK_DH_DSS_WITH_AES_128_SHA256 0x0300003E
  342. # define TLS1_CK_DH_RSA_WITH_AES_128_SHA256 0x0300003F
  343. # define TLS1_CK_DHE_DSS_WITH_AES_128_SHA256 0x03000040
  344. /* Camellia ciphersuites from RFC4132 */
  345. # define TLS1_CK_RSA_WITH_CAMELLIA_128_CBC_SHA 0x03000041
  346. # define TLS1_CK_DH_DSS_WITH_CAMELLIA_128_CBC_SHA 0x03000042
  347. # define TLS1_CK_DH_RSA_WITH_CAMELLIA_128_CBC_SHA 0x03000043
  348. # define TLS1_CK_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA 0x03000044
  349. # define TLS1_CK_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA 0x03000045
  350. # define TLS1_CK_ADH_WITH_CAMELLIA_128_CBC_SHA 0x03000046
  351. /* TLS v1.2 ciphersuites */
  352. # define TLS1_CK_DHE_RSA_WITH_AES_128_SHA256 0x03000067
  353. # define TLS1_CK_DH_DSS_WITH_AES_256_SHA256 0x03000068
  354. # define TLS1_CK_DH_RSA_WITH_AES_256_SHA256 0x03000069
  355. # define TLS1_CK_DHE_DSS_WITH_AES_256_SHA256 0x0300006A
  356. # define TLS1_CK_DHE_RSA_WITH_AES_256_SHA256 0x0300006B
  357. # define TLS1_CK_ADH_WITH_AES_128_SHA256 0x0300006C
  358. # define TLS1_CK_ADH_WITH_AES_256_SHA256 0x0300006D
  359. /* Camellia ciphersuites from RFC4132 */
  360. # define TLS1_CK_RSA_WITH_CAMELLIA_256_CBC_SHA 0x03000084
  361. # define TLS1_CK_DH_DSS_WITH_CAMELLIA_256_CBC_SHA 0x03000085
  362. # define TLS1_CK_DH_RSA_WITH_CAMELLIA_256_CBC_SHA 0x03000086
  363. # define TLS1_CK_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA 0x03000087
  364. # define TLS1_CK_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA 0x03000088
  365. # define TLS1_CK_ADH_WITH_CAMELLIA_256_CBC_SHA 0x03000089
  366. /* SEED ciphersuites from RFC4162 */
  367. # define TLS1_CK_RSA_WITH_SEED_SHA 0x03000096
  368. # define TLS1_CK_DH_DSS_WITH_SEED_SHA 0x03000097
  369. # define TLS1_CK_DH_RSA_WITH_SEED_SHA 0x03000098
  370. # define TLS1_CK_DHE_DSS_WITH_SEED_SHA 0x03000099
  371. # define TLS1_CK_DHE_RSA_WITH_SEED_SHA 0x0300009A
  372. # define TLS1_CK_ADH_WITH_SEED_SHA 0x0300009B
  373. /* TLS v1.2 GCM ciphersuites from RFC5288 */
  374. # define TLS1_CK_RSA_WITH_AES_128_GCM_SHA256 0x0300009C
  375. # define TLS1_CK_RSA_WITH_AES_256_GCM_SHA384 0x0300009D
  376. # define TLS1_CK_DHE_RSA_WITH_AES_128_GCM_SHA256 0x0300009E
  377. # define TLS1_CK_DHE_RSA_WITH_AES_256_GCM_SHA384 0x0300009F
  378. # define TLS1_CK_DH_RSA_WITH_AES_128_GCM_SHA256 0x030000A0
  379. # define TLS1_CK_DH_RSA_WITH_AES_256_GCM_SHA384 0x030000A1
  380. # define TLS1_CK_DHE_DSS_WITH_AES_128_GCM_SHA256 0x030000A2
  381. # define TLS1_CK_DHE_DSS_WITH_AES_256_GCM_SHA384 0x030000A3
  382. # define TLS1_CK_DH_DSS_WITH_AES_128_GCM_SHA256 0x030000A4
  383. # define TLS1_CK_DH_DSS_WITH_AES_256_GCM_SHA384 0x030000A5
  384. # define TLS1_CK_ADH_WITH_AES_128_GCM_SHA256 0x030000A6
  385. # define TLS1_CK_ADH_WITH_AES_256_GCM_SHA384 0x030000A7
  386. /* CCM ciphersuites from RFC6655 */
  387. # define TLS1_CK_RSA_WITH_AES_128_CCM 0x0300C09C
  388. # define TLS1_CK_RSA_WITH_AES_256_CCM 0x0300C09D
  389. # define TLS1_CK_DHE_RSA_WITH_AES_128_CCM 0x0300C09E
  390. # define TLS1_CK_DHE_RSA_WITH_AES_256_CCM 0x0300C09F
  391. # define TLS1_CK_RSA_WITH_AES_128_CCM_8 0x0300C0A0
  392. # define TLS1_CK_RSA_WITH_AES_256_CCM_8 0x0300C0A1
  393. # define TLS1_CK_DHE_RSA_WITH_AES_128_CCM_8 0x0300C0A2
  394. # define TLS1_CK_DHE_RSA_WITH_AES_256_CCM_8 0x0300C0A3
  395. # define TLS1_CK_PSK_WITH_AES_128_CCM 0x0300C0A4
  396. # define TLS1_CK_PSK_WITH_AES_256_CCM 0x0300C0A5
  397. # define TLS1_CK_DHE_PSK_WITH_AES_128_CCM 0x0300C0A6
  398. # define TLS1_CK_DHE_PSK_WITH_AES_256_CCM 0x0300C0A7
  399. # define TLS1_CK_PSK_WITH_AES_128_CCM_8 0x0300C0A8
  400. # define TLS1_CK_PSK_WITH_AES_256_CCM_8 0x0300C0A9
  401. # define TLS1_CK_DHE_PSK_WITH_AES_128_CCM_8 0x0300C0AA
  402. # define TLS1_CK_DHE_PSK_WITH_AES_256_CCM_8 0x0300C0AB
  403. /* CCM ciphersuites from RFC7251 */
  404. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_128_CCM 0x0300C0AC
  405. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_256_CCM 0x0300C0AD
  406. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_128_CCM_8 0x0300C0AE
  407. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_256_CCM_8 0x0300C0AF
  408. /* TLS 1.2 Camellia SHA-256 ciphersuites from RFC5932 */
  409. # define TLS1_CK_RSA_WITH_CAMELLIA_128_CBC_SHA256 0x030000BA
  410. # define TLS1_CK_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256 0x030000BB
  411. # define TLS1_CK_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256 0x030000BC
  412. # define TLS1_CK_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256 0x030000BD
  413. # define TLS1_CK_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 0x030000BE
  414. # define TLS1_CK_ADH_WITH_CAMELLIA_128_CBC_SHA256 0x030000BF
  415. # define TLS1_CK_RSA_WITH_CAMELLIA_256_CBC_SHA256 0x030000C0
  416. # define TLS1_CK_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256 0x030000C1
  417. # define TLS1_CK_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256 0x030000C2
  418. # define TLS1_CK_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256 0x030000C3
  419. # define TLS1_CK_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 0x030000C4
  420. # define TLS1_CK_ADH_WITH_CAMELLIA_256_CBC_SHA256 0x030000C5
  421. /* ECC ciphersuites from RFC4492 */
  422. # define TLS1_CK_ECDH_ECDSA_WITH_NULL_SHA 0x0300C001
  423. # define TLS1_CK_ECDH_ECDSA_WITH_RC4_128_SHA 0x0300C002
  424. # define TLS1_CK_ECDH_ECDSA_WITH_DES_192_CBC3_SHA 0x0300C003
  425. # define TLS1_CK_ECDH_ECDSA_WITH_AES_128_CBC_SHA 0x0300C004
  426. # define TLS1_CK_ECDH_ECDSA_WITH_AES_256_CBC_SHA 0x0300C005
  427. # define TLS1_CK_ECDHE_ECDSA_WITH_NULL_SHA 0x0300C006
  428. # define TLS1_CK_ECDHE_ECDSA_WITH_RC4_128_SHA 0x0300C007
  429. # define TLS1_CK_ECDHE_ECDSA_WITH_DES_192_CBC3_SHA 0x0300C008
  430. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_128_CBC_SHA 0x0300C009
  431. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_256_CBC_SHA 0x0300C00A
  432. # define TLS1_CK_ECDH_RSA_WITH_NULL_SHA 0x0300C00B
  433. # define TLS1_CK_ECDH_RSA_WITH_RC4_128_SHA 0x0300C00C
  434. # define TLS1_CK_ECDH_RSA_WITH_DES_192_CBC3_SHA 0x0300C00D
  435. # define TLS1_CK_ECDH_RSA_WITH_AES_128_CBC_SHA 0x0300C00E
  436. # define TLS1_CK_ECDH_RSA_WITH_AES_256_CBC_SHA 0x0300C00F
  437. # define TLS1_CK_ECDHE_RSA_WITH_NULL_SHA 0x0300C010
  438. # define TLS1_CK_ECDHE_RSA_WITH_RC4_128_SHA 0x0300C011
  439. # define TLS1_CK_ECDHE_RSA_WITH_DES_192_CBC3_SHA 0x0300C012
  440. # define TLS1_CK_ECDHE_RSA_WITH_AES_128_CBC_SHA 0x0300C013
  441. # define TLS1_CK_ECDHE_RSA_WITH_AES_256_CBC_SHA 0x0300C014
  442. # define TLS1_CK_ECDH_anon_WITH_NULL_SHA 0x0300C015
  443. # define TLS1_CK_ECDH_anon_WITH_RC4_128_SHA 0x0300C016
  444. # define TLS1_CK_ECDH_anon_WITH_DES_192_CBC3_SHA 0x0300C017
  445. # define TLS1_CK_ECDH_anon_WITH_AES_128_CBC_SHA 0x0300C018
  446. # define TLS1_CK_ECDH_anon_WITH_AES_256_CBC_SHA 0x0300C019
  447. /* SRP ciphersuites from RFC 5054 */
  448. # define TLS1_CK_SRP_SHA_WITH_3DES_EDE_CBC_SHA 0x0300C01A
  449. # define TLS1_CK_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA 0x0300C01B
  450. # define TLS1_CK_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA 0x0300C01C
  451. # define TLS1_CK_SRP_SHA_WITH_AES_128_CBC_SHA 0x0300C01D
  452. # define TLS1_CK_SRP_SHA_RSA_WITH_AES_128_CBC_SHA 0x0300C01E
  453. # define TLS1_CK_SRP_SHA_DSS_WITH_AES_128_CBC_SHA 0x0300C01F
  454. # define TLS1_CK_SRP_SHA_WITH_AES_256_CBC_SHA 0x0300C020
  455. # define TLS1_CK_SRP_SHA_RSA_WITH_AES_256_CBC_SHA 0x0300C021
  456. # define TLS1_CK_SRP_SHA_DSS_WITH_AES_256_CBC_SHA 0x0300C022
  457. /* ECDH HMAC based ciphersuites from RFC5289 */
  458. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_128_SHA256 0x0300C023
  459. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_256_SHA384 0x0300C024
  460. # define TLS1_CK_ECDH_ECDSA_WITH_AES_128_SHA256 0x0300C025
  461. # define TLS1_CK_ECDH_ECDSA_WITH_AES_256_SHA384 0x0300C026
  462. # define TLS1_CK_ECDHE_RSA_WITH_AES_128_SHA256 0x0300C027
  463. # define TLS1_CK_ECDHE_RSA_WITH_AES_256_SHA384 0x0300C028
  464. # define TLS1_CK_ECDH_RSA_WITH_AES_128_SHA256 0x0300C029
  465. # define TLS1_CK_ECDH_RSA_WITH_AES_256_SHA384 0x0300C02A
  466. /* ECDH GCM based ciphersuites from RFC5289 */
  467. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 0x0300C02B
  468. # define TLS1_CK_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 0x0300C02C
  469. # define TLS1_CK_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 0x0300C02D
  470. # define TLS1_CK_ECDH_ECDSA_WITH_AES_256_GCM_SHA384 0x0300C02E
  471. # define TLS1_CK_ECDHE_RSA_WITH_AES_128_GCM_SHA256 0x0300C02F
  472. # define TLS1_CK_ECDHE_RSA_WITH_AES_256_GCM_SHA384 0x0300C030
  473. # define TLS1_CK_ECDH_RSA_WITH_AES_128_GCM_SHA256 0x0300C031
  474. # define TLS1_CK_ECDH_RSA_WITH_AES_256_GCM_SHA384 0x0300C032
  475. /* ECDHE PSK ciphersuites from RFC5489 */
  476. # define TLS1_CK_ECDHE_PSK_WITH_RC4_128_SHA 0x0300C033
  477. # define TLS1_CK_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA 0x0300C034
  478. # define TLS1_CK_ECDHE_PSK_WITH_AES_128_CBC_SHA 0x0300C035
  479. # define TLS1_CK_ECDHE_PSK_WITH_AES_256_CBC_SHA 0x0300C036
  480. # define TLS1_CK_ECDHE_PSK_WITH_AES_128_CBC_SHA256 0x0300C037
  481. # define TLS1_CK_ECDHE_PSK_WITH_AES_256_CBC_SHA384 0x0300C038
  482. /* NULL PSK ciphersuites from RFC4785 */
  483. # define TLS1_CK_ECDHE_PSK_WITH_NULL_SHA 0x0300C039
  484. # define TLS1_CK_ECDHE_PSK_WITH_NULL_SHA256 0x0300C03A
  485. # define TLS1_CK_ECDHE_PSK_WITH_NULL_SHA384 0x0300C03B
  486. /* Camellia-CBC ciphersuites from RFC6367 */
  487. # define TLS1_CK_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 0x0300C072
  488. # define TLS1_CK_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 0x0300C073
  489. # define TLS1_CK_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 0x0300C074
  490. # define TLS1_CK_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 0x0300C075
  491. # define TLS1_CK_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 0x0300C076
  492. # define TLS1_CK_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 0x0300C077
  493. # define TLS1_CK_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256 0x0300C078
  494. # define TLS1_CK_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384 0x0300C079
  495. # define TLS1_CK_PSK_WITH_CAMELLIA_128_CBC_SHA256 0x0300C094
  496. # define TLS1_CK_PSK_WITH_CAMELLIA_256_CBC_SHA384 0x0300C095
  497. # define TLS1_CK_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 0x0300C096
  498. # define TLS1_CK_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 0x0300C097
  499. # define TLS1_CK_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 0x0300C098
  500. # define TLS1_CK_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 0x0300C099
  501. # define TLS1_CK_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 0x0300C09A
  502. # define TLS1_CK_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 0x0300C09B
  503. /* draft-ietf-tls-chacha20-poly1305-03 */
  504. # define TLS1_CK_ECDHE_RSA_WITH_CHACHA20_POLY1305 0x0300CCA8
  505. # define TLS1_CK_ECDHE_ECDSA_WITH_CHACHA20_POLY1305 0x0300CCA9
  506. # define TLS1_CK_DHE_RSA_WITH_CHACHA20_POLY1305 0x0300CCAA
  507. # define TLS1_CK_PSK_WITH_CHACHA20_POLY1305 0x0300CCAB
  508. # define TLS1_CK_ECDHE_PSK_WITH_CHACHA20_POLY1305 0x0300CCAC
  509. # define TLS1_CK_DHE_PSK_WITH_CHACHA20_POLY1305 0x0300CCAD
  510. # define TLS1_CK_RSA_PSK_WITH_CHACHA20_POLY1305 0x0300CCAE
  511. /* TLS v1.3 ciphersuites */
  512. # define TLS1_3_CK_AES_128_GCM_SHA256 0x03001301
  513. # define TLS1_3_CK_AES_256_GCM_SHA384 0x03001302
  514. # define TLS1_3_CK_CHACHA20_POLY1305_SHA256 0x03001303
  515. # define TLS1_3_CK_AES_128_CCM_SHA256 0x03001304
  516. # define TLS1_3_CK_AES_128_CCM_8_SHA256 0x03001305
  517. /* Aria ciphersuites from RFC6209 */
  518. # define TLS1_CK_RSA_WITH_ARIA_128_GCM_SHA256 0x0300C050
  519. # define TLS1_CK_RSA_WITH_ARIA_256_GCM_SHA384 0x0300C051
  520. # define TLS1_CK_DHE_RSA_WITH_ARIA_128_GCM_SHA256 0x0300C052
  521. # define TLS1_CK_DHE_RSA_WITH_ARIA_256_GCM_SHA384 0x0300C053
  522. # define TLS1_CK_DH_RSA_WITH_ARIA_128_GCM_SHA256 0x0300C054
  523. # define TLS1_CK_DH_RSA_WITH_ARIA_256_GCM_SHA384 0x0300C055
  524. # define TLS1_CK_DHE_DSS_WITH_ARIA_128_GCM_SHA256 0x0300C056
  525. # define TLS1_CK_DHE_DSS_WITH_ARIA_256_GCM_SHA384 0x0300C057
  526. # define TLS1_CK_DH_DSS_WITH_ARIA_128_GCM_SHA256 0x0300C058
  527. # define TLS1_CK_DH_DSS_WITH_ARIA_256_GCM_SHA384 0x0300C059
  528. # define TLS1_CK_DH_anon_WITH_ARIA_128_GCM_SHA256 0x0300C05A
  529. # define TLS1_CK_DH_anon_WITH_ARIA_256_GCM_SHA384 0x0300C05B
  530. # define TLS1_CK_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256 0x0300C05C
  531. # define TLS1_CK_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384 0x0300C05D
  532. # define TLS1_CK_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256 0x0300C05E
  533. # define TLS1_CK_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384 0x0300C05F
  534. # define TLS1_CK_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256 0x0300C060
  535. # define TLS1_CK_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384 0x0300C061
  536. # define TLS1_CK_ECDH_RSA_WITH_ARIA_128_GCM_SHA256 0x0300C062
  537. # define TLS1_CK_ECDH_RSA_WITH_ARIA_256_GCM_SHA384 0x0300C063
  538. # define TLS1_CK_PSK_WITH_ARIA_128_GCM_SHA256 0x0300C06A
  539. # define TLS1_CK_PSK_WITH_ARIA_256_GCM_SHA384 0x0300C06B
  540. # define TLS1_CK_DHE_PSK_WITH_ARIA_128_GCM_SHA256 0x0300C06C
  541. # define TLS1_CK_DHE_PSK_WITH_ARIA_256_GCM_SHA384 0x0300C06D
  542. # define TLS1_CK_RSA_PSK_WITH_ARIA_128_GCM_SHA256 0x0300C06E
  543. # define TLS1_CK_RSA_PSK_WITH_ARIA_256_GCM_SHA384 0x0300C06F
  544. /* a bundle of RFC standard cipher names, generated from ssl3_ciphers[] */
  545. # define TLS1_RFC_RSA_WITH_AES_128_SHA "TLS_RSA_WITH_AES_128_CBC_SHA"
  546. # define TLS1_RFC_DHE_DSS_WITH_AES_128_SHA "TLS_DHE_DSS_WITH_AES_128_CBC_SHA"
  547. # define TLS1_RFC_DHE_RSA_WITH_AES_128_SHA "TLS_DHE_RSA_WITH_AES_128_CBC_SHA"
  548. # define TLS1_RFC_ADH_WITH_AES_128_SHA "TLS_DH_anon_WITH_AES_128_CBC_SHA"
  549. # define TLS1_RFC_RSA_WITH_AES_256_SHA "TLS_RSA_WITH_AES_256_CBC_SHA"
  550. # define TLS1_RFC_DHE_DSS_WITH_AES_256_SHA "TLS_DHE_DSS_WITH_AES_256_CBC_SHA"
  551. # define TLS1_RFC_DHE_RSA_WITH_AES_256_SHA "TLS_DHE_RSA_WITH_AES_256_CBC_SHA"
  552. # define TLS1_RFC_ADH_WITH_AES_256_SHA "TLS_DH_anon_WITH_AES_256_CBC_SHA"
  553. # define TLS1_RFC_RSA_WITH_NULL_SHA256 "TLS_RSA_WITH_NULL_SHA256"
  554. # define TLS1_RFC_RSA_WITH_AES_128_SHA256 "TLS_RSA_WITH_AES_128_CBC_SHA256"
  555. # define TLS1_RFC_RSA_WITH_AES_256_SHA256 "TLS_RSA_WITH_AES_256_CBC_SHA256"
  556. # define TLS1_RFC_DHE_DSS_WITH_AES_128_SHA256 "TLS_DHE_DSS_WITH_AES_128_CBC_SHA256"
  557. # define TLS1_RFC_DHE_RSA_WITH_AES_128_SHA256 "TLS_DHE_RSA_WITH_AES_128_CBC_SHA256"
  558. # define TLS1_RFC_DHE_DSS_WITH_AES_256_SHA256 "TLS_DHE_DSS_WITH_AES_256_CBC_SHA256"
  559. # define TLS1_RFC_DHE_RSA_WITH_AES_256_SHA256 "TLS_DHE_RSA_WITH_AES_256_CBC_SHA256"
  560. # define TLS1_RFC_ADH_WITH_AES_128_SHA256 "TLS_DH_anon_WITH_AES_128_CBC_SHA256"
  561. # define TLS1_RFC_ADH_WITH_AES_256_SHA256 "TLS_DH_anon_WITH_AES_256_CBC_SHA256"
  562. # define TLS1_RFC_RSA_WITH_AES_128_GCM_SHA256 "TLS_RSA_WITH_AES_128_GCM_SHA256"
  563. # define TLS1_RFC_RSA_WITH_AES_256_GCM_SHA384 "TLS_RSA_WITH_AES_256_GCM_SHA384"
  564. # define TLS1_RFC_DHE_RSA_WITH_AES_128_GCM_SHA256 "TLS_DHE_RSA_WITH_AES_128_GCM_SHA256"
  565. # define TLS1_RFC_DHE_RSA_WITH_AES_256_GCM_SHA384 "TLS_DHE_RSA_WITH_AES_256_GCM_SHA384"
  566. # define TLS1_RFC_DHE_DSS_WITH_AES_128_GCM_SHA256 "TLS_DHE_DSS_WITH_AES_128_GCM_SHA256"
  567. # define TLS1_RFC_DHE_DSS_WITH_AES_256_GCM_SHA384 "TLS_DHE_DSS_WITH_AES_256_GCM_SHA384"
  568. # define TLS1_RFC_ADH_WITH_AES_128_GCM_SHA256 "TLS_DH_anon_WITH_AES_128_GCM_SHA256"
  569. # define TLS1_RFC_ADH_WITH_AES_256_GCM_SHA384 "TLS_DH_anon_WITH_AES_256_GCM_SHA384"
  570. # define TLS1_RFC_RSA_WITH_AES_128_CCM "TLS_RSA_WITH_AES_128_CCM"
  571. # define TLS1_RFC_RSA_WITH_AES_256_CCM "TLS_RSA_WITH_AES_256_CCM"
  572. # define TLS1_RFC_DHE_RSA_WITH_AES_128_CCM "TLS_DHE_RSA_WITH_AES_128_CCM"
  573. # define TLS1_RFC_DHE_RSA_WITH_AES_256_CCM "TLS_DHE_RSA_WITH_AES_256_CCM"
  574. # define TLS1_RFC_RSA_WITH_AES_128_CCM_8 "TLS_RSA_WITH_AES_128_CCM_8"
  575. # define TLS1_RFC_RSA_WITH_AES_256_CCM_8 "TLS_RSA_WITH_AES_256_CCM_8"
  576. # define TLS1_RFC_DHE_RSA_WITH_AES_128_CCM_8 "TLS_DHE_RSA_WITH_AES_128_CCM_8"
  577. # define TLS1_RFC_DHE_RSA_WITH_AES_256_CCM_8 "TLS_DHE_RSA_WITH_AES_256_CCM_8"
  578. # define TLS1_RFC_PSK_WITH_AES_128_CCM "TLS_PSK_WITH_AES_128_CCM"
  579. # define TLS1_RFC_PSK_WITH_AES_256_CCM "TLS_PSK_WITH_AES_256_CCM"
  580. # define TLS1_RFC_DHE_PSK_WITH_AES_128_CCM "TLS_DHE_PSK_WITH_AES_128_CCM"
  581. # define TLS1_RFC_DHE_PSK_WITH_AES_256_CCM "TLS_DHE_PSK_WITH_AES_256_CCM"
  582. # define TLS1_RFC_PSK_WITH_AES_128_CCM_8 "TLS_PSK_WITH_AES_128_CCM_8"
  583. # define TLS1_RFC_PSK_WITH_AES_256_CCM_8 "TLS_PSK_WITH_AES_256_CCM_8"
  584. # define TLS1_RFC_DHE_PSK_WITH_AES_128_CCM_8 "TLS_PSK_DHE_WITH_AES_128_CCM_8"
  585. # define TLS1_RFC_DHE_PSK_WITH_AES_256_CCM_8 "TLS_PSK_DHE_WITH_AES_256_CCM_8"
  586. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_128_CCM "TLS_ECDHE_ECDSA_WITH_AES_128_CCM"
  587. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_256_CCM "TLS_ECDHE_ECDSA_WITH_AES_256_CCM"
  588. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_128_CCM_8 "TLS_ECDHE_ECDSA_WITH_AES_128_CCM_8"
  589. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_256_CCM_8 "TLS_ECDHE_ECDSA_WITH_AES_256_CCM_8"
  590. # define TLS1_3_RFC_AES_128_GCM_SHA256 "TLS_AES_128_GCM_SHA256"
  591. # define TLS1_3_RFC_AES_256_GCM_SHA384 "TLS_AES_256_GCM_SHA384"
  592. # define TLS1_3_RFC_CHACHA20_POLY1305_SHA256 "TLS_CHACHA20_POLY1305_SHA256"
  593. # define TLS1_3_RFC_AES_128_CCM_SHA256 "TLS_AES_128_CCM_SHA256"
  594. # define TLS1_3_RFC_AES_128_CCM_8_SHA256 "TLS_AES_128_CCM_8_SHA256"
  595. # define TLS1_RFC_ECDHE_ECDSA_WITH_NULL_SHA "TLS_ECDHE_ECDSA_WITH_NULL_SHA"
  596. # define TLS1_RFC_ECDHE_ECDSA_WITH_DES_192_CBC3_SHA "TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA"
  597. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_128_CBC_SHA "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA"
  598. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_256_CBC_SHA "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA"
  599. # define TLS1_RFC_ECDHE_RSA_WITH_NULL_SHA "TLS_ECDHE_RSA_WITH_NULL_SHA"
  600. # define TLS1_RFC_ECDHE_RSA_WITH_DES_192_CBC3_SHA "TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA"
  601. # define TLS1_RFC_ECDHE_RSA_WITH_AES_128_CBC_SHA "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA"
  602. # define TLS1_RFC_ECDHE_RSA_WITH_AES_256_CBC_SHA "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA"
  603. # define TLS1_RFC_ECDH_anon_WITH_NULL_SHA "TLS_ECDH_anon_WITH_NULL_SHA"
  604. # define TLS1_RFC_ECDH_anon_WITH_DES_192_CBC3_SHA "TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA"
  605. # define TLS1_RFC_ECDH_anon_WITH_AES_128_CBC_SHA "TLS_ECDH_anon_WITH_AES_128_CBC_SHA"
  606. # define TLS1_RFC_ECDH_anon_WITH_AES_256_CBC_SHA "TLS_ECDH_anon_WITH_AES_256_CBC_SHA"
  607. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_128_SHA256 "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256"
  608. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_256_SHA384 "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384"
  609. # define TLS1_RFC_ECDHE_RSA_WITH_AES_128_SHA256 "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256"
  610. # define TLS1_RFC_ECDHE_RSA_WITH_AES_256_SHA384 "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384"
  611. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256"
  612. # define TLS1_RFC_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384"
  613. # define TLS1_RFC_ECDHE_RSA_WITH_AES_128_GCM_SHA256 "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256"
  614. # define TLS1_RFC_ECDHE_RSA_WITH_AES_256_GCM_SHA384 "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384"
  615. # define TLS1_RFC_PSK_WITH_NULL_SHA "TLS_PSK_WITH_NULL_SHA"
  616. # define TLS1_RFC_DHE_PSK_WITH_NULL_SHA "TLS_DHE_PSK_WITH_NULL_SHA"
  617. # define TLS1_RFC_RSA_PSK_WITH_NULL_SHA "TLS_RSA_PSK_WITH_NULL_SHA"
  618. # define TLS1_RFC_PSK_WITH_3DES_EDE_CBC_SHA "TLS_PSK_WITH_3DES_EDE_CBC_SHA"
  619. # define TLS1_RFC_PSK_WITH_AES_128_CBC_SHA "TLS_PSK_WITH_AES_128_CBC_SHA"
  620. # define TLS1_RFC_PSK_WITH_AES_256_CBC_SHA "TLS_PSK_WITH_AES_256_CBC_SHA"
  621. # define TLS1_RFC_DHE_PSK_WITH_3DES_EDE_CBC_SHA "TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA"
  622. # define TLS1_RFC_DHE_PSK_WITH_AES_128_CBC_SHA "TLS_DHE_PSK_WITH_AES_128_CBC_SHA"
  623. # define TLS1_RFC_DHE_PSK_WITH_AES_256_CBC_SHA "TLS_DHE_PSK_WITH_AES_256_CBC_SHA"
  624. # define TLS1_RFC_RSA_PSK_WITH_3DES_EDE_CBC_SHA "TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA"
  625. # define TLS1_RFC_RSA_PSK_WITH_AES_128_CBC_SHA "TLS_RSA_PSK_WITH_AES_128_CBC_SHA"
  626. # define TLS1_RFC_RSA_PSK_WITH_AES_256_CBC_SHA "TLS_RSA_PSK_WITH_AES_256_CBC_SHA"
  627. # define TLS1_RFC_PSK_WITH_AES_128_GCM_SHA256 "TLS_PSK_WITH_AES_128_GCM_SHA256"
  628. # define TLS1_RFC_PSK_WITH_AES_256_GCM_SHA384 "TLS_PSK_WITH_AES_256_GCM_SHA384"
  629. # define TLS1_RFC_DHE_PSK_WITH_AES_128_GCM_SHA256 "TLS_DHE_PSK_WITH_AES_128_GCM_SHA256"
  630. # define TLS1_RFC_DHE_PSK_WITH_AES_256_GCM_SHA384 "TLS_DHE_PSK_WITH_AES_256_GCM_SHA384"
  631. # define TLS1_RFC_RSA_PSK_WITH_AES_128_GCM_SHA256 "TLS_RSA_PSK_WITH_AES_128_GCM_SHA256"
  632. # define TLS1_RFC_RSA_PSK_WITH_AES_256_GCM_SHA384 "TLS_RSA_PSK_WITH_AES_256_GCM_SHA384"
  633. # define TLS1_RFC_PSK_WITH_AES_128_CBC_SHA256 "TLS_PSK_WITH_AES_128_CBC_SHA256"
  634. # define TLS1_RFC_PSK_WITH_AES_256_CBC_SHA384 "TLS_PSK_WITH_AES_256_CBC_SHA384"
  635. # define TLS1_RFC_PSK_WITH_NULL_SHA256 "TLS_PSK_WITH_NULL_SHA256"
  636. # define TLS1_RFC_PSK_WITH_NULL_SHA384 "TLS_PSK_WITH_NULL_SHA384"
  637. # define TLS1_RFC_DHE_PSK_WITH_AES_128_CBC_SHA256 "TLS_DHE_PSK_WITH_AES_128_CBC_SHA256"
  638. # define TLS1_RFC_DHE_PSK_WITH_AES_256_CBC_SHA384 "TLS_DHE_PSK_WITH_AES_256_CBC_SHA384"
  639. # define TLS1_RFC_DHE_PSK_WITH_NULL_SHA256 "TLS_DHE_PSK_WITH_NULL_SHA256"
  640. # define TLS1_RFC_DHE_PSK_WITH_NULL_SHA384 "TLS_DHE_PSK_WITH_NULL_SHA384"
  641. # define TLS1_RFC_RSA_PSK_WITH_AES_128_CBC_SHA256 "TLS_RSA_PSK_WITH_AES_128_CBC_SHA256"
  642. # define TLS1_RFC_RSA_PSK_WITH_AES_256_CBC_SHA384 "TLS_RSA_PSK_WITH_AES_256_CBC_SHA384"
  643. # define TLS1_RFC_RSA_PSK_WITH_NULL_SHA256 "TLS_RSA_PSK_WITH_NULL_SHA256"
  644. # define TLS1_RFC_RSA_PSK_WITH_NULL_SHA384 "TLS_RSA_PSK_WITH_NULL_SHA384"
  645. # define TLS1_RFC_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA "TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA"
  646. # define TLS1_RFC_ECDHE_PSK_WITH_AES_128_CBC_SHA "TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA"
  647. # define TLS1_RFC_ECDHE_PSK_WITH_AES_256_CBC_SHA "TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA"
  648. # define TLS1_RFC_ECDHE_PSK_WITH_AES_128_CBC_SHA256 "TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256"
  649. # define TLS1_RFC_ECDHE_PSK_WITH_AES_256_CBC_SHA384 "TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384"
  650. # define TLS1_RFC_ECDHE_PSK_WITH_NULL_SHA "TLS_ECDHE_PSK_WITH_NULL_SHA"
  651. # define TLS1_RFC_ECDHE_PSK_WITH_NULL_SHA256 "TLS_ECDHE_PSK_WITH_NULL_SHA256"
  652. # define TLS1_RFC_ECDHE_PSK_WITH_NULL_SHA384 "TLS_ECDHE_PSK_WITH_NULL_SHA384"
  653. # define TLS1_RFC_SRP_SHA_WITH_3DES_EDE_CBC_SHA "TLS_SRP_SHA_WITH_3DES_EDE_CBC_SHA"
  654. # define TLS1_RFC_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA "TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA"
  655. # define TLS1_RFC_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA "TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA"
  656. # define TLS1_RFC_SRP_SHA_WITH_AES_128_CBC_SHA "TLS_SRP_SHA_WITH_AES_128_CBC_SHA"
  657. # define TLS1_RFC_SRP_SHA_RSA_WITH_AES_128_CBC_SHA "TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA"
  658. # define TLS1_RFC_SRP_SHA_DSS_WITH_AES_128_CBC_SHA "TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA"
  659. # define TLS1_RFC_SRP_SHA_WITH_AES_256_CBC_SHA "TLS_SRP_SHA_WITH_AES_256_CBC_SHA"
  660. # define TLS1_RFC_SRP_SHA_RSA_WITH_AES_256_CBC_SHA "TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA"
  661. # define TLS1_RFC_SRP_SHA_DSS_WITH_AES_256_CBC_SHA "TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA"
  662. # define TLS1_RFC_DHE_RSA_WITH_CHACHA20_POLY1305 "TLS_DHE_RSA_WITH_CHACHA20_POLY1305_SHA256"
  663. # define TLS1_RFC_ECDHE_RSA_WITH_CHACHA20_POLY1305 "TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"
  664. # define TLS1_RFC_ECDHE_ECDSA_WITH_CHACHA20_POLY1305 "TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256"
  665. # define TLS1_RFC_PSK_WITH_CHACHA20_POLY1305 "TLS_PSK_WITH_CHACHA20_POLY1305_SHA256"
  666. # define TLS1_RFC_ECDHE_PSK_WITH_CHACHA20_POLY1305 "TLS_ECDHE_PSK_WITH_CHACHA20_POLY1305_SHA256"
  667. # define TLS1_RFC_DHE_PSK_WITH_CHACHA20_POLY1305 "TLS_DHE_PSK_WITH_CHACHA20_POLY1305_SHA256"
  668. # define TLS1_RFC_RSA_PSK_WITH_CHACHA20_POLY1305 "TLS_RSA_PSK_WITH_CHACHA20_POLY1305_SHA256"
  669. # define TLS1_RFC_RSA_WITH_CAMELLIA_128_CBC_SHA256 "TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256"
  670. # define TLS1_RFC_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256 "TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256"
  671. # define TLS1_RFC_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 "TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256"
  672. # define TLS1_RFC_ADH_WITH_CAMELLIA_128_CBC_SHA256 "TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA256"
  673. # define TLS1_RFC_RSA_WITH_CAMELLIA_256_CBC_SHA256 "TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256"
  674. # define TLS1_RFC_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256 "TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256"
  675. # define TLS1_RFC_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 "TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256"
  676. # define TLS1_RFC_ADH_WITH_CAMELLIA_256_CBC_SHA256 "TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA256"
  677. # define TLS1_RFC_RSA_WITH_CAMELLIA_256_CBC_SHA "TLS_RSA_WITH_CAMELLIA_256_CBC_SHA"
  678. # define TLS1_RFC_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA "TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA"
  679. # define TLS1_RFC_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA "TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA"
  680. # define TLS1_RFC_ADH_WITH_CAMELLIA_256_CBC_SHA "TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA"
  681. # define TLS1_RFC_RSA_WITH_CAMELLIA_128_CBC_SHA "TLS_RSA_WITH_CAMELLIA_128_CBC_SHA"
  682. # define TLS1_RFC_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA "TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA"
  683. # define TLS1_RFC_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA "TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA"
  684. # define TLS1_RFC_ADH_WITH_CAMELLIA_128_CBC_SHA "TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA"
  685. # define TLS1_RFC_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 "TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256"
  686. # define TLS1_RFC_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 "TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384"
  687. # define TLS1_RFC_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 "TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256"
  688. # define TLS1_RFC_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 "TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384"
  689. # define TLS1_RFC_PSK_WITH_CAMELLIA_128_CBC_SHA256 "TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256"
  690. # define TLS1_RFC_PSK_WITH_CAMELLIA_256_CBC_SHA384 "TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384"
  691. # define TLS1_RFC_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 "TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256"
  692. # define TLS1_RFC_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 "TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384"
  693. # define TLS1_RFC_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 "TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256"
  694. # define TLS1_RFC_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 "TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384"
  695. # define TLS1_RFC_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 "TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256"
  696. # define TLS1_RFC_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 "TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384"
  697. # define TLS1_RFC_RSA_WITH_SEED_SHA "TLS_RSA_WITH_SEED_CBC_SHA"
  698. # define TLS1_RFC_DHE_DSS_WITH_SEED_SHA "TLS_DHE_DSS_WITH_SEED_CBC_SHA"
  699. # define TLS1_RFC_DHE_RSA_WITH_SEED_SHA "TLS_DHE_RSA_WITH_SEED_CBC_SHA"
  700. # define TLS1_RFC_ADH_WITH_SEED_SHA "TLS_DH_anon_WITH_SEED_CBC_SHA"
  701. # define TLS1_RFC_ECDHE_PSK_WITH_RC4_128_SHA "TLS_ECDHE_PSK_WITH_RC4_128_SHA"
  702. # define TLS1_RFC_ECDH_anon_WITH_RC4_128_SHA "TLS_ECDH_anon_WITH_RC4_128_SHA"
  703. # define TLS1_RFC_ECDHE_ECDSA_WITH_RC4_128_SHA "TLS_ECDHE_ECDSA_WITH_RC4_128_SHA"
  704. # define TLS1_RFC_ECDHE_RSA_WITH_RC4_128_SHA "TLS_ECDHE_RSA_WITH_RC4_128_SHA"
  705. # define TLS1_RFC_PSK_WITH_RC4_128_SHA "TLS_PSK_WITH_RC4_128_SHA"
  706. # define TLS1_RFC_RSA_PSK_WITH_RC4_128_SHA "TLS_RSA_PSK_WITH_RC4_128_SHA"
  707. # define TLS1_RFC_DHE_PSK_WITH_RC4_128_SHA "TLS_DHE_PSK_WITH_RC4_128_SHA"
  708. # define TLS1_RFC_RSA_WITH_ARIA_128_GCM_SHA256 "TLS_RSA_WITH_ARIA_128_GCM_SHA256"
  709. # define TLS1_RFC_RSA_WITH_ARIA_256_GCM_SHA384 "TLS_RSA_WITH_ARIA_256_GCM_SHA384"
  710. # define TLS1_RFC_DHE_RSA_WITH_ARIA_128_GCM_SHA256 "TLS_DHE_RSA_WITH_ARIA_128_GCM_SHA256"
  711. # define TLS1_RFC_DHE_RSA_WITH_ARIA_256_GCM_SHA384 "TLS_DHE_RSA_WITH_ARIA_256_GCM_SHA384"
  712. # define TLS1_RFC_DH_RSA_WITH_ARIA_128_GCM_SHA256 "TLS_DH_RSA_WITH_ARIA_128_GCM_SHA256"
  713. # define TLS1_RFC_DH_RSA_WITH_ARIA_256_GCM_SHA384 "TLS_DH_RSA_WITH_ARIA_256_GCM_SHA384"
  714. # define TLS1_RFC_DHE_DSS_WITH_ARIA_128_GCM_SHA256 "TLS_DHE_DSS_WITH_ARIA_128_GCM_SHA256"
  715. # define TLS1_RFC_DHE_DSS_WITH_ARIA_256_GCM_SHA384 "TLS_DHE_DSS_WITH_ARIA_256_GCM_SHA384"
  716. # define TLS1_RFC_DH_DSS_WITH_ARIA_128_GCM_SHA256 "TLS_DH_DSS_WITH_ARIA_128_GCM_SHA256"
  717. # define TLS1_RFC_DH_DSS_WITH_ARIA_256_GCM_SHA384 "TLS_DH_DSS_WITH_ARIA_256_GCM_SHA384"
  718. # define TLS1_RFC_DH_anon_WITH_ARIA_128_GCM_SHA256 "TLS_DH_anon_WITH_ARIA_128_GCM_SHA256"
  719. # define TLS1_RFC_DH_anon_WITH_ARIA_256_GCM_SHA384 "TLS_DH_anon_WITH_ARIA_256_GCM_SHA384"
  720. # define TLS1_RFC_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256 "TLS_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256"
  721. # define TLS1_RFC_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384 "TLS_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384"
  722. # define TLS1_RFC_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256 "TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256"
  723. # define TLS1_RFC_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384 "TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384"
  724. # define TLS1_RFC_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256 "TLS_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256"
  725. # define TLS1_RFC_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384 "TLS_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384"
  726. # define TLS1_RFC_ECDH_RSA_WITH_ARIA_128_GCM_SHA256 "TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256"
  727. # define TLS1_RFC_ECDH_RSA_WITH_ARIA_256_GCM_SHA384 "TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384"
  728. # define TLS1_RFC_PSK_WITH_ARIA_128_GCM_SHA256 "TLS_PSK_WITH_ARIA_128_GCM_SHA256"
  729. # define TLS1_RFC_PSK_WITH_ARIA_256_GCM_SHA384 "TLS_PSK_WITH_ARIA_256_GCM_SHA384"
  730. # define TLS1_RFC_DHE_PSK_WITH_ARIA_128_GCM_SHA256 "TLS_DHE_PSK_WITH_ARIA_128_GCM_SHA256"
  731. # define TLS1_RFC_DHE_PSK_WITH_ARIA_256_GCM_SHA384 "TLS_DHE_PSK_WITH_ARIA_256_GCM_SHA384"
  732. # define TLS1_RFC_RSA_PSK_WITH_ARIA_128_GCM_SHA256 "TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256"
  733. # define TLS1_RFC_RSA_PSK_WITH_ARIA_256_GCM_SHA384 "TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384"
  734. /*
  735. * XXX Backward compatibility alert: Older versions of OpenSSL gave some DHE
  736. * ciphers names with "EDH" instead of "DHE". Going forward, we should be
  737. * using DHE everywhere, though we may indefinitely maintain aliases for
  738. * users or configurations that used "EDH"
  739. */
  740. # define TLS1_TXT_DHE_DSS_WITH_RC4_128_SHA "DHE-DSS-RC4-SHA"
  741. # define TLS1_TXT_PSK_WITH_NULL_SHA "PSK-NULL-SHA"
  742. # define TLS1_TXT_DHE_PSK_WITH_NULL_SHA "DHE-PSK-NULL-SHA"
  743. # define TLS1_TXT_RSA_PSK_WITH_NULL_SHA "RSA-PSK-NULL-SHA"
  744. /* AES ciphersuites from RFC3268 */
  745. # define TLS1_TXT_RSA_WITH_AES_128_SHA "AES128-SHA"
  746. # define TLS1_TXT_DH_DSS_WITH_AES_128_SHA "DH-DSS-AES128-SHA"
  747. # define TLS1_TXT_DH_RSA_WITH_AES_128_SHA "DH-RSA-AES128-SHA"
  748. # define TLS1_TXT_DHE_DSS_WITH_AES_128_SHA "DHE-DSS-AES128-SHA"
  749. # define TLS1_TXT_DHE_RSA_WITH_AES_128_SHA "DHE-RSA-AES128-SHA"
  750. # define TLS1_TXT_ADH_WITH_AES_128_SHA "ADH-AES128-SHA"
  751. # define TLS1_TXT_RSA_WITH_AES_256_SHA "AES256-SHA"
  752. # define TLS1_TXT_DH_DSS_WITH_AES_256_SHA "DH-DSS-AES256-SHA"
  753. # define TLS1_TXT_DH_RSA_WITH_AES_256_SHA "DH-RSA-AES256-SHA"
  754. # define TLS1_TXT_DHE_DSS_WITH_AES_256_SHA "DHE-DSS-AES256-SHA"
  755. # define TLS1_TXT_DHE_RSA_WITH_AES_256_SHA "DHE-RSA-AES256-SHA"
  756. # define TLS1_TXT_ADH_WITH_AES_256_SHA "ADH-AES256-SHA"
  757. /* ECC ciphersuites from RFC4492 */
  758. # define TLS1_TXT_ECDH_ECDSA_WITH_NULL_SHA "ECDH-ECDSA-NULL-SHA"
  759. # define TLS1_TXT_ECDH_ECDSA_WITH_RC4_128_SHA "ECDH-ECDSA-RC4-SHA"
  760. # define TLS1_TXT_ECDH_ECDSA_WITH_DES_192_CBC3_SHA "ECDH-ECDSA-DES-CBC3-SHA"
  761. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_128_CBC_SHA "ECDH-ECDSA-AES128-SHA"
  762. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_256_CBC_SHA "ECDH-ECDSA-AES256-SHA"
  763. # define TLS1_TXT_ECDHE_ECDSA_WITH_NULL_SHA "ECDHE-ECDSA-NULL-SHA"
  764. # define TLS1_TXT_ECDHE_ECDSA_WITH_RC4_128_SHA "ECDHE-ECDSA-RC4-SHA"
  765. # define TLS1_TXT_ECDHE_ECDSA_WITH_DES_192_CBC3_SHA "ECDHE-ECDSA-DES-CBC3-SHA"
  766. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_128_CBC_SHA "ECDHE-ECDSA-AES128-SHA"
  767. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_256_CBC_SHA "ECDHE-ECDSA-AES256-SHA"
  768. # define TLS1_TXT_ECDH_RSA_WITH_NULL_SHA "ECDH-RSA-NULL-SHA"
  769. # define TLS1_TXT_ECDH_RSA_WITH_RC4_128_SHA "ECDH-RSA-RC4-SHA"
  770. # define TLS1_TXT_ECDH_RSA_WITH_DES_192_CBC3_SHA "ECDH-RSA-DES-CBC3-SHA"
  771. # define TLS1_TXT_ECDH_RSA_WITH_AES_128_CBC_SHA "ECDH-RSA-AES128-SHA"
  772. # define TLS1_TXT_ECDH_RSA_WITH_AES_256_CBC_SHA "ECDH-RSA-AES256-SHA"
  773. # define TLS1_TXT_ECDHE_RSA_WITH_NULL_SHA "ECDHE-RSA-NULL-SHA"
  774. # define TLS1_TXT_ECDHE_RSA_WITH_RC4_128_SHA "ECDHE-RSA-RC4-SHA"
  775. # define TLS1_TXT_ECDHE_RSA_WITH_DES_192_CBC3_SHA "ECDHE-RSA-DES-CBC3-SHA"
  776. # define TLS1_TXT_ECDHE_RSA_WITH_AES_128_CBC_SHA "ECDHE-RSA-AES128-SHA"
  777. # define TLS1_TXT_ECDHE_RSA_WITH_AES_256_CBC_SHA "ECDHE-RSA-AES256-SHA"
  778. # define TLS1_TXT_ECDH_anon_WITH_NULL_SHA "AECDH-NULL-SHA"
  779. # define TLS1_TXT_ECDH_anon_WITH_RC4_128_SHA "AECDH-RC4-SHA"
  780. # define TLS1_TXT_ECDH_anon_WITH_DES_192_CBC3_SHA "AECDH-DES-CBC3-SHA"
  781. # define TLS1_TXT_ECDH_anon_WITH_AES_128_CBC_SHA "AECDH-AES128-SHA"
  782. # define TLS1_TXT_ECDH_anon_WITH_AES_256_CBC_SHA "AECDH-AES256-SHA"
  783. /* PSK ciphersuites from RFC 4279 */
  784. # define TLS1_TXT_PSK_WITH_RC4_128_SHA "PSK-RC4-SHA"
  785. # define TLS1_TXT_PSK_WITH_3DES_EDE_CBC_SHA "PSK-3DES-EDE-CBC-SHA"
  786. # define TLS1_TXT_PSK_WITH_AES_128_CBC_SHA "PSK-AES128-CBC-SHA"
  787. # define TLS1_TXT_PSK_WITH_AES_256_CBC_SHA "PSK-AES256-CBC-SHA"
  788. # define TLS1_TXT_DHE_PSK_WITH_RC4_128_SHA "DHE-PSK-RC4-SHA"
  789. # define TLS1_TXT_DHE_PSK_WITH_3DES_EDE_CBC_SHA "DHE-PSK-3DES-EDE-CBC-SHA"
  790. # define TLS1_TXT_DHE_PSK_WITH_AES_128_CBC_SHA "DHE-PSK-AES128-CBC-SHA"
  791. # define TLS1_TXT_DHE_PSK_WITH_AES_256_CBC_SHA "DHE-PSK-AES256-CBC-SHA"
  792. # define TLS1_TXT_RSA_PSK_WITH_RC4_128_SHA "RSA-PSK-RC4-SHA"
  793. # define TLS1_TXT_RSA_PSK_WITH_3DES_EDE_CBC_SHA "RSA-PSK-3DES-EDE-CBC-SHA"
  794. # define TLS1_TXT_RSA_PSK_WITH_AES_128_CBC_SHA "RSA-PSK-AES128-CBC-SHA"
  795. # define TLS1_TXT_RSA_PSK_WITH_AES_256_CBC_SHA "RSA-PSK-AES256-CBC-SHA"
  796. /* PSK ciphersuites from RFC 5487 */
  797. # define TLS1_TXT_PSK_WITH_AES_128_GCM_SHA256 "PSK-AES128-GCM-SHA256"
  798. # define TLS1_TXT_PSK_WITH_AES_256_GCM_SHA384 "PSK-AES256-GCM-SHA384"
  799. # define TLS1_TXT_DHE_PSK_WITH_AES_128_GCM_SHA256 "DHE-PSK-AES128-GCM-SHA256"
  800. # define TLS1_TXT_DHE_PSK_WITH_AES_256_GCM_SHA384 "DHE-PSK-AES256-GCM-SHA384"
  801. # define TLS1_TXT_RSA_PSK_WITH_AES_128_GCM_SHA256 "RSA-PSK-AES128-GCM-SHA256"
  802. # define TLS1_TXT_RSA_PSK_WITH_AES_256_GCM_SHA384 "RSA-PSK-AES256-GCM-SHA384"
  803. # define TLS1_TXT_PSK_WITH_AES_128_CBC_SHA256 "PSK-AES128-CBC-SHA256"
  804. # define TLS1_TXT_PSK_WITH_AES_256_CBC_SHA384 "PSK-AES256-CBC-SHA384"
  805. # define TLS1_TXT_PSK_WITH_NULL_SHA256 "PSK-NULL-SHA256"
  806. # define TLS1_TXT_PSK_WITH_NULL_SHA384 "PSK-NULL-SHA384"
  807. # define TLS1_TXT_DHE_PSK_WITH_AES_128_CBC_SHA256 "DHE-PSK-AES128-CBC-SHA256"
  808. # define TLS1_TXT_DHE_PSK_WITH_AES_256_CBC_SHA384 "DHE-PSK-AES256-CBC-SHA384"
  809. # define TLS1_TXT_DHE_PSK_WITH_NULL_SHA256 "DHE-PSK-NULL-SHA256"
  810. # define TLS1_TXT_DHE_PSK_WITH_NULL_SHA384 "DHE-PSK-NULL-SHA384"
  811. # define TLS1_TXT_RSA_PSK_WITH_AES_128_CBC_SHA256 "RSA-PSK-AES128-CBC-SHA256"
  812. # define TLS1_TXT_RSA_PSK_WITH_AES_256_CBC_SHA384 "RSA-PSK-AES256-CBC-SHA384"
  813. # define TLS1_TXT_RSA_PSK_WITH_NULL_SHA256 "RSA-PSK-NULL-SHA256"
  814. # define TLS1_TXT_RSA_PSK_WITH_NULL_SHA384 "RSA-PSK-NULL-SHA384"
  815. /* SRP ciphersuite from RFC 5054 */
  816. # define TLS1_TXT_SRP_SHA_WITH_3DES_EDE_CBC_SHA "SRP-3DES-EDE-CBC-SHA"
  817. # define TLS1_TXT_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA "SRP-RSA-3DES-EDE-CBC-SHA"
  818. # define TLS1_TXT_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA "SRP-DSS-3DES-EDE-CBC-SHA"
  819. # define TLS1_TXT_SRP_SHA_WITH_AES_128_CBC_SHA "SRP-AES-128-CBC-SHA"
  820. # define TLS1_TXT_SRP_SHA_RSA_WITH_AES_128_CBC_SHA "SRP-RSA-AES-128-CBC-SHA"
  821. # define TLS1_TXT_SRP_SHA_DSS_WITH_AES_128_CBC_SHA "SRP-DSS-AES-128-CBC-SHA"
  822. # define TLS1_TXT_SRP_SHA_WITH_AES_256_CBC_SHA "SRP-AES-256-CBC-SHA"
  823. # define TLS1_TXT_SRP_SHA_RSA_WITH_AES_256_CBC_SHA "SRP-RSA-AES-256-CBC-SHA"
  824. # define TLS1_TXT_SRP_SHA_DSS_WITH_AES_256_CBC_SHA "SRP-DSS-AES-256-CBC-SHA"
  825. /* Camellia ciphersuites from RFC4132 */
  826. # define TLS1_TXT_RSA_WITH_CAMELLIA_128_CBC_SHA "CAMELLIA128-SHA"
  827. # define TLS1_TXT_DH_DSS_WITH_CAMELLIA_128_CBC_SHA "DH-DSS-CAMELLIA128-SHA"
  828. # define TLS1_TXT_DH_RSA_WITH_CAMELLIA_128_CBC_SHA "DH-RSA-CAMELLIA128-SHA"
  829. # define TLS1_TXT_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA "DHE-DSS-CAMELLIA128-SHA"
  830. # define TLS1_TXT_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA "DHE-RSA-CAMELLIA128-SHA"
  831. # define TLS1_TXT_ADH_WITH_CAMELLIA_128_CBC_SHA "ADH-CAMELLIA128-SHA"
  832. # define TLS1_TXT_RSA_WITH_CAMELLIA_256_CBC_SHA "CAMELLIA256-SHA"
  833. # define TLS1_TXT_DH_DSS_WITH_CAMELLIA_256_CBC_SHA "DH-DSS-CAMELLIA256-SHA"
  834. # define TLS1_TXT_DH_RSA_WITH_CAMELLIA_256_CBC_SHA "DH-RSA-CAMELLIA256-SHA"
  835. # define TLS1_TXT_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA "DHE-DSS-CAMELLIA256-SHA"
  836. # define TLS1_TXT_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA "DHE-RSA-CAMELLIA256-SHA"
  837. # define TLS1_TXT_ADH_WITH_CAMELLIA_256_CBC_SHA "ADH-CAMELLIA256-SHA"
  838. /* TLS 1.2 Camellia SHA-256 ciphersuites from RFC5932 */
  839. # define TLS1_TXT_RSA_WITH_CAMELLIA_128_CBC_SHA256 "CAMELLIA128-SHA256"
  840. # define TLS1_TXT_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256 "DH-DSS-CAMELLIA128-SHA256"
  841. # define TLS1_TXT_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256 "DH-RSA-CAMELLIA128-SHA256"
  842. # define TLS1_TXT_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256 "DHE-DSS-CAMELLIA128-SHA256"
  843. # define TLS1_TXT_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 "DHE-RSA-CAMELLIA128-SHA256"
  844. # define TLS1_TXT_ADH_WITH_CAMELLIA_128_CBC_SHA256 "ADH-CAMELLIA128-SHA256"
  845. # define TLS1_TXT_RSA_WITH_CAMELLIA_256_CBC_SHA256 "CAMELLIA256-SHA256"
  846. # define TLS1_TXT_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256 "DH-DSS-CAMELLIA256-SHA256"
  847. # define TLS1_TXT_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256 "DH-RSA-CAMELLIA256-SHA256"
  848. # define TLS1_TXT_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256 "DHE-DSS-CAMELLIA256-SHA256"
  849. # define TLS1_TXT_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 "DHE-RSA-CAMELLIA256-SHA256"
  850. # define TLS1_TXT_ADH_WITH_CAMELLIA_256_CBC_SHA256 "ADH-CAMELLIA256-SHA256"
  851. # define TLS1_TXT_PSK_WITH_CAMELLIA_128_CBC_SHA256 "PSK-CAMELLIA128-SHA256"
  852. # define TLS1_TXT_PSK_WITH_CAMELLIA_256_CBC_SHA384 "PSK-CAMELLIA256-SHA384"
  853. # define TLS1_TXT_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 "DHE-PSK-CAMELLIA128-SHA256"
  854. # define TLS1_TXT_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 "DHE-PSK-CAMELLIA256-SHA384"
  855. # define TLS1_TXT_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 "RSA-PSK-CAMELLIA128-SHA256"
  856. # define TLS1_TXT_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 "RSA-PSK-CAMELLIA256-SHA384"
  857. # define TLS1_TXT_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 "ECDHE-PSK-CAMELLIA128-SHA256"
  858. # define TLS1_TXT_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 "ECDHE-PSK-CAMELLIA256-SHA384"
  859. /* SEED ciphersuites from RFC4162 */
  860. # define TLS1_TXT_RSA_WITH_SEED_SHA "SEED-SHA"
  861. # define TLS1_TXT_DH_DSS_WITH_SEED_SHA "DH-DSS-SEED-SHA"
  862. # define TLS1_TXT_DH_RSA_WITH_SEED_SHA "DH-RSA-SEED-SHA"
  863. # define TLS1_TXT_DHE_DSS_WITH_SEED_SHA "DHE-DSS-SEED-SHA"
  864. # define TLS1_TXT_DHE_RSA_WITH_SEED_SHA "DHE-RSA-SEED-SHA"
  865. # define TLS1_TXT_ADH_WITH_SEED_SHA "ADH-SEED-SHA"
  866. /* TLS v1.2 ciphersuites */
  867. # define TLS1_TXT_RSA_WITH_NULL_SHA256 "NULL-SHA256"
  868. # define TLS1_TXT_RSA_WITH_AES_128_SHA256 "AES128-SHA256"
  869. # define TLS1_TXT_RSA_WITH_AES_256_SHA256 "AES256-SHA256"
  870. # define TLS1_TXT_DH_DSS_WITH_AES_128_SHA256 "DH-DSS-AES128-SHA256"
  871. # define TLS1_TXT_DH_RSA_WITH_AES_128_SHA256 "DH-RSA-AES128-SHA256"
  872. # define TLS1_TXT_DHE_DSS_WITH_AES_128_SHA256 "DHE-DSS-AES128-SHA256"
  873. # define TLS1_TXT_DHE_RSA_WITH_AES_128_SHA256 "DHE-RSA-AES128-SHA256"
  874. # define TLS1_TXT_DH_DSS_WITH_AES_256_SHA256 "DH-DSS-AES256-SHA256"
  875. # define TLS1_TXT_DH_RSA_WITH_AES_256_SHA256 "DH-RSA-AES256-SHA256"
  876. # define TLS1_TXT_DHE_DSS_WITH_AES_256_SHA256 "DHE-DSS-AES256-SHA256"
  877. # define TLS1_TXT_DHE_RSA_WITH_AES_256_SHA256 "DHE-RSA-AES256-SHA256"
  878. # define TLS1_TXT_ADH_WITH_AES_128_SHA256 "ADH-AES128-SHA256"
  879. # define TLS1_TXT_ADH_WITH_AES_256_SHA256 "ADH-AES256-SHA256"
  880. /* TLS v1.2 GCM ciphersuites from RFC5288 */
  881. # define TLS1_TXT_RSA_WITH_AES_128_GCM_SHA256 "AES128-GCM-SHA256"
  882. # define TLS1_TXT_RSA_WITH_AES_256_GCM_SHA384 "AES256-GCM-SHA384"
  883. # define TLS1_TXT_DHE_RSA_WITH_AES_128_GCM_SHA256 "DHE-RSA-AES128-GCM-SHA256"
  884. # define TLS1_TXT_DHE_RSA_WITH_AES_256_GCM_SHA384 "DHE-RSA-AES256-GCM-SHA384"
  885. # define TLS1_TXT_DH_RSA_WITH_AES_128_GCM_SHA256 "DH-RSA-AES128-GCM-SHA256"
  886. # define TLS1_TXT_DH_RSA_WITH_AES_256_GCM_SHA384 "DH-RSA-AES256-GCM-SHA384"
  887. # define TLS1_TXT_DHE_DSS_WITH_AES_128_GCM_SHA256 "DHE-DSS-AES128-GCM-SHA256"
  888. # define TLS1_TXT_DHE_DSS_WITH_AES_256_GCM_SHA384 "DHE-DSS-AES256-GCM-SHA384"
  889. # define TLS1_TXT_DH_DSS_WITH_AES_128_GCM_SHA256 "DH-DSS-AES128-GCM-SHA256"
  890. # define TLS1_TXT_DH_DSS_WITH_AES_256_GCM_SHA384 "DH-DSS-AES256-GCM-SHA384"
  891. # define TLS1_TXT_ADH_WITH_AES_128_GCM_SHA256 "ADH-AES128-GCM-SHA256"
  892. # define TLS1_TXT_ADH_WITH_AES_256_GCM_SHA384 "ADH-AES256-GCM-SHA384"
  893. /* CCM ciphersuites from RFC6655 */
  894. # define TLS1_TXT_RSA_WITH_AES_128_CCM "AES128-CCM"
  895. # define TLS1_TXT_RSA_WITH_AES_256_CCM "AES256-CCM"
  896. # define TLS1_TXT_DHE_RSA_WITH_AES_128_CCM "DHE-RSA-AES128-CCM"
  897. # define TLS1_TXT_DHE_RSA_WITH_AES_256_CCM "DHE-RSA-AES256-CCM"
  898. # define TLS1_TXT_RSA_WITH_AES_128_CCM_8 "AES128-CCM8"
  899. # define TLS1_TXT_RSA_WITH_AES_256_CCM_8 "AES256-CCM8"
  900. # define TLS1_TXT_DHE_RSA_WITH_AES_128_CCM_8 "DHE-RSA-AES128-CCM8"
  901. # define TLS1_TXT_DHE_RSA_WITH_AES_256_CCM_8 "DHE-RSA-AES256-CCM8"
  902. # define TLS1_TXT_PSK_WITH_AES_128_CCM "PSK-AES128-CCM"
  903. # define TLS1_TXT_PSK_WITH_AES_256_CCM "PSK-AES256-CCM"
  904. # define TLS1_TXT_DHE_PSK_WITH_AES_128_CCM "DHE-PSK-AES128-CCM"
  905. # define TLS1_TXT_DHE_PSK_WITH_AES_256_CCM "DHE-PSK-AES256-CCM"
  906. # define TLS1_TXT_PSK_WITH_AES_128_CCM_8 "PSK-AES128-CCM8"
  907. # define TLS1_TXT_PSK_WITH_AES_256_CCM_8 "PSK-AES256-CCM8"
  908. # define TLS1_TXT_DHE_PSK_WITH_AES_128_CCM_8 "DHE-PSK-AES128-CCM8"
  909. # define TLS1_TXT_DHE_PSK_WITH_AES_256_CCM_8 "DHE-PSK-AES256-CCM8"
  910. /* CCM ciphersuites from RFC7251 */
  911. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_128_CCM "ECDHE-ECDSA-AES128-CCM"
  912. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_256_CCM "ECDHE-ECDSA-AES256-CCM"
  913. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_128_CCM_8 "ECDHE-ECDSA-AES128-CCM8"
  914. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_256_CCM_8 "ECDHE-ECDSA-AES256-CCM8"
  915. /* ECDH HMAC based ciphersuites from RFC5289 */
  916. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_128_SHA256 "ECDHE-ECDSA-AES128-SHA256"
  917. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_256_SHA384 "ECDHE-ECDSA-AES256-SHA384"
  918. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_128_SHA256 "ECDH-ECDSA-AES128-SHA256"
  919. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_256_SHA384 "ECDH-ECDSA-AES256-SHA384"
  920. # define TLS1_TXT_ECDHE_RSA_WITH_AES_128_SHA256 "ECDHE-RSA-AES128-SHA256"
  921. # define TLS1_TXT_ECDHE_RSA_WITH_AES_256_SHA384 "ECDHE-RSA-AES256-SHA384"
  922. # define TLS1_TXT_ECDH_RSA_WITH_AES_128_SHA256 "ECDH-RSA-AES128-SHA256"
  923. # define TLS1_TXT_ECDH_RSA_WITH_AES_256_SHA384 "ECDH-RSA-AES256-SHA384"
  924. /* ECDH GCM based ciphersuites from RFC5289 */
  925. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 "ECDHE-ECDSA-AES128-GCM-SHA256"
  926. # define TLS1_TXT_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 "ECDHE-ECDSA-AES256-GCM-SHA384"
  927. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 "ECDH-ECDSA-AES128-GCM-SHA256"
  928. # define TLS1_TXT_ECDH_ECDSA_WITH_AES_256_GCM_SHA384 "ECDH-ECDSA-AES256-GCM-SHA384"
  929. # define TLS1_TXT_ECDHE_RSA_WITH_AES_128_GCM_SHA256 "ECDHE-RSA-AES128-GCM-SHA256"
  930. # define TLS1_TXT_ECDHE_RSA_WITH_AES_256_GCM_SHA384 "ECDHE-RSA-AES256-GCM-SHA384"
  931. # define TLS1_TXT_ECDH_RSA_WITH_AES_128_GCM_SHA256 "ECDH-RSA-AES128-GCM-SHA256"
  932. # define TLS1_TXT_ECDH_RSA_WITH_AES_256_GCM_SHA384 "ECDH-RSA-AES256-GCM-SHA384"
  933. /* TLS v1.2 PSK GCM ciphersuites from RFC5487 */
  934. # define TLS1_TXT_PSK_WITH_AES_128_GCM_SHA256 "PSK-AES128-GCM-SHA256"
  935. # define TLS1_TXT_PSK_WITH_AES_256_GCM_SHA384 "PSK-AES256-GCM-SHA384"
  936. /* ECDHE PSK ciphersuites from RFC 5489 */
  937. # define TLS1_TXT_ECDHE_PSK_WITH_RC4_128_SHA "ECDHE-PSK-RC4-SHA"
  938. # define TLS1_TXT_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA "ECDHE-PSK-3DES-EDE-CBC-SHA"
  939. # define TLS1_TXT_ECDHE_PSK_WITH_AES_128_CBC_SHA "ECDHE-PSK-AES128-CBC-SHA"
  940. # define TLS1_TXT_ECDHE_PSK_WITH_AES_256_CBC_SHA "ECDHE-PSK-AES256-CBC-SHA"
  941. # define TLS1_TXT_ECDHE_PSK_WITH_AES_128_CBC_SHA256 "ECDHE-PSK-AES128-CBC-SHA256"
  942. # define TLS1_TXT_ECDHE_PSK_WITH_AES_256_CBC_SHA384 "ECDHE-PSK-AES256-CBC-SHA384"
  943. # define TLS1_TXT_ECDHE_PSK_WITH_NULL_SHA "ECDHE-PSK-NULL-SHA"
  944. # define TLS1_TXT_ECDHE_PSK_WITH_NULL_SHA256 "ECDHE-PSK-NULL-SHA256"
  945. # define TLS1_TXT_ECDHE_PSK_WITH_NULL_SHA384 "ECDHE-PSK-NULL-SHA384"
  946. /* Camellia-CBC ciphersuites from RFC6367 */
  947. # define TLS1_TXT_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 "ECDHE-ECDSA-CAMELLIA128-SHA256"
  948. # define TLS1_TXT_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 "ECDHE-ECDSA-CAMELLIA256-SHA384"
  949. # define TLS1_TXT_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 "ECDH-ECDSA-CAMELLIA128-SHA256"
  950. # define TLS1_TXT_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 "ECDH-ECDSA-CAMELLIA256-SHA384"
  951. # define TLS1_TXT_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 "ECDHE-RSA-CAMELLIA128-SHA256"
  952. # define TLS1_TXT_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 "ECDHE-RSA-CAMELLIA256-SHA384"
  953. # define TLS1_TXT_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256 "ECDH-RSA-CAMELLIA128-SHA256"
  954. # define TLS1_TXT_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384 "ECDH-RSA-CAMELLIA256-SHA384"
  955. /* draft-ietf-tls-chacha20-poly1305-03 */
  956. # define TLS1_TXT_ECDHE_RSA_WITH_CHACHA20_POLY1305 "ECDHE-RSA-CHACHA20-POLY1305"
  957. # define TLS1_TXT_ECDHE_ECDSA_WITH_CHACHA20_POLY1305 "ECDHE-ECDSA-CHACHA20-POLY1305"
  958. # define TLS1_TXT_DHE_RSA_WITH_CHACHA20_POLY1305 "DHE-RSA-CHACHA20-POLY1305"
  959. # define TLS1_TXT_PSK_WITH_CHACHA20_POLY1305 "PSK-CHACHA20-POLY1305"
  960. # define TLS1_TXT_ECDHE_PSK_WITH_CHACHA20_POLY1305 "ECDHE-PSK-CHACHA20-POLY1305"
  961. # define TLS1_TXT_DHE_PSK_WITH_CHACHA20_POLY1305 "DHE-PSK-CHACHA20-POLY1305"
  962. # define TLS1_TXT_RSA_PSK_WITH_CHACHA20_POLY1305 "RSA-PSK-CHACHA20-POLY1305"
  963. /* Aria ciphersuites from RFC6209 */
  964. # define TLS1_TXT_RSA_WITH_ARIA_128_GCM_SHA256 "ARIA128-GCM-SHA256"
  965. # define TLS1_TXT_RSA_WITH_ARIA_256_GCM_SHA384 "ARIA256-GCM-SHA384"
  966. # define TLS1_TXT_DHE_RSA_WITH_ARIA_128_GCM_SHA256 "DHE-RSA-ARIA128-GCM-SHA256"
  967. # define TLS1_TXT_DHE_RSA_WITH_ARIA_256_GCM_SHA384 "DHE-RSA-ARIA256-GCM-SHA384"
  968. # define TLS1_TXT_DH_RSA_WITH_ARIA_128_GCM_SHA256 "DH-RSA-ARIA128-GCM-SHA256"
  969. # define TLS1_TXT_DH_RSA_WITH_ARIA_256_GCM_SHA384 "DH-RSA-ARIA256-GCM-SHA384"
  970. # define TLS1_TXT_DHE_DSS_WITH_ARIA_128_GCM_SHA256 "DHE-DSS-ARIA128-GCM-SHA256"
  971. # define TLS1_TXT_DHE_DSS_WITH_ARIA_256_GCM_SHA384 "DHE-DSS-ARIA256-GCM-SHA384"
  972. # define TLS1_TXT_DH_DSS_WITH_ARIA_128_GCM_SHA256 "DH-DSS-ARIA128-GCM-SHA256"
  973. # define TLS1_TXT_DH_DSS_WITH_ARIA_256_GCM_SHA384 "DH-DSS-ARIA256-GCM-SHA384"
  974. # define TLS1_TXT_DH_anon_WITH_ARIA_128_GCM_SHA256 "ADH-ARIA128-GCM-SHA256"
  975. # define TLS1_TXT_DH_anon_WITH_ARIA_256_GCM_SHA384 "ADH-ARIA256-GCM-SHA384"
  976. # define TLS1_TXT_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256 "ECDHE-ECDSA-ARIA128-GCM-SHA256"
  977. # define TLS1_TXT_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384 "ECDHE-ECDSA-ARIA256-GCM-SHA384"
  978. # define TLS1_TXT_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256 "ECDH-ECDSA-ARIA128-GCM-SHA256"
  979. # define TLS1_TXT_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384 "ECDH-ECDSA-ARIA256-GCM-SHA384"
  980. # define TLS1_TXT_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256 "ECDHE-ARIA128-GCM-SHA256"
  981. # define TLS1_TXT_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384 "ECDHE-ARIA256-GCM-SHA384"
  982. # define TLS1_TXT_ECDH_RSA_WITH_ARIA_128_GCM_SHA256 "ECDH-ARIA128-GCM-SHA256"
  983. # define TLS1_TXT_ECDH_RSA_WITH_ARIA_256_GCM_SHA384 "ECDH-ARIA256-GCM-SHA384"
  984. # define TLS1_TXT_PSK_WITH_ARIA_128_GCM_SHA256 "PSK-ARIA128-GCM-SHA256"
  985. # define TLS1_TXT_PSK_WITH_ARIA_256_GCM_SHA384 "PSK-ARIA256-GCM-SHA384"
  986. # define TLS1_TXT_DHE_PSK_WITH_ARIA_128_GCM_SHA256 "DHE-PSK-ARIA128-GCM-SHA256"
  987. # define TLS1_TXT_DHE_PSK_WITH_ARIA_256_GCM_SHA384 "DHE-PSK-ARIA256-GCM-SHA384"
  988. # define TLS1_TXT_RSA_PSK_WITH_ARIA_128_GCM_SHA256 "RSA-PSK-ARIA128-GCM-SHA256"
  989. # define TLS1_TXT_RSA_PSK_WITH_ARIA_256_GCM_SHA384 "RSA-PSK-ARIA256-GCM-SHA384"
  990. # define TLS_CT_RSA_SIGN 1
  991. # define TLS_CT_DSS_SIGN 2
  992. # define TLS_CT_RSA_FIXED_DH 3
  993. # define TLS_CT_DSS_FIXED_DH 4
  994. # define TLS_CT_ECDSA_SIGN 64
  995. # define TLS_CT_RSA_FIXED_ECDH 65
  996. # define TLS_CT_ECDSA_FIXED_ECDH 66
  997. # define TLS_CT_GOST01_SIGN 22
  998. # define TLS_CT_GOST12_SIGN 238
  999. # define TLS_CT_GOST12_512_SIGN 239
  1000. /*
  1001. * when correcting this number, correct also SSL3_CT_NUMBER in ssl3.h (see
  1002. * comment there)
  1003. */
  1004. # define TLS_CT_NUMBER 10
  1005. # if defined(SSL3_CT_NUMBER)
  1006. # if TLS_CT_NUMBER != SSL3_CT_NUMBER
  1007. # error "SSL/TLS CT_NUMBER values do not match"
  1008. # endif
  1009. # endif
  1010. # define TLS1_FINISH_MAC_LENGTH 12
  1011. # define TLS_MD_MAX_CONST_SIZE 22
  1012. # define TLS_MD_CLIENT_FINISH_CONST "client finished"
  1013. # define TLS_MD_CLIENT_FINISH_CONST_SIZE 15
  1014. # define TLS_MD_SERVER_FINISH_CONST "server finished"
  1015. # define TLS_MD_SERVER_FINISH_CONST_SIZE 15
  1016. # define TLS_MD_KEY_EXPANSION_CONST "key expansion"
  1017. # define TLS_MD_KEY_EXPANSION_CONST_SIZE 13
  1018. # define TLS_MD_CLIENT_WRITE_KEY_CONST "client write key"
  1019. # define TLS_MD_CLIENT_WRITE_KEY_CONST_SIZE 16
  1020. # define TLS_MD_SERVER_WRITE_KEY_CONST "server write key"
  1021. # define TLS_MD_SERVER_WRITE_KEY_CONST_SIZE 16
  1022. # define TLS_MD_IV_BLOCK_CONST "IV block"
  1023. # define TLS_MD_IV_BLOCK_CONST_SIZE 8
  1024. # define TLS_MD_MASTER_SECRET_CONST "master secret"
  1025. # define TLS_MD_MASTER_SECRET_CONST_SIZE 13
  1026. # define TLS_MD_EXTENDED_MASTER_SECRET_CONST "extended master secret"
  1027. # define TLS_MD_EXTENDED_MASTER_SECRET_CONST_SIZE 22
  1028. # ifdef CHARSET_EBCDIC
  1029. # undef TLS_MD_CLIENT_FINISH_CONST
  1030. /*
  1031. * client finished
  1032. */
  1033. # define TLS_MD_CLIENT_FINISH_CONST "\x63\x6c\x69\x65\x6e\x74\x20\x66\x69\x6e\x69\x73\x68\x65\x64"
  1034. # undef TLS_MD_SERVER_FINISH_CONST
  1035. /*
  1036. * server finished
  1037. */
  1038. # define TLS_MD_SERVER_FINISH_CONST "\x73\x65\x72\x76\x65\x72\x20\x66\x69\x6e\x69\x73\x68\x65\x64"
  1039. # undef TLS_MD_SERVER_WRITE_KEY_CONST
  1040. /*
  1041. * server write key
  1042. */
  1043. # define TLS_MD_SERVER_WRITE_KEY_CONST "\x73\x65\x72\x76\x65\x72\x20\x77\x72\x69\x74\x65\x20\x6b\x65\x79"
  1044. # undef TLS_MD_KEY_EXPANSION_CONST
  1045. /*
  1046. * key expansion
  1047. */
  1048. # define TLS_MD_KEY_EXPANSION_CONST "\x6b\x65\x79\x20\x65\x78\x70\x61\x6e\x73\x69\x6f\x6e"
  1049. # undef TLS_MD_CLIENT_WRITE_KEY_CONST
  1050. /*
  1051. * client write key
  1052. */
  1053. # define TLS_MD_CLIENT_WRITE_KEY_CONST "\x63\x6c\x69\x65\x6e\x74\x20\x77\x72\x69\x74\x65\x20\x6b\x65\x79"
  1054. # undef TLS_MD_SERVER_WRITE_KEY_CONST
  1055. /*
  1056. * server write key
  1057. */
  1058. # define TLS_MD_SERVER_WRITE_KEY_CONST "\x73\x65\x72\x76\x65\x72\x20\x77\x72\x69\x74\x65\x20\x6b\x65\x79"
  1059. # undef TLS_MD_IV_BLOCK_CONST
  1060. /*
  1061. * IV block
  1062. */
  1063. # define TLS_MD_IV_BLOCK_CONST "\x49\x56\x20\x62\x6c\x6f\x63\x6b"
  1064. # undef TLS_MD_MASTER_SECRET_CONST
  1065. /*
  1066. * master secret
  1067. */
  1068. # define TLS_MD_MASTER_SECRET_CONST "\x6d\x61\x73\x74\x65\x72\x20\x73\x65\x63\x72\x65\x74"
  1069. # undef TLS_MD_EXTENDED_MASTER_SECRET_CONST
  1070. /*
  1071. * extended master secret
  1072. */
  1073. # define TLS_MD_EXTENDED_MASTER_SECRET_CONST "\x65\x78\x74\x65\x6e\x64\x65\x64\x20\x6d\x61\x73\x74\x65\x72\x20\x73\x65\x63\x72\x65\x74"
  1074. # endif
  1075. /* TLS Session Ticket extension struct */
  1076. struct tls_session_ticket_ext_st {
  1077. unsigned short length;
  1078. void *data;
  1079. };
  1080. #ifdef __cplusplus
  1081. }
  1082. #endif
  1083. #endif