Debian Codegraph @

crt/s2n/tls/s2n_cipher_preferences.h

raw symbols SCIP
1 /*
2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15
16 #pragma once
17
18 #include <stdint.h>
19
20 #include "tls/s2n_cipher_suites.h"
21 #include "tls/s2n_kem.h"
22 #include "tls/s2n_tls13.h"
23
24 struct s2n_cipher_preferences {
25 uint16_t count;
26 struct s2n_cipher_suite **suites;
27 bool allow_chacha20_boosting;
28 };
29
30 extern const struct s2n_cipher_preferences cipher_preferences_20230317;
31 extern const struct s2n_cipher_preferences cipher_preferences_20240331;
32 extern const struct s2n_cipher_preferences cipher_preferences_20140601;
33 extern const struct s2n_cipher_preferences cipher_preferences_20141001;
34 extern const struct s2n_cipher_preferences cipher_preferences_20150202;
35 extern const struct s2n_cipher_preferences cipher_preferences_20150214;
36 extern const struct s2n_cipher_preferences cipher_preferences_20150306;
37 extern const struct s2n_cipher_preferences cipher_preferences_20160411;
38 extern const struct s2n_cipher_preferences cipher_preferences_20160804;
39 extern const struct s2n_cipher_preferences cipher_preferences_20160824;
40 extern const struct s2n_cipher_preferences cipher_preferences_20170210;
41 extern const struct s2n_cipher_preferences cipher_preferences_20170328;
42 extern const struct s2n_cipher_preferences cipher_preferences_20170328_gcm;
43 extern const struct s2n_cipher_preferences cipher_preferences_20170405;
44 extern const struct s2n_cipher_preferences cipher_preferences_20170405_gcm;
45 extern const struct s2n_cipher_preferences cipher_preferences_20170718;
46 extern const struct s2n_cipher_preferences cipher_preferences_20170718_gcm;
47 extern const struct s2n_cipher_preferences cipher_preferences_20190214;
48 extern const struct s2n_cipher_preferences cipher_preferences_20190214_gcm;
49 extern const struct s2n_cipher_preferences cipher_preferences_20190801;
50 extern const struct s2n_cipher_preferences cipher_preferences_20190120;
51 extern const struct s2n_cipher_preferences cipher_preferences_20190121;
52 extern const struct s2n_cipher_preferences cipher_preferences_20190122;
53 extern const struct s2n_cipher_preferences cipher_preferences_20210816;
54 extern const struct s2n_cipher_preferences cipher_preferences_20210816_gcm;
55 extern const struct s2n_cipher_preferences cipher_preferences_20210825;
56 extern const struct s2n_cipher_preferences cipher_preferences_20210825_gcm;
57 extern const struct s2n_cipher_preferences cipher_preferences_20210831;
58 extern const struct s2n_cipher_preferences cipher_preferences_20231213;
59 extern const struct s2n_cipher_preferences cipher_preferences_20231214;
60 extern const struct s2n_cipher_preferences cipher_preferences_20240603;
61 extern const struct s2n_cipher_preferences cipher_preferences_20241008;
62 extern const struct s2n_cipher_preferences cipher_preferences_20241008_gcm;
63 extern const struct s2n_cipher_preferences cipher_preferences_20241009;
64 extern const struct s2n_cipher_preferences cipher_preferences_20250211;
65 extern const struct s2n_cipher_preferences cipher_preferences_20250429;
66 extern const struct s2n_cipher_preferences cipher_preferences_20251013;
67 extern const struct s2n_cipher_preferences cipher_preferences_20251014;
68 extern const struct s2n_cipher_preferences cipher_preferences_20251015;
69 extern const struct s2n_cipher_preferences cipher_preferences_20251113;
70 extern const struct s2n_cipher_preferences cipher_preferences_20251114;
71 extern const struct s2n_cipher_preferences cipher_preferences_20251115;
72 extern const struct s2n_cipher_preferences cipher_preferences_20251116;
73 extern const struct s2n_cipher_preferences cipher_preferences_20251117;
74 extern const struct s2n_cipher_preferences cipher_preferences_20260220;
75 extern const struct s2n_cipher_preferences cipher_preferences_20260520;
76 extern const struct s2n_cipher_preferences cipher_preferences_20260520_gcm;
77 extern const struct s2n_cipher_preferences cipher_preferences_20260521;
78 extern const struct s2n_cipher_preferences cipher_preferences_20260521_gcm;
79 extern const struct s2n_cipher_preferences cipher_preferences_20260522;
80 extern const struct s2n_cipher_preferences cipher_preferences_20260522_gcm;
81 extern const struct s2n_cipher_preferences cipher_preferences_20260523;
82 extern const struct s2n_cipher_preferences cipher_preferences_20260523_gcm;
83
84 extern const struct s2n_cipher_preferences cipher_preferences_default_fips;
85
86 extern const struct s2n_cipher_preferences cipher_preferences_test_all;
87
88 extern const struct s2n_cipher_preferences cipher_preferences_test_all_tls12;
89 extern const struct s2n_cipher_preferences cipher_preferences_test_all_fips;
90 extern const struct s2n_cipher_preferences cipher_preferences_test_all_ecdsa;
91 extern const struct s2n_cipher_preferences cipher_preferences_test_ecdsa_priority;
92 extern const struct s2n_cipher_preferences cipher_preferences_test_all_rsa_kex;
93 extern const struct s2n_cipher_preferences cipher_preferences_test_all_tls13;
94
95 /* See https://docs.aws.amazon.com/elasticloadbalancing/latest/application/create-https-listener.html */
96 extern const struct s2n_cipher_preferences elb_security_policy_2015_04;
97 extern const struct s2n_cipher_preferences elb_security_policy_2016_08;
98
99 extern const struct s2n_cipher_preferences elb_security_policy_tls_1_1_2017_01;
100 extern const struct s2n_cipher_preferences elb_security_policy_tls_1_2_2017_01;
101 extern const struct s2n_cipher_preferences elb_security_policy_tls_1_2_ext_2018_06;
102
103 extern const struct s2n_cipher_preferences elb_security_policy_fs_2018_06;
104 extern const struct s2n_cipher_preferences elb_security_policy_fs_1_2_2019_08;
105 extern const struct s2n_cipher_preferences elb_security_policy_fs_1_1_2019_08;
106 extern const struct s2n_cipher_preferences elb_security_policy_fs_1_2_Res_2019_08;
107 extern const struct s2n_cipher_preferences elb_security_policy_tls13_1_2_Ext2_2021_06;
108
109 /* CloudFront upstream */
110 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream;
111 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream_tls10;
112 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream_tls11;
113 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream_tls12;
114 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream_2025_08_08;
115 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_upstream_2025_08_08_tls13;
116 /* CloudFront viewer facing */
117 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_ssl_v_3;
118 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_0_2014;
119 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_0_2014_sha256;
120 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_0_2016;
121 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_1_2016;
122 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2017;
123 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2018;
124 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2018_beta;
125 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2025;
126 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_3_2025;
127 /* CloudFront undocumented policies for testing */
128 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2019;
129 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2021;
130 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2021_chacha20_boosted;
131
132 /* CloudFront viewer facing legacy TLS 1.2 policies */
133 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_ssl_v_3_legacy;
134 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_0_2014_legacy;
135 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_0_2016_legacy;
136 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_1_2016_legacy;
137 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2018_legacy;
138 extern const struct s2n_cipher_preferences cipher_preferences_cloudfront_tls_1_2_2019_legacy;
139
140 /* AWS Common Runtime Cipher Preferences */
141 extern const struct s2n_cipher_preferences cipher_preferences_aws_crt_sdk_ssl_v3;
142 extern const struct s2n_cipher_preferences cipher_preferences_aws_crt_sdk_default;
143 extern const struct s2n_cipher_preferences cipher_preferences_aws_crt_sdk_tls_13;
144 extern const struct s2n_cipher_preferences cipher_preferences_aws_crt_sdk_2025;
145
146 /* AWS KMS Cipher Preferences */
147 extern const struct s2n_cipher_preferences cipher_preferences_kms_tls_1_0_2018_10;
148 extern const struct s2n_cipher_preferences cipher_preferences_kms_tls_1_0_2021_08;
149 extern const struct s2n_cipher_preferences cipher_preferences_kms_fips_tls_1_2_2018_10;
150 extern const struct s2n_cipher_preferences cipher_preferences_kms_fips_tls_1_2_2021_08;
151
152 extern const struct s2n_cipher_preferences cipher_preferences_null;