Problem/Motivation
A database error occurs when a malicious actor sets the token URL query parameter to a non-UTF8 value.
The \Drupal\access_unpublished\TokenGetter::setTokenFromRequest(0 sets the raw URL query parameter value for the token. This token value is then used to run a database query for the access_token entities in access_unpublished_entity_access. This can lead to database errors for non-UTF8 values.
Proposed resolution
Check if the request's token value is valid UTF-8.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | access_unpublished-3333429-2.patch | 923 bytes | recrit |
Issue fork access_unpublished-3333429
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
recrit commentedthe attached patch checks if the request query's value is UTF-8.
Comment #3
generalredneckThis seems important. But needs tests.
Comment #6
mably commentedCreated a merge request with the accompanying kernel test.
Comment #8
generalredneckthis was merged into 1.x-dev