at master 1.9 kB view raw
1{ 2 lib, 3 fetchFromGitHub, 4 buildPythonPackage, 5 6 setuptools, 7 8 typing-extensions, 9 xeddsa, 10 11 pytestCheckHook, 12 oldmemo, 13 twomemo, 14 pytest-asyncio, 15 pytest-cov-stub, 16 17 # passthru 18 omemo, 19}: 20buildPythonPackage rec { 21 pname = "omemo"; 22 version = "2.0.0"; 23 pyproject = true; 24 25 src = fetchFromGitHub { 26 owner = "Syndace"; 27 repo = "python-omemo"; 28 tag = "v${version}"; 29 hash = "sha256-uA8Nv8xT6ROlE9eM/Oz2j5HsYtvWzKEu7DSd/ws+WZY="; 30 }; 31 32 build-system = [ 33 setuptools 34 ]; 35 36 dependencies = [ 37 typing-extensions 38 xeddsa 39 ]; 40 41 doCheck = false; 42 43 nativeCheckInputs = [ 44 pytestCheckHook 45 oldmemo 46 twomemo 47 pytest-asyncio 48 pytest-cov-stub 49 ] 50 ++ oldmemo.optional-dependencies.xml; 51 52 pythonImportsCheck = [ 53 "omemo" 54 ]; 55 56 passthru.tests = { 57 pytest = omemo.overridePythonAttrs { 58 doCheck = true; 59 }; 60 }; 61 62 meta = { 63 description = "Open python implementation of the OMEMO Multi-End Message and Object Encryption protocol"; 64 longDescription = '' 65 A complete implementation of XEP-0384 on protocol-level, i.e. more than just the cryptography. 66 python-omemo supports different versions of the specification through so-called backends. 67 68 A backend for OMEMO in the urn:xmpp:omemo:2 namespace (the most recent version of the specification) is available 69 in the python-twomemo Python package. 70 A backend for (legacy) OMEMO in the eu.siacs.conversations.axolotl namespace is available in the python-oldmemo 71 package. 72 Multiple backends can be loaded and used at the same time, the library manages their coexistence transparently. 73 ''; 74 homepage = "https://github.com/Syndace/python-omemo"; 75 changelog = "https://github.com/Syndace/python-omemo/blob/${src.tag}/CHANGELOG.md"; 76 license = lib.licenses.mit; 77 teams = with lib.teams; [ ngi ]; 78 maintainers = with lib.maintainers; [ themadbit ]; 79 }; 80}