Skip to content
This repository was archived by the owner on Jan 14, 2022. It is now read-only.
This repository was archived by the owner on Jan 14, 2022. It is now read-only.

Base64 padding #4

Description

@emersion

The salmon spec defines the base64url encoding as follows:

The encoding used to convert between the MIME type and the "data" string. In this specification, encoding MUST be the string "base64url", indicating the url safe base64 encoding as described in RFC 4648 [RFC4648], sans any trailing padding with equals (=) characters, and with the additional whitespace normalization rules specified in Section 5.1. All implementations MUST support this encoding. Appears exactly once.

Mastodon is sending base64 data with padding = characters, and it shouldn't. You can set the padding parameter to false to solve this.

The decode_base64 hack is related to this: https://github.com/tootsuite/ostatus2/blob/master/lib/ostatus2/magic_key.rb#L12

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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