fix #847
This commit is contained in:
parent
6b92497d4f
commit
43ed82062f
|
@ -5,7 +5,7 @@
|
|||
from __future__ import absolute_import, division, print_function
|
||||
|
||||
from construct import (Array, Bytes, Struct, UBInt16, UBInt32, UBInt8, PascalString, Embed, TunnelAdapter, GreedyRange,
|
||||
Switch, OptionalGreedyRange)
|
||||
Switch, OptionalGreedyRange, Optional)
|
||||
|
||||
from .utils import UBInt24
|
||||
|
||||
|
@ -112,7 +112,7 @@ Extension = Struct(
|
|||
)
|
||||
|
||||
extensions = TunnelAdapter(
|
||||
PascalString("extensions", length_field=UBInt16("extensions_length")),
|
||||
Optional(PascalString("extensions", length_field=UBInt16("extensions_length"))),
|
||||
OptionalGreedyRange(Extension)
|
||||
)
|
||||
|
||||
|
|
|
@ -318,7 +318,7 @@ class TlsLayer(Layer):
|
|||
client_hello = ClientHello.parse(raw_client_hello)
|
||||
except ConstructError as e:
|
||||
self.log("Cannot parse Client Hello: %s" % repr(e), "error")
|
||||
self.log("Raw Client Hello:\r\n:%s" % raw_client_hello.encode("hex"), "debug")
|
||||
self.log("Raw Client Hello: %s" % raw_client_hello.encode("hex"), "debug")
|
||||
return
|
||||
|
||||
self.client_ciphers = client_hello.cipher_suites.cipher_suites
|
||||
|
|
Loading…
Reference in New Issue