Opened 12 years ago
Closed 12 years ago
#29542 closed defect (bug) (fixed)
hash_equals throws a fatal error (hhvm) when a nonce is sent as an integer
| Reported by: | newleaves | Owned by: | |
|---|---|---|---|
| Priority: | low | Milestone: | 4.1 |
| Component: | Plugins | Version: | 4.0 |
| Severity: | normal | Keywords: | has-patch needs-testing |
| Cc: | Focuses: |
Description
This is a follow-up to #29217.
can we add:
$nonce = (string) $nonce;
to the top of the wp_verify_nonce() function in /wp-includes/pluggable.php
Attachments (2)
Change History (9)
#1
@
12 years ago
- Keywords needs-patch needs-unit-tests added
- Milestone Awaiting Review → 4.1
- Priority normal → low
#2
@
12 years ago
- Keywords has-patch needs-testing added; needs-patch needs-unit-tests removed
Patch 29542.diff's unit test would error on PHP 5.6 without the type cast.
#3
follow-up:
↓ 6
@
12 years ago
We can likely revert [29620/trunk/src] in the process.
#4
@
12 years ago
Patch 29542.2.diff reverts [29620/trunk/src]. Now null becomes a string "null".
I think that shouldn't be a problem.
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Type cast
$nonceto string. Includes unit tests.