Skip to content

Commit

Permalink
arg check overflow
Browse files Browse the repository at this point in the history
  • Loading branch information
b-wagn committed Oct 13, 2023
1 parent e92d44a commit 64c1b51
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/modules/schnorrsig/main_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,7 @@ int secp256k1_schnorrsig_inc_aggregate(const secp256k1_context *ctx, unsigned ch

/* Check that aggsig_size is large enough, i.e. aggsig_size >= 32*(n+1) */
n = n_before + n_new;
ARG_CHECK(n >= n_before);
if ((*aggsig_size / 32) <= 0 || ((*aggsig_size / 32)-1) < n) {
return 0;
}
Expand Down

0 comments on commit 64c1b51

Please sign in to comment.