Skip to content

authres: parse() function can't get correct quoted-string value #32

@anhdowastaken

Description

@anhdowastaken

Arcoding to https://tools.ietf.org/html/rfc8601:

     reasonspec = "reason" [CFWS] "=" [CFWS] value
                ; a free-form comment on the reason the given result
                ; was returned
   The "value" is as defined in Section 5.1 of [MIME], with
   "quoted-string" updated as specified in [RFC6532].

For example:

var parseTests = []msgauthTest{
...
	{
		value: "example.com;" +
			"dkim=pass reason=\"good signature\" header.i=@mail-router.example.net;",
		identifier: "example.com",
		results: []Result{
			&DKIMResult{Value: ResultPass, Reason: "good signature", Identifier: "@mail-router.example.net"},
		},
	},
}

Instead of good signature, value of Reason is "good.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions