Commit graph

3465 commits

Author SHA1 Message Date
8211f3d6f1
e2ee-api: Some more changes to the documentation
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-02 00:07:34 +02:00
a8bf37eb61
e2ee-api: Add documentation
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 23:54:10 +02:00
dd6efb1444 e2ee-api: change log line in _encrypt
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
a2721b207b e2ee-api: Always remove non-whitelisted subelements of messages
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
2fb0cdbb88 e2ee-api: Drop message if no body and no stanza encryption
To avoid leaking data when plugin doesn't do stanza encryption. This
will inevitably reduce the number of features available, but users want
to send "secure" messages right.

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
47103fc5eb e2ee-api: do not edit non-chat/groupchat messages
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
2778401b23 e2ee-api: Do not remove body from messages if present
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
98102d075c e2ee-api: Add <eme/> only if <body/> is present
As per discussion in jdev@

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
812d9485e3 e2ee-api: update b64 plugin with latest changes
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
29a4ea389f e2ee-api: Fix log message
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
5500e771a4 e2ee-api: Add replace_body_with_eme parameter to the class
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
fdb5baeb0c e2ee-api: add comment on tag_whitelist
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
3642e1320c e2ee api: filter out non-whitelisted tags if not doing stanza encryption
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
d1a3a35df6 e2ee api: Utilize priority in event handling
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
708ec2523d e2ee api: Ensure only one encryption method is enabled at a time
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
a0140388f3 e2ee api: Avoid creating EME tag when looking if it's present
Some slixmpp API fail.. it's be great if we didn't have to fiddle with
the xml lib directly

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
47909c4dcf e2ee api: Add space before encryption name in status bar
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
d56d442253 First shot of an E2EE plugin interface
Features:
- Decryption by default once the plugin is loaded if messages contains
the right EME magic
- Encryption of messages only if encryption is enabled for the current
tab

Missing pieces:
- No special treatment done on the order of the treatment for messages
yet
- No special handling of non-Partial(/Full) Stanza Encryption yet (i.e.,
removing stuff other than <body/>)

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:45 +02:00
b9deb7e164
doc/dev/slix: Fix Slixmpp title
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-07-01 19:42:08 +02:00
pitchum
286f69912b Fix doc rendering 2019-06-29 09:31:56 +02:00
0628c97706
Update documentation for scrollback with the alias
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-22 04:17:39 +02:00
844549b354
Rename sb command 'scrollback' and make 'sb' an alias
While this command exists in irssi and might be known by some already,
'sb' is not be the most obvious command name for newcomers.

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-22 04:13:54 +02:00
72075c9fbf
Make function name clearer
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-22 03:56:01 +02:00
e1ca4ff338 Merge remote-tracking branch 'origin/mr/31' 2019-06-22 03:52:26 +02:00
833cccb188 Rework priority handling for events
Introduce the concept of priority for event handlers, instead of the
position parameter.

The new `priority` parameter replacing `position` should be an integer
between 0 and 100. It defaults to 50.

The previous `position` parameter was only used to insert at a certain
position in the list of handlers (for this particular event). No
reference of it was kept, which means that it was not possible to ensure
an event was called in the position is was supposed to be.

I am now using per-event dicts, containing priority buckets (lists) of
handlers. I am using OrderedDicts to make it easier to loop through all
of the handlers, as insertion happens less often than reading.

I was also suggested using bisect with a simple list of tuples
(priority, handler) per event, but bisect tries to compare bound
methods, which is obviously not possible. Maybe it would be interesting
to find a way use this method instead of OrderedDict as that might be
less resource consuming.

This said, I don't think this part of poezio is a bottleneck at all, so
maybe this is just fine as is.

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-22 03:01:02 +02:00
Madhur Garg
f505c83c48 Added few comments in the code and splitted a part of code into different function. 2019-06-20 04:41:03 +05:30
Madhur Garg
569efdec36 Fixed some mistakes in coding style 2019-06-20 03:09:30 +05:30
Madhur Garg
2c4a2d3d01 Corrects the repeated refresh of the window 2019-06-20 03:09:30 +05:30
Madhur Garg
ca72ac8d26 Updated usage of /sb in documentation 2019-06-20 03:09:30 +05:30
Madhur Garg
a1aad86a5b Getting the line number of the message in the tab based on the searched timestamp 2019-06-20 03:09:30 +05:30
Madhur Garg
b2c38497d4 Code work for /sb goto <+|-linecount>|<linenum>|<timestamp> 2019-06-20 03:09:30 +05:30
Madhur Garg
d8f53e8266 Corrected code duplication 2019-06-20 03:09:30 +05:30
Madhur Garg
0d2e2b084b Corrected description of the scrollback command 2019-06-20 03:09:30 +05:30
Madhur Garg
6db84c6dc6 Few imports for scrollback command 2019-06-20 03:09:30 +05:30
Madhur Garg
20a6094331 Documentation for scrollback command. 2019-06-20 03:09:30 +05:30
Madhur Garg
75554d3a66 Initial version of scrollback 2019-06-20 03:09:30 +05:30
Madhur Garg
b881bfad96 Merge https://lab.louiz.org/poezio/poezio 2019-06-18 01:59:59 +05:30
d35256ccc9 Merge remote-tracking branch 'origin/mr/35' 2019-06-17 14:49:10 +02:00
Madhur Garg
f9d34fc789 Updated copyright for lastlog plugin 2019-06-17 18:17:56 +05:30
Madhur Garg
7250eff335 Corrected the search for lastlog messages and refresh of the window.
Corrected the search for lastlog messages and refresh of the window.

patch from Maxime Buquet

Corrected the search for lastlog messages and refresh of the window.
2019-06-14 22:33:15 +05:30
Madhur Garg
d528a2ff55 Corrected the search for lastlog messages and refresh of the window. 2019-06-13 00:29:43 +05:30
6cfd23196c patch from Maxime Buquet 2019-06-13 00:23:48 +05:30
Madhur Garg
0a573f12dd Corrected the search for lastlog messages and refresh of the window. 2019-06-12 19:49:00 +05:30
1e21de272a initial version of a lastlog plugin
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-12 19:43:22 +05:30
91eabbd17d
plugins/figlet: error out when figlet doesn't exist
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-06-07 16:09:06 +02:00
Emmanuel Gil Peyrot
b7fc562c88 Also skip librsvg import on AttributeError
In the case python-gobject isn’t installed, but another package (such as
libibus) provides overrides, the gi module will still get imported fine
despite being empty, resulting in a traceback. To prevent this, we also
catch AttributeError so that gi.require_version can fail.
2019-05-28 16:02:15 +02:00
1a825de020
plugins/ping: Import missing JID value (thanks madhur, and pylint)
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-05-11 18:46:12 +01:00
5b35bde906
config: ensure tabname is not a JID object
Tabnames should be treated as opaque strings.

This specific fix prevents tabname (JID) to be compared with invalid
stringly-typed JIDs. JID's __eq__ method used to (after
poezio/slixmpp@47968963) try and convert anything into JIDs. This has
been fixed and now properly returns NotImplemented.

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-05-07 11:58:19 +01:00
463ad192be
ConversationTab: fix undefined reference, missing self
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-04-29 21:57:32 +01:00
7a1b2b982f
plugins: Update use of tab.name to tab.jid where appropriate
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2019-04-28 01:02:49 +01:00