When trying to load a TUF repo with delegated targets, if a delegated role has a longer configuration file than the targets.json it will be unable to be loaded.
In the load_targets function, the max_targets_length variable is changed to the actual length of the targets metadata -
|
let (max_targets_size, specifier) = match targets_meta.length { |
That updated max_targets_size is then passed when loading delegated roles -
When trying to load a TUF repo with delegated targets, if a delegated role has a longer configuration file than the
targets.jsonit will be unable to be loaded.In the
load_targetsfunction, themax_targets_lengthvariable is changed to the actual length of the targets metadata -tough/tough/src/lib.rs
Line 1200 in c0d27ad
That updated
max_targets_sizeis then passed when loading delegated roles -tough/tough/src/lib.rs
Line 1266 in c0d27ad