Page MenuHomePhabricator

Catchable fatal error: Argument 3 to hash_hmac() must be of type ?string, bool given in /srv/mediawiki/php-master/includes/utils/MWCryptHash.php on line 108
Closed, ResolvedPublicPRODUCTION ERROR

Description

I see a lot of these in the logs for the beta cluster:

Feb 9 07:19:58 deployment-mediawiki01: #012Catchable fatal error: Argument 3 to hash_hmac() must be of type ?string, bool given in /srv/mediawiki/php-master/includes/utils/MWCryptHash.php on line 108
Feb 9 07:20:09 deployment-mediawiki02: message repeated 6 times: [ #012Catchable fatal error: Argument 3 to hash_hmac() must be of type ?string, bool given in /srv/mediawiki/php-master/includes/utils/MWCryptHash.php on line 108]

Event Timeline

aude raised the priority of this task from to Needs Triage.
aude updated the task description. (Show Details)
aude subscribed.

if this helps finding the cause, on commons.wikimedia.beta.wmflabs.org I'm seeing this, or a similiar error in the response body when calling the API via OAuth "Argument 3 to hash_hmac() must be of type ?string, bool given"

Does not seem to affect production (at least with the reproduction steps given in T130611), even though the same code should be live on group0 now.

Change 279413 had a related patch set uploaded (by Gergő Tisza):
Throw an exception when the $key argument to hash_hmac is not a string

https://gerrit.wikimedia.org/r/279413

Change 279413 merged by jenkins-bot:
Throw an exception when the $key argument to hash_hmac is not a string

https://gerrit.wikimedia.org/r/279413

Tgr claimed this task.

Fixed per T130611#2150001.

mmodell changed the subtype of this task from "Task" to "Production Error".Aug 28 2019, 11:11 PM