|
Post by Brownie on Apr 23, 2024 21:08:06 GMT -5
I just recently encountered this bug with a few users' posts and thought I'd open a thread for it. When quoting posts, the inner text is eaten. a random </div> tag is added to the end of the quote. From Wither's name raterjust now on ShineClan's discussion pageI've been doing a bit of troubleshooting, because I hadn't had any issues quoting posts for my own name rater throughout the day, and I think I've found out why some posts quote fine and others don't: ALL THIS IS LIES, it's def the special characters causing the bug, I cannot recreate the bug with any other users that do not contain a <
so long as there is a line break, you can quote no problem. But if the comment is a single line/paragraph, it will break with the above bug. (I'll post a single-line comment beneath this one, then a double, and others can test this with other threads too).
That being said, I still haven't really isolated what is causing the bug. Still working on that. But I thought I'd bring it up? idk it's a fun puzzle.
Some notes: I've only ever seen this happen today, since this morning. I'll see if I can find any earlier instances, but the oldest occurrence I've encountered so far was 7hrs ago (at the time of this thread's creation)
I originally thought it had to do with special characters in some users' names, but was able to recreate the bug by quoting my own posts, and also was able to successfully quote posts from the same users on posts that contained a line break This is back on the table, as I cannot cause my own posts or other users' posts to break, but those with special characters continue to break following the above pattern.
I still hold that this is caused by something reading the plaintext as a div with an invalid range. But there is no start <div> present in any of the misquoted text's code.
The quote appears as normal in preview, but breaks when posting or moving to the BBCode tab
|
|
|
Post by Brownie on Apr 23, 2024 21:10:18 GMT -5
A single line of text. This should break if you try and quote it
|
|
|
Post by Brownie on Apr 23, 2024 21:10:40 GMT -5
and this one has a line break
see there's more text and a space
this one should be fine to quote
|
|
|
Post by Brownie on Apr 23, 2024 21:11:16 GMT -5
testing a weird case with a line break via shift click (aka not technically a line break in html)
test
|
|
|
Post by Brownie on Apr 23, 2024 21:11:30 GMT -5
A single line of text. This should break if you try and quote it it doesn't break?
|
|
|
Post by mintedstar/fur on Apr 23, 2024 22:30:40 GMT -5
I'll admit, I don't know. o.o Sand ? Got any ideas?
|
|
|
Post by Sand on Apr 24, 2024 3:16:31 GMT -5
A single line of text. This should break if you try and quote it it doesn't break? Testing
|
|
|
Post by Sand on Apr 24, 2024 3:20:21 GMT -5
I'll admit, I don't know. o.o Sand ? Got any ideas? I don’t know if I have seen this issue before. I’ve seen one that was similar a long time ago when you’d quote a post and random string of code would get rid of the quote tags. Felix. Do you think I should ask pb or do you know more?
|
|
|
Post by Felix on Apr 24, 2024 11:20:51 GMT -5
Strange, I'll have a look and see if it's something we've done
|
|
|
Post by Brownie on Apr 24, 2024 12:43:59 GMT -5
< testing
|
|
|
Post by Brownie on Apr 24, 2024 12:47:07 GMT -5
hm yeah idk.
I do stand by it's having < in a username, though I don't know why the plaintext would matter; in the code of the actual quote, it uses only post ID and user tag, which shouldn't trigger any weird code autocorrects. and if it was a plaintext trigger, then why only in the username field and not the text response? because it is internal to the [quote ] tag?
lmao kind of proving my point xp (it even autocorrected with a space in there crazy)(doesn't with the no break space tho)
BBCode will auto-finish any end syntax needed if it sees the start syntax. And it would delete anything inside an empty div if it doesn't follow the correct syntax, which explains the deletion of the quotes... but there isn't any start syntax in the broken quote (even autofilled) it's just [quote.] USER ID USER @[/quote.]</div> which is weird. Also weird that it reverts back to html <> instead of BBCode [].... maybe an issue with something on the CSS side? but that doesn't really explain autofilled HTML either. Or why it defaulted to HTML instead of translating to BBCode
the more I think about it, the more it's probably on Proboard's implementation of HTML-BBCode conversion
|
|
|
Post by Brownie on Apr 24, 2024 12:57:31 GMT -5
<div style="font-size:16px;">testing</div>
<div>test
yeah it doesn't try and eat or autocorrect in plaintext. Huh even flopping between the BBCode and preview no change
it must be an order of operations thing, that it's trying to do HTML conversions before the post even makes it to preview, but that also doesn't totally explain why the text is intact in the preview screen in the broken examples.
|
|
|
Post by Felix on Apr 24, 2024 19:04:48 GMT -5
I managed to reproduce it, it's quite strange. Switching between the modes causes more and more </div> to be added. It definitely looks like an XSS mitigation going a bit wild.
I think I need to check on a plain proboards site to make sure it's not one of the plugins having a strange interaction.
|
|
|
Post by mintedstar/fur on Apr 24, 2024 20:11:21 GMT -5
It would always happen with one of my friends who had < > in the name, we just learned not to quote her. XD But I was never able to figure out why it happened.
|
|