Skip to content

Commit 7c51d3a

Browse files
committed
Fix existing sets not being included in seal
1 parent eb430db commit 7c51d3a

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

libopenarc/arc-canon.c

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2103,6 +2103,28 @@ arc_canon_add_to_seal(ARC_MESSAGE *msg)
21032103

21042104
sc = msg->arc_sealcanon;
21052105

2106+
/* This ARC Seal must include any existing ARC sets. Add those first */
2107+
for (u_int i = 0; i < msg->arc_nsets; i++)
2108+
{
2109+
hdr = msg->arc_sets[i].arcset_aar;
2110+
2111+
status = arc_canon_header(msg, msg->arc_sealcanon, hdr, TRUE);
2112+
if (status != ARC_STAT_OK)
2113+
return status;
2114+
2115+
hdr = msg->arc_sets[i].arcset_ams;
2116+
2117+
status = arc_canon_header(msg, msg->arc_sealcanon, hdr, TRUE);
2118+
if (status != ARC_STAT_OK)
2119+
return status;
2120+
2121+
hdr = msg->arc_sets[i].arcset_as;
2122+
2123+
status = arc_canon_header(msg, msg->arc_sealcanon, hdr, TRUE);
2124+
if (status != ARC_STAT_OK)
2125+
return status;
2126+
2127+
}
21062128
for (hdr = msg->arc_sealhead; hdr != NULL; hdr = hdr->hdr_next)
21072129
{
21082130
status = arc_canon_header(msg, msg->arc_sealcanon, hdr, TRUE);

0 commit comments

Comments
 (0)