Skip to content

Not following protocol specification for multiple macaroons #143

@gofeuer

Description

@gofeuer

The protocol specification here says that the macaroon portion of the authentication token, left side of : may contain multiple comma separated Macaroons.

Trying to send multiple comma separated macaroons will fail on line 72:

aperture/l402/header.go

Lines 70 to 76 in a308758

// Decode the content of the two parts of the header value.
macBase64, preimageHex := matches[2], matches[3]
macBytes, err := base64.StdEncoding.DecodeString(macBase64)
if err != nil {
return nil, lntypes.Preimage{}, fmt.Errorf("base64 "+
"decode of macaroon failed: %v", err)
}

I think this might actually be a specification problem and not a bug here.
Because what would be the use case for multiple macaroons to be passed to a request? They are all paid for my one invoice?

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