MCPcopy Create free account
hub / github.com/mitmproxy/mitmproxy / assert_alpn

Method assert_alpn

test/mitmproxy/addons/test_tlsconfig.py:436–442  ·  view source on GitHub ↗
(http2, client_offers, expected)

Source from the content-addressed store, hash-verified

434 tls_start = tls.TlsData(ctx.server, context=ctx)
435
436 def assert_alpn(http2, client_offers, expected):
437 tctx.configure(ta, http2=http2)
438 ctx.client.alpn_offers = client_offers
439 ctx.server.alpn_offers = None
440 tls_start.ssl_conn = None
441 ta.tls_start_server(tls_start)
442 assert ctx.server.alpn_offers == expected
443
444 assert_alpn(
445 True,

Callers

nothing calls this directly

Calls 2

tls_start_serverMethod · 0.80
configureMethod · 0.45

Tested by

no test coverage detected