Skip to content

Google Mail IMAP response with padding makes auth parse error #299

@Abdillah

Description

@Abdillah

Google responded to XOAUTH2 authentication with this base64 string with padding format (==),

S: + eyJzdGF0dXMiOiI0MDAiLCJzY2hlbWVzIjoiQmVhcmVyIiwic2NvcGUiOiJodHRwczovL21haWwuZ29vZ2xlLmNvbS8ifQ==

When I use online base64 tool, it reveals this text:

{"status":"400","schemes":"Bearer","scope":"https://mail.google.com/"}

The library unfortunately using base64::engine::general_purpose::STANDARD_NO_PAD that unable to parse the response and surfaced the error as error authenticating: Unable to parse authentication response.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions