| Absolute File Name: | /home/opencoverage/opencoverage/guest-scripts/openssl/src/ssl/statem/extensions_srvr.c |
| Switch to Source code | Preprocessed file |
| Line | Source | Count | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | int tls_parse_ctos_renegotiate(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 2 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 3 | { | - | ||||||||||||||||||||||||||||||||||||
| 4 | unsigned int ilen; | - | ||||||||||||||||||||||||||||||||||||
| 5 | const unsigned char *data; | - | ||||||||||||||||||||||||||||||||||||
| 6 | - | |||||||||||||||||||||||||||||||||||||
| 7 | - | |||||||||||||||||||||||||||||||||||||
| 8 | if (!PACKET_get_1(pkt, &ilen)
| 1-250 | ||||||||||||||||||||||||||||||||||||
| 9 | || !PACKET_get_bytes(pkt, &data, ilen)
| 1-249 | ||||||||||||||||||||||||||||||||||||
| 10 | ossl_statem_fatal((s), (50), (464), (336), | - | ||||||||||||||||||||||||||||||||||||
| 11 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 12 | , | - | ||||||||||||||||||||||||||||||||||||
| 13 | 51 | - | ||||||||||||||||||||||||||||||||||||
| 14 | ) | - | ||||||||||||||||||||||||||||||||||||
| 15 | ; | - | ||||||||||||||||||||||||||||||||||||
| 16 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 17 | } | - | ||||||||||||||||||||||||||||||||||||
| 18 | - | |||||||||||||||||||||||||||||||||||||
| 19 | - | |||||||||||||||||||||||||||||||||||||
| 20 | if (ilen != s->s3->previous_client_finished_len
| 1-248 | ||||||||||||||||||||||||||||||||||||
| 21 | ossl_statem_fatal((s), (40), (464), (337), | - | ||||||||||||||||||||||||||||||||||||
| 22 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 23 | , | - | ||||||||||||||||||||||||||||||||||||
| 24 | 58 | - | ||||||||||||||||||||||||||||||||||||
| 25 | ) | - | ||||||||||||||||||||||||||||||||||||
| 26 | ; | - | ||||||||||||||||||||||||||||||||||||
| 27 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 28 | } | - | ||||||||||||||||||||||||||||||||||||
| 29 | - | |||||||||||||||||||||||||||||||||||||
| 30 | if (memcmp(data, s->s3->previous_client_finished,
| 0-248 | ||||||||||||||||||||||||||||||||||||
| 31 | s->s3->previous_client_finished_len)
| 0-248 | ||||||||||||||||||||||||||||||||||||
| 32 | ossl_statem_fatal((s), (40), (464), (337), | - | ||||||||||||||||||||||||||||||||||||
| 33 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 34 | , | - | ||||||||||||||||||||||||||||||||||||
| 35 | 65 | - | ||||||||||||||||||||||||||||||||||||
| 36 | ) | - | ||||||||||||||||||||||||||||||||||||
| 37 | ; | - | ||||||||||||||||||||||||||||||||||||
| 38 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 39 | } | - | ||||||||||||||||||||||||||||||||||||
| 40 | - | |||||||||||||||||||||||||||||||||||||
| 41 | s->s3->send_connection_binding = 1; | - | ||||||||||||||||||||||||||||||||||||
| 42 | - | |||||||||||||||||||||||||||||||||||||
| 43 | return executed 248 times by 1 test: 1;return 1;Executed by:
executed 248 times by 1 test: return 1;Executed by:
| 248 | ||||||||||||||||||||||||||||||||||||
| 44 | } | - | ||||||||||||||||||||||||||||||||||||
| 45 | int tls_parse_ctos_server_name(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 46 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 47 | { | - | ||||||||||||||||||||||||||||||||||||
| 48 | unsigned int servname_type; | - | ||||||||||||||||||||||||||||||||||||
| 49 | PACKET sni, hostname; | - | ||||||||||||||||||||||||||||||||||||
| 50 | - | |||||||||||||||||||||||||||||||||||||
| 51 | if (!PACKET_as_length_prefixed_2(pkt, &sni)
| 3-604 | ||||||||||||||||||||||||||||||||||||
| 52 | - | |||||||||||||||||||||||||||||||||||||
| 53 | || PACKET_remaining(&sni) == 0
| 1-603 | ||||||||||||||||||||||||||||||||||||
| 54 | ossl_statem_fatal((s), (50), (573), (110), | - | ||||||||||||||||||||||||||||||||||||
| 55 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 56 | , | - | ||||||||||||||||||||||||||||||||||||
| 57 | 107 | - | ||||||||||||||||||||||||||||||||||||
| 58 | ) | - | ||||||||||||||||||||||||||||||||||||
| 59 | ; | - | ||||||||||||||||||||||||||||||||||||
| 60 | return executed 4 times by 1 test: 0;return 0;Executed by:
executed 4 times by 1 test: return 0;Executed by:
| 4 | ||||||||||||||||||||||||||||||||||||
| 61 | } | - | ||||||||||||||||||||||||||||||||||||
| 62 | if (!PACKET_get_1(&sni, &servname_type)
| 0-603 | ||||||||||||||||||||||||||||||||||||
| 63 | || servname_type != 0
| 2-601 | ||||||||||||||||||||||||||||||||||||
| 64 | || !PACKET_as_length_prefixed_2(&sni, &hostname)
| 2-599 | ||||||||||||||||||||||||||||||||||||
| 65 | ossl_statem_fatal((s), (50), (573), (110), | - | ||||||||||||||||||||||||||||||||||||
| 66 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 67 | , | - | ||||||||||||||||||||||||||||||||||||
| 68 | 126 | - | ||||||||||||||||||||||||||||||||||||
| 69 | ) | - | ||||||||||||||||||||||||||||||||||||
| 70 | ; | - | ||||||||||||||||||||||||||||||||||||
| 71 | return executed 4 times by 1 test: 0;return 0;Executed by:
executed 4 times by 1 test: return 0;Executed by:
| 4 | ||||||||||||||||||||||||||||||||||||
| 72 | } | - | ||||||||||||||||||||||||||||||||||||
| 73 | - | |||||||||||||||||||||||||||||||||||||
| 74 | if (!s->hit
| 0-572 | ||||||||||||||||||||||||||||||||||||
| 75 | if (PACKET_remaining(&hostname) > 255
| 1-588 | ||||||||||||||||||||||||||||||||||||
| 76 | ossl_statem_fatal((s), (112), (573), (110), | - | ||||||||||||||||||||||||||||||||||||
| 77 | - | |||||||||||||||||||||||||||||||||||||
| 78 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 79 | , | - | ||||||||||||||||||||||||||||||||||||
| 80 | - | |||||||||||||||||||||||||||||||||||||
| 81 | 134 | - | ||||||||||||||||||||||||||||||||||||
| 82 | ) | - | ||||||||||||||||||||||||||||||||||||
| 83 | - | |||||||||||||||||||||||||||||||||||||
| 84 | ; | - | ||||||||||||||||||||||||||||||||||||
| 85 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 86 | } | - | ||||||||||||||||||||||||||||||||||||
| 87 | - | |||||||||||||||||||||||||||||||||||||
| 88 | if (PACKET_contains_zero_byte(&hostname)
| 1-587 | ||||||||||||||||||||||||||||||||||||
| 89 | ossl_statem_fatal((s), (112), (573), (110), | - | ||||||||||||||||||||||||||||||||||||
| 90 | - | |||||||||||||||||||||||||||||||||||||
| 91 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 92 | , | - | ||||||||||||||||||||||||||||||||||||
| 93 | - | |||||||||||||||||||||||||||||||||||||
| 94 | 141 | - | ||||||||||||||||||||||||||||||||||||
| 95 | ) | - | ||||||||||||||||||||||||||||||||||||
| 96 | - | |||||||||||||||||||||||||||||||||||||
| 97 | ; | - | ||||||||||||||||||||||||||||||||||||
| 98 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 99 | } | - | ||||||||||||||||||||||||||||||||||||
| 100 | - | |||||||||||||||||||||||||||||||||||||
| 101 | - | |||||||||||||||||||||||||||||||||||||
| 102 | - | |||||||||||||||||||||||||||||||||||||
| 103 | - | |||||||||||||||||||||||||||||||||||||
| 104 | - | |||||||||||||||||||||||||||||||||||||
| 105 | CRYPTO_free(s->ext.hostname, __FILE__, 149); | - | ||||||||||||||||||||||||||||||||||||
| 106 | s->ext.hostname = | - | ||||||||||||||||||||||||||||||||||||
| 107 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 108 | ; | - | ||||||||||||||||||||||||||||||||||||
| 109 | if (!PACKET_strndup(&hostname, &s->ext.hostname)
| 0-587 | ||||||||||||||||||||||||||||||||||||
| 110 | ossl_statem_fatal((s), (80), (573), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 111 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 112 | , | - | ||||||||||||||||||||||||||||||||||||
| 113 | 153 | - | ||||||||||||||||||||||||||||||||||||
| 114 | ) | - | ||||||||||||||||||||||||||||||||||||
| 115 | ; | - | ||||||||||||||||||||||||||||||||||||
| 116 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 117 | } | - | ||||||||||||||||||||||||||||||||||||
| 118 | - | |||||||||||||||||||||||||||||||||||||
| 119 | s->servername_done = 1; | - | ||||||||||||||||||||||||||||||||||||
| 120 | } executed 587 times by 1 test: end of blockExecuted by:
| 587 | ||||||||||||||||||||||||||||||||||||
| 121 | if (s->hit
| 27-570 | ||||||||||||||||||||||||||||||||||||
| 122 | - | |||||||||||||||||||||||||||||||||||||
| 123 | - | |||||||||||||||||||||||||||||||||||||
| 124 | - | |||||||||||||||||||||||||||||||||||||
| 125 | - | |||||||||||||||||||||||||||||||||||||
| 126 | s->servername_done = (
| 12-15 | ||||||||||||||||||||||||||||||||||||
| 127 | ((void *)0)
| 12-15 | ||||||||||||||||||||||||||||||||||||
| 128 | )
| 12-15 | ||||||||||||||||||||||||||||||||||||
| 129 | && PACKET_equal(&hostname, s->session->ext.hostname,
| 2-13 | ||||||||||||||||||||||||||||||||||||
| 130 | strlen(s->session->ext.hostname))
| 2-13 | ||||||||||||||||||||||||||||||||||||
| 131 | - | |||||||||||||||||||||||||||||||||||||
| 132 | if (!s->servername_done
| 2-14 | ||||||||||||||||||||||||||||||||||||
| 133 | ((void *)0)
| 2-12 | ||||||||||||||||||||||||||||||||||||
| 134 | ) | - | ||||||||||||||||||||||||||||||||||||
| 135 | s->ext.early_data_ok = 0; executed 2 times by 1 test: s->ext.early_data_ok = 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 136 | } executed 27 times by 1 test: end of blockExecuted by:
| 27 | ||||||||||||||||||||||||||||||||||||
| 137 | - | |||||||||||||||||||||||||||||||||||||
| 138 | return executed 597 times by 1 test: 1;return 1;Executed by:
executed 597 times by 1 test: return 1;Executed by:
| 597 | ||||||||||||||||||||||||||||||||||||
| 139 | } | - | ||||||||||||||||||||||||||||||||||||
| 140 | - | |||||||||||||||||||||||||||||||||||||
| 141 | int tls_parse_ctos_maxfragmentlen(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 142 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 143 | { | - | ||||||||||||||||||||||||||||||||||||
| 144 | unsigned int value; | - | ||||||||||||||||||||||||||||||||||||
| 145 | - | |||||||||||||||||||||||||||||||||||||
| 146 | if (PACKET_remaining(pkt) != 1
| 0-33 | ||||||||||||||||||||||||||||||||||||
| 147 | ossl_statem_fatal((s), (50), (571), (110), | - | ||||||||||||||||||||||||||||||||||||
| 148 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 149 | , | - | ||||||||||||||||||||||||||||||||||||
| 150 | 182 | - | ||||||||||||||||||||||||||||||||||||
| 151 | ) | - | ||||||||||||||||||||||||||||||||||||
| 152 | ; | - | ||||||||||||||||||||||||||||||||||||
| 153 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 154 | } | - | ||||||||||||||||||||||||||||||||||||
| 155 | - | |||||||||||||||||||||||||||||||||||||
| 156 | - | |||||||||||||||||||||||||||||||||||||
| 157 | if (!(((
| 1-32 | ||||||||||||||||||||||||||||||||||||
| 158 | ossl_statem_fatal((s), (47), (571), (232), | - | ||||||||||||||||||||||||||||||||||||
| 159 | - | |||||||||||||||||||||||||||||||||||||
| 160 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 161 | , | - | ||||||||||||||||||||||||||||||||||||
| 162 | - | |||||||||||||||||||||||||||||||||||||
| 163 | 190 | - | ||||||||||||||||||||||||||||||||||||
| 164 | ) | - | ||||||||||||||||||||||||||||||||||||
| 165 | - | |||||||||||||||||||||||||||||||||||||
| 166 | ; | - | ||||||||||||||||||||||||||||||||||||
| 167 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 168 | } | - | ||||||||||||||||||||||||||||||||||||
| 169 | - | |||||||||||||||||||||||||||||||||||||
| 170 | - | |||||||||||||||||||||||||||||||||||||
| 171 | - | |||||||||||||||||||||||||||||||||||||
| 172 | - | |||||||||||||||||||||||||||||||||||||
| 173 | - | |||||||||||||||||||||||||||||||||||||
| 174 | - | |||||||||||||||||||||||||||||||||||||
| 175 | if (s->hit
| 0-30 | ||||||||||||||||||||||||||||||||||||
| 176 | ossl_statem_fatal((s), (47), (571), (232), | - | ||||||||||||||||||||||||||||||||||||
| 177 | - | |||||||||||||||||||||||||||||||||||||
| 178 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 179 | , | - | ||||||||||||||||||||||||||||||||||||
| 180 | - | |||||||||||||||||||||||||||||||||||||
| 181 | 202 | - | ||||||||||||||||||||||||||||||||||||
| 182 | ) | - | ||||||||||||||||||||||||||||||||||||
| 183 | - | |||||||||||||||||||||||||||||||||||||
| 184 | ; | - | ||||||||||||||||||||||||||||||||||||
| 185 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 186 | } | - | ||||||||||||||||||||||||||||||||||||
| 187 | - | |||||||||||||||||||||||||||||||||||||
| 188 | - | |||||||||||||||||||||||||||||||||||||
| 189 | - | |||||||||||||||||||||||||||||||||||||
| 190 | - | |||||||||||||||||||||||||||||||||||||
| 191 | - | |||||||||||||||||||||||||||||||||||||
| 192 | s->session->ext.max_fragment_len_mode = value; | - | ||||||||||||||||||||||||||||||||||||
| 193 | return executed 30 times by 1 test: 1;return 1;Executed by:
executed 30 times by 1 test: return 1;Executed by:
| 30 | ||||||||||||||||||||||||||||||||||||
| 194 | } | - | ||||||||||||||||||||||||||||||||||||
| 195 | - | |||||||||||||||||||||||||||||||||||||
| 196 | - | |||||||||||||||||||||||||||||||||||||
| 197 | int tls_parse_ctos_srp(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 198 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 199 | { | - | ||||||||||||||||||||||||||||||||||||
| 200 | PACKET srp_I; | - | ||||||||||||||||||||||||||||||||||||
| 201 | - | |||||||||||||||||||||||||||||||||||||
| 202 | if (!PACKET_as_length_prefixed_1(pkt, &srp_I)
| 2-18 | ||||||||||||||||||||||||||||||||||||
| 203 | || PACKET_contains_zero_byte(&srp_I)
| 1-17 | ||||||||||||||||||||||||||||||||||||
| 204 | ossl_statem_fatal((s), (50), (576), (110), | - | ||||||||||||||||||||||||||||||||||||
| 205 | - | |||||||||||||||||||||||||||||||||||||
| 206 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 207 | , | - | ||||||||||||||||||||||||||||||||||||
| 208 | - | |||||||||||||||||||||||||||||||||||||
| 209 | 224 | - | ||||||||||||||||||||||||||||||||||||
| 210 | ) | - | ||||||||||||||||||||||||||||||||||||
| 211 | - | |||||||||||||||||||||||||||||||||||||
| 212 | ; | - | ||||||||||||||||||||||||||||||||||||
| 213 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 214 | } | - | ||||||||||||||||||||||||||||||||||||
| 215 | - | |||||||||||||||||||||||||||||||||||||
| 216 | - | |||||||||||||||||||||||||||||||||||||
| 217 | - | |||||||||||||||||||||||||||||||||||||
| 218 | - | |||||||||||||||||||||||||||||||||||||
| 219 | - | |||||||||||||||||||||||||||||||||||||
| 220 | if (!PACKET_strndup(&srp_I, &s->srp_ctx.login)
| 0-17 | ||||||||||||||||||||||||||||||||||||
| 221 | ossl_statem_fatal((s), (80), (576), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 222 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 223 | , | - | ||||||||||||||||||||||||||||||||||||
| 224 | 234 | - | ||||||||||||||||||||||||||||||||||||
| 225 | ) | - | ||||||||||||||||||||||||||||||||||||
| 226 | ; | - | ||||||||||||||||||||||||||||||||||||
| 227 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 228 | } | - | ||||||||||||||||||||||||||||||||||||
| 229 | - | |||||||||||||||||||||||||||||||||||||
| 230 | return executed 17 times by 1 test: 1;return 1;Executed by:
executed 17 times by 1 test: return 1;Executed by:
| 17 | ||||||||||||||||||||||||||||||||||||
| 231 | } | - | ||||||||||||||||||||||||||||||||||||
| 232 | - | |||||||||||||||||||||||||||||||||||||
| 233 | - | |||||||||||||||||||||||||||||||||||||
| 234 | - | |||||||||||||||||||||||||||||||||||||
| 235 | int tls_parse_ctos_ec_pt_formats(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 236 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 237 | { | - | ||||||||||||||||||||||||||||||||||||
| 238 | PACKET ec_point_format_list; | - | ||||||||||||||||||||||||||||||||||||
| 239 | - | |||||||||||||||||||||||||||||||||||||
| 240 | if (!PACKET_as_length_prefixed_1(pkt, &ec_point_format_list)
| 3-1379 | ||||||||||||||||||||||||||||||||||||
| 241 | || PACKET_remaining(&ec_point_format_list) == 0
| 1-1378 | ||||||||||||||||||||||||||||||||||||
| 242 | ossl_statem_fatal((s), (50), (569), (110), | - | ||||||||||||||||||||||||||||||||||||
| 243 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 244 | , | - | ||||||||||||||||||||||||||||||||||||
| 245 | 251 | - | ||||||||||||||||||||||||||||||||||||
| 246 | ) | - | ||||||||||||||||||||||||||||||||||||
| 247 | ; | - | ||||||||||||||||||||||||||||||||||||
| 248 | return executed 4 times by 1 test: 0;return 0;Executed by:
executed 4 times by 1 test: return 0;Executed by:
| 4 | ||||||||||||||||||||||||||||||||||||
| 249 | } | - | ||||||||||||||||||||||||||||||||||||
| 250 | - | |||||||||||||||||||||||||||||||||||||
| 251 | if (!s->hit
| 81-1297 | ||||||||||||||||||||||||||||||||||||
| 252 | if (!PACKET_memdup(&ec_point_format_list,
| 0-1297 | ||||||||||||||||||||||||||||||||||||
| 253 | &s->session->ext.ecpointformats,
| 0-1297 | ||||||||||||||||||||||||||||||||||||
| 254 | &s->session->ext.ecpointformats_len)
| 0-1297 | ||||||||||||||||||||||||||||||||||||
| 255 | ossl_statem_fatal((s), (80), (569), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 256 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 257 | , | - | ||||||||||||||||||||||||||||||||||||
| 258 | 260 | - | ||||||||||||||||||||||||||||||||||||
| 259 | ) | - | ||||||||||||||||||||||||||||||||||||
| 260 | ; | - | ||||||||||||||||||||||||||||||||||||
| 261 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 262 | } | - | ||||||||||||||||||||||||||||||||||||
| 263 | } executed 1297 times by 1 test: end of blockExecuted by:
| 1297 | ||||||||||||||||||||||||||||||||||||
| 264 | - | |||||||||||||||||||||||||||||||||||||
| 265 | return executed 1378 times by 1 test: 1;return 1;Executed by:
executed 1378 times by 1 test: return 1;Executed by:
| 1378 | ||||||||||||||||||||||||||||||||||||
| 266 | } | - | ||||||||||||||||||||||||||||||||||||
| 267 | - | |||||||||||||||||||||||||||||||||||||
| 268 | - | |||||||||||||||||||||||||||||||||||||
| 269 | int tls_parse_ctos_session_ticket(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 270 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 271 | { | - | ||||||||||||||||||||||||||||||||||||
| 272 | if (s->ext.session_ticket_cb
| 0-1399 | ||||||||||||||||||||||||||||||||||||
| 273 | !s->ext.session_ticket_cb(s, PACKET_data(pkt),
| 0 | ||||||||||||||||||||||||||||||||||||
| 274 | PACKET_remaining(pkt),
| 0 | ||||||||||||||||||||||||||||||||||||
| 275 | s->ext.session_ticket_cb_arg)
| 0 | ||||||||||||||||||||||||||||||||||||
| 276 | ossl_statem_fatal((s), (80), (574), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 277 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 278 | , | - | ||||||||||||||||||||||||||||||||||||
| 279 | 277 | - | ||||||||||||||||||||||||||||||||||||
| 280 | ) | - | ||||||||||||||||||||||||||||||||||||
| 281 | ; | - | ||||||||||||||||||||||||||||||||||||
| 282 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 283 | } | - | ||||||||||||||||||||||||||||||||||||
| 284 | - | |||||||||||||||||||||||||||||||||||||
| 285 | return executed 1399 times by 1 test: 1;return 1;Executed by:
executed 1399 times by 1 test: return 1;Executed by:
| 1399 | ||||||||||||||||||||||||||||||||||||
| 286 | } | - | ||||||||||||||||||||||||||||||||||||
| 287 | - | |||||||||||||||||||||||||||||||||||||
| 288 | int tls_parse_ctos_sig_algs_cert(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 289 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 290 | { | - | ||||||||||||||||||||||||||||||||||||
| 291 | PACKET supported_sig_algs; | - | ||||||||||||||||||||||||||||||||||||
| 292 | - | |||||||||||||||||||||||||||||||||||||
| 293 | if (!PACKET_as_length_prefixed_2(pkt, &supported_sig_algs)
| 2-58 | ||||||||||||||||||||||||||||||||||||
| 294 | || PACKET_remaining(&supported_sig_algs) == 0
| 1-57 | ||||||||||||||||||||||||||||||||||||
| 295 | ossl_statem_fatal((s), (50), (615), (110), | - | ||||||||||||||||||||||||||||||||||||
| 296 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 297 | , | - | ||||||||||||||||||||||||||||||||||||
| 298 | 292 | - | ||||||||||||||||||||||||||||||||||||
| 299 | ) | - | ||||||||||||||||||||||||||||||||||||
| 300 | ; | - | ||||||||||||||||||||||||||||||||||||
| 301 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 302 | } | - | ||||||||||||||||||||||||||||||||||||
| 303 | - | |||||||||||||||||||||||||||||||||||||
| 304 | if (!s->hit
| 1-56 | ||||||||||||||||||||||||||||||||||||
| 305 | ossl_statem_fatal((s), (50), (615), (110), | - | ||||||||||||||||||||||||||||||||||||
| 306 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 307 | , | - | ||||||||||||||||||||||||||||||||||||
| 308 | 298 | - | ||||||||||||||||||||||||||||||||||||
| 309 | ) | - | ||||||||||||||||||||||||||||||||||||
| 310 | ; | - | ||||||||||||||||||||||||||||||||||||
| 311 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 312 | } | - | ||||||||||||||||||||||||||||||||||||
| 313 | - | |||||||||||||||||||||||||||||||||||||
| 314 | return executed 56 times by 1 test: 1;return 1;Executed by:
executed 56 times by 1 test: return 1;Executed by:
| 56 | ||||||||||||||||||||||||||||||||||||
| 315 | } | - | ||||||||||||||||||||||||||||||||||||
| 316 | - | |||||||||||||||||||||||||||||||||||||
| 317 | int tls_parse_ctos_sig_algs(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 318 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 319 | { | - | ||||||||||||||||||||||||||||||||||||
| 320 | PACKET supported_sig_algs; | - | ||||||||||||||||||||||||||||||||||||
| 321 | - | |||||||||||||||||||||||||||||||||||||
| 322 | if (!PACKET_as_length_prefixed_2(pkt, &supported_sig_algs)
| 7-2300 | ||||||||||||||||||||||||||||||||||||
| 323 | || PACKET_remaining(&supported_sig_algs) == 0
| 3-2297 | ||||||||||||||||||||||||||||||||||||
| 324 | ossl_statem_fatal((s), (50), (575), (110), | - | ||||||||||||||||||||||||||||||||||||
| 325 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 326 | , | - | ||||||||||||||||||||||||||||||||||||
| 327 | 313 | - | ||||||||||||||||||||||||||||||||||||
| 328 | ) | - | ||||||||||||||||||||||||||||||||||||
| 329 | ; | - | ||||||||||||||||||||||||||||||||||||
| 330 | return executed 10 times by 1 test: 0;return 0;Executed by:
executed 10 times by 1 test: return 0;Executed by:
| 10 | ||||||||||||||||||||||||||||||||||||
| 331 | } | - | ||||||||||||||||||||||||||||||||||||
| 332 | - | |||||||||||||||||||||||||||||||||||||
| 333 | if (!s->hit
| 1-2080 | ||||||||||||||||||||||||||||||||||||
| 334 | ossl_statem_fatal((s), (50), (575), (110), | - | ||||||||||||||||||||||||||||||||||||
| 335 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 336 | , | - | ||||||||||||||||||||||||||||||||||||
| 337 | 319 | - | ||||||||||||||||||||||||||||||||||||
| 338 | ) | - | ||||||||||||||||||||||||||||||||||||
| 339 | ; | - | ||||||||||||||||||||||||||||||||||||
| 340 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 341 | } | - | ||||||||||||||||||||||||||||||||||||
| 342 | - | |||||||||||||||||||||||||||||||||||||
| 343 | return executed 2296 times by 1 test: 1;return 1;Executed by:
executed 2296 times by 1 test: return 1;Executed by:
| 2296 | ||||||||||||||||||||||||||||||||||||
| 344 | } | - | ||||||||||||||||||||||||||||||||||||
| 345 | - | |||||||||||||||||||||||||||||||||||||
| 346 | - | |||||||||||||||||||||||||||||||||||||
| 347 | int tls_parse_ctos_status_request(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 348 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 349 | { | - | ||||||||||||||||||||||||||||||||||||
| 350 | PACKET responder_id_list, exts; | - | ||||||||||||||||||||||||||||||||||||
| 351 | - | |||||||||||||||||||||||||||||||||||||
| 352 | - | |||||||||||||||||||||||||||||||||||||
| 353 | if (s->hit
| 5-568 | ||||||||||||||||||||||||||||||||||||
| 354 | return executed 5 times by 1 test: 1;return 1;Executed by:
executed 5 times by 1 test: return 1;Executed by:
| 5 | ||||||||||||||||||||||||||||||||||||
| 355 | - | |||||||||||||||||||||||||||||||||||||
| 356 | - | |||||||||||||||||||||||||||||||||||||
| 357 | if (x !=
| 0-568 | ||||||||||||||||||||||||||||||||||||
| 358 | ((void *)0)
| 0-568 | ||||||||||||||||||||||||||||||||||||
| 359 | ) | - | ||||||||||||||||||||||||||||||||||||
| 360 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 361 | - | |||||||||||||||||||||||||||||||||||||
| 362 | if (!PACKET_get_1(pkt, (unsigned int *)&s->ext.status_type)
| 1-567 | ||||||||||||||||||||||||||||||||||||
| 363 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 364 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 365 | , | - | ||||||||||||||||||||||||||||||||||||
| 366 | 342 | - | ||||||||||||||||||||||||||||||||||||
| 367 | ) | - | ||||||||||||||||||||||||||||||||||||
| 368 | ; | - | ||||||||||||||||||||||||||||||||||||
| 369 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 370 | } | - | ||||||||||||||||||||||||||||||||||||
| 371 | - | |||||||||||||||||||||||||||||||||||||
| 372 | if (s->ext.status_type != 1
| 133-434 | ||||||||||||||||||||||||||||||||||||
| 373 | - | |||||||||||||||||||||||||||||||||||||
| 374 | - | |||||||||||||||||||||||||||||||||||||
| 375 | - | |||||||||||||||||||||||||||||||||||||
| 376 | s->ext.status_type = -1; | - | ||||||||||||||||||||||||||||||||||||
| 377 | return executed 133 times by 1 test: 1;return 1;Executed by:
executed 133 times by 1 test: return 1;Executed by:
| 133 | ||||||||||||||||||||||||||||||||||||
| 378 | } | - | ||||||||||||||||||||||||||||||||||||
| 379 | - | |||||||||||||||||||||||||||||||||||||
| 380 | if (!PACKET_get_length_prefixed_2 (pkt, &responder_id_list)
| 2-432 | ||||||||||||||||||||||||||||||||||||
| 381 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 382 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 383 | , | - | ||||||||||||||||||||||||||||||||||||
| 384 | 356 | - | ||||||||||||||||||||||||||||||||||||
| 385 | ) | - | ||||||||||||||||||||||||||||||||||||
| 386 | ; | - | ||||||||||||||||||||||||||||||||||||
| 387 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 388 | } | - | ||||||||||||||||||||||||||||||||||||
| 389 | - | |||||||||||||||||||||||||||||||||||||
| 390 | - | |||||||||||||||||||||||||||||||||||||
| 391 | - | |||||||||||||||||||||||||||||||||||||
| 392 | - | |||||||||||||||||||||||||||||||||||||
| 393 | - | |||||||||||||||||||||||||||||||||||||
| 394 | sk_OCSP_RESPID_pop_free(s->ext.ocsp.ids, OCSP_RESPID_free); | - | ||||||||||||||||||||||||||||||||||||
| 395 | if (PACKET_remaining(&responder_id_list) > 0
| 206-226 | ||||||||||||||||||||||||||||||||||||
| 396 | s->ext.ocsp.ids = sk_OCSP_RESPID_new_null(); | - | ||||||||||||||||||||||||||||||||||||
| 397 | if (s->ext.ocsp.ids ==
| 0-206 | ||||||||||||||||||||||||||||||||||||
| 398 | ((void *)0)
| 0-206 | ||||||||||||||||||||||||||||||||||||
| 399 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 400 | ossl_statem_fatal((s), (80), (577), ((1|64)), | - | ||||||||||||||||||||||||||||||||||||
| 401 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 402 | , | - | ||||||||||||||||||||||||||||||||||||
| 403 | 369 | - | ||||||||||||||||||||||||||||||||||||
| 404 | ) | - | ||||||||||||||||||||||||||||||||||||
| 405 | ; | - | ||||||||||||||||||||||||||||||||||||
| 406 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 407 | } | - | ||||||||||||||||||||||||||||||||||||
| 408 | } executed 206 times by 1 test: else {end of blockExecuted by:
| 206 | ||||||||||||||||||||||||||||||||||||
| 409 | s->ext.ocsp.ids = | - | ||||||||||||||||||||||||||||||||||||
| 410 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 411 | ; | - | ||||||||||||||||||||||||||||||||||||
| 412 | } executed 226 times by 1 test: end of blockExecuted by:
| 226 | ||||||||||||||||||||||||||||||||||||
| 413 | - | |||||||||||||||||||||||||||||||||||||
| 414 | while (PACKET_remaining(&responder_id_list) > 0
| 217-228 | ||||||||||||||||||||||||||||||||||||
| 415 | OCSP_RESPID *id; | - | ||||||||||||||||||||||||||||||||||||
| 416 | PACKET responder_id; | - | ||||||||||||||||||||||||||||||||||||
| 417 | const unsigned char *id_data; | - | ||||||||||||||||||||||||||||||||||||
| 418 | - | |||||||||||||||||||||||||||||||||||||
| 419 | if (!PACKET_get_length_prefixed_2(&responder_id_list, &responder_id)
| 2-215 | ||||||||||||||||||||||||||||||||||||
| 420 | || PACKET_remaining(&responder_id) == 0
| 1-214 | ||||||||||||||||||||||||||||||||||||
| 421 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 422 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 423 | , | - | ||||||||||||||||||||||||||||||||||||
| 424 | 384 | - | ||||||||||||||||||||||||||||||||||||
| 425 | ) | - | ||||||||||||||||||||||||||||||||||||
| 426 | ; | - | ||||||||||||||||||||||||||||||||||||
| 427 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 428 | } | - | ||||||||||||||||||||||||||||||||||||
| 429 | - | |||||||||||||||||||||||||||||||||||||
| 430 | id_data = PACKET_data(&responder_id); | - | ||||||||||||||||||||||||||||||||||||
| 431 | - | |||||||||||||||||||||||||||||||||||||
| 432 | id = d2i_OCSP_RESPID( | - | ||||||||||||||||||||||||||||||||||||
| 433 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 434 | , &id_data, | - | ||||||||||||||||||||||||||||||||||||
| 435 | (int)PACKET_remaining(&responder_id)); | - | ||||||||||||||||||||||||||||||||||||
| 436 | if (id ==
| 24-190 | ||||||||||||||||||||||||||||||||||||
| 437 | ((void *)0)
| 24-190 | ||||||||||||||||||||||||||||||||||||
| 438 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 439 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 440 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 441 | , | - | ||||||||||||||||||||||||||||||||||||
| 442 | 394 | - | ||||||||||||||||||||||||||||||||||||
| 443 | ) | - | ||||||||||||||||||||||||||||||||||||
| 444 | ; | - | ||||||||||||||||||||||||||||||||||||
| 445 | return executed 190 times by 1 test: 0;return 0;Executed by:
executed 190 times by 1 test: return 0;Executed by:
| 190 | ||||||||||||||||||||||||||||||||||||
| 446 | } | - | ||||||||||||||||||||||||||||||||||||
| 447 | - | |||||||||||||||||||||||||||||||||||||
| 448 | if (id_data != PACKET_end(&responder_id)
| 11-13 | ||||||||||||||||||||||||||||||||||||
| 449 | OCSP_RESPID_free(id); | - | ||||||||||||||||||||||||||||||||||||
| 450 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 451 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 452 | , | - | ||||||||||||||||||||||||||||||||||||
| 453 | 401 | - | ||||||||||||||||||||||||||||||||||||
| 454 | ) | - | ||||||||||||||||||||||||||||||||||||
| 455 | ; | - | ||||||||||||||||||||||||||||||||||||
| 456 | - | |||||||||||||||||||||||||||||||||||||
| 457 | return executed 11 times by 1 test: 0;return 0;Executed by:
executed 11 times by 1 test: return 0;Executed by:
| 11 | ||||||||||||||||||||||||||||||||||||
| 458 | } | - | ||||||||||||||||||||||||||||||||||||
| 459 | - | |||||||||||||||||||||||||||||||||||||
| 460 | if (!sk_OCSP_RESPID_push(s->ext.ocsp.ids, id)
| 0-13 | ||||||||||||||||||||||||||||||||||||
| 461 | OCSP_RESPID_free(id); | - | ||||||||||||||||||||||||||||||||||||
| 462 | ossl_statem_fatal((s), (80), (577), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 463 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 464 | , | - | ||||||||||||||||||||||||||||||||||||
| 465 | 409 | - | ||||||||||||||||||||||||||||||||||||
| 466 | ) | - | ||||||||||||||||||||||||||||||||||||
| 467 | ; | - | ||||||||||||||||||||||||||||||||||||
| 468 | - | |||||||||||||||||||||||||||||||||||||
| 469 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 470 | } | - | ||||||||||||||||||||||||||||||||||||
| 471 | } executed 13 times by 1 test: end of blockExecuted by:
| 13 | ||||||||||||||||||||||||||||||||||||
| 472 | - | |||||||||||||||||||||||||||||||||||||
| 473 | - | |||||||||||||||||||||||||||||||||||||
| 474 | if (!PACKET_as_length_prefixed_2(pkt, &exts)
| 2-226 | ||||||||||||||||||||||||||||||||||||
| 475 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 476 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 477 | , | - | ||||||||||||||||||||||||||||||||||||
| 478 | 418 | - | ||||||||||||||||||||||||||||||||||||
| 479 | ) | - | ||||||||||||||||||||||||||||||||||||
| 480 | ; | - | ||||||||||||||||||||||||||||||||||||
| 481 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 482 | } | - | ||||||||||||||||||||||||||||||||||||
| 483 | - | |||||||||||||||||||||||||||||||||||||
| 484 | if (PACKET_remaining(&exts) > 0
| 6-220 | ||||||||||||||||||||||||||||||||||||
| 485 | const unsigned char *ext_data = PACKET_data(&exts); | - | ||||||||||||||||||||||||||||||||||||
| 486 | - | |||||||||||||||||||||||||||||||||||||
| 487 | sk_X509_EXTENSION_pop_free(s->ext.ocsp.exts, | - | ||||||||||||||||||||||||||||||||||||
| 488 | X509_EXTENSION_free); | - | ||||||||||||||||||||||||||||||||||||
| 489 | s->ext.ocsp.exts = | - | ||||||||||||||||||||||||||||||||||||
| 490 | d2i_X509_EXTENSIONS( | - | ||||||||||||||||||||||||||||||||||||
| 491 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 492 | , &ext_data, (int)PACKET_remaining(&exts)); | - | ||||||||||||||||||||||||||||||||||||
| 493 | if (s->ext.ocsp.exts ==
| 2-4 | ||||||||||||||||||||||||||||||||||||
| 494 | ((void *)0)
| 2-4 | ||||||||||||||||||||||||||||||||||||
| 495 | || ext_data != PACKET_end(&exts)
| 1 | ||||||||||||||||||||||||||||||||||||
| 496 | ossl_statem_fatal((s), (50), (577), (110), | - | ||||||||||||||||||||||||||||||||||||
| 497 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 498 | , | - | ||||||||||||||||||||||||||||||||||||
| 499 | 431 | - | ||||||||||||||||||||||||||||||||||||
| 500 | ) | - | ||||||||||||||||||||||||||||||||||||
| 501 | ; | - | ||||||||||||||||||||||||||||||||||||
| 502 | return executed 5 times by 1 test: 0;return 0;Executed by:
executed 5 times by 1 test: return 0;Executed by:
| 5 | ||||||||||||||||||||||||||||||||||||
| 503 | } | - | ||||||||||||||||||||||||||||||||||||
| 504 | } executed 1 time by 1 test: end of blockExecuted by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 505 | - | |||||||||||||||||||||||||||||||||||||
| 506 | return executed 221 times by 1 test: 1;return 1;Executed by:
executed 221 times by 1 test: return 1;Executed by:
| 221 | ||||||||||||||||||||||||||||||||||||
| 507 | } | - | ||||||||||||||||||||||||||||||||||||
| 508 | - | |||||||||||||||||||||||||||||||||||||
| 509 | - | |||||||||||||||||||||||||||||||||||||
| 510 | - | |||||||||||||||||||||||||||||||||||||
| 511 | int tls_parse_ctos_npn(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 512 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 513 | { | - | ||||||||||||||||||||||||||||||||||||
| 514 | - | |||||||||||||||||||||||||||||||||||||
| 515 | - | |||||||||||||||||||||||||||||||||||||
| 516 | - | |||||||||||||||||||||||||||||||||||||
| 517 | - | |||||||||||||||||||||||||||||||||||||
| 518 | if (((
| 0-30 | ||||||||||||||||||||||||||||||||||||
| 519 | s->s3->npn_seen = 1; executed 30 times by 1 test: s->s3->npn_seen = 1;Executed by:
| 30 | ||||||||||||||||||||||||||||||||||||
| 520 | - | |||||||||||||||||||||||||||||||||||||
| 521 | return executed 30 times by 1 test: 1;return 1;Executed by:
executed 30 times by 1 test: return 1;Executed by:
| 30 | ||||||||||||||||||||||||||||||||||||
| 522 | } | - | ||||||||||||||||||||||||||||||||||||
| 523 | - | |||||||||||||||||||||||||||||||||||||
| 524 | - | |||||||||||||||||||||||||||||||||||||
| 525 | - | |||||||||||||||||||||||||||||||||||||
| 526 | - | |||||||||||||||||||||||||||||||||||||
| 527 | - | |||||||||||||||||||||||||||||||||||||
| 528 | - | |||||||||||||||||||||||||||||||||||||
| 529 | int tls_parse_ctos_alpn(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 530 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 531 | { | - | ||||||||||||||||||||||||||||||||||||
| 532 | PACKET protocol_list, save_protocol_list, protocol; | - | ||||||||||||||||||||||||||||||||||||
| 533 | - | |||||||||||||||||||||||||||||||||||||
| 534 | if (!((
| 0-76 | ||||||||||||||||||||||||||||||||||||
| 535 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 536 | - | |||||||||||||||||||||||||||||||||||||
| 537 | if (!PACKET_as_length_prefixed_2(pkt, &protocol_list)
| 2-74 | ||||||||||||||||||||||||||||||||||||
| 538 | || PACKET_remaining(&protocol_list) < 2
| 1-73 | ||||||||||||||||||||||||||||||||||||
| 539 | ossl_statem_fatal((s), (50), (567), (110), | - | ||||||||||||||||||||||||||||||||||||
| 540 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 541 | , | - | ||||||||||||||||||||||||||||||||||||
| 542 | 470 | - | ||||||||||||||||||||||||||||||||||||
| 543 | ) | - | ||||||||||||||||||||||||||||||||||||
| 544 | ; | - | ||||||||||||||||||||||||||||||||||||
| 545 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 546 | } | - | ||||||||||||||||||||||||||||||||||||
| 547 | - | |||||||||||||||||||||||||||||||||||||
| 548 | save_protocol_list = protocol_list; | - | ||||||||||||||||||||||||||||||||||||
| 549 | do { | - | ||||||||||||||||||||||||||||||||||||
| 550 | - | |||||||||||||||||||||||||||||||||||||
| 551 | if (!PACKET_get_length_prefixed_1(&protocol_list, &protocol)
| 5-333 | ||||||||||||||||||||||||||||||||||||
| 552 | || PACKET_remaining(&protocol) == 0
| 1-332 | ||||||||||||||||||||||||||||||||||||
| 553 | ossl_statem_fatal((s), (50), (567), (110), | - | ||||||||||||||||||||||||||||||||||||
| 554 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 555 | , | - | ||||||||||||||||||||||||||||||||||||
| 556 | 480 | - | ||||||||||||||||||||||||||||||||||||
| 557 | ) | - | ||||||||||||||||||||||||||||||||||||
| 558 | ; | - | ||||||||||||||||||||||||||||||||||||
| 559 | return executed 6 times by 1 test: 0;return 0;Executed by:
executed 6 times by 1 test: return 0;Executed by:
| 6 | ||||||||||||||||||||||||||||||||||||
| 560 | } | - | ||||||||||||||||||||||||||||||||||||
| 561 | } executed 332 times by 1 test: while (PACKET_remaining(&protocol_list) != 0end of blockExecuted by:
| 67-332 | ||||||||||||||||||||||||||||||||||||
| 562 | - | |||||||||||||||||||||||||||||||||||||
| 563 | CRYPTO_free(s->s3->alpn_proposed, __FILE__, 485); | - | ||||||||||||||||||||||||||||||||||||
| 564 | s->s3->alpn_proposed = | - | ||||||||||||||||||||||||||||||||||||
| 565 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 566 | ; | - | ||||||||||||||||||||||||||||||||||||
| 567 | s->s3->alpn_proposed_len = 0; | - | ||||||||||||||||||||||||||||||||||||
| 568 | if (!PACKET_memdup(&save_protocol_list,
| 0-67 | ||||||||||||||||||||||||||||||||||||
| 569 | &s->s3->alpn_proposed, &s->s3->alpn_proposed_len)
| 0-67 | ||||||||||||||||||||||||||||||||||||
| 570 | ossl_statem_fatal((s), (80), (567), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 571 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 572 | , | - | ||||||||||||||||||||||||||||||||||||
| 573 | 491 | - | ||||||||||||||||||||||||||||||||||||
| 574 | ) | - | ||||||||||||||||||||||||||||||||||||
| 575 | ; | - | ||||||||||||||||||||||||||||||||||||
| 576 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 577 | } | - | ||||||||||||||||||||||||||||||||||||
| 578 | - | |||||||||||||||||||||||||||||||||||||
| 579 | return executed 67 times by 1 test: 1;return 1;Executed by:
executed 67 times by 1 test: return 1;Executed by:
| 67 | ||||||||||||||||||||||||||||||||||||
| 580 | } | - | ||||||||||||||||||||||||||||||||||||
| 581 | - | |||||||||||||||||||||||||||||||||||||
| 582 | - | |||||||||||||||||||||||||||||||||||||
| 583 | int tls_parse_ctos_use_srtp(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 584 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 585 | { | - | ||||||||||||||||||||||||||||||||||||
| 586 | struct stack_st_SRTP_PROTECTION_PROFILE *srvr; | - | ||||||||||||||||||||||||||||||||||||
| 587 | unsigned int ct, mki_len, id; | - | ||||||||||||||||||||||||||||||||||||
| 588 | int i, srtp_pref; | - | ||||||||||||||||||||||||||||||||||||
| 589 | PACKET subpkt; | - | ||||||||||||||||||||||||||||||||||||
| 590 | - | |||||||||||||||||||||||||||||||||||||
| 591 | - | |||||||||||||||||||||||||||||||||||||
| 592 | if (SSL_get_srtp_profiles(s) ==
| 0 | ||||||||||||||||||||||||||||||||||||
| 593 | ((void *)0)
| 0 | ||||||||||||||||||||||||||||||||||||
| 594 | ) | - | ||||||||||||||||||||||||||||||||||||
| 595 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 596 | - | |||||||||||||||||||||||||||||||||||||
| 597 | - | |||||||||||||||||||||||||||||||||||||
| 598 | if (!PACKET_get_net_2(pkt, &ct)
| 0 | ||||||||||||||||||||||||||||||||||||
| 599 | || !PACKET_get_sub_packet(pkt, &subpkt, ct)
| 0 | ||||||||||||||||||||||||||||||||||||
| 600 | ossl_statem_fatal((s), (50), (465), (353), | - | ||||||||||||||||||||||||||||||||||||
| 601 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 602 | , | - | ||||||||||||||||||||||||||||||||||||
| 603 | 515 | - | ||||||||||||||||||||||||||||||||||||
| 604 | ) | - | ||||||||||||||||||||||||||||||||||||
| 605 | ; | - | ||||||||||||||||||||||||||||||||||||
| 606 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 607 | } | - | ||||||||||||||||||||||||||||||||||||
| 608 | - | |||||||||||||||||||||||||||||||||||||
| 609 | srvr = SSL_get_srtp_profiles(s); | - | ||||||||||||||||||||||||||||||||||||
| 610 | s->srtp_profile = | - | ||||||||||||||||||||||||||||||||||||
| 611 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 612 | ; | - | ||||||||||||||||||||||||||||||||||||
| 613 | - | |||||||||||||||||||||||||||||||||||||
| 614 | srtp_pref = sk_SRTP_PROTECTION_PROFILE_num(srvr); | - | ||||||||||||||||||||||||||||||||||||
| 615 | - | |||||||||||||||||||||||||||||||||||||
| 616 | while (PACKET_remaining(&subpkt)
| 0 | ||||||||||||||||||||||||||||||||||||
| 617 | if (!PACKET_get_net_2(&subpkt, &id)
| 0 | ||||||||||||||||||||||||||||||||||||
| 618 | ossl_statem_fatal((s), (50), (465), (353), | - | ||||||||||||||||||||||||||||||||||||
| 619 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 620 | , | - | ||||||||||||||||||||||||||||||||||||
| 621 | 527 | - | ||||||||||||||||||||||||||||||||||||
| 622 | ) | - | ||||||||||||||||||||||||||||||||||||
| 623 | ; | - | ||||||||||||||||||||||||||||||||||||
| 624 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 625 | } | - | ||||||||||||||||||||||||||||||||||||
| 626 | - | |||||||||||||||||||||||||||||||||||||
| 627 | - | |||||||||||||||||||||||||||||||||||||
| 628 | - | |||||||||||||||||||||||||||||||||||||
| 629 | - | |||||||||||||||||||||||||||||||||||||
| 630 | - | |||||||||||||||||||||||||||||||||||||
| 631 | - | |||||||||||||||||||||||||||||||||||||
| 632 | - | |||||||||||||||||||||||||||||||||||||
| 633 | for (i = 0; i < srtp_pref
| 0 | ||||||||||||||||||||||||||||||||||||
| 634 | SRTP_PROTECTION_PROFILE *sprof = | - | ||||||||||||||||||||||||||||||||||||
| 635 | sk_SRTP_PROTECTION_PROFILE_value(srvr, i); | - | ||||||||||||||||||||||||||||||||||||
| 636 | - | |||||||||||||||||||||||||||||||||||||
| 637 | if (sprof->id == id
| 0 | ||||||||||||||||||||||||||||||||||||
| 638 | s->srtp_profile = sprof; | - | ||||||||||||||||||||||||||||||||||||
| 639 | srtp_pref = i; | - | ||||||||||||||||||||||||||||||||||||
| 640 | break; never executed: break; | 0 | ||||||||||||||||||||||||||||||||||||
| 641 | } | - | ||||||||||||||||||||||||||||||||||||
| 642 | } never executed: end of block | 0 | ||||||||||||||||||||||||||||||||||||
| 643 | } never executed: end of block | 0 | ||||||||||||||||||||||||||||||||||||
| 644 | - | |||||||||||||||||||||||||||||||||||||
| 645 | - | |||||||||||||||||||||||||||||||||||||
| 646 | if (!PACKET_get_1(pkt, &mki_len)
| 0 | ||||||||||||||||||||||||||||||||||||
| 647 | ossl_statem_fatal((s), (50), (465), (353), | - | ||||||||||||||||||||||||||||||||||||
| 648 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 649 | , | - | ||||||||||||||||||||||||||||||||||||
| 650 | 552 | - | ||||||||||||||||||||||||||||||||||||
| 651 | ) | - | ||||||||||||||||||||||||||||||||||||
| 652 | ; | - | ||||||||||||||||||||||||||||||||||||
| 653 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 654 | } | - | ||||||||||||||||||||||||||||||||||||
| 655 | - | |||||||||||||||||||||||||||||||||||||
| 656 | if (!PACKET_forward(pkt, mki_len)
| 0 | ||||||||||||||||||||||||||||||||||||
| 657 | || PACKET_remaining(pkt)
| 0 | ||||||||||||||||||||||||||||||||||||
| 658 | ossl_statem_fatal((s), (50), (465), (352), | - | ||||||||||||||||||||||||||||||||||||
| 659 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 660 | , | - | ||||||||||||||||||||||||||||||||||||
| 661 | 559 | - | ||||||||||||||||||||||||||||||||||||
| 662 | ) | - | ||||||||||||||||||||||||||||||||||||
| 663 | ; | - | ||||||||||||||||||||||||||||||||||||
| 664 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 665 | } | - | ||||||||||||||||||||||||||||||||||||
| 666 | - | |||||||||||||||||||||||||||||||||||||
| 667 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 668 | } | - | ||||||||||||||||||||||||||||||||||||
| 669 | - | |||||||||||||||||||||||||||||||||||||
| 670 | - | |||||||||||||||||||||||||||||||||||||
| 671 | int tls_parse_ctos_etm(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 672 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 673 | { | - | ||||||||||||||||||||||||||||||||||||
| 674 | if (!(s->options & 0x00080000U)
| 2-1207 | ||||||||||||||||||||||||||||||||||||
| 675 | s->ext.use_etm = 1; executed 1207 times by 1 test: s->ext.use_etm = 1;Executed by:
| 1207 | ||||||||||||||||||||||||||||||||||||
| 676 | - | |||||||||||||||||||||||||||||||||||||
| 677 | return executed 1209 times by 1 test: 1;return 1;Executed by:
executed 1209 times by 1 test: return 1;Executed by:
| 1209 | ||||||||||||||||||||||||||||||||||||
| 678 | } | - | ||||||||||||||||||||||||||||||||||||
| 679 | - | |||||||||||||||||||||||||||||||||||||
| 680 | - | |||||||||||||||||||||||||||||||||||||
| 681 | - | |||||||||||||||||||||||||||||||||||||
| 682 | - | |||||||||||||||||||||||||||||||||||||
| 683 | - | |||||||||||||||||||||||||||||||||||||
| 684 | int tls_parse_ctos_psk_kex_modes(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 685 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 686 | { | - | ||||||||||||||||||||||||||||||||||||
| 687 | - | |||||||||||||||||||||||||||||||||||||
| 688 | PACKET psk_kex_modes; | - | ||||||||||||||||||||||||||||||||||||
| 689 | unsigned int mode; | - | ||||||||||||||||||||||||||||||||||||
| 690 | - | |||||||||||||||||||||||||||||||||||||
| 691 | if (!PACKET_as_length_prefixed_1(pkt, &psk_kex_modes)
| 2-836 | ||||||||||||||||||||||||||||||||||||
| 692 | || PACKET_remaining(&psk_kex_modes) == 0
| 2-834 | ||||||||||||||||||||||||||||||||||||
| 693 | ossl_statem_fatal((s), (50), (572), (110), | - | ||||||||||||||||||||||||||||||||||||
| 694 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 695 | , | - | ||||||||||||||||||||||||||||||||||||
| 696 | 590 | - | ||||||||||||||||||||||||||||||||||||
| 697 | ) | - | ||||||||||||||||||||||||||||||||||||
| 698 | ; | - | ||||||||||||||||||||||||||||||||||||
| 699 | return executed 4 times by 1 test: 0;return 0;Executed by:
executed 4 times by 1 test: return 0;Executed by:
| 4 | ||||||||||||||||||||||||||||||||||||
| 700 | } | - | ||||||||||||||||||||||||||||||||||||
| 701 | - | |||||||||||||||||||||||||||||||||||||
| 702 | while (PACKET_get_1(&psk_kex_modes, &mode)
| 834-1695 | ||||||||||||||||||||||||||||||||||||
| 703 | if (mode == 0x01
| 785-910 | ||||||||||||||||||||||||||||||||||||
| 704 | s->ext.psk_kex_mode |= 2; executed 910 times by 1 test: s->ext.psk_kex_mode |= 2;Executed by:
| 910 | ||||||||||||||||||||||||||||||||||||
| 705 | else if (mode == 0x00
| 286-499 | ||||||||||||||||||||||||||||||||||||
| 706 | && (
| 2-284 | ||||||||||||||||||||||||||||||||||||
| 707 | s->ext.psk_kex_mode |= 1; executed 2 times by 1 test: s->ext.psk_kex_mode |= 1;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 708 | } executed 1695 times by 1 test: end of blockExecuted by:
| 1695 | ||||||||||||||||||||||||||||||||||||
| 709 | - | |||||||||||||||||||||||||||||||||||||
| 710 | - | |||||||||||||||||||||||||||||||||||||
| 711 | return executed 834 times by 1 test: 1;return 1;Executed by:
executed 834 times by 1 test: return 1;Executed by:
| 834 | ||||||||||||||||||||||||||||||||||||
| 712 | } | - | ||||||||||||||||||||||||||||||||||||
| 713 | - | |||||||||||||||||||||||||||||||||||||
| 714 | - | |||||||||||||||||||||||||||||||||||||
| 715 | - | |||||||||||||||||||||||||||||||||||||
| 716 | - | |||||||||||||||||||||||||||||||||||||
| 717 | - | |||||||||||||||||||||||||||||||||||||
| 718 | int tls_parse_ctos_key_share(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 719 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 720 | { | - | ||||||||||||||||||||||||||||||||||||
| 721 | - | |||||||||||||||||||||||||||||||||||||
| 722 | unsigned int group_id; | - | ||||||||||||||||||||||||||||||||||||
| 723 | PACKET key_share_list, encoded_pt; | - | ||||||||||||||||||||||||||||||||||||
| 724 | const uint16_t *clntgroups, *srvrgroups; | - | ||||||||||||||||||||||||||||||||||||
| 725 | size_t clnt_num_groups, srvr_num_groups; | - | ||||||||||||||||||||||||||||||||||||
| 726 | int found = 0; | - | ||||||||||||||||||||||||||||||||||||
| 727 | - | |||||||||||||||||||||||||||||||||||||
| 728 | if (s->hit
| 1-935 | ||||||||||||||||||||||||||||||||||||
| 729 | return executed 1 time by 1 test: 1;return 1;Executed by:
executed 1 time by 1 test: return 1;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 730 | - | |||||||||||||||||||||||||||||||||||||
| 731 | - | |||||||||||||||||||||||||||||||||||||
| 732 | if (s->s3->peer_tmp !=
| 0-1068 | ||||||||||||||||||||||||||||||||||||
| 733 | ((void *)0)
| 0-1068 | ||||||||||||||||||||||||||||||||||||
| 734 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 735 | ossl_statem_fatal((s), (80), (463), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 736 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 737 | , | - | ||||||||||||||||||||||||||||||||||||
| 738 | 626 | - | ||||||||||||||||||||||||||||||||||||
| 739 | ) | - | ||||||||||||||||||||||||||||||||||||
| 740 | ; | - | ||||||||||||||||||||||||||||||||||||
| 741 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 742 | } | - | ||||||||||||||||||||||||||||||||||||
| 743 | - | |||||||||||||||||||||||||||||||||||||
| 744 | if (!PACKET_as_length_prefixed_2(pkt, &key_share_list)
| 3-1065 | ||||||||||||||||||||||||||||||||||||
| 745 | ossl_statem_fatal((s), (50), (463), (159), | - | ||||||||||||||||||||||||||||||||||||
| 746 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 747 | , | - | ||||||||||||||||||||||||||||||||||||
| 748 | 632 | - | ||||||||||||||||||||||||||||||||||||
| 749 | ) | - | ||||||||||||||||||||||||||||||||||||
| 750 | ; | - | ||||||||||||||||||||||||||||||||||||
| 751 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 752 | } | - | ||||||||||||||||||||||||||||||||||||
| 753 | - | |||||||||||||||||||||||||||||||||||||
| 754 | - | |||||||||||||||||||||||||||||||||||||
| 755 | tls1_get_supported_groups(s, &srvrgroups, &srvr_num_groups); | - | ||||||||||||||||||||||||||||||||||||
| 756 | - | |||||||||||||||||||||||||||||||||||||
| 757 | tls1_get_peer_groups(s, &clntgroups, &clnt_num_groups); | - | ||||||||||||||||||||||||||||||||||||
| 758 | if (clnt_num_groups == 0
| 1-1064 | ||||||||||||||||||||||||||||||||||||
| 759 | - | |||||||||||||||||||||||||||||||||||||
| 760 | - | |||||||||||||||||||||||||||||||||||||
| 761 | - | |||||||||||||||||||||||||||||||||||||
| 762 | - | |||||||||||||||||||||||||||||||||||||
| 763 | - | |||||||||||||||||||||||||||||||||||||
| 764 | ossl_statem_fatal((s), (109), (463), (209), | - | ||||||||||||||||||||||||||||||||||||
| 765 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 766 | , | - | ||||||||||||||||||||||||||||||||||||
| 767 | 647 | - | ||||||||||||||||||||||||||||||||||||
| 768 | ) | - | ||||||||||||||||||||||||||||||||||||
| 769 | ; | - | ||||||||||||||||||||||||||||||||||||
| 770 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 771 | } | - | ||||||||||||||||||||||||||||||||||||
| 772 | - | |||||||||||||||||||||||||||||||||||||
| 773 | if (s->s3->group_id != 0
| 1-1023 | ||||||||||||||||||||||||||||||||||||
| 774 | - | |||||||||||||||||||||||||||||||||||||
| 775 | - | |||||||||||||||||||||||||||||||||||||
| 776 | - | |||||||||||||||||||||||||||||||||||||
| 777 | - | |||||||||||||||||||||||||||||||||||||
| 778 | - | |||||||||||||||||||||||||||||||||||||
| 779 | ossl_statem_fatal((s), (47), (463), (108), | - | ||||||||||||||||||||||||||||||||||||
| 780 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 781 | , | - | ||||||||||||||||||||||||||||||||||||
| 782 | 658 | - | ||||||||||||||||||||||||||||||||||||
| 783 | ) | - | ||||||||||||||||||||||||||||||||||||
| 784 | ; | - | ||||||||||||||||||||||||||||||||||||
| 785 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 786 | } | - | ||||||||||||||||||||||||||||||||||||
| 787 | - | |||||||||||||||||||||||||||||||||||||
| 788 | while (PACKET_remaining(&key_share_list) > 0
| 1007-1533 | ||||||||||||||||||||||||||||||||||||
| 789 | if (!PACKET_get_net_2(&key_share_list, &group_id)
| 4-1529 | ||||||||||||||||||||||||||||||||||||
| 790 | || !PACKET_get_length_prefixed_2(&key_share_list, &encoded_pt)
| 18-1511 | ||||||||||||||||||||||||||||||||||||
| 791 | || PACKET_remaining(&encoded_pt) == 0
| 8-1503 | ||||||||||||||||||||||||||||||||||||
| 792 | ossl_statem_fatal((s), (50), (463), (159), | - | ||||||||||||||||||||||||||||||||||||
| 793 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 794 | , | - | ||||||||||||||||||||||||||||||||||||
| 795 | 667 | - | ||||||||||||||||||||||||||||||||||||
| 796 | ) | - | ||||||||||||||||||||||||||||||||||||
| 797 | ; | - | ||||||||||||||||||||||||||||||||||||
| 798 | return executed 30 times by 1 test: 0;return 0;Executed by:
executed 30 times by 1 test: return 0;Executed by:
| 30 | ||||||||||||||||||||||||||||||||||||
| 799 | } | - | ||||||||||||||||||||||||||||||||||||
| 800 | - | |||||||||||||||||||||||||||||||||||||
| 801 | - | |||||||||||||||||||||||||||||||||||||
| 802 | - | |||||||||||||||||||||||||||||||||||||
| 803 | - | |||||||||||||||||||||||||||||||||||||
| 804 | - | |||||||||||||||||||||||||||||||||||||
| 805 | if (found
| 398-1105 | ||||||||||||||||||||||||||||||||||||
| 806 | continue; executed 398 times by 1 test: continue;Executed by:
| 398 | ||||||||||||||||||||||||||||||||||||
| 807 | - | |||||||||||||||||||||||||||||||||||||
| 808 | - | |||||||||||||||||||||||||||||||||||||
| 809 | - | |||||||||||||||||||||||||||||||||||||
| 810 | - | |||||||||||||||||||||||||||||||||||||
| 811 | - | |||||||||||||||||||||||||||||||||||||
| 812 | if (s->s3->group_id != 0
| 40-1065 | ||||||||||||||||||||||||||||||||||||
| 813 | && (group_id != s->s3->group_id
| 2-38 | ||||||||||||||||||||||||||||||||||||
| 814 | || PACKET_remaining(&key_share_list) != 0
| 1-37 | ||||||||||||||||||||||||||||||||||||
| 815 | ossl_statem_fatal((s), (47), (463), (108), | - | ||||||||||||||||||||||||||||||||||||
| 816 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 817 | , | - | ||||||||||||||||||||||||||||||||||||
| 818 | 686 | - | ||||||||||||||||||||||||||||||||||||
| 819 | ) | - | ||||||||||||||||||||||||||||||||||||
| 820 | ; | - | ||||||||||||||||||||||||||||||||||||
| 821 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 822 | } | - | ||||||||||||||||||||||||||||||||||||
| 823 | - | |||||||||||||||||||||||||||||||||||||
| 824 | - | |||||||||||||||||||||||||||||||||||||
| 825 | if (!check_in_list(s, group_id, clntgroups, clnt_num_groups, 0)
| 2-1100 | ||||||||||||||||||||||||||||||||||||
| 826 | ossl_statem_fatal((s), (47), (463), (108), | - | ||||||||||||||||||||||||||||||||||||
| 827 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 828 | , | - | ||||||||||||||||||||||||||||||||||||
| 829 | 693 | - | ||||||||||||||||||||||||||||||||||||
| 830 | ) | - | ||||||||||||||||||||||||||||||||||||
| 831 | ; | - | ||||||||||||||||||||||||||||||||||||
| 832 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 833 | } | - | ||||||||||||||||||||||||||||||||||||
| 834 | - | |||||||||||||||||||||||||||||||||||||
| 835 | - | |||||||||||||||||||||||||||||||||||||
| 836 | if (!check_in_list(s, group_id, srvrgroups, srvr_num_groups, 1)
| 179-921 | ||||||||||||||||||||||||||||||||||||
| 837 | - | |||||||||||||||||||||||||||||||||||||
| 838 | continue; executed 179 times by 1 test: continue;Executed by:
| 179 | ||||||||||||||||||||||||||||||||||||
| 839 | } | - | ||||||||||||||||||||||||||||||||||||
| 840 | - | |||||||||||||||||||||||||||||||||||||
| 841 | if ((
| 0-921 | ||||||||||||||||||||||||||||||||||||
| 842 | ((void *)0)
| 0-921 | ||||||||||||||||||||||||||||||||||||
| 843 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 844 | ossl_statem_fatal((s), (80), (463), (314), | - | ||||||||||||||||||||||||||||||||||||
| 845 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 846 | , | - | ||||||||||||||||||||||||||||||||||||
| 847 | 705 | - | ||||||||||||||||||||||||||||||||||||
| 848 | ) | - | ||||||||||||||||||||||||||||||||||||
| 849 | ; | - | ||||||||||||||||||||||||||||||||||||
| 850 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 851 | } | - | ||||||||||||||||||||||||||||||||||||
| 852 | - | |||||||||||||||||||||||||||||||||||||
| 853 | s->s3->group_id = group_id; | - | ||||||||||||||||||||||||||||||||||||
| 854 | - | |||||||||||||||||||||||||||||||||||||
| 855 | if (!EVP_PKEY_set1_tls_encodedpoint(s->s3->peer_tmp,
| 21-900 | ||||||||||||||||||||||||||||||||||||
| 856 | PACKET_data(&encoded_pt),
| 21-900 | ||||||||||||||||||||||||||||||||||||
| 857 | PACKET_remaining(&encoded_pt))
| 21-900 | ||||||||||||||||||||||||||||||||||||
| 858 | ossl_statem_fatal((s), (47), (463), (306), | - | ||||||||||||||||||||||||||||||||||||
| 859 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 860 | , | - | ||||||||||||||||||||||||||||||||||||
| 861 | 715 | - | ||||||||||||||||||||||||||||||||||||
| 862 | ) | - | ||||||||||||||||||||||||||||||||||||
| 863 | ; | - | ||||||||||||||||||||||||||||||||||||
| 864 | return executed 21 times by 1 test: 0;return 0;Executed by:
executed 21 times by 1 test: return 0;Executed by:
| 21 | ||||||||||||||||||||||||||||||||||||
| 865 | } | - | ||||||||||||||||||||||||||||||||||||
| 866 | - | |||||||||||||||||||||||||||||||||||||
| 867 | found = 1; | - | ||||||||||||||||||||||||||||||||||||
| 868 | } executed 900 times by 1 test: end of blockExecuted by:
| 900 | ||||||||||||||||||||||||||||||||||||
| 869 | - | |||||||||||||||||||||||||||||||||||||
| 870 | - | |||||||||||||||||||||||||||||||||||||
| 871 | return executed 1007 times by 1 test: 1;return 1;Executed by:
executed 1007 times by 1 test: return 1;Executed by:
| 1007 | ||||||||||||||||||||||||||||||||||||
| 872 | } | - | ||||||||||||||||||||||||||||||||||||
| 873 | - | |||||||||||||||||||||||||||||||||||||
| 874 | int tls_parse_ctos_cookie(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 875 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 876 | { | - | ||||||||||||||||||||||||||||||||||||
| 877 | - | |||||||||||||||||||||||||||||||||||||
| 878 | unsigned int format, version, key_share, group_id; | - | ||||||||||||||||||||||||||||||||||||
| 879 | EVP_MD_CTX *hctx; | - | ||||||||||||||||||||||||||||||||||||
| 880 | EVP_PKEY *pkey; | - | ||||||||||||||||||||||||||||||||||||
| 881 | PACKET cookie, raw, chhash, appcookie; | - | ||||||||||||||||||||||||||||||||||||
| 882 | WPACKET hrrpkt; | - | ||||||||||||||||||||||||||||||||||||
| 883 | const unsigned char *data, *mdin, *ciphdata; | - | ||||||||||||||||||||||||||||||||||||
| 884 | unsigned char hmac[32]; | - | ||||||||||||||||||||||||||||||||||||
| 885 | unsigned char hrr[(4 + 2 + 32 + 1 + 32 + 2 + 1 + 2 + 6 + 4 + (2 + 2 + 2 + 2 + 2 + 1 + 4 + 2 + 64 + 1 + 4096 + 32))]; | - | ||||||||||||||||||||||||||||||||||||
| 886 | size_t rawlen, hmaclen, hrrlen, ciphlen; | - | ||||||||||||||||||||||||||||||||||||
| 887 | unsigned long tm, now; | - | ||||||||||||||||||||||||||||||||||||
| 888 | - | |||||||||||||||||||||||||||||||||||||
| 889 | - | |||||||||||||||||||||||||||||||||||||
| 890 | if (s->ctx->verify_stateless_cookie_cb ==
| 3-4 | ||||||||||||||||||||||||||||||||||||
| 891 | ((void *)0)
| 3-4 | ||||||||||||||||||||||||||||||||||||
| 892 | - | |||||||||||||||||||||||||||||||||||||
| 893 | || (
| 1-2 | ||||||||||||||||||||||||||||||||||||
| 894 | return executed 6 times by 1 test: 1;return 1;Executed by:
executed 6 times by 1 test: return 1;Executed by:
| 6 | ||||||||||||||||||||||||||||||||||||
| 895 | - | |||||||||||||||||||||||||||||||||||||
| 896 | if (!PACKET_as_length_prefixed_2(pkt, &cookie)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 897 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 898 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 899 | , | - | ||||||||||||||||||||||||||||||||||||
| 900 | 748 | - | ||||||||||||||||||||||||||||||||||||
| 901 | ) | - | ||||||||||||||||||||||||||||||||||||
| 902 | ; | - | ||||||||||||||||||||||||||||||||||||
| 903 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 904 | } | - | ||||||||||||||||||||||||||||||||||||
| 905 | - | |||||||||||||||||||||||||||||||||||||
| 906 | raw = cookie; | - | ||||||||||||||||||||||||||||||||||||
| 907 | data = PACKET_data(&raw); | - | ||||||||||||||||||||||||||||||||||||
| 908 | rawlen = PACKET_remaining(&raw); | - | ||||||||||||||||||||||||||||||||||||
| 909 | if (rawlen < 32
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 910 | || !PACKET_forward(&raw, rawlen - 32)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 911 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 912 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 913 | , | - | ||||||||||||||||||||||||||||||||||||
| 914 | 758 | - | ||||||||||||||||||||||||||||||||||||
| 915 | ) | - | ||||||||||||||||||||||||||||||||||||
| 916 | ; | - | ||||||||||||||||||||||||||||||||||||
| 917 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 918 | } | - | ||||||||||||||||||||||||||||||||||||
| 919 | mdin = PACKET_data(&raw); | - | ||||||||||||||||||||||||||||||||||||
| 920 | - | |||||||||||||||||||||||||||||||||||||
| 921 | - | |||||||||||||||||||||||||||||||||||||
| 922 | hctx = EVP_MD_CTX_new(); | - | ||||||||||||||||||||||||||||||||||||
| 923 | pkey = EVP_PKEY_new_raw_private_key(855, | - | ||||||||||||||||||||||||||||||||||||
| 924 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 925 | , | - | ||||||||||||||||||||||||||||||||||||
| 926 | s->session_ctx->ext.cookie_hmac_key, | - | ||||||||||||||||||||||||||||||||||||
| 927 | sizeof(s->session_ctx->ext | - | ||||||||||||||||||||||||||||||||||||
| 928 | .cookie_hmac_key)); | - | ||||||||||||||||||||||||||||||||||||
| 929 | if (hctx ==
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 930 | ((void *)0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 931 | || pkey ==
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 932 | ((void *)0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 933 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 934 | EVP_MD_CTX_free(hctx); | - | ||||||||||||||||||||||||||||||||||||
| 935 | EVP_PKEY_free(pkey); | - | ||||||||||||||||||||||||||||||||||||
| 936 | ossl_statem_fatal((s), (80), (614), ((1|64)), | - | ||||||||||||||||||||||||||||||||||||
| 937 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 938 | , | - | ||||||||||||||||||||||||||||||||||||
| 939 | 773 | - | ||||||||||||||||||||||||||||||||||||
| 940 | ) | - | ||||||||||||||||||||||||||||||||||||
| 941 | ; | - | ||||||||||||||||||||||||||||||||||||
| 942 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 943 | } | - | ||||||||||||||||||||||||||||||||||||
| 944 | - | |||||||||||||||||||||||||||||||||||||
| 945 | hmaclen = 32; | - | ||||||||||||||||||||||||||||||||||||
| 946 | if (EVP_DigestSignInit(hctx,
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 947 | ((void *)0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 948 | , EVP_sha256(),
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 949 | ((void *)0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 950 | , pkey) <= 0
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 951 | || EVP_DigestSign(hctx, hmac, &hmaclen, data,
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 952 | rawlen - 32) <= 0
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 953 | || hmaclen != 32
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 954 | EVP_MD_CTX_free(hctx); | - | ||||||||||||||||||||||||||||||||||||
| 955 | EVP_PKEY_free(pkey); | - | ||||||||||||||||||||||||||||||||||||
| 956 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 957 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 958 | , | - | ||||||||||||||||||||||||||||||||||||
| 959 | 785 | - | ||||||||||||||||||||||||||||||||||||
| 960 | ) | - | ||||||||||||||||||||||||||||||||||||
| 961 | ; | - | ||||||||||||||||||||||||||||||||||||
| 962 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 963 | } | - | ||||||||||||||||||||||||||||||||||||
| 964 | - | |||||||||||||||||||||||||||||||||||||
| 965 | EVP_MD_CTX_free(hctx); | - | ||||||||||||||||||||||||||||||||||||
| 966 | EVP_PKEY_free(pkey); | - | ||||||||||||||||||||||||||||||||||||
| 967 | - | |||||||||||||||||||||||||||||||||||||
| 968 | if (CRYPTO_memcmp(hmac, mdin, 32) != 0
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 969 | ossl_statem_fatal((s), (47), (614), (308), | - | ||||||||||||||||||||||||||||||||||||
| 970 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 971 | , | - | ||||||||||||||||||||||||||||||||||||
| 972 | 794 | - | ||||||||||||||||||||||||||||||||||||
| 973 | ) | - | ||||||||||||||||||||||||||||||||||||
| 974 | ; | - | ||||||||||||||||||||||||||||||||||||
| 975 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 976 | } | - | ||||||||||||||||||||||||||||||||||||
| 977 | - | |||||||||||||||||||||||||||||||||||||
| 978 | if (!PACKET_get_net_2(&cookie, &format)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 979 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 980 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 981 | , | - | ||||||||||||||||||||||||||||||||||||
| 982 | 800 | - | ||||||||||||||||||||||||||||||||||||
| 983 | ) | - | ||||||||||||||||||||||||||||||||||||
| 984 | ; | - | ||||||||||||||||||||||||||||||||||||
| 985 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 986 | } | - | ||||||||||||||||||||||||||||||||||||
| 987 | - | |||||||||||||||||||||||||||||||||||||
| 988 | if (format != 0
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 989 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 990 | - | |||||||||||||||||||||||||||||||||||||
| 991 | - | |||||||||||||||||||||||||||||||||||||
| 992 | - | |||||||||||||||||||||||||||||||||||||
| 993 | - | |||||||||||||||||||||||||||||||||||||
| 994 | - | |||||||||||||||||||||||||||||||||||||
| 995 | - | |||||||||||||||||||||||||||||||||||||
| 996 | - | |||||||||||||||||||||||||||||||||||||
| 997 | if (!PACKET_get_net_2(&cookie, &version)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 998 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 999 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1000 | , | - | ||||||||||||||||||||||||||||||||||||
| 1001 | 815 | - | ||||||||||||||||||||||||||||||||||||
| 1002 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1003 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1004 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1005 | } | - | ||||||||||||||||||||||||||||||||||||
| 1006 | if (version != 0x0304
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1007 | ossl_statem_fatal((s), (47), (614), (116), | - | ||||||||||||||||||||||||||||||||||||
| 1008 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1009 | , | - | ||||||||||||||||||||||||||||||||||||
| 1010 | 820 | - | ||||||||||||||||||||||||||||||||||||
| 1011 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1012 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1013 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1014 | } | - | ||||||||||||||||||||||||||||||||||||
| 1015 | - | |||||||||||||||||||||||||||||||||||||
| 1016 | if (!PACKET_get_net_2(&cookie, &group_id)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1017 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 1018 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1019 | , | - | ||||||||||||||||||||||||||||||||||||
| 1020 | 826 | - | ||||||||||||||||||||||||||||||||||||
| 1021 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1022 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1023 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1024 | } | - | ||||||||||||||||||||||||||||||||||||
| 1025 | - | |||||||||||||||||||||||||||||||||||||
| 1026 | ciphdata = PACKET_data(&cookie); | - | ||||||||||||||||||||||||||||||||||||
| 1027 | if (!PACKET_forward(&cookie, 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1028 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 1029 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1030 | , | - | ||||||||||||||||||||||||||||||||||||
| 1031 | 833 | - | ||||||||||||||||||||||||||||||||||||
| 1032 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1033 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1034 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1035 | } | - | ||||||||||||||||||||||||||||||||||||
| 1036 | if (group_id != s->s3->group_id
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1037 | || s->s3->tmp.new_cipher
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1038 | != ssl_get_cipher_by_char(s, ciphdata, 0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1039 | - | |||||||||||||||||||||||||||||||||||||
| 1040 | - | |||||||||||||||||||||||||||||||||||||
| 1041 | - | |||||||||||||||||||||||||||||||||||||
| 1042 | - | |||||||||||||||||||||||||||||||||||||
| 1043 | ossl_statem_fatal((s), (47), (614), (186), | - | ||||||||||||||||||||||||||||||||||||
| 1044 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1045 | , | - | ||||||||||||||||||||||||||||||||||||
| 1046 | 844 | - | ||||||||||||||||||||||||||||||||||||
| 1047 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1048 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1049 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1050 | } | - | ||||||||||||||||||||||||||||||||||||
| 1051 | - | |||||||||||||||||||||||||||||||||||||
| 1052 | if (!PACKET_get_1(&cookie, &key_share)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1053 | || !PACKET_get_net_4(&cookie, &tm)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1054 | || !PACKET_get_length_prefixed_2(&cookie, &chhash)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1055 | || !PACKET_get_length_prefixed_1(&cookie, &appcookie)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1056 | || PACKET_remaining(&cookie) != 32
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1057 | ossl_statem_fatal((s), (50), (614), (159), | - | ||||||||||||||||||||||||||||||||||||
| 1058 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1059 | , | - | ||||||||||||||||||||||||||||||||||||
| 1060 | 854 | - | ||||||||||||||||||||||||||||||||||||
| 1061 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1062 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1063 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1064 | } | - | ||||||||||||||||||||||||||||||||||||
| 1065 | - | |||||||||||||||||||||||||||||||||||||
| 1066 | - | |||||||||||||||||||||||||||||||||||||
| 1067 | now = (unsigned long)time( | - | ||||||||||||||||||||||||||||||||||||
| 1068 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1069 | ); | - | ||||||||||||||||||||||||||||||||||||
| 1070 | if (tm > now
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1071 | - | |||||||||||||||||||||||||||||||||||||
| 1072 | return never executed: 1;return 1;never executed: return 1; | 0 | ||||||||||||||||||||||||||||||||||||
| 1073 | } | - | ||||||||||||||||||||||||||||||||||||
| 1074 | - | |||||||||||||||||||||||||||||||||||||
| 1075 | - | |||||||||||||||||||||||||||||||||||||
| 1076 | if (s->ctx->verify_stateless_cookie_cb(s, PACKET_data(&appcookie),
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1077 | PACKET_remaining(&appcookie)) == 0
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1078 | ossl_statem_fatal((s), (47), (614), (308), | - | ||||||||||||||||||||||||||||||||||||
| 1079 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1080 | , | - | ||||||||||||||||||||||||||||||||||||
| 1081 | 869 | - | ||||||||||||||||||||||||||||||||||||
| 1082 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1083 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1084 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1085 | } | - | ||||||||||||||||||||||||||||||||||||
| 1086 | - | |||||||||||||||||||||||||||||||||||||
| 1087 | - | |||||||||||||||||||||||||||||||||||||
| 1088 | - | |||||||||||||||||||||||||||||||||||||
| 1089 | - | |||||||||||||||||||||||||||||||||||||
| 1090 | - | |||||||||||||||||||||||||||||||||||||
| 1091 | - | |||||||||||||||||||||||||||||||||||||
| 1092 | if (!WPACKET_init_static_len(&hrrpkt, hrr, sizeof(hrr), 0)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1093 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1094 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1095 | , | - | ||||||||||||||||||||||||||||||||||||
| 1096 | 880 | - | ||||||||||||||||||||||||||||||||||||
| 1097 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1098 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1099 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1100 | } | - | ||||||||||||||||||||||||||||||||||||
| 1101 | if (!WPACKET_put_bytes__((&hrrpkt), (2), 1)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1102 | || !WPACKET_start_sub_packet_len__((&hrrpkt), 3)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1103 | || !WPACKET_put_bytes__((&hrrpkt), (0x0303), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1104 | || !WPACKET_memcpy(&hrrpkt, hrrrandom, 32)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1105 | || !WPACKET_sub_memcpy__((&hrrpkt), (s->tmp_session_id), (s->tmp_session_id_len), 1)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1106 | - | |||||||||||||||||||||||||||||||||||||
| 1107 | || !s->method->put_cipher_by_char(s->s3->tmp.new_cipher, &hrrpkt,
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1108 | &ciphlen)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1109 | || !WPACKET_put_bytes__((&hrrpkt), (0), 1)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1110 | || !WPACKET_start_sub_packet_len__((&hrrpkt), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1111 | WPACKET_cleanup(&hrrpkt); | - | ||||||||||||||||||||||||||||||||||||
| 1112 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1113 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1114 | , | - | ||||||||||||||||||||||||||||||||||||
| 1115 | 895 | - | ||||||||||||||||||||||||||||||||||||
| 1116 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1117 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1118 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1119 | } | - | ||||||||||||||||||||||||||||||||||||
| 1120 | if (!WPACKET_put_bytes__((&hrrpkt), (43), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1121 | || !WPACKET_start_sub_packet_len__((&hrrpkt), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1122 | || !WPACKET_put_bytes__((&hrrpkt), (s->version), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1123 | || !WPACKET_close(&hrrpkt)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1124 | WPACKET_cleanup(&hrrpkt); | - | ||||||||||||||||||||||||||||||||||||
| 1125 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1126 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1127 | , | - | ||||||||||||||||||||||||||||||||||||
| 1128 | 904 | - | ||||||||||||||||||||||||||||||||||||
| 1129 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1130 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1131 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1132 | } | - | ||||||||||||||||||||||||||||||||||||
| 1133 | if (key_share
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1134 | if (!WPACKET_put_bytes__((&hrrpkt), (51), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1135 | || !WPACKET_start_sub_packet_len__((&hrrpkt), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1136 | || !WPACKET_put_bytes__((&hrrpkt), (s->s3->group_id), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1137 | || !WPACKET_close(&hrrpkt)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1138 | WPACKET_cleanup(&hrrpkt); | - | ||||||||||||||||||||||||||||||||||||
| 1139 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1140 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1141 | , | - | ||||||||||||||||||||||||||||||||||||
| 1142 | 914 | - | ||||||||||||||||||||||||||||||||||||
| 1143 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1144 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1145 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1146 | } | - | ||||||||||||||||||||||||||||||||||||
| 1147 | } never executed: end of block | 0 | ||||||||||||||||||||||||||||||||||||
| 1148 | if (!WPACKET_put_bytes__((&hrrpkt), (44), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1149 | || !WPACKET_start_sub_packet_len__((&hrrpkt), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1150 | || !WPACKET_sub_memcpy__((&hrrpkt), (data), (rawlen), 2)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1151 | || !WPACKET_close(&hrrpkt)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1152 | || !WPACKET_close(&hrrpkt)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1153 | || !WPACKET_close(&hrrpkt)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1154 | || !WPACKET_get_total_written(&hrrpkt, &hrrlen)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1155 | || !WPACKET_finish(&hrrpkt)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1156 | WPACKET_cleanup(&hrrpkt); | - | ||||||||||||||||||||||||||||||||||||
| 1157 | ossl_statem_fatal((s), (80), (614), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1158 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1159 | , | - | ||||||||||||||||||||||||||||||||||||
| 1160 | 928 | - | ||||||||||||||||||||||||||||||||||||
| 1161 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1162 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1163 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1164 | } | - | ||||||||||||||||||||||||||||||||||||
| 1165 | - | |||||||||||||||||||||||||||||||||||||
| 1166 | - | |||||||||||||||||||||||||||||||||||||
| 1167 | if (!create_synthetic_message_hash(s, PACKET_data(&chhash),
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1168 | PACKET_remaining(&chhash), hrr,
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1169 | hrrlen)
| 0-1 | ||||||||||||||||||||||||||||||||||||
| 1170 | - | |||||||||||||||||||||||||||||||||||||
| 1171 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1172 | } | - | ||||||||||||||||||||||||||||||||||||
| 1173 | - | |||||||||||||||||||||||||||||||||||||
| 1174 | - | |||||||||||||||||||||||||||||||||||||
| 1175 | s->hello_retry_request = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1176 | - | |||||||||||||||||||||||||||||||||||||
| 1177 | s->ext.cookieok = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1178 | - | |||||||||||||||||||||||||||||||||||||
| 1179 | - | |||||||||||||||||||||||||||||||||||||
| 1180 | return executed 1 time by 1 test: 1;return 1;Executed by:
executed 1 time by 1 test: return 1;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1181 | } | - | ||||||||||||||||||||||||||||||||||||
| 1182 | - | |||||||||||||||||||||||||||||||||||||
| 1183 | - | |||||||||||||||||||||||||||||||||||||
| 1184 | int tls_parse_ctos_supported_groups(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 1185 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1186 | { | - | ||||||||||||||||||||||||||||||||||||
| 1187 | PACKET supported_groups_list; | - | ||||||||||||||||||||||||||||||||||||
| 1188 | - | |||||||||||||||||||||||||||||||||||||
| 1189 | - | |||||||||||||||||||||||||||||||||||||
| 1190 | if (!PACKET_as_length_prefixed_2(pkt, &supported_groups_list)
| 5-2514 | ||||||||||||||||||||||||||||||||||||
| 1191 | || PACKET_remaining(&supported_groups_list) == 0
| 1-2513 | ||||||||||||||||||||||||||||||||||||
| 1192 | || (
| 1-2512 | ||||||||||||||||||||||||||||||||||||
| 1193 | ossl_statem_fatal((s), (50), (578), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1194 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1195 | , | - | ||||||||||||||||||||||||||||||||||||
| 1196 | 960 | - | ||||||||||||||||||||||||||||||||||||
| 1197 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1198 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1199 | return executed 7 times by 1 test: 0;return 0;Executed by:
executed 7 times by 1 test: return 0;Executed by:
| 7 | ||||||||||||||||||||||||||||||||||||
| 1200 | } | - | ||||||||||||||||||||||||||||||||||||
| 1201 | - | |||||||||||||||||||||||||||||||||||||
| 1202 | if (!s->hit
| 0-2306 | ||||||||||||||||||||||||||||||||||||
| 1203 | CRYPTO_free(s->session->ext.supportedgroups, __FILE__, 965); | - | ||||||||||||||||||||||||||||||||||||
| 1204 | s->session->ext.supportedgroups = | - | ||||||||||||||||||||||||||||||||||||
| 1205 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1206 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1207 | s->session->ext.supportedgroups_len = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1208 | if (!tls1_save_u16(&supported_groups_list,
| 0-2440 | ||||||||||||||||||||||||||||||||||||
| 1209 | &s->session->ext.supportedgroups,
| 0-2440 | ||||||||||||||||||||||||||||||||||||
| 1210 | &s->session->ext.supportedgroups_len)
| 0-2440 | ||||||||||||||||||||||||||||||||||||
| 1211 | ossl_statem_fatal((s), (80), (578), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1212 | - | |||||||||||||||||||||||||||||||||||||
| 1213 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1214 | , | - | ||||||||||||||||||||||||||||||||||||
| 1215 | - | |||||||||||||||||||||||||||||||||||||
| 1216 | 973 | - | ||||||||||||||||||||||||||||||||||||
| 1217 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1218 | - | |||||||||||||||||||||||||||||||||||||
| 1219 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1220 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1221 | } | - | ||||||||||||||||||||||||||||||||||||
| 1222 | } executed 2440 times by 1 test: end of blockExecuted by:
| 2440 | ||||||||||||||||||||||||||||||||||||
| 1223 | - | |||||||||||||||||||||||||||||||||||||
| 1224 | return executed 2512 times by 1 test: 1;return 1;Executed by:
executed 2512 times by 1 test: return 1;Executed by:
| 2512 | ||||||||||||||||||||||||||||||||||||
| 1225 | } | - | ||||||||||||||||||||||||||||||||||||
| 1226 | - | |||||||||||||||||||||||||||||||||||||
| 1227 | - | |||||||||||||||||||||||||||||||||||||
| 1228 | int tls_parse_ctos_ems(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1229 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1230 | { | - | ||||||||||||||||||||||||||||||||||||
| 1231 | - | |||||||||||||||||||||||||||||||||||||
| 1232 | if (PACKET_remaining(pkt) != 0
| 1-1390 | ||||||||||||||||||||||||||||||||||||
| 1233 | ossl_statem_fatal((s), (50), (570), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1234 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1235 | , | - | ||||||||||||||||||||||||||||||||||||
| 1236 | 988 | - | ||||||||||||||||||||||||||||||||||||
| 1237 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1238 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1239 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1240 | } | - | ||||||||||||||||||||||||||||||||||||
| 1241 | - | |||||||||||||||||||||||||||||||||||||
| 1242 | s->s3->flags |= 0x0200; | - | ||||||||||||||||||||||||||||||||||||
| 1243 | - | |||||||||||||||||||||||||||||||||||||
| 1244 | return executed 1390 times by 1 test: 1;return 1;Executed by:
executed 1390 times by 1 test: return 1;Executed by:
| 1390 | ||||||||||||||||||||||||||||||||||||
| 1245 | } | - | ||||||||||||||||||||||||||||||||||||
| 1246 | - | |||||||||||||||||||||||||||||||||||||
| 1247 | - | |||||||||||||||||||||||||||||||||||||
| 1248 | int tls_parse_ctos_early_data(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 1249 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1250 | { | - | ||||||||||||||||||||||||||||||||||||
| 1251 | if (PACKET_remaining(pkt) != 0
| 1-217 | ||||||||||||||||||||||||||||||||||||
| 1252 | ossl_statem_fatal((s), (50), (568), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1253 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1254 | , | - | ||||||||||||||||||||||||||||||||||||
| 1255 | 1003 | - | ||||||||||||||||||||||||||||||||||||
| 1256 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1257 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1258 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1259 | } | - | ||||||||||||||||||||||||||||||||||||
| 1260 | - | |||||||||||||||||||||||||||||||||||||
| 1261 | if (s->hello_retry_request != SSL_HRR_NONE
| 1-216 | ||||||||||||||||||||||||||||||||||||
| 1262 | ossl_statem_fatal((s), (47), (568), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1263 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1264 | , | - | ||||||||||||||||||||||||||||||||||||
| 1265 | 1009 | - | ||||||||||||||||||||||||||||||||||||
| 1266 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1267 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1268 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1269 | } | - | ||||||||||||||||||||||||||||||||||||
| 1270 | - | |||||||||||||||||||||||||||||||||||||
| 1271 | return executed 216 times by 1 test: 1;return 1;Executed by:
executed 216 times by 1 test: return 1;Executed by:
| 216 | ||||||||||||||||||||||||||||||||||||
| 1272 | } | - | ||||||||||||||||||||||||||||||||||||
| 1273 | - | |||||||||||||||||||||||||||||||||||||
| 1274 | static SSL_TICKET_STATUS tls_get_stateful_ticket(SSL *s, PACKET *tick, | - | ||||||||||||||||||||||||||||||||||||
| 1275 | SSL_SESSION **sess) | - | ||||||||||||||||||||||||||||||||||||
| 1276 | { | - | ||||||||||||||||||||||||||||||||||||
| 1277 | SSL_SESSION *tmpsess = | - | ||||||||||||||||||||||||||||||||||||
| 1278 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1279 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1280 | - | |||||||||||||||||||||||||||||||||||||
| 1281 | s->ext.ticket_expected = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1282 | - | |||||||||||||||||||||||||||||||||||||
| 1283 | switch (PACKET_remaining(tick)) { | - | ||||||||||||||||||||||||||||||||||||
| 1284 | case never executed: 0:case 0:never executed: case 0: | 0 | ||||||||||||||||||||||||||||||||||||
| 1285 | return never executed: 3;return 3;never executed: return 3; | 0 | ||||||||||||||||||||||||||||||||||||
| 1286 | - | |||||||||||||||||||||||||||||||||||||
| 1287 | case executed 54 times by 1 test: 32:case 32:Executed by:
executed 54 times by 1 test: case 32:Executed by:
| 54 | ||||||||||||||||||||||||||||||||||||
| 1288 | break; executed 54 times by 1 test: break;Executed by:
| 54 | ||||||||||||||||||||||||||||||||||||
| 1289 | - | |||||||||||||||||||||||||||||||||||||
| 1290 | default executed 2 times by 1 test: :default:Executed by:
executed 2 times by 1 test: default:Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1291 | return executed 2 times by 1 test: 4;return 4;Executed by:
executed 2 times by 1 test: return 4;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1292 | } | - | ||||||||||||||||||||||||||||||||||||
| 1293 | - | |||||||||||||||||||||||||||||||||||||
| 1294 | tmpsess = lookup_sess_in_cache(s, PACKET_data(tick), | - | ||||||||||||||||||||||||||||||||||||
| 1295 | 32); | - | ||||||||||||||||||||||||||||||||||||
| 1296 | - | |||||||||||||||||||||||||||||||||||||
| 1297 | if (tmpsess ==
| 14-40 | ||||||||||||||||||||||||||||||||||||
| 1298 | ((void *)0)
| 14-40 | ||||||||||||||||||||||||||||||||||||
| 1299 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1300 | return executed 14 times by 1 test: 4;return 4;Executed by:
executed 14 times by 1 test: return 4;Executed by:
| 14 | ||||||||||||||||||||||||||||||||||||
| 1301 | - | |||||||||||||||||||||||||||||||||||||
| 1302 | *sess = tmpsess; | - | ||||||||||||||||||||||||||||||||||||
| 1303 | return executed 40 times by 1 test: 5;return 5;Executed by:
executed 40 times by 1 test: return 5;Executed by:
| 40 | ||||||||||||||||||||||||||||||||||||
| 1304 | } | - | ||||||||||||||||||||||||||||||||||||
| 1305 | - | |||||||||||||||||||||||||||||||||||||
| 1306 | int tls_parse_ctos_psk(SSL *s, PACKET *pkt, unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1307 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1308 | { | - | ||||||||||||||||||||||||||||||||||||
| 1309 | PACKET identities, binders, binder; | - | ||||||||||||||||||||||||||||||||||||
| 1310 | size_t binderoffset, hashsize; | - | ||||||||||||||||||||||||||||||||||||
| 1311 | SSL_SESSION *sess = | - | ||||||||||||||||||||||||||||||||||||
| 1312 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1313 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1314 | unsigned int id, i, ext = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1315 | const EVP_MD *md = | - | ||||||||||||||||||||||||||||||||||||
| 1316 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1317 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1318 | - | |||||||||||||||||||||||||||||||||||||
| 1319 | - | |||||||||||||||||||||||||||||||||||||
| 1320 | - | |||||||||||||||||||||||||||||||||||||
| 1321 | - | |||||||||||||||||||||||||||||||||||||
| 1322 | - | |||||||||||||||||||||||||||||||||||||
| 1323 | if ((
| 3-184 | ||||||||||||||||||||||||||||||||||||
| 1324 | & (1 | 2)) == 0
| 3-184 | ||||||||||||||||||||||||||||||||||||
| 1325 | return executed 3 times by 1 test: 1;return 1;Executed by:
executed 3 times by 1 test: return 1;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 1326 | - | |||||||||||||||||||||||||||||||||||||
| 1327 | if (!PACKET_get_length_prefixed_2(pkt, &identities)
| 2-182 | ||||||||||||||||||||||||||||||||||||
| 1328 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1329 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1330 | , | - | ||||||||||||||||||||||||||||||||||||
| 1331 | 1063 | - | ||||||||||||||||||||||||||||||||||||
| 1332 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1333 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1334 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1335 | } | - | ||||||||||||||||||||||||||||||||||||
| 1336 | - | |||||||||||||||||||||||||||||||||||||
| 1337 | s->ext.ticket_expected = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1338 | for (id = 0; PACKET_remaining(&identities) != 0
| 38-185 | ||||||||||||||||||||||||||||||||||||
| 1339 | PACKET identity; | - | ||||||||||||||||||||||||||||||||||||
| 1340 | unsigned long ticket_agel; | - | ||||||||||||||||||||||||||||||||||||
| 1341 | size_t idlen; | - | ||||||||||||||||||||||||||||||||||||
| 1342 | - | |||||||||||||||||||||||||||||||||||||
| 1343 | if (!PACKET_get_length_prefixed_2(&identities, &identity)
| 2-183 | ||||||||||||||||||||||||||||||||||||
| 1344 | || !PACKET_get_net_4(&identities, &ticket_agel)
| 1-182 | ||||||||||||||||||||||||||||||||||||
| 1345 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1346 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1347 | , | - | ||||||||||||||||||||||||||||||||||||
| 1348 | 1076 | - | ||||||||||||||||||||||||||||||||||||
| 1349 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1350 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1351 | return executed 3 times by 1 test: 0;return 0;Executed by:
executed 3 times by 1 test: return 0;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 1352 | } | - | ||||||||||||||||||||||||||||||||||||
| 1353 | - | |||||||||||||||||||||||||||||||||||||
| 1354 | idlen = PACKET_remaining(&identity); | - | ||||||||||||||||||||||||||||||||||||
| 1355 | if (s->psk_find_session_cb !=
| 25-157 | ||||||||||||||||||||||||||||||||||||
| 1356 | ((void *)0)
| 25-157 | ||||||||||||||||||||||||||||||||||||
| 1357 | - | |||||||||||||||||||||||||||||||||||||
| 1358 | && !s->psk_find_session_cb(s, PACKET_data(&identity), idlen,
| 0-25 | ||||||||||||||||||||||||||||||||||||
| 1359 | &sess)
| 0-25 | ||||||||||||||||||||||||||||||||||||
| 1360 | ossl_statem_fatal((s), (80), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1361 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1362 | , | - | ||||||||||||||||||||||||||||||||||||
| 1363 | 1085 | - | ||||||||||||||||||||||||||||||||||||
| 1364 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1365 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1366 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1367 | } | - | ||||||||||||||||||||||||||||||||||||
| 1368 | - | |||||||||||||||||||||||||||||||||||||
| 1369 | - | |||||||||||||||||||||||||||||||||||||
| 1370 | if(sess ==
| 20-162 | ||||||||||||||||||||||||||||||||||||
| 1371 | ((void *)0)
| 20-162 | ||||||||||||||||||||||||||||||||||||
| 1372 | - | |||||||||||||||||||||||||||||||||||||
| 1373 | && s->psk_server_callback !=
| 8-154 | ||||||||||||||||||||||||||||||||||||
| 1374 | ((void *)0)
| 8-154 | ||||||||||||||||||||||||||||||||||||
| 1375 | - | |||||||||||||||||||||||||||||||||||||
| 1376 | && idlen <= 128
| 0-8 | ||||||||||||||||||||||||||||||||||||
| 1377 | char *pskid = | - | ||||||||||||||||||||||||||||||||||||
| 1378 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1379 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1380 | unsigned char pskdata[256]; | - | ||||||||||||||||||||||||||||||||||||
| 1381 | unsigned int pskdatalen; | - | ||||||||||||||||||||||||||||||||||||
| 1382 | - | |||||||||||||||||||||||||||||||||||||
| 1383 | if (!PACKET_strndup(&identity, &pskid)
| 0-8 | ||||||||||||||||||||||||||||||||||||
| 1384 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1385 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1386 | , | - | ||||||||||||||||||||||||||||||||||||
| 1387 | 1099 | - | ||||||||||||||||||||||||||||||||||||
| 1388 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1389 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1390 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1391 | } | - | ||||||||||||||||||||||||||||||||||||
| 1392 | pskdatalen = s->psk_server_callback(s, pskid, pskdata, | - | ||||||||||||||||||||||||||||||||||||
| 1393 | sizeof(pskdata)); | - | ||||||||||||||||||||||||||||||||||||
| 1394 | CRYPTO_free(pskid, __FILE__, 1104); | - | ||||||||||||||||||||||||||||||||||||
| 1395 | if (pskdatalen > 256
| 0-8 | ||||||||||||||||||||||||||||||||||||
| 1396 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1397 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1398 | , | - | ||||||||||||||||||||||||||||||||||||
| 1399 | 1107 | - | ||||||||||||||||||||||||||||||||||||
| 1400 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1401 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1402 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1403 | } else if (pskdatalen > 0
| 2-6 | ||||||||||||||||||||||||||||||||||||
| 1404 | const SSL_CIPHER *cipher; | - | ||||||||||||||||||||||||||||||||||||
| 1405 | const unsigned char tls13_aes128gcmsha256_id[] = { 0x13, 0x01 }; | - | ||||||||||||||||||||||||||||||||||||
| 1406 | - | |||||||||||||||||||||||||||||||||||||
| 1407 | - | |||||||||||||||||||||||||||||||||||||
| 1408 | - | |||||||||||||||||||||||||||||||||||||
| 1409 | - | |||||||||||||||||||||||||||||||||||||
| 1410 | - | |||||||||||||||||||||||||||||||||||||
| 1411 | cipher = SSL_CIPHER_find(s, tls13_aes128gcmsha256_id); | - | ||||||||||||||||||||||||||||||||||||
| 1412 | if (cipher ==
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1413 | ((void *)0)
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1414 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 1415 | OPENSSL_cleanse(pskdata, pskdatalen); | - | ||||||||||||||||||||||||||||||||||||
| 1416 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1417 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1418 | , | - | ||||||||||||||||||||||||||||||||||||
| 1419 | 1121 | - | ||||||||||||||||||||||||||||||||||||
| 1420 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1421 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1422 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1423 | } | - | ||||||||||||||||||||||||||||||||||||
| 1424 | - | |||||||||||||||||||||||||||||||||||||
| 1425 | sess = SSL_SESSION_new(); | - | ||||||||||||||||||||||||||||||||||||
| 1426 | if (sess ==
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1427 | ((void *)0)
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1428 | - | |||||||||||||||||||||||||||||||||||||
| 1429 | || !SSL_SESSION_set1_master_key(sess, pskdata,
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1430 | pskdatalen)
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1431 | || !SSL_SESSION_set_cipher(sess, cipher)
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1432 | || !SSL_SESSION_set_protocol_version(sess,
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1433 | 0x0304)
| 0-6 | ||||||||||||||||||||||||||||||||||||
| 1434 | OPENSSL_cleanse(pskdata, pskdatalen); | - | ||||||||||||||||||||||||||||||||||||
| 1435 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1436 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1437 | , | - | ||||||||||||||||||||||||||||||||||||
| 1438 | 1134 | - | ||||||||||||||||||||||||||||||||||||
| 1439 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1440 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1441 | goto never executed: err;goto err;never executed: goto err; | 0 | ||||||||||||||||||||||||||||||||||||
| 1442 | } | - | ||||||||||||||||||||||||||||||||||||
| 1443 | OPENSSL_cleanse(pskdata, pskdatalen); | - | ||||||||||||||||||||||||||||||||||||
| 1444 | } executed 6 times by 1 test: end of blockExecuted by:
| 6 | ||||||||||||||||||||||||||||||||||||
| 1445 | } executed 8 times by 1 test: end of blockExecuted by:
| 8 | ||||||||||||||||||||||||||||||||||||
| 1446 | - | |||||||||||||||||||||||||||||||||||||
| 1447 | - | |||||||||||||||||||||||||||||||||||||
| 1448 | if (sess !=
| 26-156 | ||||||||||||||||||||||||||||||||||||
| 1449 | ((void *)0)
| 26-156 | ||||||||||||||||||||||||||||||||||||
| 1450 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 1451 | - | |||||||||||||||||||||||||||||||||||||
| 1452 | SSL_SESSION *sesstmp = ssl_session_dup(sess, 0); | - | ||||||||||||||||||||||||||||||||||||
| 1453 | - | |||||||||||||||||||||||||||||||||||||
| 1454 | if (sesstmp ==
| 0-26 | ||||||||||||||||||||||||||||||||||||
| 1455 | ((void *)0)
| 0-26 | ||||||||||||||||||||||||||||||||||||
| 1456 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 1457 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1458 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1459 | , | - | ||||||||||||||||||||||||||||||||||||
| 1460 | 1148 | - | ||||||||||||||||||||||||||||||||||||
| 1461 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1462 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1463 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1464 | } | - | ||||||||||||||||||||||||||||||||||||
| 1465 | SSL_SESSION_free(sess); | - | ||||||||||||||||||||||||||||||||||||
| 1466 | sess = sesstmp; | - | ||||||||||||||||||||||||||||||||||||
| 1467 | - | |||||||||||||||||||||||||||||||||||||
| 1468 | - | |||||||||||||||||||||||||||||||||||||
| 1469 | - | |||||||||||||||||||||||||||||||||||||
| 1470 | - | |||||||||||||||||||||||||||||||||||||
| 1471 | - | |||||||||||||||||||||||||||||||||||||
| 1472 | memcpy(sess->sid_ctx, s->sid_ctx, s->sid_ctx_length); | - | ||||||||||||||||||||||||||||||||||||
| 1473 | sess->sid_ctx_length = s->sid_ctx_length; | - | ||||||||||||||||||||||||||||||||||||
| 1474 | ext = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1475 | if (id == 0
| 0-26 | ||||||||||||||||||||||||||||||||||||
| 1476 | s->ext.early_data_ok = 1; executed 26 times by 1 test: s->ext.early_data_ok = 1;Executed by:
| 26 | ||||||||||||||||||||||||||||||||||||
| 1477 | s->ext.ticket_expected = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1478 | } executed 26 times by 1 test: else {end of blockExecuted by:
| 26 | ||||||||||||||||||||||||||||||||||||
| 1479 | uint32_t ticket_age = 0, now, agesec, agems; | - | ||||||||||||||||||||||||||||||||||||
| 1480 | int ret; | - | ||||||||||||||||||||||||||||||||||||
| 1481 | - | |||||||||||||||||||||||||||||||||||||
| 1482 | - | |||||||||||||||||||||||||||||||||||||
| 1483 | - | |||||||||||||||||||||||||||||||||||||
| 1484 | - | |||||||||||||||||||||||||||||||||||||
| 1485 | - | |||||||||||||||||||||||||||||||||||||
| 1486 | - | |||||||||||||||||||||||||||||||||||||
| 1487 | if ((
| 11-145 | ||||||||||||||||||||||||||||||||||||
| 1488 | || (s->max_early_data > 0
| 61-84 | ||||||||||||||||||||||||||||||||||||
| 1489 | && (
| 16-45 | ||||||||||||||||||||||||||||||||||||
| 1490 | ret = tls_get_stateful_ticket(s, &identity, &sess); executed 56 times by 1 test: ret = tls_get_stateful_ticket(s, &identity, &sess);Executed by:
| 56 | ||||||||||||||||||||||||||||||||||||
| 1491 | else | - | ||||||||||||||||||||||||||||||||||||
| 1492 | ret = tls_decrypt_ticket(s, PACKET_data(&identity), executed 100 times by 1 test: ret = tls_decrypt_ticket(s, PACKET_data(&identity), PACKET_remaining(&identity), ((void *)0) , 0, &sess);Executed by:
| 100 | ||||||||||||||||||||||||||||||||||||
| 1493 | PACKET_remaining(&identity), executed 100 times by 1 test: ret = tls_decrypt_ticket(s, PACKET_data(&identity), PACKET_remaining(&identity), ((void *)0) , 0, &sess);Executed by:
| 100 | ||||||||||||||||||||||||||||||||||||
| 1494 | ((void *)0) executed 100 times by 1 test: ret = tls_decrypt_ticket(s, PACKET_data(&identity), PACKET_remaining(&identity), ((void *)0) , 0, &sess);Executed by:
| 100 | ||||||||||||||||||||||||||||||||||||
| 1495 | , 0, executed 100 times by 1 test: ret = tls_decrypt_ticket(s, PACKET_data(&identity), PACKET_remaining(&identity), ((void *)0) , 0, &sess);Executed by:
| 100 | ||||||||||||||||||||||||||||||||||||
| 1496 | &sess); executed 100 times by 1 test: ret = tls_decrypt_ticket(s, PACKET_data(&identity), PACKET_remaining(&identity), ((void *)0) , 0, &sess);Executed by:
| 100 | ||||||||||||||||||||||||||||||||||||
| 1497 | - | |||||||||||||||||||||||||||||||||||||
| 1498 | if (ret == 3
| 2-154 | ||||||||||||||||||||||||||||||||||||
| 1499 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1500 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1501 | , | - | ||||||||||||||||||||||||||||||||||||
| 1502 | 1184 | - | ||||||||||||||||||||||||||||||||||||
| 1503 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1504 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1505 | return executed 2 times by 1 test: 0;return 0;Executed by:
executed 2 times by 1 test: return 0;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1506 | } | - | ||||||||||||||||||||||||||||||||||||
| 1507 | - | |||||||||||||||||||||||||||||||||||||
| 1508 | if (ret == 0
| 0-154 | ||||||||||||||||||||||||||||||||||||
| 1509 | || ret == 1
| 0-154 | ||||||||||||||||||||||||||||||||||||
| 1510 | ossl_statem_fatal((s), (80), (505), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1511 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1512 | , | - | ||||||||||||||||||||||||||||||||||||
| 1513 | 1191 | - | ||||||||||||||||||||||||||||||||||||
| 1514 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1515 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1516 | return never executed: 0;return 0;never executed: return 0; | 0 | ||||||||||||||||||||||||||||||||||||
| 1517 | } | - | ||||||||||||||||||||||||||||||||||||
| 1518 | if (ret == 2
| 1-153 | ||||||||||||||||||||||||||||||||||||
| 1519 | continue; executed 36 times by 1 test: continue;Executed by:
| 36 | ||||||||||||||||||||||||||||||||||||
| 1520 | - | |||||||||||||||||||||||||||||||||||||
| 1521 | - | |||||||||||||||||||||||||||||||||||||
| 1522 | if (s->max_early_data > 0
| 48-70 | ||||||||||||||||||||||||||||||||||||
| 1523 | && (
| 16-32 | ||||||||||||||||||||||||||||||||||||
| 1524 | && !SSL_CTX_remove_session(s->session_ctx, sess)
| 0-32 | ||||||||||||||||||||||||||||||||||||
| 1525 | SSL_SESSION_free(sess); | - | ||||||||||||||||||||||||||||||||||||
| 1526 | sess = | - | ||||||||||||||||||||||||||||||||||||
| 1527 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1528 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1529 | continue; never executed: continue; | 0 | ||||||||||||||||||||||||||||||||||||
| 1530 | } | - | ||||||||||||||||||||||||||||||||||||
| 1531 | - | |||||||||||||||||||||||||||||||||||||
| 1532 | ticket_age = (uint32_t)ticket_agel; | - | ||||||||||||||||||||||||||||||||||||
| 1533 | now = (uint32_t)time( | - | ||||||||||||||||||||||||||||||||||||
| 1534 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1535 | ); | - | ||||||||||||||||||||||||||||||||||||
| 1536 | agesec = now - (uint32_t)sess->time; | - | ||||||||||||||||||||||||||||||||||||
| 1537 | agems = agesec * (uint32_t)1000; | - | ||||||||||||||||||||||||||||||||||||
| 1538 | ticket_age -= sess->ext.tick_age_add; | - | ||||||||||||||||||||||||||||||||||||
| 1539 | if (id == 0
| 0-118 | ||||||||||||||||||||||||||||||||||||
| 1540 | && sess->timeout >= (long)agesec
| 5-113 | ||||||||||||||||||||||||||||||||||||
| 1541 | && agems / (uint32_t)1000 == agesec
| 0-113 | ||||||||||||||||||||||||||||||||||||
| 1542 | && ticket_age <= agems + 1000
| 7-106 | ||||||||||||||||||||||||||||||||||||
| 1543 | && ticket_age + (10 * 1000) >= agems + 1000
| 0-106 | ||||||||||||||||||||||||||||||||||||
| 1544 | - | |||||||||||||||||||||||||||||||||||||
| 1545 | - | |||||||||||||||||||||||||||||||||||||
| 1546 | - | |||||||||||||||||||||||||||||||||||||
| 1547 | - | |||||||||||||||||||||||||||||||||||||
| 1548 | s->ext.early_data_ok = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1549 | } executed 106 times by 1 test: end of blockExecuted by:
| 106 | ||||||||||||||||||||||||||||||||||||
| 1550 | } executed 118 times by 1 test: end of blockExecuted by:
| 118 | ||||||||||||||||||||||||||||||||||||
| 1551 | - | |||||||||||||||||||||||||||||||||||||
| 1552 | md = ssl_md(sess->cipher->algorithm2); | - | ||||||||||||||||||||||||||||||||||||
| 1553 | if (md != ssl_md(s->s3->tmp.new_cipher->algorithm2)
| 5-139 | ||||||||||||||||||||||||||||||||||||
| 1554 | - | |||||||||||||||||||||||||||||||||||||
| 1555 | SSL_SESSION_free(sess); | - | ||||||||||||||||||||||||||||||||||||
| 1556 | sess = | - | ||||||||||||||||||||||||||||||||||||
| 1557 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 1558 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1559 | s->ext.early_data_ok = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1560 | s->ext.ticket_expected = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1561 | continue; executed 5 times by 1 test: continue;Executed by:
| 5 | ||||||||||||||||||||||||||||||||||||
| 1562 | } | - | ||||||||||||||||||||||||||||||||||||
| 1563 | break; executed 139 times by 1 test: break;Executed by:
| 139 | ||||||||||||||||||||||||||||||||||||
| 1564 | } | - | ||||||||||||||||||||||||||||||||||||
| 1565 | - | |||||||||||||||||||||||||||||||||||||
| 1566 | if (sess ==
| 38-139 | ||||||||||||||||||||||||||||||||||||
| 1567 | ((void *)0)
| 38-139 | ||||||||||||||||||||||||||||||||||||
| 1568 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1569 | return executed 38 times by 1 test: 1;return 1;Executed by:
executed 38 times by 1 test: return 1;Executed by:
| 38 | ||||||||||||||||||||||||||||||||||||
| 1570 | - | |||||||||||||||||||||||||||||||||||||
| 1571 | binderoffset = PACKET_data(pkt) - (const unsigned char *)s->init_buf->data; | - | ||||||||||||||||||||||||||||||||||||
| 1572 | hashsize = EVP_MD_size(md); | - | ||||||||||||||||||||||||||||||||||||
| 1573 | - | |||||||||||||||||||||||||||||||||||||
| 1574 | if (!PACKET_get_length_prefixed_2(pkt, &binders)
| 2-137 | ||||||||||||||||||||||||||||||||||||
| 1575 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1576 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1577 | , | - | ||||||||||||||||||||||||||||||||||||
| 1578 | 1253 | - | ||||||||||||||||||||||||||||||||||||
| 1579 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1580 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1581 | goto executed 2 times by 1 test: err;goto err;Executed by:
executed 2 times by 1 test: goto err;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1582 | } | - | ||||||||||||||||||||||||||||||||||||
| 1583 | - | |||||||||||||||||||||||||||||||||||||
| 1584 | for (i = 0; i <= id
| 135-137 | ||||||||||||||||||||||||||||||||||||
| 1585 | if (!PACKET_get_length_prefixed_1(&binders, &binder)
| 2-135 | ||||||||||||||||||||||||||||||||||||
| 1586 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1587 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1588 | , | - | ||||||||||||||||||||||||||||||||||||
| 1589 | 1260 | - | ||||||||||||||||||||||||||||||||||||
| 1590 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1591 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1592 | goto executed 2 times by 1 test: err;goto err;Executed by:
executed 2 times by 1 test: goto err;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 1593 | } | - | ||||||||||||||||||||||||||||||||||||
| 1594 | } executed 135 times by 1 test: end of blockExecuted by:
| 135 | ||||||||||||||||||||||||||||||||||||
| 1595 | - | |||||||||||||||||||||||||||||||||||||
| 1596 | if (PACKET_remaining(&binder) != hashsize
| 1-134 | ||||||||||||||||||||||||||||||||||||
| 1597 | ossl_statem_fatal((s), (50), (505), (110), | - | ||||||||||||||||||||||||||||||||||||
| 1598 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1599 | , | - | ||||||||||||||||||||||||||||||||||||
| 1600 | 1267 | - | ||||||||||||||||||||||||||||||||||||
| 1601 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1602 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1603 | goto executed 1 time by 1 test: err;goto err;Executed by:
executed 1 time by 1 test: goto err;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1604 | } | - | ||||||||||||||||||||||||||||||||||||
| 1605 | if (tls_psk_do_binder(s, md, (const unsigned char *)s->init_buf->data,
| 1-133 | ||||||||||||||||||||||||||||||||||||
| 1606 | binderoffset, PACKET_data(&binder),
| 1-133 | ||||||||||||||||||||||||||||||||||||
| 1607 | ((void *)0)
| 1-133 | ||||||||||||||||||||||||||||||||||||
| 1608 | , sess, 0,
| 1-133 | ||||||||||||||||||||||||||||||||||||
| 1609 | ext) != 1
| 1-133 | ||||||||||||||||||||||||||||||||||||
| 1610 | - | |||||||||||||||||||||||||||||||||||||
| 1611 | goto executed 1 time by 1 test: err;goto err;Executed by:
executed 1 time by 1 test: goto err;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1612 | } | - | ||||||||||||||||||||||||||||||||||||
| 1613 | - | |||||||||||||||||||||||||||||||||||||
| 1614 | sess->ext.tick_identity = id; | - | ||||||||||||||||||||||||||||||||||||
| 1615 | - | |||||||||||||||||||||||||||||||||||||
| 1616 | SSL_SESSION_free(s->session); | - | ||||||||||||||||||||||||||||||||||||
| 1617 | s->session = sess; | - | ||||||||||||||||||||||||||||||||||||
| 1618 | return executed 133 times by 1 test: 1;return 1;Executed by:
executed 133 times by 1 test: return 1;Executed by:
| 133 | ||||||||||||||||||||||||||||||||||||
| 1619 | err: | - | ||||||||||||||||||||||||||||||||||||
| 1620 | SSL_SESSION_free(sess); | - | ||||||||||||||||||||||||||||||||||||
| 1621 | return executed 6 times by 1 test: 0;return 0;Executed by:
executed 6 times by 1 test: return 0;Executed by:
| 6 | ||||||||||||||||||||||||||||||||||||
| 1622 | } | - | ||||||||||||||||||||||||||||||||||||
| 1623 | - | |||||||||||||||||||||||||||||||||||||
| 1624 | int tls_parse_ctos_post_handshake_auth(SSL *s, PACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 1625 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1626 | { | - | ||||||||||||||||||||||||||||||||||||
| 1627 | if (PACKET_remaining(pkt) != 0
| 1-48 | ||||||||||||||||||||||||||||||||||||
| 1628 | ossl_statem_fatal((s), (50), (620), (278), | - | ||||||||||||||||||||||||||||||||||||
| 1629 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1630 | , | - | ||||||||||||||||||||||||||||||||||||
| 1631 | 1292 | - | ||||||||||||||||||||||||||||||||||||
| 1632 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1633 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1634 | return executed 1 time by 1 test: 0;return 0;Executed by:
executed 1 time by 1 test: return 0;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 1635 | } | - | ||||||||||||||||||||||||||||||||||||
| 1636 | - | |||||||||||||||||||||||||||||||||||||
| 1637 | s->post_handshake_auth = SSL_PHA_EXT_RECEIVED; | - | ||||||||||||||||||||||||||||||||||||
| 1638 | - | |||||||||||||||||||||||||||||||||||||
| 1639 | return executed 48 times by 1 test: 1;return 1;Executed by:
executed 48 times by 1 test: return 1;Executed by:
| 48 | ||||||||||||||||||||||||||||||||||||
| 1640 | } | - | ||||||||||||||||||||||||||||||||||||
| 1641 | - | |||||||||||||||||||||||||||||||||||||
| 1642 | - | |||||||||||||||||||||||||||||||||||||
| 1643 | - | |||||||||||||||||||||||||||||||||||||
| 1644 | - | |||||||||||||||||||||||||||||||||||||
| 1645 | EXT_RETURN tls_construct_stoc_renegotiate(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1646 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1647 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1648 | { | - | ||||||||||||||||||||||||||||||||||||
| 1649 | if (!s->s3->send_connection_binding
| 157-1353 | ||||||||||||||||||||||||||||||||||||
| 1650 | return executed 157 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 157 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 157 | ||||||||||||||||||||||||||||||||||||
| 1651 | - | |||||||||||||||||||||||||||||||||||||
| 1652 | - | |||||||||||||||||||||||||||||||||||||
| 1653 | if (!WPACKET_put_bytes__((pkt), (0xff01), 2)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1654 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1655 | || !WPACKET_start_sub_packet_len__((pkt), 1)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1656 | || !WPACKET_memcpy(pkt, s->s3->previous_client_finished,
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1657 | s->s3->previous_client_finished_len)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1658 | || !WPACKET_memcpy(pkt, s->s3->previous_server_finished,
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1659 | s->s3->previous_server_finished_len)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1660 | || !WPACKET_close(pkt)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1661 | || !WPACKET_close(pkt)
| 0-1353 | ||||||||||||||||||||||||||||||||||||
| 1662 | ossl_statem_fatal((s), (80), (458), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1663 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1664 | , | - | ||||||||||||||||||||||||||||||||||||
| 1665 | 1322 | - | ||||||||||||||||||||||||||||||||||||
| 1666 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1667 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1668 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1669 | } | - | ||||||||||||||||||||||||||||||||||||
| 1670 | - | |||||||||||||||||||||||||||||||||||||
| 1671 | return executed 1353 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 1353 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 1353 | ||||||||||||||||||||||||||||||||||||
| 1672 | } | - | ||||||||||||||||||||||||||||||||||||
| 1673 | - | |||||||||||||||||||||||||||||||||||||
| 1674 | EXT_RETURN tls_construct_stoc_server_name(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1675 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1676 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1677 | { | - | ||||||||||||||||||||||||||||||||||||
| 1678 | if (s->hit
| 31-2169 | ||||||||||||||||||||||||||||||||||||
| 1679 | || s->ext.hostname ==
| 0-31 | ||||||||||||||||||||||||||||||||||||
| 1680 | ((void *)0)
| 0-31 | ||||||||||||||||||||||||||||||||||||
| 1681 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1682 | return executed 2333 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2333 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2333 | ||||||||||||||||||||||||||||||||||||
| 1683 | - | |||||||||||||||||||||||||||||||||||||
| 1684 | if (!WPACKET_put_bytes__((pkt), (0), 2)
| 0-31 | ||||||||||||||||||||||||||||||||||||
| 1685 | || !WPACKET_put_bytes__((pkt), (0), 2)
| 0-31 | ||||||||||||||||||||||||||||||||||||
| 1686 | ossl_statem_fatal((s), (80), (459), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1687 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1688 | , | - | ||||||||||||||||||||||||||||||||||||
| 1689 | 1340 | - | ||||||||||||||||||||||||||||||||||||
| 1690 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1691 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1692 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1693 | } | - | ||||||||||||||||||||||||||||||||||||
| 1694 | - | |||||||||||||||||||||||||||||||||||||
| 1695 | return executed 31 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 31 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 31 | ||||||||||||||||||||||||||||||||||||
| 1696 | } | - | ||||||||||||||||||||||||||||||||||||
| 1697 | - | |||||||||||||||||||||||||||||||||||||
| 1698 | - | |||||||||||||||||||||||||||||||||||||
| 1699 | EXT_RETURN tls_construct_stoc_maxfragmentlen(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1700 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1701 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1702 | { | - | ||||||||||||||||||||||||||||||||||||
| 1703 | if (!(((
| 0-2337 | ||||||||||||||||||||||||||||||||||||
| 1704 | return executed 2337 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2337 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2337 | ||||||||||||||||||||||||||||||||||||
| 1705 | - | |||||||||||||||||||||||||||||||||||||
| 1706 | - | |||||||||||||||||||||||||||||||||||||
| 1707 | - | |||||||||||||||||||||||||||||||||||||
| 1708 | - | |||||||||||||||||||||||||||||||||||||
| 1709 | - | |||||||||||||||||||||||||||||||||||||
| 1710 | if (!WPACKET_put_bytes__((pkt), (1), 2)
| 0-27 | ||||||||||||||||||||||||||||||||||||
| 1711 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-27 | ||||||||||||||||||||||||||||||||||||
| 1712 | || !WPACKET_put_bytes__((pkt), (s->session->ext.max_fragment_len_mode), 1)
| 0-27 | ||||||||||||||||||||||||||||||||||||
| 1713 | || !WPACKET_close(pkt)
| 0-27 | ||||||||||||||||||||||||||||||||||||
| 1714 | ossl_statem_fatal((s), (80), (548), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1715 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1716 | , | - | ||||||||||||||||||||||||||||||||||||
| 1717 | 1364 | - | ||||||||||||||||||||||||||||||||||||
| 1718 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1719 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1720 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1721 | } | - | ||||||||||||||||||||||||||||||||||||
| 1722 | - | |||||||||||||||||||||||||||||||||||||
| 1723 | return executed 27 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 27 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 27 | ||||||||||||||||||||||||||||||||||||
| 1724 | } | - | ||||||||||||||||||||||||||||||||||||
| 1725 | - | |||||||||||||||||||||||||||||||||||||
| 1726 | - | |||||||||||||||||||||||||||||||||||||
| 1727 | EXT_RETURN tls_construct_stoc_ec_pt_formats(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1728 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1729 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1730 | { | - | ||||||||||||||||||||||||||||||||||||
| 1731 | unsigned long alg_k = s->s3->tmp.new_cipher->algorithm_mkey; | - | ||||||||||||||||||||||||||||||||||||
| 1732 | unsigned long alg_a = s->s3->tmp.new_cipher->algorithm_auth; | - | ||||||||||||||||||||||||||||||||||||
| 1733 | int using_ecc = ((
| 0-1157 | ||||||||||||||||||||||||||||||||||||
| 1734 | && (
| 161-996 | ||||||||||||||||||||||||||||||||||||
| 1735 | ((void *)0)
| 161-996 | ||||||||||||||||||||||||||||||||||||
| 1736 | )
| 161-996 | ||||||||||||||||||||||||||||||||||||
| 1737 | const unsigned char *plist; | - | ||||||||||||||||||||||||||||||||||||
| 1738 | size_t plistlen; | - | ||||||||||||||||||||||||||||||||||||
| 1739 | - | |||||||||||||||||||||||||||||||||||||
| 1740 | if (!using_ecc
| 514-996 | ||||||||||||||||||||||||||||||||||||
| 1741 | return executed 514 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 514 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 514 | ||||||||||||||||||||||||||||||||||||
| 1742 | - | |||||||||||||||||||||||||||||||||||||
| 1743 | tls1_get_formatlist(s, &plist, &plistlen); | - | ||||||||||||||||||||||||||||||||||||
| 1744 | if (!WPACKET_put_bytes__((pkt), (11), 2)
| 0-996 | ||||||||||||||||||||||||||||||||||||
| 1745 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-996 | ||||||||||||||||||||||||||||||||||||
| 1746 | || !WPACKET_sub_memcpy__((pkt), (plist), (plistlen), 1)
| 0-996 | ||||||||||||||||||||||||||||||||||||
| 1747 | || !WPACKET_close(pkt)
| 0-996 | ||||||||||||||||||||||||||||||||||||
| 1748 | ossl_statem_fatal((s), (80), (453), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1749 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1750 | , | - | ||||||||||||||||||||||||||||||||||||
| 1751 | 1392 | - | ||||||||||||||||||||||||||||||||||||
| 1752 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1753 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1754 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1755 | } | - | ||||||||||||||||||||||||||||||||||||
| 1756 | - | |||||||||||||||||||||||||||||||||||||
| 1757 | return executed 996 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 996 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 996 | ||||||||||||||||||||||||||||||||||||
| 1758 | } | - | ||||||||||||||||||||||||||||||||||||
| 1759 | - | |||||||||||||||||||||||||||||||||||||
| 1760 | - | |||||||||||||||||||||||||||||||||||||
| 1761 | - | |||||||||||||||||||||||||||||||||||||
| 1762 | EXT_RETURN tls_construct_stoc_supported_groups(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1763 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1764 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1765 | { | - | ||||||||||||||||||||||||||||||||||||
| 1766 | const uint16_t *groups; | - | ||||||||||||||||||||||||||||||||||||
| 1767 | size_t numgroups, i, first = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1768 | - | |||||||||||||||||||||||||||||||||||||
| 1769 | - | |||||||||||||||||||||||||||||||||||||
| 1770 | if (s->s3->group_id == 0
| 852-1512 | ||||||||||||||||||||||||||||||||||||
| 1771 | return executed 1512 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 1512 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 1512 | ||||||||||||||||||||||||||||||||||||
| 1772 | - | |||||||||||||||||||||||||||||||||||||
| 1773 | - | |||||||||||||||||||||||||||||||||||||
| 1774 | tls1_get_supported_groups(s, &groups, &numgroups); | - | ||||||||||||||||||||||||||||||||||||
| 1775 | if (numgroups == 0
| 0-852 | ||||||||||||||||||||||||||||||||||||
| 1776 | ossl_statem_fatal((s), (80), (544), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1777 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1778 | , | - | ||||||||||||||||||||||||||||||||||||
| 1779 | 1416 | - | ||||||||||||||||||||||||||||||||||||
| 1780 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1781 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1782 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1783 | } | - | ||||||||||||||||||||||||||||||||||||
| 1784 | - | |||||||||||||||||||||||||||||||||||||
| 1785 | - | |||||||||||||||||||||||||||||||||||||
| 1786 | for (i = 0; i < numgroups
| 117-1320 | ||||||||||||||||||||||||||||||||||||
| 1787 | uint16_t group = groups[i]; | - | ||||||||||||||||||||||||||||||||||||
| 1788 | - | |||||||||||||||||||||||||||||||||||||
| 1789 | if (tls_curve_allowed(s, group, (4 | (2 << 16)))
| 0-1320 | ||||||||||||||||||||||||||||||||||||
| 1790 | if (first
| 468-852 | ||||||||||||||||||||||||||||||||||||
| 1791 | - | |||||||||||||||||||||||||||||||||||||
| 1792 | - | |||||||||||||||||||||||||||||||||||||
| 1793 | - | |||||||||||||||||||||||||||||||||||||
| 1794 | - | |||||||||||||||||||||||||||||||||||||
| 1795 | if (s->s3->group_id == group
| 117-735 | ||||||||||||||||||||||||||||||||||||
| 1796 | return executed 735 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 735 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 735 | ||||||||||||||||||||||||||||||||||||
| 1797 | - | |||||||||||||||||||||||||||||||||||||
| 1798 | - | |||||||||||||||||||||||||||||||||||||
| 1799 | if (!WPACKET_put_bytes__((pkt), (10), 2)
| 0-117 | ||||||||||||||||||||||||||||||||||||
| 1800 | - | |||||||||||||||||||||||||||||||||||||
| 1801 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-117 | ||||||||||||||||||||||||||||||||||||
| 1802 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-117 | ||||||||||||||||||||||||||||||||||||
| 1803 | ossl_statem_fatal((s), (80), (544), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1804 | - | |||||||||||||||||||||||||||||||||||||
| 1805 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1806 | , | - | ||||||||||||||||||||||||||||||||||||
| 1807 | - | |||||||||||||||||||||||||||||||||||||
| 1808 | 1440 | - | ||||||||||||||||||||||||||||||||||||
| 1809 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1810 | - | |||||||||||||||||||||||||||||||||||||
| 1811 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1812 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1813 | } | - | ||||||||||||||||||||||||||||||||||||
| 1814 | - | |||||||||||||||||||||||||||||||||||||
| 1815 | first = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1816 | } executed 117 times by 1 test: end of blockExecuted by:
| 117 | ||||||||||||||||||||||||||||||||||||
| 1817 | if (!WPACKET_put_bytes__((pkt), (group), 2)
| 0-585 | ||||||||||||||||||||||||||||||||||||
| 1818 | ossl_statem_fatal((s), (80), (544), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1819 | - | |||||||||||||||||||||||||||||||||||||
| 1820 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1821 | , | - | ||||||||||||||||||||||||||||||||||||
| 1822 | - | |||||||||||||||||||||||||||||||||||||
| 1823 | 1449 | - | ||||||||||||||||||||||||||||||||||||
| 1824 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1825 | - | |||||||||||||||||||||||||||||||||||||
| 1826 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1827 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1828 | } | - | ||||||||||||||||||||||||||||||||||||
| 1829 | } executed 585 times by 1 test: end of blockExecuted by:
| 585 | ||||||||||||||||||||||||||||||||||||
| 1830 | } executed 585 times by 1 test: end of blockExecuted by:
| 585 | ||||||||||||||||||||||||||||||||||||
| 1831 | - | |||||||||||||||||||||||||||||||||||||
| 1832 | if (!WPACKET_close(pkt)
| 0-117 | ||||||||||||||||||||||||||||||||||||
| 1833 | ossl_statem_fatal((s), (80), (544), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1834 | - | |||||||||||||||||||||||||||||||||||||
| 1835 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1836 | , | - | ||||||||||||||||||||||||||||||||||||
| 1837 | - | |||||||||||||||||||||||||||||||||||||
| 1838 | 1458 | - | ||||||||||||||||||||||||||||||||||||
| 1839 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1840 | - | |||||||||||||||||||||||||||||||||||||
| 1841 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1842 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1843 | } | - | ||||||||||||||||||||||||||||||||||||
| 1844 | - | |||||||||||||||||||||||||||||||||||||
| 1845 | return executed 117 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 117 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 117 | ||||||||||||||||||||||||||||||||||||
| 1846 | } | - | ||||||||||||||||||||||||||||||||||||
| 1847 | - | |||||||||||||||||||||||||||||||||||||
| 1848 | - | |||||||||||||||||||||||||||||||||||||
| 1849 | EXT_RETURN tls_construct_stoc_session_ticket(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1850 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1851 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1852 | { | - | ||||||||||||||||||||||||||||||||||||
| 1853 | if (!s->ext.ticket_expected
| 0-1139 | ||||||||||||||||||||||||||||||||||||
| 1854 | s->ext.ticket_expected = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1855 | return executed 371 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 371 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 371 | ||||||||||||||||||||||||||||||||||||
| 1856 | } | - | ||||||||||||||||||||||||||||||||||||
| 1857 | - | |||||||||||||||||||||||||||||||||||||
| 1858 | if (!WPACKET_put_bytes__((pkt), (35), 2)
| 0-1139 | ||||||||||||||||||||||||||||||||||||
| 1859 | || !WPACKET_put_bytes__((pkt), (0), 2)
| 0-1139 | ||||||||||||||||||||||||||||||||||||
| 1860 | ossl_statem_fatal((s), (80), (460), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1861 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1862 | , | - | ||||||||||||||||||||||||||||||||||||
| 1863 | 1478 | - | ||||||||||||||||||||||||||||||||||||
| 1864 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1865 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1866 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1867 | } | - | ||||||||||||||||||||||||||||||||||||
| 1868 | - | |||||||||||||||||||||||||||||||||||||
| 1869 | return executed 1139 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 1139 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 1139 | ||||||||||||||||||||||||||||||||||||
| 1870 | } | - | ||||||||||||||||||||||||||||||||||||
| 1871 | - | |||||||||||||||||||||||||||||||||||||
| 1872 | - | |||||||||||||||||||||||||||||||||||||
| 1873 | EXT_RETURN tls_construct_stoc_status_request(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1874 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1875 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1876 | { | - | ||||||||||||||||||||||||||||||||||||
| 1877 | if (!s->ext.status_expected
| 11-2369 | ||||||||||||||||||||||||||||||||||||
| 1878 | return executed 2369 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2369 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2369 | ||||||||||||||||||||||||||||||||||||
| 1879 | - | |||||||||||||||||||||||||||||||||||||
| 1880 | if ((!(s->method->ssl3_enc->enc_flags & 0x8)
| 0-9 | ||||||||||||||||||||||||||||||||||||
| 1881 | return never executed: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;never executed: return EXT_RETURN_NOT_SENT; | 0 | ||||||||||||||||||||||||||||||||||||
| 1882 | - | |||||||||||||||||||||||||||||||||||||
| 1883 | if (!WPACKET_put_bytes__((pkt), (5), 2)
| 0-11 | ||||||||||||||||||||||||||||||||||||
| 1884 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-11 | ||||||||||||||||||||||||||||||||||||
| 1885 | ossl_statem_fatal((s), (80), (461), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1886 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1887 | , | - | ||||||||||||||||||||||||||||||||||||
| 1888 | 1499 | - | ||||||||||||||||||||||||||||||||||||
| 1889 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1890 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1891 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1892 | } | - | ||||||||||||||||||||||||||||||||||||
| 1893 | - | |||||||||||||||||||||||||||||||||||||
| 1894 | - | |||||||||||||||||||||||||||||||||||||
| 1895 | - | |||||||||||||||||||||||||||||||||||||
| 1896 | - | |||||||||||||||||||||||||||||||||||||
| 1897 | - | |||||||||||||||||||||||||||||||||||||
| 1898 | - | |||||||||||||||||||||||||||||||||||||
| 1899 | if ((!(s->method->ssl3_enc->enc_flags & 0x8)
| 0-9 | ||||||||||||||||||||||||||||||||||||
| 1900 | - | |||||||||||||||||||||||||||||||||||||
| 1901 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1902 | } | - | ||||||||||||||||||||||||||||||||||||
| 1903 | if (!WPACKET_close(pkt)
| 0-11 | ||||||||||||||||||||||||||||||||||||
| 1904 | ossl_statem_fatal((s), (80), (461), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1905 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1906 | , | - | ||||||||||||||||||||||||||||||||||||
| 1907 | 1514 | - | ||||||||||||||||||||||||||||||||||||
| 1908 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1909 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1910 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1911 | } | - | ||||||||||||||||||||||||||||||||||||
| 1912 | - | |||||||||||||||||||||||||||||||||||||
| 1913 | return executed 11 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 11 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 11 | ||||||||||||||||||||||||||||||||||||
| 1914 | } | - | ||||||||||||||||||||||||||||||||||||
| 1915 | - | |||||||||||||||||||||||||||||||||||||
| 1916 | - | |||||||||||||||||||||||||||||||||||||
| 1917 | - | |||||||||||||||||||||||||||||||||||||
| 1918 | EXT_RETURN tls_construct_stoc_next_proto_neg(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1919 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1920 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1921 | { | - | ||||||||||||||||||||||||||||||||||||
| 1922 | const unsigned char *npa; | - | ||||||||||||||||||||||||||||||||||||
| 1923 | unsigned int npalen; | - | ||||||||||||||||||||||||||||||||||||
| 1924 | int ret; | - | ||||||||||||||||||||||||||||||||||||
| 1925 | int npn_seen = s->s3->npn_seen; | - | ||||||||||||||||||||||||||||||||||||
| 1926 | - | |||||||||||||||||||||||||||||||||||||
| 1927 | s->s3->npn_seen = 0; | - | ||||||||||||||||||||||||||||||||||||
| 1928 | if (!npn_seen
| 6-1483 | ||||||||||||||||||||||||||||||||||||
| 1929 | ((void *)0)
| 6-21 | ||||||||||||||||||||||||||||||||||||
| 1930 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1931 | return executed 1489 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 1489 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 1489 | ||||||||||||||||||||||||||||||||||||
| 1932 | - | |||||||||||||||||||||||||||||||||||||
| 1933 | ret = s->ctx->ext.npn_advertised_cb(s, &npa, &npalen, | - | ||||||||||||||||||||||||||||||||||||
| 1934 | s->ctx->ext.npn_advertised_cb_arg); | - | ||||||||||||||||||||||||||||||||||||
| 1935 | if (ret == 0
| 0-21 | ||||||||||||||||||||||||||||||||||||
| 1936 | if (!WPACKET_put_bytes__((pkt), (13172), 2)
| 0-21 | ||||||||||||||||||||||||||||||||||||
| 1937 | || !WPACKET_sub_memcpy__((pkt), (npa), (npalen), 2)
| 0-21 | ||||||||||||||||||||||||||||||||||||
| 1938 | ossl_statem_fatal((s), (80), (457), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1939 | - | |||||||||||||||||||||||||||||||||||||
| 1940 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1941 | , | - | ||||||||||||||||||||||||||||||||||||
| 1942 | - | |||||||||||||||||||||||||||||||||||||
| 1943 | 1543 | - | ||||||||||||||||||||||||||||||||||||
| 1944 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1945 | - | |||||||||||||||||||||||||||||||||||||
| 1946 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1947 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1948 | } | - | ||||||||||||||||||||||||||||||||||||
| 1949 | s->s3->npn_seen = 1; | - | ||||||||||||||||||||||||||||||||||||
| 1950 | } executed 21 times by 1 test: end of blockExecuted by:
| 21 | ||||||||||||||||||||||||||||||||||||
| 1951 | - | |||||||||||||||||||||||||||||||||||||
| 1952 | return executed 21 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 21 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 21 | ||||||||||||||||||||||||||||||||||||
| 1953 | } | - | ||||||||||||||||||||||||||||||||||||
| 1954 | - | |||||||||||||||||||||||||||||||||||||
| 1955 | - | |||||||||||||||||||||||||||||||||||||
| 1956 | EXT_RETURN tls_construct_stoc_alpn(SSL *s, WPACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 1957 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1958 | { | - | ||||||||||||||||||||||||||||||||||||
| 1959 | if (s->s3->alpn_selected ==
| 22-2342 | ||||||||||||||||||||||||||||||||||||
| 1960 | ((void *)0)
| 22-2342 | ||||||||||||||||||||||||||||||||||||
| 1961 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1962 | return executed 2342 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2342 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2342 | ||||||||||||||||||||||||||||||||||||
| 1963 | - | |||||||||||||||||||||||||||||||||||||
| 1964 | if (!WPACKET_put_bytes__((pkt), (16), 2)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1965 | - | |||||||||||||||||||||||||||||||||||||
| 1966 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1967 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1968 | || !WPACKET_sub_memcpy__((pkt), (s->s3->alpn_selected), (s->s3->alpn_selected_len), 1)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1969 | - | |||||||||||||||||||||||||||||||||||||
| 1970 | || !WPACKET_close(pkt)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1971 | || !WPACKET_close(pkt)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 1972 | ossl_statem_fatal((s), (80), (451), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 1973 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 1974 | , | - | ||||||||||||||||||||||||||||||||||||
| 1975 | 1568 | - | ||||||||||||||||||||||||||||||||||||
| 1976 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1977 | ; | - | ||||||||||||||||||||||||||||||||||||
| 1978 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 1979 | } | - | ||||||||||||||||||||||||||||||||||||
| 1980 | - | |||||||||||||||||||||||||||||||||||||
| 1981 | return executed 22 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 22 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 22 | ||||||||||||||||||||||||||||||||||||
| 1982 | } | - | ||||||||||||||||||||||||||||||||||||
| 1983 | - | |||||||||||||||||||||||||||||||||||||
| 1984 | - | |||||||||||||||||||||||||||||||||||||
| 1985 | EXT_RETURN tls_construct_stoc_use_srtp(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 1986 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 1987 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 1988 | { | - | ||||||||||||||||||||||||||||||||||||
| 1989 | if (s->srtp_profile ==
| 0-2364 | ||||||||||||||||||||||||||||||||||||
| 1990 | ((void *)0)
| 0-2364 | ||||||||||||||||||||||||||||||||||||
| 1991 | ) | - | ||||||||||||||||||||||||||||||||||||
| 1992 | return executed 2364 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2364 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2364 | ||||||||||||||||||||||||||||||||||||
| 1993 | - | |||||||||||||||||||||||||||||||||||||
| 1994 | if (!WPACKET_put_bytes__((pkt), (14), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1995 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1996 | || !WPACKET_put_bytes__((pkt), (2), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1997 | || !WPACKET_put_bytes__((pkt), (s->srtp_profile->id), 2)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1998 | || !WPACKET_put_bytes__((pkt), (0), 1)
| 0 | ||||||||||||||||||||||||||||||||||||
| 1999 | || !WPACKET_close(pkt)
| 0 | ||||||||||||||||||||||||||||||||||||
| 2000 | ossl_statem_fatal((s), (80), (462), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2001 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2002 | , | - | ||||||||||||||||||||||||||||||||||||
| 2003 | 1590 | - | ||||||||||||||||||||||||||||||||||||
| 2004 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2005 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2006 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2007 | } | - | ||||||||||||||||||||||||||||||||||||
| 2008 | - | |||||||||||||||||||||||||||||||||||||
| 2009 | return never executed: EXT_RETURN_SENT;return EXT_RETURN_SENT;never executed: return EXT_RETURN_SENT; | 0 | ||||||||||||||||||||||||||||||||||||
| 2010 | } | - | ||||||||||||||||||||||||||||||||||||
| 2011 | - | |||||||||||||||||||||||||||||||||||||
| 2012 | - | |||||||||||||||||||||||||||||||||||||
| 2013 | EXT_RETURN tls_construct_stoc_etm(SSL *s, WPACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 2014 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2015 | { | - | ||||||||||||||||||||||||||||||||||||
| 2016 | if (!s->ext.use_etm
| 363-1147 | ||||||||||||||||||||||||||||||||||||
| 2017 | return executed 363 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 363 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 363 | ||||||||||||||||||||||||||||||||||||
| 2018 | - | |||||||||||||||||||||||||||||||||||||
| 2019 | - | |||||||||||||||||||||||||||||||||||||
| 2020 | - | |||||||||||||||||||||||||||||||||||||
| 2021 | - | |||||||||||||||||||||||||||||||||||||
| 2022 | - | |||||||||||||||||||||||||||||||||||||
| 2023 | if (s->s3->tmp.new_cipher->algorithm_mac == 0x00000040U
| 536-611 | ||||||||||||||||||||||||||||||||||||
| 2024 | || s->s3->tmp.new_cipher->algorithm_enc == 0x00000004U
| 0-611 | ||||||||||||||||||||||||||||||||||||
| 2025 | || s->s3->tmp.new_cipher->algorithm_enc == 0x00000400U
| 0-611 | ||||||||||||||||||||||||||||||||||||
| 2026 | || s->s3->tmp.new_cipher->algorithm_enc == 0x00040000U
| 0-611 | ||||||||||||||||||||||||||||||||||||
| 2027 | s->ext.use_etm = 0; | - | ||||||||||||||||||||||||||||||||||||
| 2028 | return executed 536 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 536 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 536 | ||||||||||||||||||||||||||||||||||||
| 2029 | } | - | ||||||||||||||||||||||||||||||||||||
| 2030 | - | |||||||||||||||||||||||||||||||||||||
| 2031 | if (!WPACKET_put_bytes__((pkt), (22), 2)
| 0-611 | ||||||||||||||||||||||||||||||||||||
| 2032 | || !WPACKET_put_bytes__((pkt), (0), 2)
| 0-611 | ||||||||||||||||||||||||||||||||||||
| 2033 | ossl_statem_fatal((s), (80), (455), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2034 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2035 | , | - | ||||||||||||||||||||||||||||||||||||
| 2036 | 1619 | - | ||||||||||||||||||||||||||||||||||||
| 2037 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2038 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2039 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2040 | } | - | ||||||||||||||||||||||||||||||||||||
| 2041 | - | |||||||||||||||||||||||||||||||||||||
| 2042 | return executed 611 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 611 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 611 | ||||||||||||||||||||||||||||||||||||
| 2043 | } | - | ||||||||||||||||||||||||||||||||||||
| 2044 | - | |||||||||||||||||||||||||||||||||||||
| 2045 | EXT_RETURN tls_construct_stoc_ems(SSL *s, WPACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 2046 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2047 | { | - | ||||||||||||||||||||||||||||||||||||
| 2048 | if ((
| 186-1324 | ||||||||||||||||||||||||||||||||||||
| 2049 | return executed 186 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 186 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 186 | ||||||||||||||||||||||||||||||||||||
| 2050 | - | |||||||||||||||||||||||||||||||||||||
| 2051 | if (!WPACKET_put_bytes__((pkt), (23), 2)
| 0-1324 | ||||||||||||||||||||||||||||||||||||
| 2052 | || !WPACKET_put_bytes__((pkt), (0), 2)
| 0-1324 | ||||||||||||||||||||||||||||||||||||
| 2053 | ossl_statem_fatal((s), (80), (454), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2054 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2055 | , | - | ||||||||||||||||||||||||||||||||||||
| 2056 | 1635 | - | ||||||||||||||||||||||||||||||||||||
| 2057 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2058 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2059 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2060 | } | - | ||||||||||||||||||||||||||||||||||||
| 2061 | - | |||||||||||||||||||||||||||||||||||||
| 2062 | return executed 1324 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 1324 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 1324 | ||||||||||||||||||||||||||||||||||||
| 2063 | } | - | ||||||||||||||||||||||||||||||||||||
| 2064 | - | |||||||||||||||||||||||||||||||||||||
| 2065 | EXT_RETURN tls_construct_stoc_supported_versions(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 2066 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 2067 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2068 | { | - | ||||||||||||||||||||||||||||||||||||
| 2069 | if (!(((!(s->method->ssl3_enc->enc_flags & 0x8)
| 0-971 | ||||||||||||||||||||||||||||||||||||
| 2070 | ossl_statem_fatal((s), (80), (611), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2071 | - | |||||||||||||||||||||||||||||||||||||
| 2072 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2073 | , | - | ||||||||||||||||||||||||||||||||||||
| 2074 | - | |||||||||||||||||||||||||||||||||||||
| 2075 | 1649 | - | ||||||||||||||||||||||||||||||||||||
| 2076 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2077 | - | |||||||||||||||||||||||||||||||||||||
| 2078 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2079 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2080 | } | - | ||||||||||||||||||||||||||||||||||||
| 2081 | - | |||||||||||||||||||||||||||||||||||||
| 2082 | if (!WPACKET_put_bytes__((pkt), (43), 2)
| 0-971 | ||||||||||||||||||||||||||||||||||||
| 2083 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-971 | ||||||||||||||||||||||||||||||||||||
| 2084 | || !WPACKET_put_bytes__((pkt), (s->version), 2)
| 0-971 | ||||||||||||||||||||||||||||||||||||
| 2085 | || !WPACKET_close(pkt)
| 0-971 | ||||||||||||||||||||||||||||||||||||
| 2086 | ossl_statem_fatal((s), (80), (611), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2087 | - | |||||||||||||||||||||||||||||||||||||
| 2088 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2089 | , | - | ||||||||||||||||||||||||||||||||||||
| 2090 | - | |||||||||||||||||||||||||||||||||||||
| 2091 | 1659 | - | ||||||||||||||||||||||||||||||||||||
| 2092 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2093 | - | |||||||||||||||||||||||||||||||||||||
| 2094 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2095 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2096 | } | - | ||||||||||||||||||||||||||||||||||||
| 2097 | - | |||||||||||||||||||||||||||||||||||||
| 2098 | return executed 971 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 971 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 971 | ||||||||||||||||||||||||||||||||||||
| 2099 | } | - | ||||||||||||||||||||||||||||||||||||
| 2100 | - | |||||||||||||||||||||||||||||||||||||
| 2101 | EXT_RETURN tls_construct_stoc_key_share(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 2102 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 2103 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2104 | { | - | ||||||||||||||||||||||||||||||||||||
| 2105 | - | |||||||||||||||||||||||||||||||||||||
| 2106 | unsigned char *encodedPoint; | - | ||||||||||||||||||||||||||||||||||||
| 2107 | size_t encoded_pt_len = 0; | - | ||||||||||||||||||||||||||||||||||||
| 2108 | EVP_PKEY *ckey = s->s3->peer_tmp, *skey = | - | ||||||||||||||||||||||||||||||||||||
| 2109 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 2110 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2111 | - | |||||||||||||||||||||||||||||||||||||
| 2112 | if (s->hello_retry_request == SSL_HRR_PENDING
| 115-856 | ||||||||||||||||||||||||||||||||||||
| 2113 | if (ckey !=
| 3-112 | ||||||||||||||||||||||||||||||||||||
| 2114 | ((void *)0)
| 3-112 | ||||||||||||||||||||||||||||||||||||
| 2115 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 2116 | - | |||||||||||||||||||||||||||||||||||||
| 2117 | return executed 3 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 3 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 3 | ||||||||||||||||||||||||||||||||||||
| 2118 | } | - | ||||||||||||||||||||||||||||||||||||
| 2119 | if (!WPACKET_put_bytes__((pkt), (51), 2)
| 0-112 | ||||||||||||||||||||||||||||||||||||
| 2120 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-112 | ||||||||||||||||||||||||||||||||||||
| 2121 | || !WPACKET_put_bytes__((pkt), (s->s3->group_id), 2)
| 0-112 | ||||||||||||||||||||||||||||||||||||
| 2122 | || !WPACKET_close(pkt)
| 0-112 | ||||||||||||||||||||||||||||||||||||
| 2123 | ossl_statem_fatal((s), (80), (456), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2124 | - | |||||||||||||||||||||||||||||||||||||
| 2125 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2126 | , | - | ||||||||||||||||||||||||||||||||||||
| 2127 | - | |||||||||||||||||||||||||||||||||||||
| 2128 | 1686 | - | ||||||||||||||||||||||||||||||||||||
| 2129 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2130 | - | |||||||||||||||||||||||||||||||||||||
| 2131 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2132 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2133 | } | - | ||||||||||||||||||||||||||||||||||||
| 2134 | - | |||||||||||||||||||||||||||||||||||||
| 2135 | return executed 112 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 112 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 112 | ||||||||||||||||||||||||||||||||||||
| 2136 | } | - | ||||||||||||||||||||||||||||||||||||
| 2137 | - | |||||||||||||||||||||||||||||||||||||
| 2138 | if (ckey ==
| 2-854 | ||||||||||||||||||||||||||||||||||||
| 2139 | ((void *)0)
| 2-854 | ||||||||||||||||||||||||||||||||||||
| 2140 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 2141 | - | |||||||||||||||||||||||||||||||||||||
| 2142 | if (!s->hit
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2143 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2144 | , 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2145 | ossl_statem_fatal((s), (80), (456), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2146 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2147 | , | - | ||||||||||||||||||||||||||||||||||||
| 2148 | 1697 | - | ||||||||||||||||||||||||||||||||||||
| 2149 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2150 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2151 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2152 | } | - | ||||||||||||||||||||||||||||||||||||
| 2153 | return executed 2 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 2 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 2154 | } | - | ||||||||||||||||||||||||||||||||||||
| 2155 | - | |||||||||||||||||||||||||||||||||||||
| 2156 | if (!WPACKET_put_bytes__((pkt), (51), 2)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2157 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2158 | || !WPACKET_put_bytes__((pkt), (s->s3->group_id), 2)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2159 | ossl_statem_fatal((s), (80), (456), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2160 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2161 | , | - | ||||||||||||||||||||||||||||||||||||
| 2162 | 1707 | - | ||||||||||||||||||||||||||||||||||||
| 2163 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2164 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2165 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2166 | } | - | ||||||||||||||||||||||||||||||||||||
| 2167 | - | |||||||||||||||||||||||||||||||||||||
| 2168 | skey = ssl_generate_pkey(ckey); | - | ||||||||||||||||||||||||||||||||||||
| 2169 | if (skey ==
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2170 | ((void *)0)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2171 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 2172 | ossl_statem_fatal((s), (80), (456), ((1|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2173 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2174 | , | - | ||||||||||||||||||||||||||||||||||||
| 2175 | 1714 | - | ||||||||||||||||||||||||||||||||||||
| 2176 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2177 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2178 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2179 | } | - | ||||||||||||||||||||||||||||||||||||
| 2180 | - | |||||||||||||||||||||||||||||||||||||
| 2181 | - | |||||||||||||||||||||||||||||||||||||
| 2182 | encoded_pt_len = EVP_PKEY_get1_tls_encodedpoint(skey, &encodedPoint); | - | ||||||||||||||||||||||||||||||||||||
| 2183 | if (encoded_pt_len == 0
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2184 | ossl_statem_fatal((s), (80), (456), (16), | - | ||||||||||||||||||||||||||||||||||||
| 2185 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2186 | , | - | ||||||||||||||||||||||||||||||||||||
| 2187 | 1722 | - | ||||||||||||||||||||||||||||||||||||
| 2188 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2189 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2190 | EVP_PKEY_free(skey); | - | ||||||||||||||||||||||||||||||||||||
| 2191 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2192 | } | - | ||||||||||||||||||||||||||||||||||||
| 2193 | - | |||||||||||||||||||||||||||||||||||||
| 2194 | if (!WPACKET_sub_memcpy__((pkt), (encodedPoint), (encoded_pt_len), 2)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2195 | || !WPACKET_close(pkt)
| 0-854 | ||||||||||||||||||||||||||||||||||||
| 2196 | ossl_statem_fatal((s), (80), (456), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2197 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2198 | , | - | ||||||||||||||||||||||||||||||||||||
| 2199 | 1730 | - | ||||||||||||||||||||||||||||||||||||
| 2200 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2201 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2202 | EVP_PKEY_free(skey); | - | ||||||||||||||||||||||||||||||||||||
| 2203 | CRYPTO_free(encodedPoint, __FILE__, 1732); | - | ||||||||||||||||||||||||||||||||||||
| 2204 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2205 | } | - | ||||||||||||||||||||||||||||||||||||
| 2206 | CRYPTO_free(encodedPoint, __FILE__, 1735); | - | ||||||||||||||||||||||||||||||||||||
| 2207 | - | |||||||||||||||||||||||||||||||||||||
| 2208 | - | |||||||||||||||||||||||||||||||||||||
| 2209 | s->s3->tmp.pkey = skey; | - | ||||||||||||||||||||||||||||||||||||
| 2210 | if (ssl_derive(s, skey, ckey, 1) == 0
| 2-852 | ||||||||||||||||||||||||||||||||||||
| 2211 | - | |||||||||||||||||||||||||||||||||||||
| 2212 | return executed 2 times by 1 test: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;Executed by:
executed 2 times by 1 test: return EXT_RETURN_FAIL;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 2213 | } | - | ||||||||||||||||||||||||||||||||||||
| 2214 | return executed 852 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 852 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 852 | ||||||||||||||||||||||||||||||||||||
| 2215 | - | |||||||||||||||||||||||||||||||||||||
| 2216 | - | |||||||||||||||||||||||||||||||||||||
| 2217 | - | |||||||||||||||||||||||||||||||||||||
| 2218 | } | - | ||||||||||||||||||||||||||||||||||||
| 2219 | - | |||||||||||||||||||||||||||||||||||||
| 2220 | EXT_RETURN tls_construct_stoc_cookie(SSL *s, WPACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 2221 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2222 | { | - | ||||||||||||||||||||||||||||||||||||
| 2223 | - | |||||||||||||||||||||||||||||||||||||
| 2224 | unsigned char *hashval1, *hashval2, *appcookie1, *appcookie2, *cookie; | - | ||||||||||||||||||||||||||||||||||||
| 2225 | unsigned char *hmac, *hmac2; | - | ||||||||||||||||||||||||||||||||||||
| 2226 | size_t startlen, ciphlen, totcookielen, hashlen, hmaclen, appcookielen; | - | ||||||||||||||||||||||||||||||||||||
| 2227 | EVP_MD_CTX *hctx; | - | ||||||||||||||||||||||||||||||||||||
| 2228 | EVP_PKEY *pkey; | - | ||||||||||||||||||||||||||||||||||||
| 2229 | int ret = EXT_RETURN_FAIL; | - | ||||||||||||||||||||||||||||||||||||
| 2230 | - | |||||||||||||||||||||||||||||||||||||
| 2231 | if ((
| 3-112 | ||||||||||||||||||||||||||||||||||||
| 2232 | return executed 112 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 112 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 112 | ||||||||||||||||||||||||||||||||||||
| 2233 | - | |||||||||||||||||||||||||||||||||||||
| 2234 | if (s->ctx->gen_stateless_cookie_cb ==
| 1-2 | ||||||||||||||||||||||||||||||||||||
| 2235 | ((void *)0)
| 1-2 | ||||||||||||||||||||||||||||||||||||
| 2236 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 2237 | ossl_statem_fatal((s), (80), (613), (287), | - | ||||||||||||||||||||||||||||||||||||
| 2238 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2239 | , | - | ||||||||||||||||||||||||||||||||||||
| 2240 | 1765 | - | ||||||||||||||||||||||||||||||||||||
| 2241 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2242 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2243 | return executed 1 time by 1 test: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;Executed by:
executed 1 time by 1 test: return EXT_RETURN_FAIL;Executed by:
| 1 | ||||||||||||||||||||||||||||||||||||
| 2244 | } | - | ||||||||||||||||||||||||||||||||||||
| 2245 | - | |||||||||||||||||||||||||||||||||||||
| 2246 | if (!WPACKET_put_bytes__((pkt), (44), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2247 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2248 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2249 | || !WPACKET_get_total_written(pkt, &startlen)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2250 | || !WPACKET_reserve_bytes(pkt, (2 + 2 + 2 + 2 + 2 + 1 + 4 + 2 + 64 + 1 + 4096 + 32), &cookie)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2251 | || !WPACKET_put_bytes__((pkt), (0), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2252 | || !WPACKET_put_bytes__((pkt), (0x0304), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2253 | || !WPACKET_put_bytes__((pkt), (s->s3->group_id), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2254 | || !s->method->put_cipher_by_char(s->s3->tmp.new_cipher, pkt,
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2255 | &ciphlen)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2256 | - | |||||||||||||||||||||||||||||||||||||
| 2257 | || !WPACKET_put_bytes__((pkt), (s->s3->peer_tmp ==
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2258 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2259 | ), 1)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2260 | || !WPACKET_put_bytes__((pkt), ((unsigned int)time(
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2261 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2262 | )), 4)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2263 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2264 | || !WPACKET_reserve_bytes(pkt, 64, &hashval1)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2265 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2266 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2267 | , | - | ||||||||||||||||||||||||||||||||||||
| 2268 | 1785 | - | ||||||||||||||||||||||||||||||||||||
| 2269 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2270 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2271 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2272 | } | - | ||||||||||||||||||||||||||||||||||||
| 2273 | - | |||||||||||||||||||||||||||||||||||||
| 2274 | - | |||||||||||||||||||||||||||||||||||||
| 2275 | - | |||||||||||||||||||||||||||||||||||||
| 2276 | - | |||||||||||||||||||||||||||||||||||||
| 2277 | - | |||||||||||||||||||||||||||||||||||||
| 2278 | - | |||||||||||||||||||||||||||||||||||||
| 2279 | if (!ssl3_digest_cached_records(s, 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2280 | || !ssl_handshake_hash(s, hashval1, 64, &hashlen)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2281 | - | |||||||||||||||||||||||||||||||||||||
| 2282 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2283 | } | - | ||||||||||||||||||||||||||||||||||||
| 2284 | - | |||||||||||||||||||||||||||||||||||||
| 2285 | if (!WPACKET_allocate_bytes(pkt, hashlen, &hashval2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2286 | || !((hashval1 == hashval2) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2287 | || !WPACKET_close(pkt)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2288 | || !WPACKET_start_sub_packet_len__((pkt), 1)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2289 | || !WPACKET_reserve_bytes(pkt, 4096, &appcookie1)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2290 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2291 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2292 | , | - | ||||||||||||||||||||||||||||||||||||
| 2293 | 1806 | - | ||||||||||||||||||||||||||||||||||||
| 2294 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2295 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2296 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2297 | } | - | ||||||||||||||||||||||||||||||||||||
| 2298 | - | |||||||||||||||||||||||||||||||||||||
| 2299 | - | |||||||||||||||||||||||||||||||||||||
| 2300 | if (s->ctx->gen_stateless_cookie_cb(s, appcookie1, &appcookielen) == 0
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2301 | ossl_statem_fatal((s), (80), (613), (400), | - | ||||||||||||||||||||||||||||||||||||
| 2302 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2303 | , | - | ||||||||||||||||||||||||||||||||||||
| 2304 | 1813 | - | ||||||||||||||||||||||||||||||||||||
| 2305 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2306 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2307 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2308 | } | - | ||||||||||||||||||||||||||||||||||||
| 2309 | - | |||||||||||||||||||||||||||||||||||||
| 2310 | if (!WPACKET_allocate_bytes(pkt, appcookielen, &appcookie2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2311 | || !((appcookie1 == appcookie2) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2312 | || !WPACKET_close(pkt)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2313 | || !WPACKET_get_total_written(pkt, &totcookielen)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2314 | || !WPACKET_reserve_bytes(pkt, 32, &hmac)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2315 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2316 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2317 | , | - | ||||||||||||||||||||||||||||||||||||
| 2318 | 1823 | - | ||||||||||||||||||||||||||||||||||||
| 2319 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2320 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2321 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2322 | } | - | ||||||||||||||||||||||||||||||||||||
| 2323 | hmaclen = 32; | - | ||||||||||||||||||||||||||||||||||||
| 2324 | - | |||||||||||||||||||||||||||||||||||||
| 2325 | totcookielen -= startlen; | - | ||||||||||||||||||||||||||||||||||||
| 2326 | if (!((totcookielen <= (2 + 2 + 2 + 2 + 2 + 1 + 4 + 2 + 64 + 1 + 4096 + 32) - 32) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2327 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2328 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2329 | , | - | ||||||||||||||||||||||||||||||||||||
| 2330 | 1831 | - | ||||||||||||||||||||||||||||||||||||
| 2331 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2332 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2333 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2334 | } | - | ||||||||||||||||||||||||||||||||||||
| 2335 | - | |||||||||||||||||||||||||||||||||||||
| 2336 | - | |||||||||||||||||||||||||||||||||||||
| 2337 | hctx = EVP_MD_CTX_new(); | - | ||||||||||||||||||||||||||||||||||||
| 2338 | pkey = EVP_PKEY_new_raw_private_key(855, | - | ||||||||||||||||||||||||||||||||||||
| 2339 | ((void *)0) | - | ||||||||||||||||||||||||||||||||||||
| 2340 | , | - | ||||||||||||||||||||||||||||||||||||
| 2341 | s->session_ctx->ext.cookie_hmac_key, | - | ||||||||||||||||||||||||||||||||||||
| 2342 | sizeof(s->session_ctx->ext | - | ||||||||||||||||||||||||||||||||||||
| 2343 | .cookie_hmac_key)); | - | ||||||||||||||||||||||||||||||||||||
| 2344 | if (hctx ==
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2345 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2346 | || pkey ==
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2347 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2348 | ) { | - | ||||||||||||||||||||||||||||||||||||
| 2349 | ossl_statem_fatal((s), (80), (613), ((1|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2350 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2351 | , | - | ||||||||||||||||||||||||||||||||||||
| 2352 | 1843 | - | ||||||||||||||||||||||||||||||||||||
| 2353 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2354 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2355 | goto never executed: err;goto err;never executed: goto err; | 0 | ||||||||||||||||||||||||||||||||||||
| 2356 | } | - | ||||||||||||||||||||||||||||||||||||
| 2357 | - | |||||||||||||||||||||||||||||||||||||
| 2358 | if (EVP_DigestSignInit(hctx,
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2359 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2360 | , EVP_sha256(),
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2361 | ((void *)0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2362 | , pkey) <= 0
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2363 | || EVP_DigestSign(hctx, hmac, &hmaclen, cookie,
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2364 | totcookielen) <= 0
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2365 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2366 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2367 | , | - | ||||||||||||||||||||||||||||||||||||
| 2368 | 1851 | - | ||||||||||||||||||||||||||||||||||||
| 2369 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2370 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2371 | goto never executed: err;goto err;never executed: goto err; | 0 | ||||||||||||||||||||||||||||||||||||
| 2372 | } | - | ||||||||||||||||||||||||||||||||||||
| 2373 | - | |||||||||||||||||||||||||||||||||||||
| 2374 | if (!((totcookielen + hmaclen <= (2 + 2 + 2 + 2 + 2 + 1 + 4 + 2 + 64 + 1 + 4096 + 32)) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2375 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2376 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2377 | , | - | ||||||||||||||||||||||||||||||||||||
| 2378 | 1857 | - | ||||||||||||||||||||||||||||||||||||
| 2379 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2380 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2381 | goto never executed: err;goto err;never executed: goto err; | 0 | ||||||||||||||||||||||||||||||||||||
| 2382 | } | - | ||||||||||||||||||||||||||||||||||||
| 2383 | - | |||||||||||||||||||||||||||||||||||||
| 2384 | if (!WPACKET_allocate_bytes(pkt, hmaclen, &hmac2)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2385 | || !((hmac == hmac2) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2386 | || !((cookie == hmac - totcookielen) != 0)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2387 | || !WPACKET_close(pkt)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2388 | || !WPACKET_close(pkt)
| 0-2 | ||||||||||||||||||||||||||||||||||||
| 2389 | ossl_statem_fatal((s), (80), (613), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2390 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2391 | , | - | ||||||||||||||||||||||||||||||||||||
| 2392 | 1867 | - | ||||||||||||||||||||||||||||||||||||
| 2393 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2394 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2395 | goto never executed: err;goto err;never executed: goto err; | 0 | ||||||||||||||||||||||||||||||||||||
| 2396 | } | - | ||||||||||||||||||||||||||||||||||||
| 2397 | - | |||||||||||||||||||||||||||||||||||||
| 2398 | ret = EXT_RETURN_SENT; | - | ||||||||||||||||||||||||||||||||||||
| 2399 | - | |||||||||||||||||||||||||||||||||||||
| 2400 | err: code before this statement executed 2 times by 1 test: err:Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 2401 | EVP_MD_CTX_free(hctx); | - | ||||||||||||||||||||||||||||||||||||
| 2402 | EVP_PKEY_free(pkey); | - | ||||||||||||||||||||||||||||||||||||
| 2403 | return executed 2 times by 1 test: ret;return ret;Executed by:
executed 2 times by 1 test: return ret;Executed by:
| 2 | ||||||||||||||||||||||||||||||||||||
| 2404 | - | |||||||||||||||||||||||||||||||||||||
| 2405 | - | |||||||||||||||||||||||||||||||||||||
| 2406 | - | |||||||||||||||||||||||||||||||||||||
| 2407 | } | - | ||||||||||||||||||||||||||||||||||||
| 2408 | - | |||||||||||||||||||||||||||||||||||||
| 2409 | EXT_RETURN tls_construct_stoc_cryptopro_bug(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 2410 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 2411 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2412 | { | - | ||||||||||||||||||||||||||||||||||||
| 2413 | const unsigned char cryptopro_ext[36] = { | - | ||||||||||||||||||||||||||||||||||||
| 2414 | 0xfd, 0xe8, | - | ||||||||||||||||||||||||||||||||||||
| 2415 | 0x00, 0x20, | - | ||||||||||||||||||||||||||||||||||||
| 2416 | 0x30, 0x1e, 0x30, 0x08, 0x06, 0x06, 0x2a, 0x85, | - | ||||||||||||||||||||||||||||||||||||
| 2417 | 0x03, 0x02, 0x02, 0x09, 0x30, 0x08, 0x06, 0x06, | - | ||||||||||||||||||||||||||||||||||||
| 2418 | 0x2a, 0x85, 0x03, 0x02, 0x02, 0x16, 0x30, 0x08, | - | ||||||||||||||||||||||||||||||||||||
| 2419 | 0x06, 0x06, 0x2a, 0x85, 0x03, 0x02, 0x02, 0x17 | - | ||||||||||||||||||||||||||||||||||||
| 2420 | }; | - | ||||||||||||||||||||||||||||||||||||
| 2421 | - | |||||||||||||||||||||||||||||||||||||
| 2422 | if (((
| 0-1510 | ||||||||||||||||||||||||||||||||||||
| 2423 | && (
| 0-1510 | ||||||||||||||||||||||||||||||||||||
| 2424 | || (
| 0 | ||||||||||||||||||||||||||||||||||||
| 2425 | return executed 1510 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 1510 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 1510 | ||||||||||||||||||||||||||||||||||||
| 2426 | - | |||||||||||||||||||||||||||||||||||||
| 2427 | if (!WPACKET_memcpy(pkt, cryptopro_ext, sizeof(cryptopro_ext))
| 0 | ||||||||||||||||||||||||||||||||||||
| 2428 | ossl_statem_fatal((s), (80), (452), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2429 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2430 | , | - | ||||||||||||||||||||||||||||||||||||
| 2431 | 1902 | - | ||||||||||||||||||||||||||||||||||||
| 2432 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2433 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2434 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2435 | } | - | ||||||||||||||||||||||||||||||||||||
| 2436 | - | |||||||||||||||||||||||||||||||||||||
| 2437 | return never executed: EXT_RETURN_SENT;return EXT_RETURN_SENT;never executed: return EXT_RETURN_SENT; | 0 | ||||||||||||||||||||||||||||||||||||
| 2438 | } | - | ||||||||||||||||||||||||||||||||||||
| 2439 | - | |||||||||||||||||||||||||||||||||||||
| 2440 | EXT_RETURN tls_construct_stoc_early_data(SSL *s, WPACKET *pkt, | - | ||||||||||||||||||||||||||||||||||||
| 2441 | unsigned int context, X509 *x, | - | ||||||||||||||||||||||||||||||||||||
| 2442 | size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2443 | { | - | ||||||||||||||||||||||||||||||||||||
| 2444 | if (context == 0x2000
| 854-1033 | ||||||||||||||||||||||||||||||||||||
| 2445 | if (s->max_early_data == 0
| 147-886 | ||||||||||||||||||||||||||||||||||||
| 2446 | return executed 886 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 886 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 886 | ||||||||||||||||||||||||||||||||||||
| 2447 | - | |||||||||||||||||||||||||||||||||||||
| 2448 | if (!WPACKET_put_bytes__((pkt), (42), 2)
| 0-147 | ||||||||||||||||||||||||||||||||||||
| 2449 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-147 | ||||||||||||||||||||||||||||||||||||
| 2450 | || !WPACKET_put_bytes__((pkt), (s->max_early_data), 4)
| 0-147 | ||||||||||||||||||||||||||||||||||||
| 2451 | || !WPACKET_close(pkt)
| 0-147 | ||||||||||||||||||||||||||||||||||||
| 2452 | ossl_statem_fatal((s), (80), (531), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2453 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2454 | , | - | ||||||||||||||||||||||||||||||||||||
| 2455 | 1922 | - | ||||||||||||||||||||||||||||||||||||
| 2456 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2457 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2458 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2459 | } | - | ||||||||||||||||||||||||||||||||||||
| 2460 | - | |||||||||||||||||||||||||||||||||||||
| 2461 | return executed 147 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 147 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 147 | ||||||||||||||||||||||||||||||||||||
| 2462 | } | - | ||||||||||||||||||||||||||||||||||||
| 2463 | - | |||||||||||||||||||||||||||||||||||||
| 2464 | if (s->ext.early_data != 2
| 22-832 | ||||||||||||||||||||||||||||||||||||
| 2465 | return executed 832 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 832 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 832 | ||||||||||||||||||||||||||||||||||||
| 2466 | - | |||||||||||||||||||||||||||||||||||||
| 2467 | if (!WPACKET_put_bytes__((pkt), (42), 2)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 2468 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 2469 | || !WPACKET_close(pkt)
| 0-22 | ||||||||||||||||||||||||||||||||||||
| 2470 | ossl_statem_fatal((s), (80), (531), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2471 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2472 | , | - | ||||||||||||||||||||||||||||||||||||
| 2473 | 1936 | - | ||||||||||||||||||||||||||||||||||||
| 2474 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2475 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2476 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2477 | } | - | ||||||||||||||||||||||||||||||||||||
| 2478 | - | |||||||||||||||||||||||||||||||||||||
| 2479 | return executed 22 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 22 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 22 | ||||||||||||||||||||||||||||||||||||
| 2480 | } | - | ||||||||||||||||||||||||||||||||||||
| 2481 | - | |||||||||||||||||||||||||||||||||||||
| 2482 | EXT_RETURN tls_construct_stoc_psk(SSL *s, WPACKET *pkt, unsigned int context, | - | ||||||||||||||||||||||||||||||||||||
| 2483 | X509 *x, size_t chainidx) | - | ||||||||||||||||||||||||||||||||||||
| 2484 | { | - | ||||||||||||||||||||||||||||||||||||
| 2485 | if (!s->hit
| 113-741 | ||||||||||||||||||||||||||||||||||||
| 2486 | return executed 741 times by 1 test: EXT_RETURN_NOT_SENT;return EXT_RETURN_NOT_SENT;Executed by:
executed 741 times by 1 test: return EXT_RETURN_NOT_SENT;Executed by:
| 741 | ||||||||||||||||||||||||||||||||||||
| 2487 | - | |||||||||||||||||||||||||||||||||||||
| 2488 | if (!WPACKET_put_bytes__((pkt), (41), 2)
| 0-113 | ||||||||||||||||||||||||||||||||||||
| 2489 | || !WPACKET_start_sub_packet_len__((pkt), 2)
| 0-113 | ||||||||||||||||||||||||||||||||||||
| 2490 | || !WPACKET_put_bytes__((pkt), (s->session->ext.tick_identity), 2)
| 0-113 | ||||||||||||||||||||||||||||||||||||
| 2491 | || !WPACKET_close(pkt)
| 0-113 | ||||||||||||||||||||||||||||||||||||
| 2492 | ossl_statem_fatal((s), (80), (504), ((4|64)), | - | ||||||||||||||||||||||||||||||||||||
| 2493 | __FILE__ | - | ||||||||||||||||||||||||||||||||||||
| 2494 | , | - | ||||||||||||||||||||||||||||||||||||
| 2495 | 1954 | - | ||||||||||||||||||||||||||||||||||||
| 2496 | ) | - | ||||||||||||||||||||||||||||||||||||
| 2497 | ; | - | ||||||||||||||||||||||||||||||||||||
| 2498 | return never executed: EXT_RETURN_FAIL;return EXT_RETURN_FAIL;never executed: return EXT_RETURN_FAIL; | 0 | ||||||||||||||||||||||||||||||||||||
| 2499 | } | - | ||||||||||||||||||||||||||||||||||||
| 2500 | - | |||||||||||||||||||||||||||||||||||||
| 2501 | return executed 113 times by 1 test: EXT_RETURN_SENT;return EXT_RETURN_SENT;Executed by:
executed 113 times by 1 test: return EXT_RETURN_SENT;Executed by:
| 113 | ||||||||||||||||||||||||||||||||||||
| 2502 | } | - | ||||||||||||||||||||||||||||||||||||
| Switch to Source code | Preprocessed file |