Skip to content

Base64 error since v10.0.2 #449

@maciek-szn

Description

@maciek-szn

Since updating to version 10.0.2, I can't send notifications to my subscribers. They fail with the following error. This is most likely a result of pull request #438, which replaced spomky-labs/base64url with web-token/jwt-library. It appears this change isn't backward compatible. Downgrading to 10.0.1 resolved the issue.

RangeException: Base64::decode() only expects characters in the correct base64 alphabet in /[...]/vendor/web-token/jwt-library/Core/Util/Base64UrlSafe.php:153
Stack trace:
#0 /[...]/vendor/minishlink/web-push/src/Encryption.php(79): Jose\Component\Core\Util\Base64UrlSafe::decode()
#1 /[...]/vendor/minishlink/web-push/src/Encryption.php(57): Minishlink\WebPush\Encryption::deterministicEncrypt()
#2 /[...]/vendor/minishlink/web-push/src/WebPush.php(252): Minishlink\WebPush\Encryption::encrypt()
#3 /[...]/vendor/minishlink/web-push/src/WebPush.php(148): Minishlink\WebPush\WebPush->prepare()
#4 [internal function]: Minishlink\WebPush\WebPush->flush()
#5 /[...]/vendor/minishlink/web-push/src/WebPush.php(118): Generator->current()
#6 /[...]/app/NotificationChannels/WebPush/WebPushChannel.php(29): Minishlink\WebPush\WebPush->sendOneNotification()

[...]

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