Commit 617920f
Fixed a TypeError that triggered when reading a pcap file containing a NTP packet. (#1186)
* Fixed an error (TypeError) that triggered when reading a pcap file that
contained ntp packets. The type of variable "cls" was string not a class
type (invalid argument for method: issubclass()). By importing the type
'TCP' from 'scapy.layers.inet' and by converting cls to a classtype by
reading the key from globals, the TypeError is mitigated.
* Added test to provide insight into the cls variable inconsistencies.
Fixed a small mistake
* https://github.com/secdev/scapy/pull/1186/files/d0a2544ae13ba353d25e86be2cfc13cceda36a10
* Moved tests.
* fix backward incompatibility of scapy.utils.RawPcapReader.read_packet() for scapy's v2.4 againts v2.3.2 & v2.3.3
named tuple instead of tuple as result of RawPcap[Ng]Reader.read_block_???()/read_packet():
* Fixed an error (TypeError) that triggered when calling sessions() on a PacketList that
contained ntp packets. The type of variable "cls" was a string not a class
type (invalid argument for method: issubclass()).
* Added test to provide insight into the cls variable inconsistencies.
Fixed a small mistake
* https://github.com/secdev/scapy/pull/1186/files/d0a2544ae13ba353d25e86be2cfc13cceda36a10
* Forgot to delete ntp.uts during rebase...1 parent f61f98f commit 617920f
2 files changed
Lines changed: 12 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
214 | 214 | | |
215 | 215 | | |
216 | 216 | | |
217 | | - | |
| 217 | + | |
218 | 218 | | |
219 | 219 | | |
220 | 220 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7053 | 7053 | | |
7054 | 7054 | | |
7055 | 7055 | | |
7056 | | - | |
7057 | 7056 | | |
7058 | 7057 | | |
7059 | 7058 | | |
| |||
7062 | 7061 | | |
7063 | 7062 | | |
7064 | 7063 | | |
| 7064 | + | |
| 7065 | + | |
| 7066 | + | |
| 7067 | + | |
| 7068 | + | |
| 7069 | + | |
| 7070 | + | |
| 7071 | + | |
| 7072 | + | |
| 7073 | + | |
| 7074 | + | |
7065 | 7075 | | |
7066 | 7076 | | |
7067 | 7077 | | |
| |||
0 commit comments