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

fix: fp when editing template-parts in gutenberg editor #49

Merged
merged 8 commits into from
Jun 28, 2024

Conversation

EsadCetiner
Copy link
Member

@EsadCetiner EsadCetiner commented Jun 27, 2024

Fixes false positives with the new gutenberg when editing template parts of a website, for instance the header or footer.

I couldn't figure out why the linter is failing, I can't find any trailing whitespace, missing/extra line breaks, and the error message is ambiguous. nvm I can see the error now after I've opened the PR.

@azurit
Copy link
Member

azurit commented Jun 27, 2024

Can you 'fix' tests?

  • we use "OWASP CRS test agent" as User-Agent for CRS (so we should do it also for plugins)
  • URI should start with endpoint /method (i.e. /post/...)
  • explicitly set protocol version using version: "HTTP/1.1"

Thanks.

@EsadCetiner
Copy link
Member Author

@azurit

Thanks, I missed that, cleaned up the tests a bit too.

@azurit
Copy link
Member

azurit commented Jun 28, 2024

@EsadCetiner Why have you decided to remove END-WORDPRESS-ADMIN hack?

@EsadCetiner
Copy link
Member Author

@azurit It caused a false positive, 9507600 is meant to apply unconditionally but it only apples for wp-admin because of the skip rule.

@azurit
Copy link
Member

azurit commented Jun 28, 2024

Then i suggest to move 9507600 out of that block (and renumber it if you feel it's needed).

@EsadCetiner EsadCetiner merged commit ab0ee24 into coreruleset:master Jun 28, 2024
3 checks passed
@EsadCetiner EsadCetiner deleted the fix-site-editor branch June 28, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants