Commit graph libervia-backend/setup.py
Author SHA1 Message Date
Goffi
e1f123f120 plugin app manager: first draft:
/!\ new optional dependency: pyyaml

this plugin manage the life cycle of external applications. Application handlers register
to it.

Data needed to launch an application as set in YAML files. Local data types are used to
get values directly from SàT:

- !sat_conf to retrieve a configuration value
- !sat_generate_pwd to generate a password
- !sat_param for parameters specified a launch

Data can be exposed when an instance is launched, this can be used to specify the port
(notably the one used for web), or a generated password.
2020-09-28 21:10:30 +02:00
Goffi
f8a7232e7b install (setup.py): added missing extra_requires 2020-09-13 22:49:10 +02:00
Goffi
5c46b74c69 plugin XEP-0264: fix orientation of thumbnails:
Rotation of thumbnailis is now modified according to EXIF orientation data. Original image
is not modified as user may want to keep it, and orientation transformation can modify
encoding parameters.

Update `pillow` minimum version to the first one with `exif_transpose` implementation.
2020-08-13 23:46:18 +02:00
Goffi
a1eb68c1e7 core: replaced sat shell script by a python script:
the backend is now launched by `sat.core.launcher`, and the script is generated during
installation with a new entry point in `setup.py`.
2020-05-25 15:50:01 +02:00
Goffi
47ec15cc46 core: image convertion + SVG support:
/!\ new optional dependency: CairoSVG (with installed `[SVG]` extra)

- new `convert` method in `tools.image` to save an image in an other format, with support
  for SVG (when CairoSVG is available)
- new `imageConvert` method is available for frontends
2020-04-19 16:53:44 +02:00
Goffi
d0741de2ad core (memory/crypto): replaced PyCrypto by cryptography:
`PyCrypto` is unmaintained for years but was used in SàT for password hashing. This patch
fixes that by replacing `PyCrypto` by the reference `cryptography` module which is well
maintained.

The behaviour stays the same (except that previously async `hash`, `encrypt` and `decrypt`
methods are now synchronous, as they are quick and using a deferToThread may actually be
more resource intensive than using blocking methods).

It is planed to improve `memory.crypto` by using more up-to-date cryptography/hashing
algorithms in the future.

PyCrypto is no more a dependency of SàT
2020-02-09 23:50:26 +01:00
Goffi
a39349fe64 dates update 2020-01-29 09:50:54 +01:00
Goffi
644e80df00 install (setup.py): use progressbar2 instead of progressbar 2020-01-11 17:20:44 +01:00
Goffi
f9a034509c plugin sec aesgcm: new plugin handling aesgcm: scheme for e2e encrypted media sharing:
The scheme is register with download meta plugin, and it is activated with HTTP Upload
(XEP-0363) when `encryption` is used in `options` with the value of C.ENC_AES_GCM.
This is also known as `OMEMO Media Sharing` even if this method is not directly linked to
OMEMO and can be used independently.
2019-12-20 12:28:04 +01:00
Goffi
edbee4d719 plugin upload, XEP-0363: code modernisation + preparation for extension:
- use of async/await syntax
- fileUpload's options are now serialised, allowing non string values
- (XEP-0363) Slot is now a dataclass, so it can be modified by other plugins
- (XEP-0363) Moved SSL related code to the new tools.web module
- (XEP-0363) added `XEP-0363_upload_size` and `XEP-0363_upload` trigger points
- a Deferred is not used anymore for `progress_id`, the value is directly returned
2019-12-20 12:28:04 +01:00
Goffi
a300181a01 plugin XEP-0384: update to latest python-omemo + better trust management:
- python-omemo minimal version is now 0.11.0
- `undecided` devices are now handled, fixing the "accept all or none" issue: if a device
  is `undecided`, the trust manager will be shown with the missing devices before sending
  the message.
- `untrusted` devices are discarded
2019-12-20 12:28:01 +01:00
Goffi
ad1ec9698c plugin XEP-0384: specific warning on missing omemo-backend-signal + fixed encoding following Python 3 port 2019-12-07 11:30:56 +01:00
Goffi
0ca17c71e0 install (setup): added Python 3.8 classifier 2019-11-15 17:55:39 +01:00
Goffi
ed73fd8bf8 tools (common/template): removed warning catches, jinja2>=2.10.3 now handles them correctly 2019-10-18 17:51:44 +02:00
Goffi
f7aad247c2 misc: don't import memory in launch script:
launch script was importing a method from memory (fixLocalDir), but memory is importing
twisted.internet.reactor which can result to a ReactorAlreadyInstalledError.

This patch fixes it by moving fixLocalDir to tools/config.

The launch script is now using /usr/bin/env.
2019-10-08 12:10:26 +02:00
Goffi
310ce2eb13 core (patches): updated TLS patches:
- updated patches to handle TLS after implementation in Twisted 19.7.0. A patch is still
  needed for Wokkel.
- minimum required version of Twisted is now 19.7.0
2019-10-01 22:49:10 +02:00
Goffi
76aadbb3fb jp: jp asyncio port:
/!\ this commit is huge. Jp is temporarily not working with `dbus` bridge /!\

This patch implements the port of jp to asyncio, so it is now correctly using the bridge
asynchronously, and it can be used with bridges like `pb`. This also simplify the code,
notably for things which were previously implemented with many callbacks (like pagination
with RSM).

During the process, some behaviours have been modified/fixed, in jp and backends, check
diff for details.
2019-09-25 08:56:41 +02:00
Goffi
2b062e9cde install (setup.py): updated classifiers 2019-08-25 12:16:18 +02:00
Goffi
c9574e2b87 install (setup.py): updated python_requires 2019-08-25 09:53:03 +02:00
Goffi
fbfe96c505 Python 3 port:
/!\ this is a huge commit
/!\ starting from this commit, SàT is needs Python 3.6+
/!\ SàT maybe be instable or some feature may not work anymore, this will improve with time

This patch port backend, bridge and frontends to Python 3.

Roughly this has been done this way:

- 2to3 tools has been applied (with python 3.7)
- all references to python2 have been replaced with python3 (notably shebangs)
- fixed files not handled by 2to3 (notably the shell script)
- several manual fixes
- fixed issues reported by Python 3 that where not handled in Python 2
- replaced "async" with "async_" when needed (it's a reserved word from Python 3.7)
- replaced zope's "implements" with @implementer decorator
- temporary hack to handle data pickled in database, as str or bytes may be returned,
  to be checked later
- fixed hash comparison for password
- removed some code which is not needed anymore with Python 3
- deactivated some code which needs to be checked (notably certificate validation)
- tested with jp, fixed reported issues until some basic commands worked
- ported Primitivus (after porting dependencies like urwid satext)
- more manual fixes
2019-08-13 19:08:41 +02:00
Goffi
5cd41da237 install: remove "service_identity" which is need by Twisted, and request "tls" extra for twisted 2019-06-21 11:37:51 +02:00
Goffi
88843cb483 install: updated minimal version for sat_tmp and urwid-satext 2019-06-19 20:07:56 +02:00
Goffi
e1ff10bf77 template (i18n): activate ext.i18n.trimmed policy, to have clean translation strings. Set minimal jinja2 version to 2.10 2019-04-14 08:21:51 +02:00
Goffi
08650b3037 misc (setup): minimum markdown version is not 3.0 2019-03-25 08:46:09 +01:00
Goffi
ace2f57027 plugin XEP-0384: removed version restriction, it is now compatible with (and require) last version of python-omemo (0.10.4) 2019-03-20 09:08:37 +01:00
Goffi
e8e8881016 plugin XEP-0384: better bundle handling + misc improvments
- public bundles are now retrieved only when needed (i.e. on MissingBundleException when encrypting a message)
- a feedback is given to user when a message is received but it has not been encrypted for our device
- fixed feedback on decryption error if message come from an other device of the client (i.e. it's a carbon copy)
- setBundle if called in a "finally" if republish_bundle is set after decrypting a message
2019-02-28 18:57:26 +01:00
Goffi
111d77e75e plugin XEP-0384: update to last python-omemo + trust management:
- Plugin has been updated to use last version of python-omemo (10.0.3).
- A temporary method remove all storage data if they are found, this method must be removed before 0.7 release (only people using dev version should have old omemo data in there storage).
- Trust management is not implemented, using new encryptionTrustUIGet method (an UI is also displayed when trust handling is needed before sending a message).
- omemo.DefaultOTPKPolicy is now used, instead of previous test policy of always deleting.

OMEMO e2e encryption is now functional for one2one conversations, including fingerprint management.
2019-01-02 18:50:28 +01:00
Goffi
9771affbcc install: don't do conditional requirement for omemo anymore, it should now work on all unixes 2018-09-23 17:02:47 +02:00
Goffi
465ba81bc2 install: use omemo in install_requires only for platforms supported upstream 2018-09-20 19:04:02 +02:00
Goffi
583d4b0c2e plugin XEP-0384, install: adapted plugin to omemo module changes + added omemo module to dependencies:
- omemo module logs are now integrated in SàT
- OmemoStorage adapated to changes
- now really delete OTPK each time, behaviour may be modified in future
- fixed bad arguments used during decryption
- adapted to other changes

OMEMO is now working \o/
It still needs some adjustements though: bundles/devices are for the moment requested on each message encryption, and fingerprints management is not implemented yet.
2018-08-11 18:24:55 +02:00
Goffi
a3ed513ee1 install (setup.py): don't use sys.prefix for locales 2018-07-08 18:37:36 +02:00
Goffi
a84634d3f8 install: fixed DBUS_FILE path 2018-07-04 07:58:24 +02:00
Goffi
ea9583aea0 core: some more line limiting 2018-06-27 07:23:13 +02:00
Goffi
d36f76e7d3 install (setup): added python-dateutil as dependency (was already a dependency of Wokkel) 2018-06-21 01:21:44 +02:00
Goffi
a9e368cf6a setup, tools(utils): fixed versioning in setup and getRepositoryData 2018-04-06 16:47:40 +02:00
Goffi
38d303f09d setup: use NAME to get version 2018-04-05 17:42:05 +02:00
Goffi
b5a4d8c58d setup: use scm version 2018-04-05 12:49:25 +02:00
Goffi
ac954f378d setup: version is now set in SAT/VERSION, sat is not imported anymore in setup 2018-04-05 10:41:08 +02:00
Goffi
69faabb405 setup: minimal version of sat_tmp is 0.0.3 2018-04-04 08:45:09 +02:00
Goffi
14c817fa2c setup, constant: use https address in APP_URL, and keep pypi NAME separated from constants 2018-04-03 09:04:55 +02:00
Goffi
b92101dabc setup: use constants to get name and version 2018-04-03 08:00:42 +02:00
Goffi
80ef13612b core, setup: huge cleaning:
- moved directories from src and frontends/src to sat and sat_frontends, which is the recommanded naming convention
- move twisted directory to root
- removed all hacks from setup.py, and added missing dependencies, it is now clean
- use https URL for website in setup.py
- removed "Environment :: X11 Applications :: GTK", as wix is deprecated and removed
- renamed sat.sh to sat and fixed its installation
- added python_requires to specify Python version needed
- replaced glib2reactor which use deprecated code by gtk3reactor

sat can now be installed directly from virtualenv without using --system-site-packages anymore \o/
2018-04-02 19:44:50 +02:00
Goffi
87690d88ce core, template (filters): added pygments as a dependency + new highlight filter to use it. 2017-11-30 21:00:24 +01:00
Goffi
a5f28ef7dd tmp: removed sat.tmp hierarchy and fixed references to it as it is now an independant sat_tmp repository 2017-11-03 14:19:10 +01:00
Goffi
c6ea8e7dbe core (tools/common/template): i18n support
- babel has been added as a new dependencies, and should replace gettext in core in the future
    - added i18n support in template rendered
    - current locale is available as babel Locale in templates through "locale" variable
    - locales can be changed before rendering using setLocale
    - for now, all locales translations are loaded on init, and stay in cache. A more complex cache system may be needed in the future (e.g. keeping only most used and load others from files when needed).
2017-05-21 15:59:47 +02:00
Goffi
d7d5ca1d18 plugin invitations: first draft:
/!\ new dependency: shortuuid
Plugin invitations allows to invite somebody without XMPP account, using an unique identifier.
The various arguments are explained in the docstring.
2017-03-12 19:35:36 +01:00
Goffi
cd5e05bd1f installation (setup.py): changed version to 0.6.1.1 so new archive with fixed MANIFEST can be uploaded on pypi 2016-07-13 11:01:07 +02:00
Goffi
ec8a5fbffb version update (0.6.1) 2016-07-12 23:30:13 +02:00
Goffi
effcee07bf installation: updated urwid-satext minimal version to 0.6.1 + added service_identity which is needed by Twisted for proper TLS check 2016-07-12 23:29:43 +02:00
Goffi
0b52799489 core (installation): minor comment in setup.py 2016-04-17 18:07:55 +02:00