Repository navigation
feat(application): under PCAPKIT_MIMIC=wireshark, TLS extensions are gated by handshake message as Wireshark gates them (#3228) - #3252
Conversation
Documentation build overview
7 files changed ·
|
|
Needs changes at
|
|
Decision needed: should each TLS extension schema's new class-level
I recommend (A), and I'm proceeding with it. The table encodes RFC and engine gating, which #3234 routes through |
fc435f6 to
00d883c
Compare
|
Good to go at
The |
|
Correction to my earlier review of #3252. I asked for |
…gated by handshake message as Wireshark gates them (#3228) With PCAPKIT_MIMIC=wireshark, each TLS and DTLS extension decodes, and builds from keyword arguments, as its case in Wireshark's ssl_dissect_hnd_extension (epan/dissectors/packet-tls-utils.c) reads it, in the messages that function reads extensions in. Unset, #2853's RFC gating stays. - supported_groups, ec_point_formats, signature_algorithms, ALPN, padding, record_size_limit, session_ticket, cookie, psk_key_exchange_modes and renegotiation_info decode in each of those messages. - The other types decode their structure where their case reads one, and are empty where it reads nothing, as ssl_end_vector flags any octet left; connection_id keeps its hellos-only reading. - Each extension schema holds its structures by message, for the RFC and for Wireshark, in a class-level __structure__ that its data selector and its constructor both read. - The engines page's Mimic Mode table gains the site.
00d883c to
235142b
Compare
|
Good to go at |
|
Take recommendations. And I think extension on schema's registry is actually done by subclassing the base schema class. Right? |
|
Recorded: (A). Yes, extension goes through subclassing. I checked this against the code:
|
|
Coverage: 94.99% (unit tier, Python 3.15,
Per-file detail: the |
Please follow the guide below
Put an
xinto every box [ ] that applies to your pull request (like this: [x])Use the Preview tab to see how your pull request will look
Searched for similar pull requests
Followed the coding style (
make pylint,make mypy,make isort)make testpasses, and a test case covers the changeDescribed the user-visible change below and left its changelog entry to the maintainer, keeping
docs/source/changelog/andCHANGELOG.mdout of the diff, if the change is user-visible: N/A — centralisedWhat is the purpose of your pull request?
Tick the commit type your subject line carries.
fix— corrects a defectfeat— adds a featureperf— changes performance, not behaviourrefactor— changes neither behaviour nor performancetest— tests onlydocs— documentation onlyci— workflows or build toolingrelease— bumps the version or rolls up a distributionchore— anything elseAlso tick if it regenerates constant or registry tables, members keeping their numeric values (the
constlabel)Description of your pull request and other information
Closes #3228.
With
PCAPKIT_MIMIC=wireshark, each TLS/DTLS extension decodes, and builds from keyword arguments, as itscasein Wireshark'sssl_dissect_hnd_extension(epan/dissectors/packet-tls-utils.cat0235e7b9e) reads it, in the messages that function reads extensions in: CH, SH, HRR, NST, EE, CT, CR. Unset,dpktandscapykeep #2853's RFC gating.supported_groups,ec_point_formats,signature_algorithms, ALPN,padding,record_size_limit,session_ticket,cookie,psk_key_exchange_modes,renegotiation_info: in each of those messages.casereads one,Emptywhere it reads nothing (ssl_end_vectorflags any octet left, which stays raw).connection_idkeeps feat(utilities): a PCAPKIT_WIRESHARK flag that makes pcapkit follow Wireshark where it follows an RFC instead (#3224) #3226's hellos-only reading. Kept raw for want of a schema:status_requestin a TLS 1.3Certificate,early_datain aNewSessionTicket.__structure__) feeds both thedataselector and the constructor, so read and make agree. Each schema'sdatadoc names its Wireshark case; the engines page's Mimic Mode table gains the site.Tests:
test_tls_extension_wireshark_gating_3228_unit.pyfails on agit archive origin/developexport (unittest: 105 failures, 102 errors). Coverage ofssl/rises (99.16% to 99.21%, branch). No pins moved.tests/protocols/application,tests/utilities,tests/project,tests/protocols/*.py,tests/*.py, the Sphinx-gated modules and a docs build pass, buttest_conda_dev_release_gate_2458, which fails the same on the export.