mirror of
https://github.com/curl/curl.git
synced 2026-08-25 07:53:32 +03:00
gnutls: use session cache for QUIC
Add session reuse for QUIC transfers using GnuTLS. This does not include support for TLS early data, yet. Fix check of early data support in common GnuTLS init code to not access the filter context, as the struct varies between TCP and QUIC connections. Closes #15265
This commit is contained in:
parent
954177b9da
commit
fe8399f066
5 changed files with 99 additions and 40 deletions
|
|
@ -625,10 +625,16 @@ class TestDownload:
|
|||
self.check_downloads(client, srcfile, count)
|
||||
# check that TLS earlydata worked as expected
|
||||
earlydata = {}
|
||||
reused_session = False
|
||||
for line in r.trace_lines:
|
||||
m = re.match(r'^\[t-(\d+)] EarlyData: (\d+)', line)
|
||||
if m:
|
||||
earlydata[int(m.group(1))] = int(m.group(2))
|
||||
continue
|
||||
m = re.match(r'\[1-1] \* SSL reusing session.*', line)
|
||||
if m:
|
||||
reused_session = True
|
||||
assert reused_session, 'session was not reused for 2nd transfer'
|
||||
assert earlydata[0] == 0, f'{earlydata}'
|
||||
if proto == 'http/1.1':
|
||||
assert earlydata[1] == 69, f'{earlydata}'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue