Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-dpkt for openSUSE:Factory 
checked in at 2021-10-20 20:22:45
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-dpkt (Old)
 and      /work/SRC/openSUSE:Factory/.python-dpkt.new.1890 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-dpkt"

Wed Oct 20 20:22:45 2021 rev:9 rq:924285 version:1.9.7.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-dpkt/python-dpkt.changes  2021-01-08 
17:32:00.589163827 +0100
+++ /work/SRC/openSUSE:Factory/.python-dpkt.new.1890/python-dpkt.changes        
2021-10-20 20:22:57.469328946 +0200
@@ -1,0 +2,67 @@
+Fri Oct  8 06:53:28 UTC 2021 - Matej Cepl <mc...@suse.com>
+
+- Update skip-BE-tests.patch so that it actually fixes things,
+  instead of just skipping tests (gh#kbandla/dpkt#615).
+
+-------------------------------------------------------------------
+Thu Oct  7 10:42:16 UTC 2021 - Matej Cepl <mc...@suse.com>
+
+- Update to 1.9.7.2:
+  - Fixed performance regression (#611)
+  - Moved the project documentation from Read the Docs(RST) to
+    github.io(MarkDown)
+  - Added a new mechanism for creating bit-sized field
+    definitions in the protocol parsers (Packet.__bit_fields__)
+  - Added pretty printing capability aka Packet.pprint(),
+    Packet.__pprint_funcs__
+  - Added documentation on developing protocol parsers in dpkt
+    (creating_parsers.md)
+  - Added a universal pcap+pcapng reader
+    (dpkt.pcap.UniversalReader)
+  - Improved TLS ClientHello and ServerHello parsing: return an
+    "Unknown" ciphersuite instead of raising an exception, add
+    codes for rfc8701, GREASE ciphersutes
+  - Added function to get IP protocol name
+  - Modified Packet.__getitem__() and added Packet.__contains__()
+    to address the nested protocol layers
+  - Fixed payload length interpretation in AH decoder
+  - Improved handling of invalid chunks in HTTP and SCTP
+  - Fixed decoding of IPv6 fragments after the 1st fragment
+  - Support rfc3540 nonce sum flag in TCP
+  - Added in the TLS 1.3 Cipher Suite from the RFC 8446 dated
+    August 2018
+  - Added support for Linux cooked capture v2, SLL2.
+  - New example showing how to process truncated DNS packets
+    (examples/print_dns_truncated.py).
+  - Corrected typo in BGP.notification attribute.
+  - BGP.Update.Attribute.MPReachNLRI.SNPA now inherits from
+    dpkt.Packet.
+  - Byteorder is now specified when packing GRE optional fields.
+  - #517: Improvement to Radiotap class, supporting multi-byte
+    and misaligned flags fields. Endianness is now enforced.
+  - Github issue template added for bug reporting.
+  - Compliance with flake8 formatting.
+  - asn1.py::utctime method now returns time in UTC, instead of
+    local.
+  - Allow multiple InterfaceDescriptionBlocks with pcapng.Writer.
+  - SCTP decoder DATA chunk padding aligned to 4-bytes, and
+    improved handling of .data field.
+  - IEEE80211 DELBA frame now works on big and little-endian
+    architectures.
+  - Introduce compat.ntole which converts from network byte order
+    to little-endian byte order, regardless of host endianness.
+  - Ethernet class now attempts to unpack the padding and trailer
+    if present.
+  - Added anonymous property to cipher suites, which returns True
+    if the cipher suite starts with 'anon'.
+  - Added pfs (Perfect Forward Secrecy) and aead (Authenticated
+    Encryption with Additional Data) properties to cipher suites.
+  - Added old CHACHA20-POLY1305 related cipher suites to TLS
+    CipherSuite list.
+  - Remove redundant num_compression_methods from TLSClientHello
+  - Testing improved from 90% coverage to over 99%.
+- Remove upstreamed patch fix_s390x_tests.patch
+- Add patch skip-BE-tests.patch skipping failing tests again
+  (gh#kbandla/dpkt#505).
+
+-------------------------------------------------------------------

Old:
----
  fix_s390x_tests.patch
  v1.9.4.tar.gz

New:
----
  skip-BE-tests.patch
  v1.9.7.2.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-dpkt.spec ++++++
--- /var/tmp/diff_new_pack.sRMcmJ/_old  2021-10-20 20:22:58.057329309 +0200
+++ /var/tmp/diff_new_pack.sRMcmJ/_new  2021-10-20 20:22:58.069329316 +0200
@@ -18,17 +18,16 @@
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-dpkt
-Version:        1.9.4
+Version:        1.9.7.2
 Release:        0
 Summary:        Packet creation and parsing module for Python
 License:        BSD-3-Clause
 Group:          Development/Libraries/Python
 URL:            https://github.com/kbandla/dpkt
 Source:         https://github.com/kbandla/dpkt/archive/v%{version}.tar.gz
-# PATCH-FIX-UPSTREAM fix_s390x_tests.patch gh#kbandla/dpkt#505 mc...@suse.com
-# Skip failing tests on s390x arch
-Patch0:         fix_s390x_tests.patch
-BuildRequires:  %{python_module mock}
+# PATCH-FIX-UPSTREAM skip-BE-tests.patch gh#kbandla/dpkt#505 mc...@suse.com
+# Adjust tests to work on BE machines, gh#kbandla/dpkt#615
+Patch0:         skip-BE-tests.patch
 BuildRequires:  %{python_module pytest}
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  fdupes
@@ -55,12 +54,11 @@
 %python_expand %fdupes %{buildroot}%{$python_sitelib}
 
 %check
-# gh#kbandla/dpkt#505
-%pytest -s dpkt
+%pytest dpkt
 
 %files %{python_files}
 %license LICENSE
-%doc examples AUTHORS CHANGES README.rst
+%doc examples AUTHORS README.md docs
 %{python_sitelib}/*
 
 %changelog

++++++ skip-BE-tests.patch ++++++
---
 dpkt/loopback.py |   24 +++++++++++++++++-------
 dpkt/pcapng.py   |   24 ++++++++++++++----------
 2 files changed, 31 insertions(+), 17 deletions(-)

--- a/dpkt/loopback.py
+++ b/dpkt/loopback.py
@@ -1,6 +1,9 @@
 # $Id: loopback.py 38 2007-03-17 03:33:16Z dugsong $
 # -*- coding: utf-8 -*-
 """Platform-dependent loopback header."""
+
+# https://wiki.wireshark.org/NullLoopback
+
 from __future__ import absolute_import
 
 from . import dpkt
@@ -24,17 +27,23 @@ class Loopback(dpkt.Packet):
 
     def unpack(self, buf):
         dpkt.Packet.unpack(self, buf)
-        if self.family == 2:
-            self.data = ip.IP(self.data)
-
-        elif self.family == 0x02000000:
+        if self.family in (0x02, 0x02000000):
             self.family = 2
             self.data = ip.IP(self.data)
 
-        elif self.family in (24, 28, 30):
+        elif self.family in (0x18, 0x18000000):
+            self.family = 24
             self.data = ip6.IP6(self.data)
 
-        elif self.family > 1500:
+        elif self.family in (0x1c, 0x1c000000):
+            self.family = 28
+            self.data = ip6.IP6(self.data)
+
+        elif self.family in (0x1e, 0x1e000000):
+            self.family = 30
+            self.data = ip6.IP6(self.data)
+
+        else:
             self.data = ethernet.Ethernet(self.data)
 
 
@@ -43,7 +52,7 @@ def test_ethernet_unpack():
     hdr = b'\x00\x02\x00\x02'
 
     lo = Loopback(hdr + buf)
-    assert lo.family == 33554944
+    assert lo.family in (0x02000200, 0x00020002)  # little endian, big endian
     assert isinstance(lo.data, ethernet.Ethernet)
     assert lo.data.src == b'\x07\x08\t\n\x0b\x0c'
     assert lo.data.dst == b'\x01\x02\x03\x04\x05\x06'
@@ -61,6 +70,7 @@ def test_ip_unpack():
 
 
 def test_ip6_unpack():
+
     import struct
     buf = 
(b'\x60\x00\x00\x00\x00\x14\x06\x38\x26\x07\xf8\xb0\x40\x0c\x0c\x03\x00\x00\x00\x00\x00\x00'
            
b'\x00\x1a\x20\x01\x04\x70\xe5\xbf\xde\xad\x49\x57\x21\x74\xe8\x2c\x48\x87')
--- a/dpkt/pcapng.py
+++ b/dpkt/pcapng.py
@@ -888,6 +888,10 @@ def define_testdata():
         def shb_idb_epb_be(self):
             return self.valid_shb_be, self.valid_idb_be, self.valid_epb_be
 
+        @property
+        def shb_idb_epb(self):
+            return self.shb_idb_epb_le if sys.byteorder == 'little' else 
self.shb_idb_epb_be
+
     return TestData()
 
 
@@ -1138,15 +1142,14 @@ def test_custom_read_write():
     fobj.close()
 
     # test pcapng customized writing
-    if sys.byteorder == 'little':
-        shb, idb, epb = define_testdata().shb_idb_epb_le
-    else:
-        shb, idb, epb = define_testdata().shb_idb_epb_be
+    shb, idb, epb = define_testdata().shb_idb_epb
 
     fobj = BytesIO()
     writer = Writer(fobj, shb=shb, idb=idb)
     writer.writepkt(epb, ts=1442984653.210838)
-    assert fobj.getvalue() == buf
+    # .valid_pcapng buf was collected on a little endian system
+    if sys.byteorder == 'little':
+        assert fobj.getvalue() == buf
     fobj.close()
 
     # same with timestamps defined inside EPB
@@ -1156,14 +1159,15 @@ def test_custom_read_write():
     fobj = BytesIO()
     writer = Writer(fobj, shb=shb, idb=idb)
     writer.writepkt(epb)
-    assert fobj.getvalue() == buf
+    if sys.byteorder == 'little':
+        assert fobj.getvalue() == buf
     fobj.close()
 
 
 def test_multi_idb_writer():
     """Test writing multiple interface description blocks into pcapng and read 
it"""
     fobj = BytesIO()
-    shb, idb, epb = define_testdata().shb_idb_epb_le
+    shb, idb, epb = define_testdata().shb_idb_epb
 
     writer = Writer(fobj, shb=shb, idb=[idb, idb])
     writer.writepkt(epb)
@@ -1190,7 +1194,7 @@ def test_writer_validate_instance():
 def test_writepkt_epb_ts():
     """writepkt should assign ts_high/low for epb if they are 0"""
     global time
-    shb, idb, epb = define_testdata().shb_idb_epb_le
+    shb, idb, epb = define_testdata().shb_idb_epb
     writer = Writer(fobj, shb=shb, idb=idb)  # noqa
     epb.ts_high = epb.ts_low = 0
     ts = 1454725786.526401
@@ -1296,7 +1300,7 @@ def test_pcapng_block_unpack():
 
 def test_epb_unpack():
     """EnhancedPacketBlock can only unpack data >64 bytes, the length of their 
header"""
-    shb, idb, epb = define_testdata().shb_idb_epb_be
+    shb, idb, epb = define_testdata().shb_idb_epb
     buf = b'quite-long-but-not-long-enough-at-least-32'
     try:
         epb.unpack(buf)
@@ -1306,7 +1310,7 @@ def test_epb_unpack():
 
 def test_epb_unpack_length_mismatch():
     """Force calculated len to be 0 when unpacking epb, this should fail when 
unpacking"""
-    shb, idb, epb = define_testdata().shb_idb_epb_be
+    shb, idb, epb = define_testdata().shb_idb_epb
 
     unpackme = bytes(epb)
     unpackme = unpackme[:-4] + b'\x00' * 4
++++++ v1.9.4.tar.gz -> v1.9.7.2.tar.gz ++++++
++++ 14706 lines of diff (skipped)

Reply via email to