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

We should sanitize the block id before using it in sql. #3

Open
georgestephanis opened this issue Oct 1, 2020 · 0 comments
Open

We should sanitize the block id before using it in sql. #3

georgestephanis opened this issue Oct 1, 2020 · 0 comments

Comments

@georgestephanis
Copy link

I know it's not a sqli issue, as we're previously verifying that is_numeric( $_GET['block_instances'] ) but just for code sniffing and explicitness, probably would be worth either casting as an (int) or passing through intval() inline here where we're using it:

$where .= ' AND post_content LIKE \'%<!-- wp:block {"ref":' . $_GET['block_instances'] . '}%\' ';

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

No branches or pull requests

1 participant