Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update two tests to match changes made to Uptane's TUF fork #16

Merged
merged 1 commit into from
Jul 24, 2018

Conversation

awwad
Copy link
Owner

@awwad awwad commented Jul 24, 2018

test_repository_lib fix:
Some time ago in PR #5
I changed signature code such that tuf.keys.create_signature
and verify_signature accept already-encoded bytes instead of
assuming what the encodings should look like, and moved
encoding up a bit in the stack (often to tuf.sig). This
test wasn't updated at that point, and now it is being
updated to deal with this (by encoding first, then calling
the tuf.keys.create_signature function).

test_mix_and_match_attack fix:
A fix to the way that role files are retained if validation
fails (possibly from #13)
broke this test, I think, though I'm not certain. In any
event, this demonstrates passable behavior for now, with the
role info loaded correctly.

These tests in the TUF fork are not regarded as critical,
given that testing occurs at the Uptane level and Uptane will
be migrating to the main TUF repository when possible;
however, these fixes may be helpful in the interim.

test_repository_lib fix:
Some time ago in PR #5 #5
I changed signature code such that tuf.keys.create_signature
and verify_signature accept already-encoded bytes instead of
assuming what the encodings should look like, and moved
encoding up a bit in the stack (often to tuf.sig). This
test wasn't updated at that point, and now it is being
updated to deal with this (by encoding first, then calling
the tuf.keys.create_signature function).

test_mix_and_match_attack fix:
A fix to the way that role files are retained if validation
fails (possibly from #13 )
broke this test, I think, though I'm not certain. In any
event, this demonstrates passable behavior for now, with the
role info loaded correctly.

These tests in the TUF fork are not regarded as critical,
given that testing occurs at the Uptane level and Uptane will
be migrating to the main TUF repository when possible;
however, these fixes may be helpful in the interim.

Signed-off-by: Sebastien Awwad <sebastien.awwad@gmail.com>
@awwad
Copy link
Owner Author

awwad commented Jul 24, 2018

At this point, in JSON mode, almost all the old TUF tests in this repository work that are expected to work:

  • The interpose updater is not of use here, so it is not maintained and test_interpose_updater fails
  • developer_tool is not used and not maintained, so it fails
  • There's an issue remaining with test_key_revocation that I'll figure out.

Because DER data has not been added to all of the tests in DER mode at the level of this TUF repository, the tests don't all succeed in DER mode (failures: sig, slow retrieval, updater, key revocation, endless data attack, arbitrary package attack, mix and match, replay attack, repository lib, repository tool). Testing occurs at the level of the Uptane repository instead.

@awwad awwad merged commit 803fae4 into develop Jul 24, 2018
@awwad awwad deleted the fix_two_tests branch March 4, 2019 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant