Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bad word filters with 'escaped' parenthesis cause errors as of 1.8.18 #3461

Closed
bartico6 opened this issue Oct 3, 2018 · 2 comments · Fixed by #3489
Closed

Bad word filters with 'escaped' parenthesis cause errors as of 1.8.18 #3461

bartico6 opened this issue Oct 3, 2018 · 2 comments · Fixed by #3489
Labels
b:1.8 Branch: 1.8.x s:resolved Status: Resolved. Solution implemented or scheduled t:bug Type: Bug. An issue causing error / flaw / malfunction
Milestone

Comments

@bartico6
Copy link

bartico6 commented Oct 3, 2018

Filter: "\()"

Error: Warning [2] preg_replace(): Compilation failed: unmatched parentheses at offset 32 - Line: 659 - File: inc/class_parser.php

Filter: "(\)"

Error: Warning [2] preg_replace(): Compilation failed: missing ) at offset 7 - Line: 659

@bartico6 bartico6 changed the title Bad word filters with 'escaped' parenthesis cause errors as 1.8.19 Bad word filters with 'escaped' parenthesis cause errors as of 1.8.19 Oct 3, 2018
@bartico6 bartico6 changed the title Bad word filters with 'escaped' parenthesis cause errors as of 1.8.19 Bad word filters with 'escaped' parenthesis cause errors as of 1.8.18 Oct 3, 2018
@bartico6
Copy link
Author

bartico6 commented Oct 3, 2018

Appending: Before 1.8.18 filters with 'escaped' parenthesis worked fine.
The case for using those is certain variants of the lenny face which we filter out.
They worked fine until the update, updating caused the engine to spam regex errors all over the site.

I also fixed the wrong version "blame", it was 1.8.18 and not 1.8.19, since 1.8.19's diff suggests the inc/class_parser.php file was not touched at all.

@Eldenroot
Copy link
Contributor

@effone

Yes, there were some changes for bad words filter feature, good catch

@euantorano euantorano added t:bug Type: Bug. An issue causing error / flaw / malfunction b:1.8 Branch: 1.8.x labels Oct 15, 2018
@effone effone added this to the 1.8.20 milestone Nov 8, 2018
euantorano pushed a commit that referenced this issue Jan 5, 2019
* badword filter enhancement

* Filter bad words in text wrapped with url
@effone effone added the s:resolved Status: Resolved. Solution implemented or scheduled label Jan 6, 2019
lairdshaw pushed a commit to lairdshaw/mybb that referenced this issue Oct 11, 2021
[Rebased for 1.9 by Laird]

* badword filter enhancement

* Filter bad words in text wrapped with url
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
b:1.8 Branch: 1.8.x s:resolved Status: Resolved. Solution implemented or scheduled t:bug Type: Bug. An issue causing error / flaw / malfunction
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants