Skip to content

Commit

Permalink
Reject resume data if it contains mismatching info hashes
Browse files Browse the repository at this point in the history
  • Loading branch information
glassez committed Jan 30, 2024
1 parent 44598ba commit 352ea7e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/read_resume_data.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,11 @@ namespace {
{
ec = err;
}
else if (((ret.info_hashes.has_v1() && ret.info_hashes.v1 != ret.ti->info_hashes().v1)
|| (ret.info_hashes.has_v2() && ret.info_hashes.v2 != ret.ti->info_hashes().v2)))
{
ec = errors::mismatching_info_hash;
}
else
{
// time_t might be 32 bit if we're unlucky, but there isn't
Expand Down

0 comments on commit 352ea7e

Please sign in to comment.