MangoCubes / remotrix

SMS <-> Matrix bridge for Android device. No Matrix admin access or additional server required.
Other
13 stars 0 forks source link

Setup guidance #18

Closed skug67 closed 1 year ago

skug67 commented 1 year ago

I'm very intrigued by this and would be interested in using it instead of the matrix-gmessages bridge (https://github.com/mautrix/gmessages) for both privacy reasons (the less info I have flowing through Google's servers the happier I am) and because honestly the Google Messages app isn't my favorite MMS/SMS interface on android.

But I haven't actually figured out how to get it set up. I had thought I'd need to set up a dedicated account to be the "manager" referred to when first installing the app and then enter the info for an existing user in the "Add A New Account" section in order to actually receive/send messages. But....

(a) I never get asked for authentication info for the "manager" (b) When I try to "Add a New Account" I get messages regardless of whether I use an existing user separate from the manager (in which case the error is a lack of permissions for setting up a child account in the management space) or whether I use the manager account itself (in which case the error is that the user is already in the room).

Additional guidance on setup would be greatly appreciated.

And thanks for heading down this path -- I'm sure it'll be a great app.

MangoCubes commented 1 year ago

Thank you for trying my app; I really appreciate it. To answer your questions:

  1. The manager account does not have to be dedicated. It just means who the bot reports to. This is why app never asks for authentication details for the manager; It just needs to invite the manager, and send messages to it. Whenever SMS arrives, bot invites manager into a room, and forwards it messages. Bot account does not have to be one either, but I recommend using a dedicated one for that. Both manager and bot should be created beforehand; The app does not do any registrations itself.
  2. Yes, the bot needs to be given permission to create child room in the management room. This can be done through the following steps i. Invite the bot before login in the Android app. ii. Give it permission. You can just give it admin if you can't be bothered, it should work. Note that Matrix allows you to give permission to the account that has been invited, but not yet joined, so you can do this.

Here is a video of me doing it. I hope this helps. ![Video]

Few notes about the video:

  1. You can see the warnings next to the message. They are not "Not encrypted" warnings; They indicate that the current session has not been verified. Messages are still encrypted, but the current session has not been verified. This happens only when some sessions of a user (in this case, testbot) are verified, but some are not.
  2. You might receive "Unable to decrypt messages" messages instead of actual data. This is unfortunately taking a while to fix. Workaround seems to be repeatedly leaving the management room, and re-inviting yourself. This option is available in Manage Accounts -> Vertical dropdown menu.

School has started for me, and I have limited time for personal projects. But I'll try my best to assist.

skug67 commented 1 year ago

Super helpful.  But I still have a follow-up question -- if I want the messages to appear in a new space for an existing user, do I just set that user as the "bot"?Sent from my iPadOn Oct 23, 2023, at 11:35 AM, MangoCubes @.***> wrote: Thank you for trying my app; I really appreciate it. To answer your questions:

The manager account does not have to be dedicated. It just means who the bot reports to. This is why app never asks for authentication details for the manager; It just needs to invite the manager, and send messages to it. Whenever SMS arrives, bot invites manager into a room, and forwards it messages. Bot account does not have to be one either, but I recommend using a dedicated one for that. Both manager and bot should be created beforehand; The app does not do any registrations itself. Yes, the bot needs to be given permission to create child room in the management room. This can be done through the following steps i. Invite the bot before login in the Android app. ii. Give it permission. You can just give it admin if you can't be bothered, it should work. Note that Matrix allows you to give permission to the account that has been invited, but not yet joined, so you can do this.

Here is a video of me doing it. I hope this helps. ![Video] Few notes about the video:

You can see the warnings next to the message. They are not "Not encrypted" warnings; They indicate that the current session has not been verified. Messages are still encrypted, but the current session has not been verified. You might receive "Unable to decrypt messages" messages instead of actual data. This is unfortunately taking a while to fix. Workaround seems to be repeatedly leaving the management room, and re-inviting yourself. This option is available in Manage Accounts -> Vertical dropdown menu.

School has started for me, and I have limited time for personal projects. But I'll try my best to assist.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

MangoCubes commented 1 year ago

I don't quite understand what you mean by that, sorry. The structure is quite fixed for now: Whenever a bot account is added to Remotrix, it creates its own dedicated space called "message space". In that space, the added bot account automatically creates a dedicated room for each SMS sender whenever a SMS message arrives. It does not create any room outside the message space (except for that one management room in the management space). The "message space" to "bot account" is 1-to-1. If you wish to show these messages to someone else, you can either:

  1. Invite someone to that message space, in which case they will see ALL SMS the bot forwards as they can join any room in that space
  2. Invite someone to one of the room in the message space. Each room in the message space is dedicated to conversation between you and one SMS sender.

Unfortunately, changing this would require quite a rework. If you can explain your use case, I'll look into it at the end of this term. Hope this helps.

skug67 commented 1 year ago

So, assume I've got an existing account I'll call "user." "user" is a member of various spaces and rooms. I'd like "user" to see all of the sms messages received by my phone and to be able to respond those messages via sms (even if "user" is not physically in possession of the phone at that moment, understand that the phone is connected both to the carrier network and the internet).

Should I use "user" as the management account? as the bot account? Or do I just add "user" as as yet a third member of bot's message space?

On 2023-10-23 12:28 pm, MangoCubes wrote:

I don't quite understand what you mean by that, sorry. The structure is quite fixed for now: Whenever a bot account is added to Remotrix, it creates its own dedicated space. In that space, the added account automatically creates a dedicated room for each sender whenever a SMS message arrives. It does not create any room outside the message space (except for that one management room in the management space). The "message space" to "bot account" is 1-to-1. If you wish to show these messages to someone else, you can either:

  • Invite someone to that message space, in which case they will see ALL SMS the bot forwards as they can join any room in that space
  • Invite someone to one of the room in the message space. Each room in the message space is dedicated to conversation between you and one receiver.

Hope this helps.

-- Reply to this email directly, view it on GitHub [1], or unsubscribe [2]. You are receiving this because you authored the thread.Message ID: @.***>

Links:

[1] https://github.com/MangoCubes/remotrix/issues/18#issuecomment-1775570747 [2] https://github.com/notifications/unsubscribe-auth/AB6X5QGVZWST7UXTJ4BQNULYA2LLJAVCNFSM6AAAAAA6K6IVCSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONZVGU3TANZUG4

MangoCubes commented 1 year ago

Ah, I see. I can recommend both adding them as the third member of the room, or having them as manager. If you have them as manager, they will be invited into the management room and subsequent messaging rooms automatically whenever you add a bot account. If you add them as normal user, they will not be automatically invited. Of course, you can manually join them, or just join the messaging space, in which case you can then join rooms inside it. The person that sends the messages and commands doesn't matter; the actions (such as !reload) are limited by whether they are in a room or not.

skug67 commented 1 year ago

Thanks. I got it set up and working. In the end, I think I'm going to stick w/the mautrix-gmessages bridge for a couple of reasons --

(1) E2EE -- for all that I'm a fan of security, I find the Matrix mechanism that makes you verify each session with another session very clunky and since I'm self-hosting my own server pretty much just for unified messaging (more or less trying to recreate/self-host beeper), I generally just go ahead and live w/o encryption to make keeping my history a lot easier. It seems like your app defaults (w/o a user configurable option) into using encrypted rooms. I totally get why, but it makes me lean against it.

(2) Messages all appear to show up as "from" the bot account. This is actually a bigger deal, because a lot of the messages I get on my phone are group texts. The mautrix-gmessages bridge actually shows which phone number/user has written a particular entry in a given group text.
Which is an important usability function. I got the sense that your app will not produce that result (although I haven't actually gotten a group text since I installed it, so perhaps I'm wrong and the functionality is there in some way I'm not seeing).

In any case, it's an impressive bit of programming and does a lot of what I'm looking to get done. But it seems like it's not quite a perfect match for my idiosyncratic needs.

Thanks again,

Seth

On 2023-10-23 12:43 pm, MangoCubes wrote:

Ah, I see. I can recommend both adding them as the third member of the room, or having them as manager. If you have them as manager, they will be invited into the management room automatically. The person that sends the commands doesn't matter; the action (such as !reload) is limited by whether they are in a room or not.

-- Reply to this email directly, view it on GitHub [1], or unsubscribe [2]. You are receiving this because you authored the thread.Message ID: @.***>

Links:

[1] https://github.com/MangoCubes/remotrix/issues/18#issuecomment-1775596506 [2] https://github.com/notifications/unsubscribe-auth/AB6X5QFE6NVHLR63NRXIMWDYA2NCVAVCNFSM6AAAAAA6K6IVCSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONZVGU4TMNJQGY

MangoCubes commented 1 year ago

Good to know it works for others too. Yeah, this app is primarily made for 1-to-1 conversations, and I have not done testing for group SMS chat. It's probably better for you to use that.