Activate encryption #2
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Based on report by @collas22 on matrix
After the installation of maubot, you have to activate the encryption. To do this, you must first access the virtualenv
Then install all the dependencies to enable encryption in maubot.
Then it is better to disable the maubot service in order to configure the
config.yaml
file without problemsOnce this is done, just open the config.yaml file and change the
default
value in front of thecrypto_database
variable with the new value:sqlite:///crypto.db
.This change is important for the encryption to work properly, as there are problems with the database code working with sqlite. This way, as soon as the maubot service is restarted, the two databases
maubot.db
andcrypto.db
will be created automatically.But before restarting the service you have to delete the database
maubot.db
first in order to start again without errors.Now we can restart the maubot service and make sure that it works well
We can also see that the two databases
crypto.db
andmaubot.db
were created automatically when the service was launchedNow we have to authenticate on our maubot account that we created during the installation of maubot and that is accessible from its web-panel, but we will have to do it from the terminal with the
mbc
toolConnect to the panel with mbc :
Once the authentication is done, we will use the same tool again to connect to our user account (bot client) that we created on the Matrix homeserver, to generate a unique token code and a device-id in order to allow the bot to have full control over the client (It is important to do it from the terminal, not from a classic matrix client)
It is important that the user used has www-data rights, otherwise the authentication will not work.
Generate the token and the device ID by connecting with the matrix user:
If the authentication succeeds, and you have run
mbc auth
with the--update-client
option, then the token and device-id will be automatically implemented in the bot manager, and there is nothing else to do, otherwise you can always integrate them manually.If the procedure failed, then you have to start again with
mbc login
andmbc auth --update-client
.Another method using the curl tool, allows to obtain a token and a device-id by replacing
PASSWORD HERE
by the session password andHOMESERVER
by the matrix homserver used.If the operation fails, it is possible to generate the token and device-id with this command by filling in the values properly:
Now maubot should display the "E2EE device fingerprint" under the access token and the device ID when it works