Mercurial > libervia-backend
annotate doc/libervia-cli/blocking.rst @ 4231:e11b13418ba6
plugin XEP-0353, XEP-0234, jingle: WebRTC data channel signaling implementation:
Implement XEP-0343: Signaling WebRTC Data Channels in Jingle. The current version of the
XEP (0.3.1) has no implementation and contains some flaws. After discussing this on xsf@,
Daniel (from Conversations) mentioned that they had a sprint with Larma (from Dino) to
work on another version and provided me with this link:
https://gist.github.com/iNPUTmice/6c56f3e948cca517c5fb129016d99e74 . I have used it for my
implementation.
This implementation reuses work done on Jingle A/V call (notably XEP-0176 and XEP-0167
plugins), with adaptations. When used, XEP-0234 will not handle the file itself as it
normally does. This is because WebRTC has several implementations (browser for web
interface, GStreamer for others), and file/data must be handled directly by the frontend.
This is particularly important for web frontends, as the file is not sent from the backend
but from the end-user's browser device.
Among the changes, there are:
- XEP-0343 implementation.
- `file_send` bridge method now use serialised dict as output.
- New `BaseTransportHandler.is_usable` method which get content data and returns a boolean
(default to `True`) to tell if this transport can actually be used in this context (when
we are initiator). Used in webRTC case to see if call data are available.
- Support of `application` media type, and everything necessary to handle data channels.
- Better confirmation message, with file name, size and description when available.
- When file is accepted in preflight, it is specified in following `action_new` signal for
actual file transfer. This way, frontend can avoid the display or 2 confirmation
messages.
- XEP-0166: when not specified, default `content` name is now its index number instead of
a UUID. This follows the behaviour of browsers.
- XEP-0353: better handling of events such as call taken by another device.
- various other updates.
rel 441
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 06 Apr 2024 12:57:23 +0200 |
parents | 29380ef68dbe |
children |
rev | line source |
---|---|
3810
29380ef68dbe
doc (components): AP item retraction + blocking:
Goffi <goffi@goffi.org>
parents:
3789
diff
changeset
|
1 .. _libervia-cli_blocking: |
29380ef68dbe
doc (components): AP item retraction + blocking:
Goffi <goffi@goffi.org>
parents:
3789
diff
changeset
|
2 |
3789
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
3 =========================== |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
4 blocking: entities blocking |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
5 =========================== |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
6 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
7 ``blocking`` are commands to block or unblock users by their JIDs (as specified by |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
8 `XEP-0191`_). You server must implement this XEP to use those commands. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
9 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
10 A blocking is usually done using bare JID, however, you may specify a resource if you want |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
11 to block only this resource, or a domain if you want to block a whole domain. Please check |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
12 `XEP-0191 § JID Matching`_ for details. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
13 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
14 list |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
15 ==== |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
16 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
17 List already blocked users. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
18 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
19 examples |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
20 -------- |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
21 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
22 Check who has already been blocked:: |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
23 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
24 $ li blocking list |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
25 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
26 block |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
27 ===== |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
28 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
29 Block one or more entities by specifying their JIDs. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
30 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
31 You just need to specify the bare JIDs of users that you want to block as positional |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
32 argument, specify only a domain if you want to block a whole domain. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
33 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
34 examples |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
35 -------- |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
36 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
37 Louise wants to block ``spammer@example.com`` and the whole domain ``spammers.example``:: |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
38 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
39 $ li blocking block spammer@example.com spammers.example |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
40 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
41 unblock |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
42 ======= |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
43 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
44 ``unblock`` works the same way as ``block``. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
45 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
46 If you want to unblock all blocked users at once, you can use the ``all`` keyword. In this |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
47 case, you'll have to confirm the action. If you don't want to confirm manually, you can |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
48 use the ``-f, --force`` flag. |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
49 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
50 examples |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
51 -------- |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
52 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
53 Pierre wants to unblock the domain ``example.com`` that he has blocked earlier:: |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
54 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
55 $ li blocking unblock example.com |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
56 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
57 Élysée want to unblock all blocked users, without confirmation:: |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
58 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
59 $ li blocking unblock -f all |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
60 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
61 |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
62 .. _XEP-0191: https://xmpp.org/extensions/xep-0191.html |
665f060fbecb
doc (cli/blocking): `blocking` command documentation:
Goffi <goffi@goffi.org>
parents:
diff
changeset
|
63 .. _XEP-0191 § JID Matching: https://xmpp.org/extensions/xep-0191.html#matching |