OpenCoverage

extensions.c

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/openssl/src/ssl/statem/extensions.c
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3static int final_renegotiate(SSL *s, unsigned int context, int sent);-
4static int init_server_name(SSL *s, unsigned int context);-
5static int final_server_name(SSL *s, unsigned int context, int sent);-
6-
7static int final_ec_pt_formats(SSL *s, unsigned int context, int sent);-
8-
9static int init_session_ticket(SSL *s, unsigned int context);-
10-
11static int init_status_request(SSL *s, unsigned int context);-
12-
13-
14static int init_npn(SSL *s, unsigned int context);-
15-
16static int init_alpn(SSL *s, unsigned int context);-
17static int final_alpn(SSL *s, unsigned int context, int sent);-
18static int init_sig_algs_cert(SSL *s, unsigned int context);-
19static int init_sig_algs(SSL *s, unsigned int context);-
20static int init_certificate_authorities(SSL *s, unsigned int context);-
21static EXT_RETURN tls_construct_certificate_authorities(SSL *s, WPACKET *pkt,-
22 unsigned int context,-
23 X509 *x,-
24 size_t chainidx);-
25static int tls_parse_certificate_authorities(SSL *s, PACKET *pkt,-
26 unsigned int context, X509 *x,-
27 size_t chainidx);-
28-
29static int init_srp(SSL *s, unsigned int context);-
30-
31static int init_etm(SSL *s, unsigned int context);-
32static int init_ems(SSL *s, unsigned int context);-
33static int final_ems(SSL *s, unsigned int context, int sent);-
34static int init_psk_kex_modes(SSL *s, unsigned int context);-
35-
36static int final_key_share(SSL *s, unsigned int context, int sent);-
37-
38-
39static int init_srtp(SSL *s, unsigned int context);-
40-
41static int final_sig_algs(SSL *s, unsigned int context, int sent);-
42static int final_early_data(SSL *s, unsigned int context, int sent);-
43static int final_maxfragmentlen(SSL *s, unsigned int context, int sent);-
44static int init_post_handshake_auth(SSL *s, unsigned int context);-
45-
46-
47typedef struct extensions_definition_st {-
48-
49 unsigned int type;-
50-
51-
52-
53-
54 unsigned int context;-
55-
56-
57-
58-
59 int (*init)(SSL *s, unsigned int context);-
60-
61 int (*parse_ctos)(SSL *s, PACKET *pkt, unsigned int context, X509 *x,-
62 size_t chainidx);-
63-
64 int (*parse_stoc)(SSL *s, PACKET *pkt, unsigned int context, X509 *x,-
65 size_t chainidx);-
66-
67 EXT_RETURN (*construct_stoc)(SSL *s, WPACKET *pkt, unsigned int context,-
68 X509 *x, size_t chainidx);-
69-
70 EXT_RETURN (*construct_ctos)(SSL *s, WPACKET *pkt, unsigned int context,-
71 X509 *x, size_t chainidx);-
72-
73-
74-
75-
76-
77 int (*final)(SSL *s, unsigned int context, int sent);-
78} EXTENSION_DEFINITION;-
79static const EXTENSION_DEFINITION ext_defs[] = {-
80 {-
81 0xff01,-
82 0x0080 | 0x0100-
83 | 0x0008 | 0x0010,-
84 -
85 ((void *)0)-
86 , tls_parse_ctos_renegotiate, tls_parse_stoc_renegotiate,-
87 tls_construct_stoc_renegotiate, tls_construct_ctos_renegotiate,-
88 final_renegotiate-
89 },-
90 {-
91 0,-
92 0x0080 | 0x0100-
93 | 0x0400,-
94 init_server_name,-
95 tls_parse_ctos_server_name, tls_parse_stoc_server_name,-
96 tls_construct_stoc_server_name, tls_construct_ctos_server_name,-
97 final_server_name-
98 },-
99 {-
100 1,-
101 0x0080 | 0x0100-
102 | 0x0400,-
103 -
104 ((void *)0)-
105 , tls_parse_ctos_maxfragmentlen, tls_parse_stoc_maxfragmentlen,-
106 tls_construct_stoc_maxfragmentlen, tls_construct_ctos_maxfragmentlen,-
107 final_maxfragmentlen-
108 },-
109-
110 {-
111 12,-
112 0x0080 | 0x0010,-
113 init_srp, tls_parse_ctos_srp, -
114 ((void *)0)-
115 , -
116 ((void *)0)-
117 , tls_construct_ctos_srp, -
118 ((void *)0)-
119 -
120 },-
121-
122-
123-
124-
125 {-
126 11,-
127 0x0080 | 0x0100-
128 | 0x0010,-
129 -
130 ((void *)0)-
131 , tls_parse_ctos_ec_pt_formats, tls_parse_stoc_ec_pt_formats,-
132 tls_construct_stoc_ec_pt_formats, tls_construct_ctos_ec_pt_formats,-
133 final_ec_pt_formats-
134 },-
135 {-
136 10,-
137 0x0080 | 0x0400-
138 | 0x0100,-
139 -
140 ((void *)0)-
141 , tls_parse_ctos_supported_groups, -
142 ((void *)0)-
143 ,-
144 tls_construct_stoc_supported_groups,-
145 tls_construct_ctos_supported_groups, -
146 ((void *)0)-
147 -
148 },-
149-
150-
151-
152-
153 {-
154 35,-
155 0x0080 | 0x0100-
156 | 0x0010,-
157 init_session_ticket, tls_parse_ctos_session_ticket,-
158 tls_parse_stoc_session_ticket, tls_construct_stoc_session_ticket,-
159 tls_construct_ctos_session_ticket, -
160 ((void *)0)-
161 -
162 },-
163-
164 {-
165 5,-
166 0x0080 | 0x0100-
167 | 0x1000 | 0x4000,-
168 init_status_request, tls_parse_ctos_status_request,-
169 tls_parse_stoc_status_request, tls_construct_stoc_status_request,-
170 tls_construct_ctos_status_request, -
171 ((void *)0)-
172 -
173 },-
174-
175-
176-
177-
178 {-
179 13172,-
180 0x0080 | 0x0100-
181 | 0x0010,-
182 init_npn, tls_parse_ctos_npn, tls_parse_stoc_npn,-
183 tls_construct_stoc_next_proto_neg, tls_construct_ctos_npn, -
184 ((void *)0)-
185 -
186 },-
187-
188-
189-
190 {-
191-
192-
193-
194-
195 16,-
196 0x0080 | 0x0100-
197 | 0x0400,-
198 init_alpn, tls_parse_ctos_alpn, tls_parse_stoc_alpn,-
199 tls_construct_stoc_alpn, tls_construct_ctos_alpn, final_alpn-
200 },-
201-
202 {-
203 14,-
204 0x0080 | 0x0100-
205 | 0x0400 | 0x0002,-
206 init_srtp, tls_parse_ctos_use_srtp, tls_parse_stoc_use_srtp,-
207 tls_construct_stoc_use_srtp, tls_construct_ctos_use_srtp, -
208 ((void *)0)-
209 -
210 },-
211-
212-
213-
214 {-
215 22,-
216 0x0080 | 0x0100-
217 | 0x0010,-
218 init_etm, tls_parse_ctos_etm, tls_parse_stoc_etm,-
219 tls_construct_stoc_etm, tls_construct_ctos_etm, -
220 ((void *)0)-
221 -
222 },-
223-
224 {-
225 18,-
226 0x0080 | 0x0100-
227 | 0x1000 | 0x4000,-
228 -
229 ((void *)0)-
230 ,-
231-
232-
233-
234-
235-
236 -
237 ((void *)0)-
238 , tls_parse_stoc_sct, -
239 ((void *)0)-
240 , tls_construct_ctos_sct, -
241 ((void *)0)-
242 -
243 },-
244-
245-
246-
247 {-
248 23,-
249 0x0080 | 0x0100-
250 | 0x0010,-
251 init_ems, tls_parse_ctos_ems, tls_parse_stoc_ems,-
252 tls_construct_stoc_ems, tls_construct_ctos_ems, final_ems-
253 },-
254 {-
255 50,-
256 0x0080 | 0x4000,-
257 init_sig_algs_cert, tls_parse_ctos_sig_algs_cert,-
258 tls_parse_ctos_sig_algs_cert,-
259-
260 -
261 ((void *)0)-
262 , -
263 ((void *)0)-
264 , -
265 ((void *)0)-
266 -
267 },-
268 {-
269 49,-
270 0x0080 | 0x0020,-
271 init_post_handshake_auth,-
272 tls_parse_ctos_post_handshake_auth, -
273 ((void *)0)-
274 ,-
275 -
276 ((void *)0)-
277 , tls_construct_ctos_post_handshake_auth,-
278 -
279 ((void *)0)-
280 ,-
281 },-
282 {-
283 13,-
284 0x0080 | 0x4000,-
285 init_sig_algs, tls_parse_ctos_sig_algs,-
286 tls_parse_ctos_sig_algs, tls_construct_ctos_sig_algs,-
287 tls_construct_ctos_sig_algs, final_sig_algs-
288 },-
289 {-
290 43,-
291 0x0080 | 0x0200-
292 | 0x0800 | 0x0004,-
293 -
294 ((void *)0)-
295 ,-
296-
297 -
298 ((void *)0)-
299 , tls_parse_stoc_supported_versions,-
300 tls_construct_stoc_supported_versions,-
301 tls_construct_ctos_supported_versions, -
302 ((void *)0)-
303 -
304 },-
305 {-
306 45,-
307 0x0080 | 0x0004-
308 | 0x0020,-
309 init_psk_kex_modes, tls_parse_ctos_psk_kex_modes, -
310 ((void *)0)-
311 , -
312 ((void *)0)-
313 ,-
314 tls_construct_ctos_psk_kex_modes, -
315 ((void *)0)-
316 -
317 },-
318-
319 {-
320-
321-
322-
323-
324 51,-
325 0x0080 | 0x0200-
326 | 0x0800 | 0x0004-
327 | 0x0020,-
328 -
329 ((void *)0)-
330 , tls_parse_ctos_key_share, tls_parse_stoc_key_share,-
331 tls_construct_stoc_key_share, tls_construct_ctos_key_share,-
332 final_key_share-
333 },-
334-
335 {-
336-
337 44,-
338 0x0080 | 0x0800-
339 | 0x0004 | 0x0020,-
340 -
341 ((void *)0)-
342 , tls_parse_ctos_cookie, tls_parse_stoc_cookie,-
343 tls_construct_stoc_cookie, tls_construct_ctos_cookie, -
344 ((void *)0)-
345 -
346 },-
347 {-
348-
349-
350-
351-
352 0xfde8,-
353 0x0100 | 0x0010,-
354 -
355 ((void *)0)-
356 , -
357 ((void *)0)-
358 , -
359 ((void *)0)-
360 , tls_construct_stoc_cryptopro_bug, -
361 ((void *)0)-
362 , -
363 ((void *)0)-
364 -
365 },-
366 {-
367 42,-
368 0x0080 | 0x0400-
369 | 0x2000 | 0x0020,-
370 -
371 ((void *)0)-
372 , tls_parse_ctos_early_data, tls_parse_stoc_early_data,-
373 tls_construct_stoc_early_data, tls_construct_ctos_early_data,-
374 final_early_data-
375 },-
376 {-
377 47,-
378 0x0080 | 0x4000-
379 | 0x0020,-
380 init_certificate_authorities,-
381 tls_parse_certificate_authorities, tls_parse_certificate_authorities,-
382 tls_construct_certificate_authorities,-
383 tls_construct_certificate_authorities, -
384 ((void *)0)-
385 ,-
386 },-
387 {-
388-
389 21,-
390 0x0080,-
391 -
392 ((void *)0)-
393 ,-
394-
395 -
396 ((void *)0)-
397 , -
398 ((void *)0)-
399 , -
400 ((void *)0)-
401 , tls_construct_ctos_padding, -
402 ((void *)0)-
403 -
404 },-
405 {-
406-
407 41,-
408 0x0080 | 0x0200-
409 | 0x0004 | 0x0020,-
410 -
411 ((void *)0)-
412 , tls_parse_ctos_psk, tls_parse_stoc_psk, tls_construct_stoc_psk,-
413 tls_construct_ctos_psk, -
414 ((void *)0)-
415 -
416 }-
417};-
418-
419-
420static int validate_context(SSL *s, unsigned int extctx, unsigned int thisctx)-
421{-
422-
423 if ((
(thisctx & extctx) == 0Description
TRUEevaluated 13 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 43031 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & extctx) == 0
(thisctx & extctx) == 0Description
TRUEevaluated 13 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 43031 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
13-43031
424 return
executed 13 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 13 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
13
425-
426 if ((
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 2542 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 40489 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->method->ssl3_enc->enc_flags & 0x8)
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 2542 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 40489 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
2542-40489
427 if ((
(extctx & 0x0001) != 0Description
TRUEnever evaluated
FALSEevaluated 2542 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0001) != 0
(extctx & 0x0001) != 0Description
TRUEnever evaluated
FALSEevaluated 2542 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-2542
428 return
never executed: return 0;
0;
never executed: return 0;
0
429 }
executed 2542 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else if ((
(extctx & 0x0002) != 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 40487 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0002) != 0
(extctx & 0x0002) != 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 40487 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
2-40487
430 return
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
2
431 }-
432-
433 return
executed 43029 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 43029 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
43029
434}-
435-
436int tls_validate_all_contexts(SSL *s, unsigned int thisctx, RAW_EXTENSION *exts)-
437{-
438 size_t i, num_exts, builtin_num = (sizeof(ext_defs)/sizeof((ext_defs)[0])), offset;-
439 RAW_EXTENSION *thisext;-
440 unsigned int context;-
441 ENDPOINT role = ENDPOINT_BOTH;-
442-
443 if ((
(thisctx & 0x0080) != 0Description
TRUEnever evaluated
FALSEevaluated 3492 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & 0x0080) != 0
(thisctx & 0x0080) != 0Description
TRUEnever evaluated
FALSEevaluated 3492 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-3492
444 role = ENDPOINT_SERVER;
never executed: role = ENDPOINT_SERVER;
0
445 else if ((
(thisctx & 0x0100) != 0Description
TRUEevaluated 2856 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 636 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & 0x0100) != 0
(thisctx & 0x0100) != 0Description
TRUEevaluated 2856 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 636 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
636-2856
446 role = ENDPOINT_CLIENT;
executed 2856 times by 1 test: role = ENDPOINT_CLIENT;
Executed by:
  • libssl.so.1.1
2856
447-
448-
449 num_exts = builtin_num + s->cert->custext.meths_count;-
450-
451 for (thisext = exts, i = 0; i < num_exts
i < num_extsDescription
TRUEevaluated 90758 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3489 times by 1 test
Evaluated by:
  • libssl.so.1.1
; i++, thisext++) {
3489-90758
452 if (!thisext->present
!thisext->presentDescription
TRUEevaluated 80860 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 9898 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
9898-80860
453 continue;
executed 80860 times by 1 test: continue;
Executed by:
  • libssl.so.1.1
80860
454-
455 if (i < builtin_num
i < builtin_numDescription
TRUEevaluated 9884 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 14 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
14-9884
456 context = ext_defs[i].context;-
457 }
executed 9884 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
9884
458 custom_ext_method *meth = -
459 ((void *)0)-
460 ;-
461-
462 meth = custom_ext_find(&s->cert->custext, role, thisext->type,-
463 &offset);-
464 if (!((meth !=
!((meth != ((void *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 14 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-14
465 ((void *)0)
!((meth != ((void *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 14 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-14
466 ) != 0)
!((meth != ((void *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 14 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-14
467 return
never executed: return 0;
0;
never executed: return 0;
0
468 context = meth->context;-
469 }
executed 14 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
14
470-
471 if (!validate_context(s, context, thisctx)
!validate_cont...text, thisctx)Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 9895 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
3-9895
472 return
executed 3 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 3 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
3
473 }
executed 9895 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
9895
474-
475 return
executed 3489 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3489 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3489
476}-
477-
478-
479-
480-
481-
482-
483-
484static int verify_extension(SSL *s, unsigned int context, unsigned int type,-
485 custom_ext_methods *meths, RAW_EXTENSION *rawexlist,-
486 RAW_EXTENSION **found)-
487{-
488 size_t i;-
489 size_t builtin_num = (sizeof(ext_defs)/sizeof((ext_defs)[0]));-
490 const EXTENSION_DEFINITION *thisext;-
491-
492 for (i = 0, thisext = ext_defs; i < builtin_num
i < builtin_numDescription
TRUEevaluated 466521 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4344 times by 1 test
Evaluated by:
  • libssl.so.1.1
; i++, thisext++) {
4344-466521
493 if (type == thisext->type
type == thisext->typeDescription
TRUEevaluated 33107 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 433414 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
33107-433414
494 if (!validate_context(s, thisext->context, context)
!validate_cont...text, context)Description
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 33095 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
12-33095
495 return
executed 12 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 12 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
12
496-
497 *found = &rawexlist[i];-
498 return
executed 33095 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 33095 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
33095
499 }-
500 }
executed 433414 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
433414
501-
502-
503 if (meths !=
meths != ((void *)0)Description
TRUEevaluated 4344 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-4344
504 ((void *)0)
meths != ((void *)0)Description
TRUEevaluated 4344 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-4344
505 ) {-
506 size_t offset = 0;-
507 ENDPOINT role = ENDPOINT_BOTH;-
508 custom_ext_method *meth = -
509 ((void *)0)-
510 ;-
511-
512 if ((
(context & 0x0080) != 0Description
TRUEevaluated 2133 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2211 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0080) != 0
(context & 0x0080) != 0Description
TRUEevaluated 2133 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2211 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
2133-2211
513 role = ENDPOINT_SERVER;
executed 2133 times by 1 test: role = ENDPOINT_SERVER;
Executed by:
  • libssl.so.1.1
2133
514 else if ((
(context & 0x0100) != 0Description
TRUEevaluated 1039 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1172 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0100) != 0
(context & 0x0100) != 0Description
TRUEevaluated 1039 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1172 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
1039-1172
515 role = ENDPOINT_CLIENT;
executed 1039 times by 1 test: role = ENDPOINT_CLIENT;
Executed by:
  • libssl.so.1.1
1039
516-
517 meth = custom_ext_find(meths, role, type, &offset);-
518 if (meth !=
meth != ((void *)0)Description
TRUEevaluated 39 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
39-4305
519 ((void *)0)
meth != ((void *)0)Description
TRUEevaluated 39 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
39-4305
520 ) {-
521 if (!validate_context(s, meth->context, context)
!validate_cont...text, context)Description
TRUEnever evaluated
FALSEevaluated 39 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-39
522 return
never executed: return 0;
0;
never executed: return 0;
0
523 *found = &rawexlist[offset + builtin_num];-
524 return
executed 39 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 39 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
39
525 }-
526 }
executed 4305 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
4305
527-
528-
529 *found = -
530 ((void *)0)-
531 ;-
532 return
executed 4305 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 4305 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
4305
533}-
534-
535-
536-
537-
538-
539-
540int extension_is_relevant(SSL *s, unsigned int extctx, unsigned int thisctx)-
541{-
542 int is_tls13;-
543-
544-
545-
546-
547-
548 if ((
(thisctx & 0x0800) != 0Description
TRUEevaluated 1072 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 268271 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & 0x0800) != 0
(thisctx & 0x0800) != 0Description
TRUEevaluated 1072 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 268271 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
1072-268271
549 is_tls13 = 1;
executed 1072 times by 1 test: is_tls13 = 1;
Executed by:
  • libssl.so.1.1
1072
550 else-
551 is_tls13 = (!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEevaluated 254914 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 13357 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->version >= 0x0304Description
TRUEevaluated 219061 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 35853 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEevaluated 219061 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 35853 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->v...ion != 0x10000Description
TRUEevaluated 23738 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 195323 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEevaluated 23738 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 195323 times by 1 test
Evaluated by:
  • libssl.so.1.1
);
executed 268271 times by 1 test: is_tls13 = (!(s->method->ssl3_enc->enc_flags & 0x8) && (s)->method->version >= 0x0304 && (s)->method->version != 0x10000);
Executed by:
  • libssl.so.1.1
13357-268271
552-
553 if (((
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 13357 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 255986 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->method->ssl3_enc->enc_flags & 0x8)
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 13357 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 255986 times by 1 test
Evaluated by:
  • libssl.so.1.1
13357-255986
554 && (
(extctx & 0x0004) != 0Description
TRUEevaluated 1150 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 12207 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0004) != 0
(extctx & 0x0004) != 0Description
TRUEevaluated 1150 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 12207 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
1150-12207
555 || (s->version == 0x0300
s->version == 0x0300Description
TRUEnever evaluated
FALSEevaluated 268193 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-268193
556 && (
(extctx & 0x0008) == 0Description
TRUEnever evaluated
FALSEnever evaluated
extctx & 0x0008) == 0
(extctx & 0x0008) == 0Description
TRUEnever evaluated
FALSEnever evaluated
)
0
557 || (is_tls13
is_tls13Description
TRUEevaluated 24810 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 243383 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(extctx & 0x0010) != 0Description
TRUEevaluated 4091 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 20719 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0010) != 0
(extctx & 0x0010) != 0Description
TRUEevaluated 4091 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 20719 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
4091-243383
558 || (!is_tls13
!is_tls13Description
TRUEevaluated 243383 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 20719 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(extctx & 0x0020) != 0Description
TRUEevaluated 44868 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 198515 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0020) != 0
(extctx & 0x0020) != 0Description
TRUEevaluated 44868 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 198515 times by 1 test
Evaluated by:
  • libssl.so.1.1
20719-243383
559 && (
(thisctx & 0x0080) == 0Description
TRUEnever evaluated
FALSEevaluated 44868 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & 0x0080) == 0
(thisctx & 0x0080) == 0Description
TRUEnever evaluated
FALSEevaluated 44868 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-44868
560 || (s->server
s->serverDescription
TRUEevaluated 97816 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 166286 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& !is_tls13
!is_tls13Description
TRUEevaluated 81280 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 16536 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(extctx & 0x0020) != 0Description
TRUEevaluated 11069 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 70211 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0020) != 0
(extctx & 0x0020) != 0Description
TRUEevaluated 11069 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 70211 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
11069-166286
561 || (s->hit
s->hitDescription
TRUEevaluated 4013 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 249020 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(extctx & 0x0040) != 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4011 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0040) != 0
(extctx & 0x0040) != 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4011 times by 1 test
Evaluated by:
  • libssl.so.1.1
))
2-249020
562 return
executed 16312 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 16312 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
16312
563 return
executed 253031 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 253031 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
253031
564}-
565int tls_collect_extensions(SSL *s, PACKET *packet, unsigned int context,-
566 RAW_EXTENSION **res, size_t *len, int init)-
567{-
568 PACKET extensions = *packet;-
569 size_t i = 0;-
570 size_t num_exts;-
571 custom_ext_methods *exts = &s->cert->custext;-
572 RAW_EXTENSION *raw_extensions = -
573 ((void *)0)-
574 ;-
575 const EXTENSION_DEFINITION *thisexd;-
576-
577 *res = -
578 ((void *)0)-
579 ;-
580-
581-
582-
583-
584-
585 if ((
(context & 0x0080) != 0Description
TRUEevaluated 3693 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6709 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0080) != 0
(context & 0x0080) != 0Description
TRUEevaluated 3693 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6709 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
3693-6709
586 custom_ext_init(&s->cert->custext);
executed 3693 times by 1 test: custom_ext_init(&s->cert->custext);
Executed by:
  • libssl.so.1.1
3693
587-
588 num_exts = (sizeof(ext_defs)/sizeof((ext_defs)[0])) + (exts !=
exts != ((void *)0)Description
TRUEevaluated 10402 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-10402
589 ((void *)0)
exts != ((void *)0)Description
TRUEevaluated 10402 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-10402
590 ? exts->meths_count : 0);-
591 raw_extensions = CRYPTO_zalloc(num_exts * sizeof(*raw_extensions), __FILE__, 571);-
592 if (raw_extensions ==
raw_extensions == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 10402 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-10402
593 ((void *)0)
raw_extensions == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 10402 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-10402
594 ) {-
595 ossl_statem_fatal((s), (80), (435), ((1|64)),-
596 __FILE__-
597 ,-
598 574-
599 )-
600 ;-
601 return
never executed: return 0;
0;
never executed: return 0;
0
602 }-
603-
604 i = 0;-
605 while (PACKET_remaining(&extensions) > 0
PACKET_remaini...xtensions) > 0Description
TRUEevaluated 37466 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 10333 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
10333-37466
606 unsigned int type, idx;-
607 PACKET extension;-
608 RAW_EXTENSION *thisex;-
609-
610 if (!PACKET_get_net_2(&extensions, &type)
!PACKET_get_ne...nsions, &type)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 37462 times by 1 test
Evaluated by:
  • libssl.so.1.1
||
4-37462
611 !PACKET_get_length_prefixed_2(&extensions, &extension)
!PACKET_get_le...s, &extension)Description
TRUEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 37451 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
11-37451
612 ossl_statem_fatal((s), (50), (435), (110),-
613 __FILE__-
614 ,-
615 587-
616 )-
617 ;-
618 goto
executed 15 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
err;
executed 15 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
15
619 }-
620-
621-
622-
623-
624-
625 if (!verify_extension(s, context, type, exts, raw_extensions, &thisex)
!verify_extens...ions, &thisex)Description
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 37439 times by 1 test
Evaluated by:
  • libssl.so.1.1
12-37439
626 || (thisex !=
thisex != ((void *)0)Description
TRUEevaluated 33134 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
4305-33134
627 ((void *)0)
thisex != ((void *)0)Description
TRUEevaluated 33134 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
4305-33134
628 && thisex->present == 1
thisex->present == 1Description
TRUEevaluated 31 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 33103 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
31-33103
629 || (type == 41
type == 41Description
TRUEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 37100 times by 1 test
Evaluated by:
  • libssl.so.1.1
308-37100
630 && (
(context & 0x0080) != 0Description
TRUEevaluated 200 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 108 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0080) != 0
(context & 0x0080) != 0Description
TRUEevaluated 200 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 108 times by 1 test
Evaluated by:
  • libssl.so.1.1
108-200
631 && PACKET_remaining(&extensions) != 0
PACKET_remaini...tensions) != 0Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 198 times by 1 test
Evaluated by:
  • libssl.so.1.1
)) {
2-198
632 ossl_statem_fatal((s), (47), (435), (110),-
633 __FILE__-
634 ,-
635 601-
636 )-
637 ;-
638 goto
executed 45 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
err;
executed 45 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
45
639 }-
640 idx = thisex - raw_extensions;-
641 if (idx < (sizeof(ext_defs)/sizeof((ext_defs)[0]))
idx < (sizeof(...ext_defs)[0]))Description
TRUEevaluated 33062 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4344 times by 1 test
Evaluated by:
  • libssl.so.1.1
4344-33062
642 && (
(context & (0x... 0x2000)) == 0Description
TRUEevaluated 11272 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21790 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & (0x0080
(context & (0x... 0x2000)) == 0Description
TRUEevaluated 11272 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21790 times by 1 test
Evaluated by:
  • libssl.so.1.1
11272-21790
643 | 0x4000
(context & (0x... 0x2000)) == 0Description
TRUEevaluated 11272 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21790 times by 1 test
Evaluated by:
  • libssl.so.1.1
11272-21790
644 | 0x2000)) == 0
(context & (0x... 0x2000)) == 0Description
TRUEevaluated 11272 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21790 times by 1 test
Evaluated by:
  • libssl.so.1.1
11272-21790
645 && type != 44
type != 44Description
TRUEevaluated 11128 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 144 times by 1 test
Evaluated by:
  • libssl.so.1.1
144-11128
646 && type != 0xff01
type != 0xff01Description
TRUEevaluated 8353 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2775 times by 1 test
Evaluated by:
  • libssl.so.1.1
2775-8353
647 && type != 18
type != 18Description
TRUEevaluated 8344 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 9 times by 1 test
Evaluated by:
  • libssl.so.1.1
9-8344
648 && (
(s->ext.extfla...x] & 0x2) == 0Description
TRUEevaluated 9 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 8335 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->ext.extflags[idx] & 0x2) == 0
(s->ext.extfla...x] & 0x2) == 0Description
TRUEevaluated 9 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 8335 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
9-8335
649 ossl_statem_fatal((s), (110), (435), (217),-
650 __FILE__-
651 ,-
652 628-
653 )-
654 ;-
655 goto
executed 9 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
err;
executed 9 times by 1 test: goto err;
Executed by:
  • libssl.so.1.1
9
656 }-
657 if (thisex !=
thisex != ((void *)0)Description
TRUEevaluated 33092 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
4305-33092
658 ((void *)0)
thisex != ((void *)0)Description
TRUEevaluated 33092 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4305 times by 1 test
Evaluated by:
  • libssl.so.1.1
4305-33092
659 ) {-
660 thisex->data = extension;-
661 thisex->present = 1;-
662 thisex->type = type;-
663 thisex->received_order = i++;-
664 if (s->ext.debug_cb
s->ext.debug_cbDescription
TRUEnever evaluated
FALSEevaluated 33092 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-33092
665 s->ext.debug_cb(s, !s->server, thisex->type,
never executed: s->ext.debug_cb(s, !s->server, thisex->type, PACKET_data(&thisex->data), PACKET_remaining(&thisex->data), s->ext.debug_arg);
0
666 PACKET_data(&thisex->data),
never executed: s->ext.debug_cb(s, !s->server, thisex->type, PACKET_data(&thisex->data), PACKET_remaining(&thisex->data), s->ext.debug_arg);
0
667 PACKET_remaining(&thisex->data),
never executed: s->ext.debug_cb(s, !s->server, thisex->type, PACKET_data(&thisex->data), PACKET_remaining(&thisex->data), s->ext.debug_arg);
0
668 s->ext.debug_arg);
never executed: s->ext.debug_cb(s, !s->server, thisex->type, PACKET_data(&thisex->data), PACKET_remaining(&thisex->data), s->ext.debug_arg);
0
669 }
executed 33092 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
33092
670 }
executed 37397 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
37397
671-
672 if (init
initDescription
TRUEevaluated 10233 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 100 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
100-10233
673-
674-
675-
676-
677 for (thisexd = ext_defs, i = 0; i < (sizeof(ext_defs)/sizeof((ext_defs)[0]))
i < (sizeof(ex...ext_defs)[0]))Description
TRUEevaluated 266058 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 10233 times by 1 test
Evaluated by:
  • libssl.so.1.1
;
10233-266058
678 i++, thisexd++) {-
679 if (thisexd->init !=
thisexd->init != ((void *)0)Description
TRUEevaluated 143262 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 122796 times by 1 test
Evaluated by:
  • libssl.so.1.1
122796-143262
680 ((void *)0)
thisexd->init != ((void *)0)Description
TRUEevaluated 143262 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 122796 times by 1 test
Evaluated by:
  • libssl.so.1.1
122796-143262
681 && (
(thisexd->cont... context) != 0Description
TRUEevaluated 84149 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 59113 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisexd->context & context) != 0
(thisexd->cont... context) != 0Description
TRUEevaluated 84149 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 59113 times by 1 test
Evaluated by:
  • libssl.so.1.1
59113-84149
682 && extension_is_relevant(s, thisexd->context, context)
extension_is_r...text, context)Description
TRUEevaluated 73048 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 11101 times by 1 test
Evaluated by:
  • libssl.so.1.1
11101-73048
683 && !thisexd->init(s, context)
!thisexd->init(s, context)Description
TRUEnever evaluated
FALSEevaluated 73048 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-73048
684-
685 goto
never executed: goto err;
err;
never executed: goto err;
0
686 }-
687 }
executed 266058 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
266058
688 }
executed 10233 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
10233
689-
690 *res = raw_extensions;-
691 if (len !=
len != ((void *)0)Description
TRUEevaluated 3657 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6676 times by 1 test
Evaluated by:
  • libssl.so.1.1
3657-6676
692 ((void *)0)
len != ((void *)0)Description
TRUEevaluated 3657 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6676 times by 1 test
Evaluated by:
  • libssl.so.1.1
3657-6676
693 )-
694 *
executed 3657 times by 1 test: *len = num_exts;
Executed by:
  • libssl.so.1.1
len = num_exts;
executed 3657 times by 1 test: *len = num_exts;
Executed by:
  • libssl.so.1.1
3657
695 return
executed 10333 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 10333 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
10333
696-
697 err:-
698 CRYPTO_free(raw_extensions, __FILE__, 666);-
699 return
executed 69 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 69 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
69
700}-
701int tls_parse_extension(SSL *s, TLSEXT_INDEX idx, int context,-
702 RAW_EXTENSION *exts, X509 *x, size_t chainidx)-
703{-
704 RAW_EXTENSION *currext = &exts[idx];-
705 int (*parser)(SSL *s, PACKET *pkt, unsigned int context, X509 *x,-
706 size_t chainidx) = -
707 ((void *)0)-
708 ;-
709-
710-
711 if (!currext->present
!currext->presentDescription
TRUEevaluated 213464 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 34722 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
34722-213464
712 return
executed 213464 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 213464 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
213464
713-
714-
715 if (currext->parsed
currext->parsedDescription
TRUEevaluated 5214 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 29508 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
5214-29508
716 return
executed 5214 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 5214 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
5214
717-
718 currext->parsed = 1;-
719-
720 if (idx < (sizeof(ext_defs)/sizeof((ext_defs)[0]))
idx < (sizeof(...ext_defs)[0]))Description
TRUEevaluated 29469 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 39 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
39-29469
721-
722 const EXTENSION_DEFINITION *extdef = &ext_defs[idx];-
723-
724-
725 if (!extension_is_relevant(s, extdef->context, context)
!extension_is_...text, context)Description
TRUEevaluated 4249 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 25220 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
4249-25220
726 return
executed 4249 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 4249 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
4249
727-
728 parser = s->server
s->serverDescription
TRUEevaluated 14488 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 10732 times by 1 test
Evaluated by:
  • libssl.so.1.1
? extdef->parse_ctos : extdef->parse_stoc;
10732-14488
729-
730 if (parser !=
parser != ((void *)0)Description
TRUEevaluated 24926 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 294 times by 1 test
Evaluated by:
  • libssl.so.1.1
294-24926
731 ((void *)0)
parser != ((void *)0)Description
TRUEevaluated 24926 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 294 times by 1 test
Evaluated by:
  • libssl.so.1.1
294-24926
732 )-
733 return
executed 24926 times by 1 test: return parser(s, &currext->data, context, x, chainidx);
Executed by:
  • libssl.so.1.1
parser(s, &currext->data, context, x, chainidx);
executed 24926 times by 1 test: return parser(s, &currext->data, context, x, chainidx);
Executed by:
  • libssl.so.1.1
24926
734-
735-
736-
737-
738-
739 }
executed 294 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
294
740-
741-
742 return
executed 333 times by 1 test: return custom_ext_parse(s, context, currext->type, PACKET_data(&currext->data), PACKET_remaining(&currext->data), x, chainidx);
Executed by:
  • libssl.so.1.1
custom_ext_parse(s, context, currext->type,
executed 333 times by 1 test: return custom_ext_parse(s, context, currext->type, PACKET_data(&currext->data), PACKET_remaining(&currext->data), x, chainidx);
Executed by:
  • libssl.so.1.1
333
743 PACKET_data(&currext->data),
executed 333 times by 1 test: return custom_ext_parse(s, context, currext->type, PACKET_data(&currext->data), PACKET_remaining(&currext->data), x, chainidx);
Executed by:
  • libssl.so.1.1
333
744 PACKET_remaining(&currext->data),
executed 333 times by 1 test: return custom_ext_parse(s, context, currext->type, PACKET_data(&currext->data), PACKET_remaining(&currext->data), x, chainidx);
Executed by:
  • libssl.so.1.1
333
745 x, chainidx);
executed 333 times by 1 test: return custom_ext_parse(s, context, currext->type, PACKET_data(&currext->data), PACKET_remaining(&currext->data), x, chainidx);
Executed by:
  • libssl.so.1.1
333
746}-
747int tls_parse_all_extensions(SSL *s, int context, RAW_EXTENSION *exts, X509 *x,-
748 size_t chainidx, int fin)-
749{-
750 size_t i, numexts = (sizeof(ext_defs)/sizeof((ext_defs)[0]));-
751 const EXTENSION_DEFINITION *thisexd;-
752-
753-
754 numexts += s->cert->custext.meths_count;-
755-
756-
757 for (i = 0; i < numexts
i < numextsDescription
TRUEevaluated 238354 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 9001 times by 1 test
Evaluated by:
  • libssl.so.1.1
; i++) {
9001-238354
758 if (!tls_parse_extension(s, i, context, exts, x, chainidx)
!tls_parse_ext..., x, chainidx)Description
TRUEevaluated 379 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 237975 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
379-237975
759-
760 return
executed 379 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 379 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
379
761 }-
762 }
executed 237975 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
237975
763-
764 if (fin
finDescription
TRUEevaluated 8901 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 100 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
100-8901
765-
766-
767-
768-
769 for (i = 0, thisexd = ext_defs; i < (sizeof(ext_defs)/sizeof((ext_defs)[0]))
i < (sizeof(ex...ext_defs)[0]))Description
TRUEevaluated 231175 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 8872 times by 1 test
Evaluated by:
  • libssl.so.1.1
;
8872-231175
770 i++, thisexd++) {-
771 if (thisexd->final !=
thisexd->final != ((void *)0)Description
TRUEevaluated 80055 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 151120 times by 1 test
Evaluated by:
  • libssl.so.1.1
80055-151120
772 ((void *)0)
thisexd->final != ((void *)0)Description
TRUEevaluated 80055 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 151120 times by 1 test
Evaluated by:
  • libssl.so.1.1
80055-151120
773 && (
(thisexd->cont... context) != 0Description
TRUEevaluated 46006 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 34049 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisexd->context & context) != 0
(thisexd->cont... context) != 0Description
TRUEevaluated 46006 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 34049 times by 1 test
Evaluated by:
  • libssl.so.1.1
34049-46006
774 && !thisexd->final(s, context, exts[i].present)
!thisexd->fina...ts[i].present)Description
TRUEevaluated 29 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 45977 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
29-45977
775-
776 return
executed 29 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 29 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
29
777 }-
778 }
executed 231146 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
231146
779 }
executed 8872 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
8872
780-
781 return
executed 8972 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 8972 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
8972
782}-
783-
784int should_add_extension(SSL *s, unsigned int extctx, unsigned int thisctx,-
785 int max_version)-
786{-
787-
788 if ((
(extctx & thisctx) == 0Description
TRUEevaluated 109840 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 155678 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & thisctx) == 0
(extctx & thisctx) == 0Description
TRUEevaluated 109840 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 155678 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
109840-155678
789 return
executed 109840 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 109840 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
109840
790-
791-
792 if (!extension_is_relevant(s, extctx, thisctx)
!extension_is_...tctx, thisctx)Description
TRUEevaluated 961 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 154717 times by 1 test
Evaluated by:
  • libssl.so.1.1
961-154717
793 || ((
(extctx & 0x0020) != 0Description
TRUEevaluated 37671 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 117046 times by 1 test
Evaluated by:
  • libssl.so.1.1
extctx & 0x0020) != 0
(extctx & 0x0020) != 0Description
TRUEevaluated 37671 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 117046 times by 1 test
Evaluated by:
  • libssl.so.1.1
37671-117046
794 && (
(thisctx & 0x0080) != 0Description
TRUEevaluated 33799 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3872 times by 1 test
Evaluated by:
  • libssl.so.1.1
thisctx & 0x0080) != 0
(thisctx & 0x0080) != 0Description
TRUEevaluated 33799 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3872 times by 1 test
Evaluated by:
  • libssl.so.1.1
3872-33799
795 && ((
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 576 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 33223 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->method->ssl3_enc->enc_flags & 0x8)
(s->method->ss...c_flags & 0x8)Description
TRUEevaluated 576 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 33223 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| max_version < 0x0304
max_version < 0x0304Description
TRUEevaluated 5803 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 27420 times by 1 test
Evaluated by:
  • libssl.so.1.1
)))
576-33223
796 return
executed 7340 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 7340 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
7340
797-
798 return
executed 148338 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 148338 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
148338
799}-
800int tls_construct_extensions(SSL *s, WPACKET *pkt, unsigned int context,-
801 X509 *x, size_t chainidx)-
802{-
803 size_t i;-
804 int min_version, max_version = 0, reason;-
805 const EXTENSION_DEFINITION *thisexd;-
806-
807 if (!WPACKET_start_sub_packet_len__((pkt), 2)
!WPACKET_start...en__((pkt), 2)Description
TRUEnever evaluated
FALSEevaluated 10211 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-10211
808-
809-
810-
811-
812-
813 || ((
(context & (0x... 0x0100)) != 0Description
TRUEevaluated 6449 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3762 times by 1 test
Evaluated by:
  • libssl.so.1.1
context &
(context & (0x... 0x0100)) != 0Description
TRUEevaluated 6449 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3762 times by 1 test
Evaluated by:
  • libssl.so.1.1
3762-6449
814 (0x0080 | 0x0100)) != 0
(context & (0x... 0x0100)) != 0Description
TRUEevaluated 6449 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3762 times by 1 test
Evaluated by:
  • libssl.so.1.1
3762-6449
815 && !WPACKET_set_flags(pkt,
!WPACKET_set_flags(pkt, 2)Description
TRUEnever evaluated
FALSEevaluated 6449 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-6449
816 2)
!WPACKET_set_flags(pkt, 2)Description
TRUEnever evaluated
FALSEevaluated 6449 times by 1 test
Evaluated by:
  • libssl.so.1.1
)) {
0-6449
817 ossl_statem_fatal((s), (80), (447), ((4|64)),-
818 __FILE__-
819 ,-
820 808-
821 )-
822 ;-
823 return
never executed: return 0;
0;
never executed: return 0;
0
824 }-
825-
826 if ((
(context & 0x0080) != 0Description
TRUEevaluated 4939 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5272 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0080) != 0
(context & 0x0080) != 0Description
TRUEevaluated 4939 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5272 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
4939-5272
827 reason = ssl_get_min_max_version(s, &min_version, &max_version, -
828 ((void *)0)-
829 );-
830 if (reason != 0
reason != 0Description
TRUEnever evaluated
FALSEevaluated 4939 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-4939
831 ossl_statem_fatal((s), (80), (447), (reason),-
832 __FILE__-
833 ,-
834 816-
835 )-
836 ;-
837 return
never executed: return 0;
0;
never executed: return 0;
0
838 }-
839 }
executed 4939 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
4939
840-
841-
842 if ((
(context & 0x0080) != 0Description
TRUEevaluated 4939 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5272 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0080) != 0
(context & 0x0080) != 0Description
TRUEevaluated 4939 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5272 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
4939-5272
843-
844 custom_ext_init(&s->cert->custext);-
845 }
executed 4939 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
4939
846 if (!custom_ext_add(s, context, pkt, x, chainidx, max_version)
!custom_ext_ad..., max_version)Description
TRUEnever evaluated
FALSEevaluated 10211 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-10211
847-
848 return
never executed: return 0;
0;
never executed: return 0;
0
849 }-
850-
851 for (i = 0, thisexd = ext_defs; i < (sizeof(ext_defs)/sizeof((ext_defs)[0]))
i < (sizeof(ex...ext_defs)[0]))Description
TRUEevaluated 265451 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 10204 times by 1 test
Evaluated by:
  • libssl.so.1.1
; i++, thisexd++) {
10204-265451
852 EXT_RETURN (*construct)(SSL *s, WPACKET *pkt, unsigned int context,-
853 X509 *x, size_t chainidx);-
854 EXT_RETURN ret;-
855-
856-
857 if (!should_add_extension(s, thisexd->context, context, max_version)
!should_add_ex..., max_version)Description
TRUEevaluated 117171 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 148280 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
117171-148280
858 continue;
executed 117171 times by 1 test: continue;
Executed by:
  • libssl.so.1.1
117171
859-
860 construct = s->server
s->serverDescription
TRUEevaluated 32085 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 116195 times by 1 test
Evaluated by:
  • libssl.so.1.1
? thisexd->construct_stoc
32085-116195
861 : thisexd->construct_ctos;-
862-
863 if (construct ==
construct == ((void *)0)Description
TRUEevaluated 7365 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 140915 times by 1 test
Evaluated by:
  • libssl.so.1.1
7365-140915
864 ((void *)0)
construct == ((void *)0)Description
TRUEevaluated 7365 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 140915 times by 1 test
Evaluated by:
  • libssl.so.1.1
7365-140915
865 )-
866 continue;
executed 7365 times by 1 test: continue;
Executed by:
  • libssl.so.1.1
7365
867-
868 ret = construct(s, pkt, context, x, chainidx);-
869 if (ret == EXT_RETURN_FAIL
ret == EXT_RETURN_FAILDescription
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 140908 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
7-140908
870-
871 return
executed 7 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 7 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
7
872 }-
873 if (ret == EXT_RETURN_SENT
ret == EXT_RETURN_SENTDescription
TRUEevaluated 52570 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 88338 times by 1 test
Evaluated by:
  • libssl.so.1.1
52570-88338
874 && (
(context & (0x... 0x2000)) != 0Description
TRUEevaluated 44846 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 7724 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & (0x0080
(context & (0x... 0x2000)) != 0Description
TRUEevaluated 44846 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 7724 times by 1 test
Evaluated by:
  • libssl.so.1.1
7724-44846
875 | 0x4000
(context & (0x... 0x2000)) != 0Description
TRUEevaluated 44846 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 7724 times by 1 test
Evaluated by:
  • libssl.so.1.1
7724-44846
876 | 0x2000)) != 0
(context & (0x... 0x2000)) != 0Description
TRUEevaluated 44846 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 7724 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
7724-44846
877 s->ext.extflags[i] |= 0x2;
executed 44846 times by 1 test: s->ext.extflags[i] |= 0x2;
Executed by:
  • libssl.so.1.1
44846
878 }
executed 140908 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
140908
879-
880 if (!WPACKET_close(pkt)
!WPACKET_close(pkt)Description
TRUEnever evaluated
FALSEevaluated 10204 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-10204
881 ossl_statem_fatal((s), (80), (447), ((4|64)),-
882 __FILE__-
883 ,-
884 860-
885 )-
886 ;-
887 return
never executed: return 0;
0;
never executed: return 0;
0
888 }-
889-
890 return
executed 10204 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 10204 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
10204
891}-
892static int final_renegotiate(SSL *s, unsigned int context, int sent)-
893{-
894 if (!s->server
!s->serverDescription
TRUEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2745 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
2745-2787
895-
896-
897-
898-
899 if (!(s->options & 0x00000004U)
!(s->options & 0x00000004U)Description
TRUEnever evaluated
FALSEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-2787
900 && !(s->options & 0x00040000U)
!(s->options & 0x00040000U)Description
TRUEnever evaluated
FALSEnever evaluated
0
901 && !sent
!sentDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
902 ossl_statem_fatal((s), (40), (483), (338),-
903 __FILE__-
904 ,-
905 885-
906 )-
907 ;-
908 return
never executed: return 0;
0;
never executed: return 0;
0
909 }-
910-
911 return
executed 2787 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2787 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2787
912 }-
913-
914-
915 if (s->renegotiate
s->renegotiateDescription
TRUEevaluated 22 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2723 times by 1 test
Evaluated by:
  • libssl.so.1.1
22-2723
916 && !(s->options & 0x00040000U)
!(s->options & 0x00040000U)Description
TRUEevaluated 22 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-22
917 && !sent
!sentDescription
TRUEnever evaluated
FALSEevaluated 22 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-22
918 ossl_statem_fatal((s), (40), (483), (338),-
919 __FILE__-
920 ,-
921 897-
922 )-
923 ;-
924 return
never executed: return 0;
0;
never executed: return 0;
0
925 }-
926-
927-
928 return
executed 2745 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2745 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2745
929}-
930-
931static int init_server_name(SSL *s, unsigned int context)-
932{-
933 if (s->server
s->serverDescription
TRUEevaluated 3657 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4401 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
3657-4401
934 s->servername_done = 0;-
935-
936 CRYPTO_free(s->ext.hostname, __FILE__, 910);-
937 s->ext.hostname = -
938 ((void *)0)-
939 ;-
940 }
executed 3657 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
3657
941-
942 return
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
8058
943}-
944-
945static int final_server_name(SSL *s, unsigned int context, int sent)-
946{-
947 int ret = 3;-
948 int altmp = 112;-
949 int was_ticket = (SSL_get_options(s) & 0x00004000U) == 0;-
950-
951 if (!((s->ctx !=
!((s->ctx != (...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-6116
952 ((void *)0)
!((s->ctx != (...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-6116
953 ) != 0)
!((s->ctx != (...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| !((s->session_ctx !=
!((s->session_...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-6116
954 ((void *)0)
!((s->session_...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-6116
955 ) != 0)
!((s->session_...d *)0) ) != 0)Description
TRUEnever evaluated
FALSEevaluated 6116 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-6116
956 ossl_statem_fatal((s), (80), (558), ((4|64)),-
957 __FILE__-
958 ,-
959 925-
960 )-
961 ;-
962 return
never executed: return 0;
0;
never executed: return 0;
0
963 }-
964-
965 if (s->ctx->ext.servername_cb !=
s->ctx->ext.se...!= ((void *)0)Description
TRUEevaluated 176 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5940 times by 1 test
Evaluated by:
  • libssl.so.1.1
176-5940
966 ((void *)0)
s->ctx->ext.se...!= ((void *)0)Description
TRUEevaluated 176 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5940 times by 1 test
Evaluated by:
  • libssl.so.1.1
176-5940
967 )-
968 ret = s->ctx->ext.servername_cb(s, &altmp,
executed 176 times by 1 test: ret = s->ctx->ext.servername_cb(s, &altmp, s->ctx->ext.servername_arg);
Executed by:
  • libssl.so.1.1
176
969 s->ctx->ext.servername_arg);
executed 176 times by 1 test: ret = s->ctx->ext.servername_cb(s, &altmp, s->ctx->ext.servername_arg);
Executed by:
  • libssl.so.1.1
176
970 else if (s->session_ctx->ext.servername_cb !=
s->session_ctx...!= ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 5940 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-5940
971 ((void *)0)
s->session_ctx...!= ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 5940 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-5940
972 )-
973 ret = s->session_ctx->ext.servername_cb(s, &altmp,
never executed: ret = s->session_ctx->ext.servername_cb(s, &altmp, s->session_ctx->ext.servername_arg);
0
974 s->session_ctx->ext.servername_arg);
never executed: ret = s->session_ctx->ext.servername_cb(s, &altmp, s->session_ctx->ext.servername_arg);
0
975 if (s->server
s->serverDescription
TRUEevaluated 2745 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3371 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
2745-3371
976-
977 if (sent
sentDescription
TRUEevaluated 462 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2283 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& ret == 0
ret == 0Description
TRUEevaluated 32 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 430 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (!s->hit
!s->hitDescription
TRUEevaluated 31 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
|| (!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
&& (
(s)->method->version >= 0x0304Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
&& (
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
))) {
0-2283
978-
979 CRYPTO_free(s->session->ext.hostname, __FILE__, 948);-
980 s->session->ext.hostname = CRYPTO_strdup(s->ext.hostname, __FILE__, 949);-
981 if (s->session->ext.hostname ==
s->session->ex...== ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 32 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-32
982 ((void *)0)
s->session->ex...== ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 32 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-32
983 && s->ext.hostname !=
s->ext.hostname != ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
984 ((void *)0)
s->ext.hostname != ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
985 ) {-
986 ossl_statem_fatal((s), (80), (558), ((4|64)),-
987 __FILE__-
988 ,-
989 952-
990 )-
991 ;-
992 }
never executed: end of block
0
993 }
executed 32 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
32
994 }
executed 2745 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
2745
995-
996-
997-
998-
999-
1000-
1001-
1002 if (((
(s)->s3->tmp.f...sh_md_len == 0Description
TRUEevaluated 6072 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->s3->tmp.finish_md_len == 0
(s)->s3->tmp.f...sh_md_len == 0Description
TRUEevaluated 6072 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| (
(s)->s3->tmp.p...sh_md_len == 0Description
TRUEnever evaluated
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->s3->tmp.peer_finish_md_len == 0
(s)->s3->tmp.p...sh_md_len == 0Description
TRUEnever evaluated
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
) && s->ctx != s->session_ctx
s->ctx != s->session_ctxDescription
TRUEevaluated 23 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6049 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-6072
1003 -
1004 __atomic_fetch_add ((-
1005 (&s->ctx->stats.sess_accept)-
1006 ), (-
1007 1-
1008 ), (-
1009 memory_order_relaxed-
1010 ))-
1011 ;-
1012 -
1013 __atomic_fetch_add ((-
1014 (&s->session_ctx->stats.sess_accept)-
1015 ), (-
1016 1-
1017 ), (-
1018 memory_order_relaxed-
1019 ))-
1020 ;-
1021 }
executed 23 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
23
1022-
1023-
1024-
1025-
1026-
1027-
1028 if (ret == 0
ret == 0Description
TRUEevaluated 172 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5944 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& s->ext.ticket_expected
s->ext.ticket_expectedDescription
TRUEevaluated 94 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 78 times by 1 test
Evaluated by:
  • libssl.so.1.1
78-5944
1029 && was_ticket
was_ticketDescription
TRUEevaluated 94 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
&& (
(SSL_get_optio...0004000U) != 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 93 times by 1 test
Evaluated by:
  • libssl.so.1.1
SSL_get_options(s) & 0x00004000U) != 0
(SSL_get_optio...0004000U) != 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 93 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-94
1030 s->ext.ticket_expected = 0;-
1031 if (!s->hit
!s->hitDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
) {
0-1
1032 SSL_SESSION* ss = SSL_get_session(s);-
1033-
1034 if (ss !=
ss != ((void *)0)Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-1
1035 ((void *)0)
ss != ((void *)0)Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-1
1036 ) {-
1037 CRYPTO_free(ss->ext.tick, __FILE__, 980);-
1038 ss->ext.tick = -
1039 ((void *)0)-
1040 ;-
1041 ss->ext.ticklen = 0;-
1042 ss->ext.tick_lifetime_hint = 0;-
1043 ss->ext.tick_age_add = 0;-
1044 ss->ext.tick_identity = 0;-
1045 if (!ssl_generate_session_id(s, ss)
!ssl_generate_...sion_id(s, ss)Description
TRUEnever evaluated
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-1
1046 ossl_statem_fatal((s), (80), (558), ((4|64)),-
1047 __FILE__-
1048 ,-
1049 988-
1050 )-
1051 ;-
1052 return
never executed: return 0;
0;
never executed: return 0;
0
1053 }-
1054 }
executed 1 time by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
1
1055 ossl_statem_fatal((s), (80), (558), ((4|64)),-
1056 __FILE__-
1057 ,-
1058 993-
1059 )-
1060 ;-
1061 return
never executed: return 0;
0;
never executed: return 0;
0
1062 }-
1063 }-
1064 }
executed 1 time by 1 test: end of block
Executed by:
  • libssl.so.1.1
1
1065-
1066 switch (ret) {-
1067 case
executed 1 time by 1 test: case 2:
Executed by:
  • libssl.so.1.1
2:
executed 1 time by 1 test: case 2:
Executed by:
  • libssl.so.1.1
1
1068 ossl_statem_fatal((s), (altmp), (558), (234), __FILE__, 1001);-
1069 return
executed 1 time by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 1 time by 1 test: return 0;
Executed by:
  • libssl.so.1.1
1
1070-
1071 case
never executed: case 1:
1:
never executed: case 1:
0
1072-
1073 if (!(!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEnever evaluated
FALSEnever evaluated
&& (
(s)->method->version >= 0x0304Description
TRUEnever evaluated
FALSEnever evaluated
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEnever evaluated
FALSEnever evaluated
&& (
(s)->method->v...ion != 0x10000Description
TRUEnever evaluated
FALSEnever evaluated
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEnever evaluated
FALSEnever evaluated
))
0
1074 ssl3_send_alert(s, 1, altmp);
never executed: ssl3_send_alert(s, 1, altmp);
0
1075 return
never executed: return 1;
1;
never executed: return 1;
0
1076-
1077 case
executed 5943 times by 1 test: case 3:
Executed by:
  • libssl.so.1.1
3:
executed 5943 times by 1 test: case 3:
Executed by:
  • libssl.so.1.1
5943
1078 s->servername_done = 0;-
1079 return
executed 5943 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 5943 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
5943
1080-
1081 default
executed 172 times by 1 test: default:
Executed by:
  • libssl.so.1.1
:
executed 172 times by 1 test: default:
Executed by:
  • libssl.so.1.1
172
1082 return
executed 172 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 172 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
172
1083 }-
1084}-
1085-
1086-
1087static int final_ec_pt_formats(SSL *s, unsigned int context, int sent)-
1088{-
1089 unsigned long alg_k, alg_a;-
1090-
1091 if (s->server
s->serverDescription
TRUEevaluated 2744 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
2744-2787
1092 return
executed 2744 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2744 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2744
1093-
1094 alg_k = s->s3->tmp.new_cipher->algorithm_mkey;-
1095 alg_a = s->s3->tmp.new_cipher->algorithm_auth;-
1096-
1097-
1098-
1099-
1100-
1101-
1102 if (s->ext.ecpointformats !=
s->ext.ecpoint...!= ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-2787
1103 ((void *)0)
s->ext.ecpoint...!= ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-2787
1104 -
1105 && s->ext.ecpointformats_len > 0
s->ext.ecpointformats_len > 0Description
TRUEnever evaluated
FALSEnever evaluated
0
1106 && s->session->ext.ecpointformats !=
s->session->ex...!= ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
1107 ((void *)0)
s->session->ex...!= ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
1108 -
1109 && s->session->ext.ecpointformats_len > 0
s->session->ex...ormats_len > 0Description
TRUEnever evaluated
FALSEnever evaluated
0
1110 && ((
(alg_k & 0x00000004U)Description
TRUEnever evaluated
FALSEnever evaluated
alg_k & 0x00000004U)
(alg_k & 0x00000004U)Description
TRUEnever evaluated
FALSEnever evaluated
|| (
(alg_a & 0x00000008U)Description
TRUEnever evaluated
FALSEnever evaluated
alg_a & 0x00000008U)
(alg_a & 0x00000008U)Description
TRUEnever evaluated
FALSEnever evaluated
)) {
0
1111-
1112 size_t i;-
1113 unsigned char *list = s->session->ext.ecpointformats;-
1114-
1115 for (i = 0; i < s->session->ext.ecpointformats_len
i < s->session...intformats_lenDescription
TRUEnever evaluated
FALSEnever evaluated
; i++) {
0
1116 if (*
*list++ == 0Description
TRUEnever evaluated
FALSEnever evaluated
list++ == 0
*list++ == 0Description
TRUEnever evaluated
FALSEnever evaluated
)
0
1117 break;
never executed: break;
0
1118 }
never executed: end of block
0
1119 if (i == s->session->ext.ecpointformats_len
i == s->sessio...intformats_lenDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
1120 ossl_statem_fatal((s), (47), (485), (157),-
1121 __FILE__-
1122 ,-
1123 1050-
1124 )-
1125 ;-
1126 return
never executed: return 0;
0;
never executed: return 0;
0
1127 }-
1128 }
never executed: end of block
0
1129-
1130 return
executed 2787 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2787 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2787
1131}-
1132-
1133-
1134static int init_session_ticket(SSL *s, unsigned int context)-
1135{-
1136 if (!s->server
!s->serverDescription
TRUEevaluated 3816 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3592 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
3592-3816
1137 s->ext.ticket_expected = 0;
executed 3816 times by 1 test: s->ext.ticket_expected = 0;
Executed by:
  • libssl.so.1.1
3816
1138-
1139 return
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
7408
1140}-
1141-
1142-
1143static int init_status_request(SSL *s, unsigned int context)-
1144{-
1145 if (s->server
s->serverDescription
TRUEevaluated 3675 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4337 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
3675-4337
1146 s->ext.status_type = -1;-
1147 }
executed 3675 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
3675
1148-
1149-
1150-
1151-
1152 CRYPTO_free(s->ext.ocsp.resp, __FILE__, 1077);-
1153 s->ext.ocsp.resp = -
1154 ((void *)0)-
1155 ;-
1156 s->ext.ocsp.resp_len = 0;-
1157 }
executed 4337 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
4337
1158-
1159 return
executed 8012 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 8012 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
8012
1160}-
1161-
1162-
1163-
1164static int init_npn(SSL *s, unsigned int context)-
1165{-
1166 s->s3->npn_seen = 0;-
1167-
1168 return
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
7408
1169}-
1170-
1171-
1172static int init_alpn(SSL *s, unsigned int context)-
1173{-
1174 CRYPTO_free(s->s3->alpn_selected, __FILE__, 1097);-
1175 s->s3->alpn_selected = -
1176 ((void *)0)-
1177 ;-
1178 s->s3->alpn_selected_len = 0;-
1179 if (s->server
s->serverDescription
TRUEevaluated 3657 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4401 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
3657-4401
1180 CRYPTO_free(s->s3->alpn_proposed, __FILE__, 1101);-
1181 s->s3->alpn_proposed = -
1182 ((void *)0)-
1183 ;-
1184 s->s3->alpn_proposed_len = 0;-
1185 }
executed 3657 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
3657
1186 return
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
8058
1187}-
1188-
1189static int final_alpn(SSL *s, unsigned int context, int sent)-
1190{-
1191 if (!s->server
!s->serverDescription
TRUEevaluated 3371 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2744 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& !sent
!sentDescription
TRUEevaluated 3350 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& s->session->ext.alpn_selected !=
s->session->ex...!= ((void *)0)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3346 times by 1 test
Evaluated by:
  • libssl.so.1.1
4-3371
1192 ((void *)0)
s->session->ex...!= ((void *)0)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3346 times by 1 test
Evaluated by:
  • libssl.so.1.1
4-3346
1193 )-
1194 s->ext.early_data_ok = 0;
executed 4 times by 1 test: s->ext.early_data_ok = 0;
Executed by:
  • libssl.so.1.1
4
1195-
1196 if (!s->server
!s->serverDescription
TRUEevaluated 3371 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2744 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| !(!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEevaluated 2558 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 186 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->version >= 0x0304Description
TRUEevaluated 1025 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1533 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEevaluated 1025 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1533 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1025 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1025 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
))
0-3371
1197 return
executed 5090 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 5090 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
5090
1198 return
executed 1025 times by 1 test: return tls_handle_alpn(s);
Executed by:
  • libssl.so.1.1
tls_handle_alpn(s);
executed 1025 times by 1 test: return tls_handle_alpn(s);
Executed by:
  • libssl.so.1.1
1025
1199}-
1200-
1201static int init_sig_algs(SSL *s, unsigned int context)-
1202{-
1203-
1204 CRYPTO_free(s->s3->tmp.peer_sigalgs, __FILE__, 1131);-
1205 s->s3->tmp.peer_sigalgs = -
1206 ((void *)0)-
1207 ;-
1208-
1209 return
executed 3700 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3700 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3700
1210}-
1211-
1212static int init_sig_algs_cert(SSL *s, unsigned int context)-
1213{-
1214-
1215 CRYPTO_free(s->s3->tmp.peer_cert_sigalgs, __FILE__, 1140);-
1216 s->s3->tmp.peer_cert_sigalgs = -
1217 ((void *)0)-
1218 ;-
1219-
1220 return
executed 3700 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3700 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3700
1221}-
1222-
1223-
1224static int init_srp(SSL *s, unsigned int context)-
1225{-
1226 CRYPTO_free(s->srp_ctx.login, __FILE__, 1149);-
1227 s->srp_ctx.login = -
1228 ((void *)0)-
1229 ;-
1230-
1231 return
executed 3592 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3592 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3592
1232}-
1233-
1234-
1235static int init_etm(SSL *s, unsigned int context)-
1236{-
1237 s->ext.use_etm = 0;-
1238-
1239 return
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
7408
1240}-
1241-
1242static int init_ems(SSL *s, unsigned int context)-
1243{-
1244 if (!s->server
!s->serverDescription
TRUEevaluated 3816 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3592 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
3592-3816
1245 s->s3->flags &= ~0x0200;
executed 3816 times by 1 test: s->s3->flags &= ~0x0200;
Executed by:
  • libssl.so.1.1
3816
1246-
1247 return
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 7408 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
7408
1248}-
1249-
1250static int final_ems(SSL *s, unsigned int context, int sent)-
1251{-
1252 if (!s->server
!s->serverDescription
TRUEevaluated 2787 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2742 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& s->hit
s->hitDescription
TRUEevaluated 65 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2722 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
65-2787
1253-
1254-
1255-
1256-
1257 if (!(s->s3->flags & 0x0200) !=
!(s->s3->flags...->flags & 0x1)Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 63 times by 1 test
Evaluated by:
  • libssl.so.1.1
2-63
1258 !(s->session->flags & 0x1)
!(s->s3->flags...->flags & 0x1)Description
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 63 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
2-63
1259 ossl_statem_fatal((s), (40), (486), (104),-
1260 __FILE__-
1261 ,-
1262 1181-
1263 )-
1264 ;-
1265 return
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
2
1266 }-
1267 }
executed 63 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
63
1268-
1269 return
executed 5527 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 5527 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
5527
1270}-
1271-
1272static int init_certificate_authorities(SSL *s, unsigned int context)-
1273{-
1274 sk_X509_NAME_pop_free(s->s3->tmp.peer_ca_names, X509_NAME_free);-
1275 s->s3->tmp.peer_ca_names = -
1276 ((void *)0)-
1277 ;-
1278 return
executed 108 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 108 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
108
1279}-
1280-
1281static EXT_RETURN tls_construct_certificate_authorities(SSL *s, WPACKET *pkt,-
1282 unsigned int context,-
1283 X509 *x,-
1284 size_t chainidx)-
1285{-
1286 const struct stack_st_X509_NAME *ca_sk = SSL_get0_CA_list(s);-
1287-
1288 if (ca_sk ==
ca_sk == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 3960 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-3960
1289 ((void *)0)
ca_sk == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 3960 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-3960
1290 || sk_X509_NAME_num(ca_sk) == 0
sk_X509_NAME_num(ca_sk) == 0Description
TRUEevaluated 3955 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
5-3955
1291 return
executed 3955 times by 1 test: return EXT_RETURN_NOT_SENT;
Executed by:
  • libssl.so.1.1
EXT_RETURN_NOT_SENT;
executed 3955 times by 1 test: return EXT_RETURN_NOT_SENT;
Executed by:
  • libssl.so.1.1
3955
1292-
1293 if (!WPACKET_put_bytes__((pkt), (47), 2)
!WPACKET_put_b...pkt), (47), 2)Description
TRUEnever evaluated
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-5
1294 || !WPACKET_start_sub_packet_len__((pkt), 2)
!WPACKET_start...en__((pkt), 2)Description
TRUEnever evaluated
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-5
1295 ossl_statem_fatal((s), (80), (542), ((4|64)),-
1296-
1297 __FILE__-
1298 ,-
1299-
1300 1210-
1301 )-
1302-
1303 ;-
1304 return
never executed: return EXT_RETURN_FAIL;
EXT_RETURN_FAIL;
never executed: return EXT_RETURN_FAIL;
0
1305 }-
1306-
1307 if (!construct_ca_names(s, pkt)
!construct_ca_names(s, pkt)Description
TRUEnever evaluated
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-5
1308-
1309 return
never executed: return EXT_RETURN_FAIL;
EXT_RETURN_FAIL;
never executed: return EXT_RETURN_FAIL;
0
1310 }-
1311-
1312 if (!WPACKET_close(pkt)
!WPACKET_close(pkt)Description
TRUEnever evaluated
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-5
1313 ossl_statem_fatal((s), (80), (542), ((4|64)),-
1314-
1315 __FILE__-
1316 ,-
1317-
1318 1222-
1319 )-
1320-
1321 ;-
1322 return
never executed: return EXT_RETURN_FAIL;
EXT_RETURN_FAIL;
never executed: return EXT_RETURN_FAIL;
0
1323 }-
1324-
1325 return
executed 5 times by 1 test: return EXT_RETURN_SENT;
Executed by:
  • libssl.so.1.1
EXT_RETURN_SENT;
executed 5 times by 1 test: return EXT_RETURN_SENT;
Executed by:
  • libssl.so.1.1
5
1326}-
1327-
1328static int tls_parse_certificate_authorities(SSL *s, PACKET *pkt,-
1329 unsigned int context, X509 *x,-
1330 size_t chainidx)-
1331{-
1332 if (!parse_ca_names(s, pkt)
!parse_ca_names(s, pkt)Description
TRUEevaluated 14 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 8 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
8-14
1333 return
executed 14 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 14 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
14
1334 if (PACKET_remaining(pkt) != 0
PACKET_remaining(pkt) != 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 7 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
1-7
1335 ossl_statem_fatal((s), (50), (566), (110),-
1336 __FILE__-
1337 ,-
1338 1237-
1339 )-
1340 ;-
1341 return
executed 1 time by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 1 time by 1 test: return 0;
Executed by:
  • libssl.so.1.1
1
1342 }-
1343 return
executed 7 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 7 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
7
1344}-
1345-
1346-
1347static int init_srtp(SSL *s, unsigned int context)-
1348{-
1349 if (s->server
s->serverDescription
TRUEevaluated 3657 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4401 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
3657-4401
1350 s->srtp_profile =
executed 3657 times by 1 test: s->srtp_profile = ((void *)0) ;
Executed by:
  • libssl.so.1.1
3657
1351 ((void *)0)
executed 3657 times by 1 test: s->srtp_profile = ((void *)0) ;
Executed by:
  • libssl.so.1.1
3657
1352 ;
executed 3657 times by 1 test: s->srtp_profile = ((void *)0) ;
Executed by:
  • libssl.so.1.1
3657
1353-
1354 return
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 8058 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
8058
1355}-
1356-
1357-
1358static int final_sig_algs(SSL *s, unsigned int context, int sent)-
1359{-
1360 if (!sent
!sentDescription
TRUEevaluated 560 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2225 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEevaluated 534 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 26 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->version >= 0x0304Description
TRUEevaluated 10 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 524 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEevaluated 10 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 524 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->v...ion != 0x10000Description
TRUEevaluated 10 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEevaluated 10 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
) && !s->hit
!s->hitDescription
TRUEevaluated 9 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-2225
1361 ossl_statem_fatal((s), (109), (497), (112),-
1362 __FILE__-
1363 ,-
1364 1257-
1365 )-
1366 ;-
1367 return
executed 9 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 9 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
9
1368 }-
1369-
1370 return
executed 2776 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2776 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2776
1371}-
1372-
1373-
1374static int final_key_share(SSL *s, unsigned int context, int sent)-
1375{-
1376 if (!(!(s->method->ssl3_enc->enc_flags & 0x8)
!(s->method->s...c_flags & 0x8)Description
TRUEevaluated 3846 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 186 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->version >= 0x0304Description
TRUEevaluated 2313 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1533 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version >= 0x0304
(s)->method->version >= 0x0304Description
TRUEevaluated 2313 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1533 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1633 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 680 times by 1 test
Evaluated by:
  • libssl.so.1.1
s)->method->version != 0x10000
(s)->method->v...ion != 0x10000Description
TRUEevaluated 1633 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 680 times by 1 test
Evaluated by:
  • libssl.so.1.1
))
186-3846
1377 return
executed 2399 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 2399 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
2399
1378-
1379-
1380 if ((
(context & 0x0800) != 0Description
TRUEnever evaluated
FALSEevaluated 1633 times by 1 test
Evaluated by:
  • libssl.so.1.1
context & 0x0800) != 0
(context & 0x0800) != 0Description
TRUEnever evaluated
FALSEevaluated 1633 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
0-1633
1381 return
never executed: return 1;
1;
never executed: return 1;
0
1382 if (!s->server
!s->serverDescription
TRUEevaluated 619 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1014 times by 1 test
Evaluated by:
  • libssl.so.1.1
619-1014
1383 && !sent
!sentDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 615 times by 1 test
Evaluated by:
  • libssl.so.1.1
4-615
1384 && (!s->hit
!s->hitDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
2
1385 || (
(s->ext.psk_kex_mode & 1) == 0Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->ext.psk_kex_mode & 1) == 0
(s->ext.psk_kex_mode & 1) == 0Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
)) {
0-2
1386-
1387 ossl_statem_fatal((s), (109), (503), (101),-
1388 __FILE__-
1389 ,-
1390 1291-
1391 )-
1392 ;-
1393 return
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 2 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
2
1394 }-
1395 if (s->server
s->serverDescription
TRUEevaluated 1014 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 617 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
617-1014
1396 if (s->s3->peer_tmp !=
s->s3->peer_tmp != ((void *)0)Description
TRUEevaluated 876 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 138 times by 1 test
Evaluated by:
  • libssl.so.1.1
138-876
1397 ((void *)0)
s->s3->peer_tmp != ((void *)0)Description
TRUEevaluated 876 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 138 times by 1 test
Evaluated by:
  • libssl.so.1.1
138-876
1398 ) {-
1399-
1400 if ((
(s->s3->flags & 0x0800) != 0Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 872 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->s3->flags & 0x0800) != 0
(s->s3->flags & 0x0800) != 0Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 872 times by 1 test
Evaluated by:
  • libssl.so.1.1
4-872
1401 && !s->ext.cookieok
!s->ext.cookieokDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
) {
1-3
1402 if (!((s->hello_retry_request == SSL_HRR_NONE) != 0)
!((s->hello_re...RR_NONE) != 0)Description
TRUEnever evaluated
FALSEevaluated 3 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-3
1403-
1404-
1405-
1406-
1407-
1408 ossl_statem_fatal((s), (80), (503), ((4|64)),-
1409 __FILE__-
1410 ,-
1411 1340-
1412 )-
1413 ;-
1414 return
never executed: return 0;
0;
never executed: return 0;
0
1415 }-
1416 s->hello_retry_request = SSL_HRR_PENDING;-
1417 return
executed 3 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3
1418 }-
1419 }
executed 873 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
873
1420-
1421 if (s->hello_retry_request == SSL_HRR_NONE
s->hello_retry...= SSL_HRR_NONEDescription
TRUEevaluated 133 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& sent
sentDescription
TRUEevaluated 128 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 5 times by 1 test
Evaluated by:
  • libssl.so.1.1
5-133
1422 && (!s->hit
!s->hitDescription
TRUEevaluated 107 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 21 times by 1 test
Evaluated by:
  • libssl.so.1.1
21-107
1423 || (
(s->ext.psk_kex_mode & 2) != 0Description
TRUEevaluated 20 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
s->ext.psk_kex_mode & 2)
(s->ext.psk_kex_mode & 2) != 0Description
TRUEevaluated 20 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
1-20
1424 != 0
(s->ext.psk_kex_mode & 2) != 0Description
TRUEevaluated 20 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
)) {
1-20
1425 const uint16_t *pgroups, *clntgroups;-
1426 size_t num_groups, clnt_num_groups, i;-
1427 unsigned int group_id = 0;-
1428-
1429-
1430-
1431-
1432 tls1_get_peer_groups(s, &clntgroups, &clnt_num_groups);-
1433 tls1_get_supported_groups(s, &pgroups, &num_groups);-
1434-
1435-
1436-
1437-
1438 for (i = 0; i < num_groups
i < num_groupsDescription
TRUEevaluated 222 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
; i++) {
4-222
1439 group_id = pgroups[i];-
1440-
1441 if (check_in_list(s, group_id, clntgroups, clnt_num_groups,
check_in_list(...num_groups, 1)Description
TRUEevaluated 123 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 99 times by 1 test
Evaluated by:
  • libssl.so.1.1
99-123
1442 1)
check_in_list(...num_groups, 1)Description
TRUEevaluated 123 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 99 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
99-123
1443 break;
executed 123 times by 1 test: break;
Executed by:
  • libssl.so.1.1
123
1444 }
executed 99 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
99
1445-
1446 if (i < num_groups
i < num_groupsDescription
TRUEevaluated 123 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
4-123
1447-
1448 s->s3->group_id = group_id;-
1449 s->hello_retry_request = SSL_HRR_PENDING;-
1450 return
executed 123 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 123 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
123
1451 }-
1452 }
executed 4 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
4
1453 if (!s->hit
!s->hitDescription
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3 times by 1 test
Evaluated by:
  • libssl.so.1.1
3-12
1454 || (
(s->ext.psk_kex_mode & 1) == 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->ext.psk_kex_mode & 1) == 0
(s->ext.psk_kex_mode & 1) == 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
1-2
1455-
1456 ossl_statem_fatal((s), (sent ? 40 : 109), (503), (101),-
1457-
1458 __FILE__-
1459 ,-
1460-
1461 1385-
1462 )-
1463-
1464 ;-
1465 return
executed 13 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
0;
executed 13 times by 1 test: return 0;
Executed by:
  • libssl.so.1.1
13
1466 }-
1467-
1468 if ((
(s->s3->flags & 0x0800) != 0Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->s3->flags & 0x0800) != 0
(s->s3->flags & 0x0800) != 0Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-2
1469 && !s->ext.cookieok
!s->ext.cookieokDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
1470 if (!((s->hello_retry_request == SSL_HRR_NONE) != 0)
!((s->hello_re...RR_NONE) != 0)Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
1471-
1472-
1473-
1474-
1475-
1476 ossl_statem_fatal((s), (80), (503), ((4|64)),-
1477 __FILE__-
1478 ,-
1479 1398-
1480 )-
1481 ;-
1482 return
never executed: return 0;
0;
never executed: return 0;
0
1483 }-
1484 s->hello_retry_request = SSL_HRR_PENDING;-
1485 return
never executed: return 1;
1;
never executed: return 1;
0
1486 }-
1487 }
executed 2 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
2
1488-
1489-
1490-
1491-
1492-
1493 if (s->hello_retry_request == SSL_HRR_PENDING
s->hello_retry...SL_HRR_PENDINGDescription
TRUEevaluated 38 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 837 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
38-837
1494 s->hello_retry_request = SSL_HRR_COMPLETE;
executed 38 times by 1 test: s->hello_retry_request = SSL_HRR_COMPLETE;
Executed by:
  • libssl.so.1.1
38
1495 }
executed 875 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
875
1496-
1497-
1498-
1499-
1500-
1501 if (!sent
!sentDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 615 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& !tls13_generate_handshake_secret(s,
!tls13_generat...void *)0) , 0)Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-615
1502 ((void *)0)
!tls13_generat...void *)0) , 0)Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-2
1503 , 0)
!tls13_generat...void *)0) , 0)Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-2
1504 ossl_statem_fatal((s), (80), (503), ((4|64)),-
1505 __FILE__-
1506 ,-
1507 1420-
1508 )-
1509 ;-
1510 return
never executed: return 0;
0;
never executed: return 0;
0
1511 }-
1512 }
executed 617 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
617
1513-
1514 return
executed 1492 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 1492 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1492
1515}-
1516-
1517-
1518static int init_psk_kex_modes(SSL *s, unsigned int context)-
1519{-
1520 s->ext.psk_kex_mode = 0;-
1521 return
executed 65 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 65 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
65
1522}-
1523-
1524int tls_psk_do_binder(SSL *s, const EVP_MD *md, const unsigned char *msgstart,-
1525 size_t binderoffset, const unsigned char *binderin,-
1526 unsigned char *binderout, SSL_SESSION *sess, int sign,-
1527 int external)-
1528{-
1529 EVP_PKEY *mackey = -
1530 ((void *)0)-
1531 ;-
1532 EVP_MD_CTX *mctx = -
1533 ((void *)0)-
1534 ;-
1535 unsigned char hash[64], binderkey[64];-
1536 unsigned char finishedkey[64], tmpbinder[64];-
1537 unsigned char *early_secret;-
1538 static const unsigned char resumption_label[] = "res binder";-
1539 static const unsigned char external_label[] = "ext binder";-
1540 const unsigned char *label;-
1541 size_t bindersize, labelsize, hashsize;-
1542 int hashsizei = EVP_MD_size(md);-
1543 int ret = -1;-
1544 int usepskfored = 0;-
1545-
1546-
1547 if (!((hashsizei >= 0) != 0)
!((hashsizei >= 0) != 0)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1548 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1549 __FILE__-
1550 ,-
1551 1456-
1552 )-
1553 ;-
1554 goto
never executed: goto err;
err;
never executed: goto err;
0
1555 }-
1556 hashsize = (size_t)hashsizei;-
1557-
1558 if (external
externalDescription
TRUEevaluated 58 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 250 times by 1 test
Evaluated by:
  • libssl.so.1.1
58-250
1559 && s->early_data_state == SSL_EARLY_DATA_CONNECTING
s->early_data_...ATA_CONNECTINGDescription
TRUEevaluated 13 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 45 times by 1 test
Evaluated by:
  • libssl.so.1.1
13-45
1560 && s->session->ext.max_early_data == 0
s->session->ex...arly_data == 0Description
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
1-12
1561 && sess->ext.max_early_data > 0
sess->ext.max_early_data > 0Description
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
)
0-12
1562 usepskfored = 1;
executed 12 times by 1 test: usepskfored = 1;
Executed by:
  • libssl.so.1.1
12
1563-
1564 if (external
externalDescription
TRUEevaluated 58 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 250 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
58-250
1565 label = external_label;-
1566 labelsize = sizeof(external_label) - 1;-
1567 }
executed 58 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
58
1568 label = resumption_label;-
1569 labelsize = sizeof(resumption_label) - 1;-
1570 }
executed 250 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
250
1571 if (s->server
s->serverDescription
TRUEevaluated 134 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 174 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| !external
!externalDescription
TRUEevaluated 142 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 32 times by 1 test
Evaluated by:
  • libssl.so.1.1
|| usepskfored
usepskforedDescription
TRUEevaluated 12 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 20 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
12-174
1572 early_secret = (unsigned char *)s->early_secret;
executed 288 times by 1 test: early_secret = (unsigned char *)s->early_secret;
Executed by:
  • libssl.so.1.1
288
1573 else-
1574 early_secret = (unsigned char *)sess->early_secret;
executed 20 times by 1 test: early_secret = (unsigned char *)sess->early_secret;
Executed by:
  • libssl.so.1.1
20
1575-
1576 if (!tls13_generate_secret(s, md,
!tls13_generat... early_secret)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1577 ((void *)0)
!tls13_generat... early_secret)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1578 , sess->master_key,
!tls13_generat... early_secret)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1579 sess->master_key_length, early_secret)
!tls13_generat... early_secret)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1580-
1581 goto
never executed: goto err;
err;
never executed: goto err;
0
1582 }-
1583-
1584-
1585-
1586-
1587-
1588 mctx = EVP_MD_CTX_new();-
1589 if (mctx ==
mctx == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1590 ((void *)0)
mctx == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1591 -
1592 || EVP_DigestInit_ex(mctx, md,
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1593 ((void *)0)
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1594 ) <= 0
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1595 || EVP_DigestFinal_ex(mctx, hash,
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1596 ((void *)0)
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1597 ) <= 0
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1598 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1599 __FILE__-
1600 ,-
1601 1503-
1602 )-
1603 ;-
1604 goto
never executed: goto err;
err;
never executed: goto err;
0
1605 }-
1606-
1607-
1608 if (!tls13_hkdf_expand(s, md, early_secret, label, labelsize, hash,
!tls13_hkdf_ex...key, hashsize)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1609 hashsize, binderkey, hashsize)
!tls13_hkdf_ex...key, hashsize)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1610-
1611 goto
never executed: goto err;
err;
never executed: goto err;
0
1612 }-
1613-
1614-
1615 if (!tls13_derive_finishedkey(s, md, binderkey, finishedkey, hashsize)
!tls13_derive_...key, hashsize)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1616-
1617 goto
never executed: goto err;
err;
never executed: goto err;
0
1618 }-
1619-
1620 if (EVP_DigestInit_ex(mctx, md,
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1621 ((void *)0)
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1622 ) <= 0
EVP_DigestInit...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1623 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1624 __FILE__-
1625 ,-
1626 1522-
1627 )-
1628 ;-
1629 goto
never executed: goto err;
err;
never executed: goto err;
0
1630 }-
1631-
1632-
1633-
1634-
1635-
1636-
1637 if (s->hello_retry_request == SSL_HRR_PENDING
s->hello_retry...SL_HRR_PENDINGDescription
TRUEevaluated 29 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 279 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
29-279
1638 size_t hdatalen;-
1639 void *hdata;-
1640-
1641 hdatalen = BIO_ctrl(s->s3->handshake_buffer,3,0,(char *)(&hdata));-
1642 if (hdatalen <= 0
hdatalen <= 0Description
TRUEnever evaluated
FALSEevaluated 29 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-29
1643 ossl_statem_fatal((s), (80), (506), (332),-
1644 __FILE__-
1645 ,-
1646 1538-
1647 )-
1648 ;-
1649 goto
never executed: goto err;
err;
never executed: goto err;
0
1650 }-
1651-
1652-
1653-
1654-
1655-
1656 if (s->server
s->serverDescription
TRUEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
11-18
1657 PACKET hashprefix, msg;-
1658-
1659-
1660 if (!PACKET_buf_init(&hashprefix, hdata, hdatalen)
!PACKET_buf_in...ata, hdatalen)Description
TRUEnever evaluated
FALSEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-11
1661 || !PACKET_forward(&hashprefix, 1)
!PACKET_forwar...hashprefix, 1)Description
TRUEnever evaluated
FALSEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-11
1662 || !PACKET_get_length_prefixed_3(&hashprefix, &msg)
!PACKET_get_le...hprefix, &msg)Description
TRUEnever evaluated
FALSEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-11
1663 || !PACKET_forward(&hashprefix, 1)
!PACKET_forwar...hashprefix, 1)Description
TRUEnever evaluated
FALSEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-11
1664 || !PACKET_get_length_prefixed_3(&hashprefix, &msg)
!PACKET_get_le...hprefix, &msg)Description
TRUEnever evaluated
FALSEevaluated 11 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-11
1665 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1666 __FILE__-
1667 ,-
1668 1556-
1669 )-
1670 ;-
1671 goto
never executed: goto err;
err;
never executed: goto err;
0
1672 }-
1673 hdatalen -= PACKET_remaining(&hashprefix);-
1674 }
executed 11 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
11
1675-
1676 if (EVP_DigestUpdate(mctx, hdata, hdatalen) <= 0
EVP_DigestUpda...hdatalen) <= 0Description
TRUEnever evaluated
FALSEevaluated 29 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-29
1677 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1678 __FILE__-
1679 ,-
1680 1564-
1681 )-
1682 ;-
1683 goto
never executed: goto err;
err;
never executed: goto err;
0
1684 }-
1685 }
executed 29 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
29
1686-
1687 if (EVP_DigestUpdate(mctx, msgstart, binderoffset) <= 0
EVP_DigestUpda...eroffset) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1688 || EVP_DigestFinal_ex(mctx, hash,
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1689 ((void *)0)
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1690 ) <= 0
EVP_DigestFina...id *)0) ) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1691 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1692 __FILE__-
1693 ,-
1694 1572-
1695 )-
1696 ;-
1697 goto
never executed: goto err;
err;
never executed: goto err;
0
1698 }-
1699-
1700 mackey = EVP_PKEY_new_raw_private_key(855, -
1701 ((void *)0)-
1702 , finishedkey,-
1703 hashsize);-
1704 if (mackey ==
mackey == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1705 ((void *)0)
mackey == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1706 ) {-
1707 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1708 __FILE__-
1709 ,-
1710 1580-
1711 )-
1712 ;-
1713 goto
never executed: goto err;
err;
never executed: goto err;
0
1714 }-
1715-
1716 if (!sign
!signDescription
TRUEevaluated 134 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 174 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
134-174
1717 binderout = tmpbinder;
executed 134 times by 1 test: binderout = tmpbinder;
Executed by:
  • libssl.so.1.1
134
1718-
1719 bindersize = hashsize;-
1720 if (EVP_DigestSignInit(mctx,
EVP_DigestSign..., mackey) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1721 ((void *)0)
EVP_DigestSign..., mackey) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1722 , md,
EVP_DigestSign..., mackey) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1723 ((void *)0)
EVP_DigestSign..., mackey) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1724 , mackey) <= 0
EVP_DigestSign..., mackey) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1725 || EVP_DigestUpdate(mctx,hash,hashsize) <= 0
EVP_DigestUpda...hashsize) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1726 || EVP_DigestSignFinal(mctx, binderout, &bindersize) <= 0
EVP_DigestSign...ndersize) <= 0Description
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-308
1727 || bindersize != hashsize
bindersize != hashsizeDescription
TRUEnever evaluated
FALSEevaluated 308 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-308
1728 ossl_statem_fatal((s), (80), (506), ((4|64)),-
1729 __FILE__-
1730 ,-
1731 1593-
1732 )-
1733 ;-
1734 goto
never executed: goto err;
err;
never executed: goto err;
0
1735 }-
1736-
1737 if (sign
signDescription
TRUEevaluated 174 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 134 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
134-174
1738 ret = 1;-
1739 }
executed 174 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
174
1740-
1741 ret = (CRYPTO_memcmp(binderin, binderout, hashsize) == 0);-
1742 if (!ret
!retDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 133 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
1-133
1743 ossl_statem_fatal((s), (47), (506), (253),
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1744 __FILE__
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1745 ,
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1746 1604
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1747 )
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1748 ;
executed 1 time by 1 test: ossl_statem_fatal((s), (47), (506), (253), __FILE__ , 1604 ) ;
Executed by:
  • libssl.so.1.1
1
1749 }
executed 134 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
134
1750-
1751 err:
code before this statement executed 308 times by 1 test: err:
Executed by:
  • libssl.so.1.1
308
1752 OPENSSL_cleanse(binderkey, sizeof(binderkey));-
1753 OPENSSL_cleanse(finishedkey, sizeof(finishedkey));-
1754 EVP_PKEY_free(mackey);-
1755 EVP_MD_CTX_free(mctx);-
1756-
1757 return
executed 308 times by 1 test: return ret;
Executed by:
  • libssl.so.1.1
ret;
executed 308 times by 1 test: return ret;
Executed by:
  • libssl.so.1.1
308
1758}-
1759-
1760static int final_early_data(SSL *s, unsigned int context, int sent)-
1761{-
1762 if (!sent
!sentDescription
TRUEevaluated 3848 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 403 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
403-3848
1763 return
executed 3848 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 3848 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
3848
1764-
1765 if (!s->server
!s->serverDescription
TRUEevaluated 150 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 253 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
150-253
1766 if (context == 0x0400
context == 0x0400Description
TRUEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 132 times by 1 test
Evaluated by:
  • libssl.so.1.1
18-132
1767 && sent
sentDescription
TRUEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
0-18
1768 && !s->ext.early_data_ok
!s->ext.early_data_okDescription
TRUEnever evaluated
FALSEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-18
1769-
1770-
1771-
1772-
1773-
1774 ossl_statem_fatal((s), (47), (556), (233),-
1775 __FILE__-
1776 ,-
1777 1631-
1778 )-
1779 ;-
1780 return
never executed: return 0;
0;
never executed: return 0;
0
1781 }-
1782-
1783 return
executed 150 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 150 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
150
1784 }-
1785-
1786 if (s->max_early_data == 0
s->max_early_data == 0Description
TRUEevaluated 203 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 50 times by 1 test
Evaluated by:
  • libssl.so.1.1
50-203
1787 || !s->hit
!s->hitDescription
TRUEevaluated 6 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
6-44
1788 || s->session->ext.tick_identity != 0
s->session->ex..._identity != 0Description
TRUEnever evaluated
FALSEevaluated 44 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-44
1789 || s->early_data_state != SSL_EARLY_DATA_ACCEPTING
s->early_data_...DATA_ACCEPTINGDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 41 times by 1 test
Evaluated by:
  • libssl.so.1.1
3-41
1790 || !s->ext.early_data_ok
!s->ext.early_data_okDescription
TRUEevaluated 6 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 35 times by 1 test
Evaluated by:
  • libssl.so.1.1
6-35
1791 || s->hello_retry_request != SSL_HRR_NONE
s->hello_retry...= SSL_HRR_NONEDescription
TRUEevaluated 9 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 26 times by 1 test
Evaluated by:
  • libssl.so.1.1
9-26
1792 || (s->ctx->allow_early_data_cb !=
s->ctx->allow_...!= ((void *)0)Description
TRUEevaluated 8 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
8-18
1793 ((void *)0)
s->ctx->allow_...!= ((void *)0)Description
TRUEevaluated 8 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 18 times by 1 test
Evaluated by:
  • libssl.so.1.1
8-18
1794 -
1795 && !s->ctx->allow_early_data_cb(s,
!s->ctx->allow..._data_cb_data)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
4
1796 s->ctx->allow_early_data_cb_data)
!s->ctx->allow..._data_cb_data)Description
TRUEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 4 times by 1 test
Evaluated by:
  • libssl.so.1.1
)) {
4
1797 s->ext.early_data = 1;-
1798 }
executed 231 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
else {
231
1799 s->ext.early_data = 2;-
1800-
1801 if (!tls13_change_cipher_state(s,
!tls13_change_...(0x020|0x001))Description
TRUEnever evaluated
FALSEevaluated 22 times by 1 test
Evaluated by:
  • libssl.so.1.1
0-22
1802 0x040 | (0x020|0x001))
!tls13_change_...(0x020|0x001))Description
TRUEnever evaluated
FALSEevaluated 22 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-22
1803-
1804 return
never executed: return 0;
0;
never executed: return 0;
0
1805 }-
1806 }
executed 22 times by 1 test: end of block
Executed by:
  • libssl.so.1.1
22
1807-
1808 return
executed 253 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 253 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
253
1809}-
1810-
1811static int final_maxfragmentlen(SSL *s, unsigned int context, int sent)-
1812{-
1813-
1814-
1815-
1816-
1817 if (s->server
s->serverDescription
TRUEevaluated 2744 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 3371 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& s->hit
s->hitDescription
TRUEevaluated 216 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 2528 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& (((
((s->session->...en_mode) >= 1)Description
TRUEnever evaluated
FALSEevaluated 216 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->session->ext.max_fragment_len_mode) >= 1)
((s->session->...en_mode) >= 1)Description
TRUEnever evaluated
FALSEevaluated 216 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& ((
((s->session->...en_mode) <= 4)Description
TRUEnever evaluated
FALSEnever evaluated
s->session->ext.max_fragment_len_mode) <= 4)
((s->session->...en_mode) <= 4)Description
TRUEnever evaluated
FALSEnever evaluated
)
0-3371
1818 && !sent
!sentDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
1819 ossl_statem_fatal((s), (109), (557), (110),-
1820 __FILE__-
1821 ,-
1822 1670-
1823 )-
1824 ;-
1825 return
never executed: return 0;
0;
never executed: return 0;
0
1826 }-
1827-
1828-
1829 if (s->session
s->sessionDescription
TRUEevaluated 6115 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
&& (((
((s->session->...en_mode) >= 1)Description
TRUEevaluated 33 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6082 times by 1 test
Evaluated by:
  • libssl.so.1.1
s->session->ext.max_fragment_len_mode) >= 1)
((s->session->...en_mode) >= 1)Description
TRUEevaluated 33 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 6082 times by 1 test
Evaluated by:
  • libssl.so.1.1
&& ((
((s->session->...en_mode) <= 4)Description
TRUEevaluated 33 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
s->session->ext.max_fragment_len_mode) <= 4)
((s->session->...en_mode) <= 4)Description
TRUEevaluated 33 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEnever evaluated
)
0-6115
1830 && s->max_send_fragment < (512U << (s->session->ext.max_fragment_len_mode - 1))
s->max_send_fr...len_mode - 1))Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • libssl.so.1.1
FALSEevaluated 27 times by 1 test
Evaluated by:
  • libssl.so.1.1
)
6-27
1831-
1832 if (!ssl3_setup_buffers(s)
!ssl3_setup_buffers(s)Description
TRUEnever evaluated
FALSEevaluated 6 times by 1 test
Evaluated by:
  • libssl.so.1.1
) {
0-6
1833-
1834 return
never executed: return 0;
0;
never executed: return 0;
0
1835 }-
1836-
1837 return
executed 6115 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 6115 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
6115
1838}-
1839-
1840static int init_post_handshake_auth(SSL *s, unsigned int context)-
1841{-
1842 s->post_handshake_auth = SSL_PHA_NONE;-
1843-
1844 return
executed 65 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
1;
executed 65 times by 1 test: return 1;
Executed by:
  • libssl.so.1.1
65
1845}-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.2