Skip to content

Commit

Permalink
Remove add_restricted_paths from TUTORIAL.md and test_tutorial.py
Browse files Browse the repository at this point in the history
add_restricted_paths was renamed to add_path; however, this
function represents a problematic element of TUF that assumes
that roles are have a single delegator and delegatee, and that
one can refer to a role's expected keys without being concerned
about any delegation metadata....

So this is being removed from the tutorial. In time, add_paths
will either be removed or changed (to expect a delegator role
and a delegatee role, not just a delegatee role).

This comment does not do justice to the issue: please see TUF
GitHub Issue theupdateframework#660:
theupdateframework#660

Signed-off-by: Sebastien Awwad <sebastien.awwad@gmail.com>
  • Loading branch information
awwad authored and lukpueh committed Nov 19, 2019
1 parent 7c7d2f8 commit 9fc1f64
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 5 deletions.
2 changes: 0 additions & 2 deletions docs/TUTORIAL.md
Original file line number Diff line number Diff line change
Expand Up @@ -617,8 +617,6 @@ to some role.
>>> for delegation in repository.targets('unclaimed').delegations:
... delegation.load_signing_key(private_unclaimed_key)

# Delegated roles can be restricted to particular paths with add_restricted_paths().
>>> repository.targets('unclaimed').add_restricted_paths('repository/targets/myproject/*', 'django')
```

## How to Perform an Update ##
Expand Down
3 changes: 0 additions & 3 deletions tests/test_tutorial.py
Original file line number Diff line number Diff line change
Expand Up @@ -300,9 +300,6 @@ def test_tutorial(self):
for delegation in repository.targets('unclaimed').delegations:
delegation.load_signing_key(private_unclaimed_key)

repository.targets('unclaimed').add_restricted_paths(
'repository/targets/myproject/*', 'django')



# ----- Tutorial Section: How to Perform an Update
Expand Down

0 comments on commit 9fc1f64

Please sign in to comment.