[Python-apps-team] Bug#922466: whitelist not working on python3 (buster version)

Benedikt Trefzer benedikt.trefzer at cirrax.com
Sat Feb 16 15:11:11 GMT 2019


Source: pyzor
Version: 1:1.0.0-3
Severity: important
Tags: patch

Whitelisting in pyzor is broken.

Steps to reproduce:
-------------------

normal invocation (working):
  > pyzor check < testspam4.txt
  public.pyzor.org:24441	(200, 'OK')	11407300	133104

whitelist the testspam4.txt message (localy) (still working):
  > pyzor local_whitelist < testspam4.txt

  This generates a file ~/.pyzor/whitelist with the appropriate checksum.

check the testspam4 messate again:
  > pyzor check < testspam4.txt
  Traceback (most recent call last):
    File "/usr/bin/pyzor", line 408, in <module>
      main()
    File "/usr/bin/pyzor", line 152, in main
      if not dispatch(client, servers, config):
    File "/usr/bin/pyzor", line 239, in check
      send_digest(digested, mock_runner, servers)
    File "/usr/bin/pyzor", line 262, in send_digest
      _send_digest(runner, servers[0], digested)
    File "/usr/bin/pyzor", line 253, in _send_digest
      runner.run(server, (digested, server))
    File "/usr/lib/python3/dist-packages/pyzor/client.py", line 258, in run
      response = self.routine(*args, **kwargs)
    File "/usr/lib/python3/dist-packages/pyzor/client.py", line 122, in
_mock_check
      pyzor.proto_version))
  TypeError: %b requires bytes, or an object that implements __bytes__,
not 'int'

Fix:
----
Upstream bug is available at
https://github.com/SpamExperts/pyzor/issues/44

To fix, apply:
https://github.com/SpamExperts/pyzor/pull/58/commits/1385ab7c7e8ba051cd22e7eb5a16f0c60854358d

Remark:
-------
I did only test (and fix) on a backported package for stretch (since I
needed python3 version). But I assume
the problem will also exist on buster !



More information about the Python-apps-team mailing list