Skip to content

Commit 84c0fe0

Browse files
abeverleyflowerysong
authored andcommitted
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. trusteddomainproject/OpenARC#167
1 parent 32f0c95 commit 84c0fe0

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
@@ -2916,8 +2916,8 @@ arc_eoh(ARC_MESSAGE *msg)
29162916
return ARC_STAT_SYNTAX;
29172917
}
29182918

2919-
if ((msg->arc_mode & ARC_MODE_VERIFY) != 0 &&
2920-
msg->arc_cstate != ARC_CHAIN_FAIL)
2919+
/* need to verify previous sets even if running in sign mode */
2920+
if (msg->arc_cstate != ARC_CHAIN_FAIL)
29212921
{
29222922
status = arc_canon_runheaders_seal(msg);
29232923
if (status != ARC_STAT_OK)

0 commit comments

Comments
 (0)