Fixed stripBbCode does not correctly handle bbcode with _ in the name

Xon

Well-known member
Affected version
2.1.3
In \XF\Str\Formatter::stripBbCode lines 743 & 768 the regex fragment [a-z0-9]+ is used to match a bb-code tag, while in line 729 [a-z0-9_]+ is used. Other bb-code tag validation allows _
 
Thank you for reporting this issue. It has now been resolved and we are aiming to include it in a future XF release (2.1.4).

Change log:
Standardize on `\w` for BB code tag matching, rather than a mishmash of `[a-z0-9]` and `[a-z0-9_]`
Any changes made as a result of this issue being resolved may not be rolled out here until later.
 
Top Bottom