Since the server restart yesterday, the Discord bridge has been kinda broken. Whenever someone would send a message from SAX, the bridge would edit a random message instead of sending a new one.

The bridge seems to be interpreting duplicate message IDs as a request to edit the message with that ID since the restart, regardless of whether the sender matches. Additionally, strophejs seems to be using a really dumb ID generator - it starts at 1 each time you load SAX and increases by 1 each time you call it. So, if you refresh the page or navigate to anywhere else on the forum, your message IDs restart from 1. As a result, SAX messages almost always replace an existing message on the Discord side of the bridge.

The easiest way to fix this would probably be to replace line 734 of saxjax.js (along with other calls to groupchat with:

Code:
connection.muc.groupchat(sax_room, text, null, Math.random())


However, this would still leave an issue with impersonation by allowing anyone with a custom XMPP client to edit the message of anyone else on Discord. I doubt anyone would exploit it, though, as there are easier ways to impersonate SAX users.
I've reported this upstream as a bug and rolled matterbridge back to a version that doesn't seem to do it.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement