How exactly does the JITSI "replace participant" feature work

Greetings!

I was hoping to get an understanding of how exactly the “replace participant” functionality works. Does it replace a participant if an another one joins or does it replace an existing meeting participant if a new participant were to provide the exact same auth credentials (password/username or JWT)?

I’ve been trying to look for some documentation on the same, and haven’t found anything yet. Any pointers/answers/documentation would be greatly appreciated.

Thank you.

err, did I just wake up from a thousand year slumber ? I have never read anything about such functionality. You are asking for doc, but where did you read/heard about that ?

Line 176

It’s not a general feature, it means that a user try to access first as an anonymous user, this fails because it’s a secure domain, and then it’s replaced by the authenticated version. I was surprised because what you are thinking it is has been asked for on a Github issue and got a reserved answer (it would be nice but it’s complicated…)

 * Will try to join the conference again in case it failed earlier with
 * {@link JitsiConferenceErrors.AUTHENTICATION_REQUIRED}. It means that Jicofo
 * did not allow to create new room from anonymous domain, but it can be tried
 * again later in case authenticated user created it in the meantime.
(...)
        const replaceParticipant = getReplaceParticipant(getState());

I was going through the change log of when this feature was added

If you see the description - "feat(replace-participant): Replace participant with same jwt in the conf ", the meaning conveyed is along the lines of my initial query.

you seem to be correct, it’s a feature hidden in plain sight. The only indication of usefulness seem to be in the original tree for the pull-request: ‘flip-device’. So based on the name, I’d say that if you join a meeting from a PC, disconnect, and reconnect with your phone with the same jwt, you’d be reconnected as the same user (possibly to get back the chat history ? - although I can’t see how it could work for private messages, or how you could keep the local changes such as display name). If you check it out, I’d be interested to know if you have found it useful.

Fascinating, I remember the discussion on GH about this and it looks like the functionality might already be (partially) there. Going to test this out…

@damencho - while I understand and appreciate that your time is spread thin going over multiple queries, I would be really grateful if you can let me know your thoughts on the “replace participant” feature in JITSI.

Thank you!

Hi. You are correct, the idea was to have the option to switch devices without leaving the meeting. In order for this to work, it needs a prosody plugin that will have a hook on the pre-join event and it will check if the presence has a special tag(e.g flip_device) and if the id from the JWT of the participant that joined is the same with the id of somebody from the meeting. If that is the case the first participant will be kicked. You will also have to bypass lobby or password and do some validation for any malicious users.

In other words, it’s not ready for general consumption. Maybe the new password whitelist module committed in task: mod_muc_password_whitelist prosody module (#11184) · jitsi/jitsi-meet@be45413 · GitHub is another step in this direction.

Thanks!