Skip to content

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

@georgestephanis

Description

@georgestephanis

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'] . '}%\' ';

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions