From 7b2c8f5d66245aea79cd6912f3664f8d6f7d20cf Mon Sep 17 00:00:00 2001 From: Martin Vrachev Date: Wed, 29 Jun 2022 14:47:52 +0300 Subject: [PATCH] Fix comment about SuccinctRoles zero-padding Signed-off-by: Martin Vrachev --- tuf/api/metadata.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tuf/api/metadata.py b/tuf/api/metadata.py index 072ee1ff61..24f78b4557 100644 --- a/tuf/api/metadata.py +++ b/tuf/api/metadata.py @@ -1495,8 +1495,8 @@ def __init__( self.name_prefix = name_prefix # Calculate the suffix_len value based on the total number of bins in - # hex. If bit_length = 8 then number_of_bins = 256 or 100 in hex - # and suffix_len = 3 meaning the third bin will have a suffix of "003" + # hex. If bit_length = 10 then number_of_bins = 1024 or "3ff" in hex + # and suffix_len = 2 meaning the third bin will have a suffix of "003". self.number_of_bins = 2**bit_length # suffix_len is calculated based on "number_of_bins - 1" as the name # of the last bin contains the number "number_of_bins -1" as a suffix.