Skip to content

Commit 2093e7a

Browse files
committed
Fix invalid ARC-Seal when email contains existing sets
This fixes a bug whereby existing sets were not being included in a signature and thus the signature was invalid. This was only happening when Mode was undefined (default value) or only signing. This meant that the code to verify existing sets was never executed. This commit removes the check for running the previous-set verification function, to ensure that it is run regardless (if there are no previous sets then arc_canon_runheaders_seal() is basically a no-op anyway.
1 parent eb430db commit 2093e7a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libopenarc/arc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2912,8 +2912,8 @@ arc_eoh(ARC_MESSAGE *msg)
29122912
return ARC_STAT_SYNTAX;
29132913
}
29142914

2915-
if ((msg->arc_mode & ARC_MODE_VERIFY) != 0 &&
2916-
msg->arc_cstate != ARC_CHAIN_FAIL)
2915+
/* need to verify previous sets even if running in sign mode */
2916+
if (msg->arc_cstate != ARC_CHAIN_FAIL)
29172917
{
29182918
status = arc_canon_runheaders_seal(msg);
29192919
if (status != ARC_STAT_OK)

0 commit comments

Comments
 (0)