View Issue Details

IDProjectCategoryView StatusLast Update
0008695Kali LinuxKali Package Bugpublic2024-04-04 04:20
ReporterIgnis Assigned Tosbrun  
PrioritynormalSeverityminorReproducibilityhave not tried
Status resolvedResolutionfixed 
Fixed in Version2024.2 
Summary0008695: mitmproxy 10.2.4 requires python3-cryptography >= 42.
Description

After a recent update mitmproxy can't start.
$ mitmproxy
Error logged during startup:
Addon error: 'cryptography.hazmat.bindings._rust.x509.Certificat' object has no attribute 'not_valid_after_utc'
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/mitmproxy/addons/tlsconfig.py", line 425, in running
self.configure("confdir") # pragma: no cover
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/mitmproxy/addons/tlsconfig.py", line 443, in configure
if self.certstore.default_ca.has_expired():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/mitmproxy/certs.py", line 113, in has_expired
return datetime.datetime.now(datetime.UTC) > self.notafter
^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/mitmproxy/certs.py", line 108, in notafter
return self._cert.not_valid_after_utc # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'cryptography.hazmat.bindings._rust.x509.Certificat' object has no attribute 'not_valid_after_utc'

dpkg-query -s mitmproxy says:
Version: 10.2.4-0kali1
Depends: fonts-font-awesome (>= 4.2.0~dfsg), python3-aioquic, python3-h2 (>= 4.0), python3-hyperframe (>= 6.0), python3-mitmproxy-rs (>= 0.5.1), python3-mitmproxy-wireguard, python3-pkg-resources, python3-urwid, python3-asgiref (>= 3.2.10), python3-brotli (>= 1.0), python3-certifi (>= 2019.9.11), python3-cryptography (<< 42.1), python3-cryptography (>= 41.0), python3-flask (<< 3.1), python3-flask (>= 1.1.1), python3-h11, python3-kaitaistruct (>= 0.7), python3-ldap3 (>= 2.8), python3-msgpack (>= 1.0.0), python3-openssl (>= 19.1.0), python3-passlib (>= 1.6.5), python3-protobuf (>= 3.6.0), python3-publicsuffix2 (>= 2.20190812), python3-pyparsing (>= 2.4.2), python3-pyperclip (>= 1.6.0), python3-ruamel.yaml (>= 0.16), python3-sortedcontainers (>= 2.1.0), python3-tornado (>= 4.3), python3-typing-extensions | python3-supported-min (>= 3.11), python3-wsproto (>= 0.14), python3-zstandard, python3:any

└─$ dpkg -l | grep -P 'mitmproxy|python3-cryptography'
ii mitmproxy 10.2.4-0kali1 all SSL-capable man-in-the-middle HTTP proxy
ii python3-cryptography 41.0.7-4 amd64 Python library exposing cryptographic recipes and primitives (Python 3)

But the maintainer of mitmproxy had said it requires python3-cryptography >= 42 here: https://github.com/mitmproxy/mitmproxy/discussions/6733

Activities

Arszilla

Arszilla

2024-03-29 22:29

reporter   ~0019081

python3-cryptography is maintained by Debian. Thus there are 2 possible options:

  1. Submit a bug ticket to Debian and ask them to upgrade their package in the Testing branch
  2. Kali Team downgrades/rolls back mitmproxy

I'd recommend you mail the Debian Bug Tracker and try to get the maintainers to update it. If they don't, I assume the Kali Team will perform Option #2.

Ignis

Ignis

2024-03-30 12:29

reporter   ~0019089

Last edited: 2024-03-30 22:01

I'm expecting a downgrade indeed.

The maintainer of mitmproxy from the Kali Team made a mistake updating it to rolling as the dependencies were not satisfied. Therefore I hardly see why it would be up to Debian to fix it.

sbrun

sbrun

2024-04-03 12:04

manager   ~0019097

I have reintroduced the version 10.2.3 in kali-rolling (version 10.2.4+really10.2.3-0kali1 is in kali-rolling).

FTR we will wait for python3-cryptography version 42 from Debian (blocked by librust-pem-3.0-dev and its dependencies, and the t64 changes in Debian).

Issue History

Date Modified Username Field Change
2024-03-29 15:41 Ignis New Issue
2024-03-29 22:29 Arszilla Note Added: 0019081
2024-03-30 12:29 Ignis Note Added: 0019089
2024-03-30 22:01 Ignis Note Edited: 0019089
2024-04-02 07:46 sbrun Assigned To => sbrun
2024-04-02 07:46 sbrun Status new => assigned
2024-04-03 12:04 sbrun Note Added: 0019097
2024-04-03 12:04 sbrun Status assigned => resolved
2024-04-03 12:04 sbrun Resolution open => fixed
2024-04-03 12:04 sbrun Fixed in Version => 2024.2