Commit graph

716 commits

Author SHA1 Message Date
Vladimir Diaz
aa62fc5862 Verify the 'repository_name' argument in test_clear_keydb() 2016-05-09 15:10:42 -04:00
Vladimir Diaz
decfa5558e Expand test conditions in test_keydb.py to verify named repositories 2016-05-09 14:19:53 -04:00
Vladimir Diaz
223993c43e Update test_keydb.py following refactoring of keydb.py
keydb.py was refactored to allow multiple sets of keys to be tracked
2016-05-06 17:33:18 -04:00
Vladimir Diaz
9d85b5f4b1 Update test_roledb.py following refactoring of roledb.py
refactored roledb.py to keep track of multiple sets of role info.
2016-05-06 16:54:45 -04:00
Vladimir Diaz
e3a1544070 Begin implementation changes to address issue with a global role and key database 2016-05-06 12:13:57 -04:00
Vladimir Diaz
d09d3a0678 Address Issue #332. Add test cases for the remaining roles of test_key_revocation.py 2016-04-28 11:00:57 -04:00
Vladimir Diaz
09163247b6 Initial integration test for key revocations 2016-04-28 09:02:58 -04:00
Vladimir Diaz
a8a8b13864 Initial changes for prepended digests and version numbers 2016-04-28 08:57:07 -04:00
Vladimir Diaz
e27371113f Update developer tool 2016-04-14 16:53:48 -04:00
Vladimir Diaz
f2c3e09bf2 Fix remaining issues with previous implementation of _update_metadata_via_fileinfo() 2016-04-14 11:22:13 -04:00
Vladimir Diaz
3f42feba31 Add functions to update and detect fileinfo changes for root and snapshot 2016-04-14 09:08:57 -04:00
Vladimir Diaz
b8ce4bbfcd Implement changes to write and load the new format of snapshot.json
The repository tools should properly write and load consistent versions of root.json and snapshot.json.  Version numbers were previously prepended to these two roles.
2016-04-14 08:13:50 -04:00
Vladimir Diaz
c0958f11f2 Modify repository data to use new snapshot format
snapshot.json should list the hash(es) of root metadata, rather than version number
2016-04-14 08:11:34 -04:00
Vladimir Diaz
22b42e97b5 Remove obsolete method: refresh_targets_metadata_chain() 2016-04-06 10:54:45 -04:00
Vladimir Diaz
18844f6453 Initial refactor of developer tool 2016-04-05 20:23:37 -04:00
Vladimir Diaz
90d0d5c49a Fix remaining updater.py test failures 2016-04-05 20:12:31 -04:00
Vladimir Diaz
b0c86cacb4 Remove test condition for tuf.ForbiddenTargetError exception (has been removed) 2016-03-31 17:29:38 -04:00
Vladimir Diaz
efc01f0007 Remove obsolete functions tested in test_roledb.py 2016-03-31 17:24:57 -04:00
Vladimir Diaz
09f6261b4a Specify correct number of arguments for modified _visit_child_role() 2016-03-31 13:26:06 -04:00
Vladimir Diaz
f162b4b7e8 Update test_roledb following the changes to remove_delegated_roles() 2016-03-30 17:24:11 -04:00
Vladimir Diaz
aaf755e381 Delete remove_delegated_roles() and modify affected lines (including add_role())
We shouldn't remove delegated roles if the repository can resemble a graph of delegations, since the delegations of one role are independent of another
2016-03-30 16:43:51 -04:00
Vladimir Diaz
c20c83b3ff Remove parent 'targets' directory from role1.json paths 2016-03-29 15:35:20 -04:00
Vladimir Diaz
9536cacdee Fix bug where the snapshot and timestamp roles are listed in snapshot.json 2016-03-29 15:28:18 -04:00
Vladimir Diaz
28e738ed8c Repository data that contains the correct number of delegated roles in snapshot.json 2016-03-28 17:51:43 -04:00
Vladimir Diaz
51adc771a0 More bug fixes
When loading roles from disk, ensure these roles are not marked as dirty.  Add a boolean to relevant functions to provide the option to update the roledb without marking roles as dirty
2016-03-28 17:49:56 -04:00
Vladimir Diaz
f47cdb04d2 Remove 'targets' directory from path in 'test_extraneous_dependencies_attack.py
and fixes in repository_tool.py
2016-03-28 16:30:35 -04:00
Vladimir Diaz
8ccdff540f Convert list of dirty roles to set to avoid duplicates 2016-03-28 16:25:49 -04:00
Vladimir Diaz
283c62abe0 More unit test fixes
A delegated rolename is no longer required to start with 'targets'
2016-03-25 11:59:11 -04:00
Vladimir Diaz
9c0064e39d Fix remaining issues with add_target_to_bin() and remove_target_from_bin() 2016-03-24 13:55:44 -04:00
Vladimir Diaz
251bbaa93c Remove full name for hashed bin delegation, update comment, and remove outdated test condition 2016-03-24 13:16:43 -04:00
Vladimir Diaz
b982c063db Latest WIP 2016-03-22 11:26:55 -04:00
Vladimir Diaz
b4626f172a Merge branch 'develop' of github.com:theupdateframework/tuf into remaining-1.0-tasks 2016-03-17 12:23:51 -04:00
Vladimir Diaz
dd8a7eb0dd Review test_indefinite_freeze_attack.py and updater.py. Minor edits made 2016-03-17 11:36:11 -04:00
Sebastien Awwad
1ee1f92a4d
added clarifying comments to repo and key loading 2016-03-16 14:27:40 -04:00
Sebastien Awwad
4d8732bee8
removing unnecessary loading of root keys in test 2016-03-16 14:23:58 -04:00
Sebastien Awwad
9137986301
Removing superstitious 0.1s sleeps. 2016-03-16 14:14:26 -04:00
Sebastien Awwad
893911614a
fixing minor comment wording 2016-03-16 11:54:18 -04:00
Sebastien Awwad
85a7502603
- Tweaked the sleep durations to be more minimal, based on time that had passed. (updater.refresh() can take a while.)
- Put code back into working state after some failure mode debugging of a separate bug by Vlad and me.
- Expanded some comments, added explanations, and made a few others more readable.
- Removed an unnecessary path recalculation and an unnecessary sleep.
2016-03-16 11:50:11 -04:00
Sebastien Awwad
ab4cbdde52
guaranteed test failure: unprintable on 3, printable on 2 2016-03-14 18:08:24 -04:00
Sebastien Awwad
fee25a44cd
sharing bug with Vlad 2016-03-14 17:39:04 -04:00
Sebastien Awwad
8250223207
removed unnecessary temp variable reload line; switched names of Test 1 and Test 2 2016-03-14 16:30:12 -04:00
Sebastien Awwad
08e005330a
Minor log message improvements. 2016-03-14 15:51:58 -04:00
Sebastien Awwad
6a4982fa8a
Improving comments in test_indefinite_freeze_attack 2016-03-14 12:59:46 -04:00
Sebastien Awwad
0fa4518929 comment improvement in indefinite freeze attack test 2016-03-11 17:01:35 -05:00
Sebastien Awwad
66f56271d2 This is a manual squash commit of detect_expiry_322, to avoid merge conflicts.
Comment lines from the individual commits include:
1. Fix #322 by detecting expiry of stale files. initial attempt
2. temp commit of files from Soma
3. removing freeze_attack_stale_expiry and leaving the test added to indefinite freeze attack
4. fixing indefinite freeze attack test: now incorporates old reject-freshly-downloaded-but-expired-timestamp test as well as reject-stale-already-present-but-expired-snapshot test
5. small refinements to indefinite freeze attack test
6. Pulled the recursion out of the except block in refresh() to avoid unprintable nested exceptions.
7. Added comments to the last commit (retry_once)
8. Merge pull request #1 from awwad/detect_expiry_322_temp (removing cruft in another branch)
2016-03-10 15:01:12 -05:00
Vladimir Diaz
a111661a72 Fix roledb.get_delegated_roles() and test cases in test_repository_tool.py 2016-03-02 13:08:46 -05:00
Vladimir Diaz
6611efbf09 Add the new delegation structure to repository_data 2016-03-02 12:03:39 -05:00
Vladimir Diaz
c6ffcf0d83 Update the unit tests for _versioninfo_has_been_updated() (to use the renamed function) 2016-02-26 13:35:37 -05:00
Vladimir Diaz
55f1a5bad3 Merge branch 'develop' of github.com:theupdateframework/tuf into 1.0-review 2016-01-27 17:11:16 -05:00
Vladimir Diaz
f38d99ab27 Add the new path to the SSL certificate used for testing 2016-01-27 16:35:23 -05:00
Vladimir Diaz
5ce17a3945 Add the newly-generated SSL cert and key to simple_https_server.py 2016-01-27 16:32:59 -05:00
Vladimir Diaz
dfbdc5aaea Add SSL certificate and key used to test https connections 2016-01-27 16:31:33 -05:00
Vladimir Diaz
1f06c656ea Remove certificates used to test https connections 2016-01-27 16:30:52 -05:00
Vladimir Diaz
50a65e56ba Merge branch 'develop' of github.com:theupdateframework/tuf into test_https_connection 2016-01-26 15:26:45 -05:00
Vladimir Diaz
b50960a056 Update the test case for create_rsa_signature()
Verify that ValueError is now raised
2016-01-25 11:42:15 -05:00
Vladimir Diaz
284e8008a4 Fix comment for generate_rsa_public_and_private test case
The incorrect comment  was previously written for PyCrypto.  Also remove a call to generate_rsa_public_and_private(2050) that is actually valid under pyca/cryptography
2016-01-21 16:57:42 -05:00
Vladimir Diaz
ddec8ab44a Update aggregate_tests.py
Decrease the verbosity of the test runner so that only test failures are shown.
2016-01-21 13:25:58 -05:00
Vladimir Diaz
c45ce4f060 Merge branch 'develop' of https://github.com/theupdateframework/tuf into test_https_connection 2016-01-21 11:12:22 -05:00
Vladimir Diaz
25ba4001c2 Merge branch 'develop' of https://github.com/theupdateframework/tuf into develop 2016-01-20 10:52:26 -05:00
Vladimir Diaz
cb687b4c2f Import tuf.log in test_init and fix logger name. Issue #303.
In PR #307, tuf.log is no longer imported by __init__.py.  Add an import statement for tuf.log to fix missing handler warning in 'test_init.py.  The logger name specified is also incorrect.
2016-01-20 10:29:58 -05:00
Vladimir Diaz
47cae502fa Allow users to specify the path (via conf.py) to save log files 2016-01-14 17:25:08 -05:00
David Halls
c859eeb258 Address code review comments 2016-01-13 23:02:17 +00:00
Vladimir Diaz
b5f7a1aa8d Review test_updater.py 2015-10-28 14:26:49 -04:00
Vladimir Diaz
fab23480b3 Review 'test_repository_lib.py' 2015-10-28 11:45:01 -04:00
Vladimir Diaz
7bf14b3bc4 Review 'test_replay_attack' 2015-10-27 17:24:57 -04:00
Vladimir Diaz
2541276320 Review 'test_mix_and_match_attack.py 2015-10-27 17:22:14 -04:00
Vladimir Diaz
25d98780fb Review 'test_extraneous_dependencies_attack.py' 2015-10-27 17:15:46 -04:00
Vladimir Diaz
0912495b2b Review 'test_formats.py' 2015-10-27 16:55:51 -04:00
Vladimir Diaz
4cb851ca0a Fix remaining issues with unit tests after implementing version numbers in snapshot.json 2015-10-27 16:11:11 -04:00
Vladimir Diaz
987411ff04 Resolve remaining issues with writing / loading the new changes 2015-10-20 09:16:39 -04:00
Vladimir Diaz
14ca0d1565 Update the repository test data following the addition of the 'compression algorithms' key in root.json 2015-10-20 09:14:21 -04:00
Vladimir Diaz
d993ccf35e Generate a repository for the unit tests that contains the changes to the snapshot role 2015-10-15 09:53:54 -04:00
Vladimir Diaz
7bbdd87117 Update the unit test for updater.py after implementing versioninfo 2015-10-15 09:52:14 -04:00
Vladimir Diaz
3fc1e59000 Initial implementation of stored version numbers in snapshot.json 2015-09-22 07:31:30 -04:00
Vladimir Diaz
e9b2271e6d Check the format of 'data' arguments in pycrypto_keys.py 2015-08-31 15:33:51 -04:00
Vladimir Diaz
398555f32e Review edits up to create_rsa_encrypted_pem().
Add checks against invalid 'data' arguments in relevant functions.
2015-08-28 17:24:57 -04:00
Vladimir Diaz
bc0ba6b8d8 Add whitespace for readability 2015-08-26 17:31:21 -04:00
Vladimir Diaz
116f3b335b Remove incorrectly loaded 'snapshot' key in test case 2015-08-26 11:09:30 -04:00
Vladimir Diaz
97d6f5edb8 Remove status() checks used during debugging 2015-08-26 11:08:18 -04:00
Vladimir Diaz
6cbebc0606 Temporarily disable check for non-string arguments to the rsa signature methods
TODO: Modify these functions to check for non-string arguments.
2015-08-26 11:07:30 -04:00
Vladimir Diaz
115b2d2bce Ensure the PSS defaults used by PyCrypto match those set with pyca/cryptography's 2015-08-05 14:51:27 -04:00
Vladimir Diaz
b2132e3c72 Support enryption + decryption with pyca/cryptography 2015-07-30 10:19:44 -04:00
Vladimir Diaz
af85746713 Support for pyca/cryptography 2015-07-21 10:16:20 -04:00
Vladimir Diaz
7a07179279 Fix shebang statment in unit test module 2015-06-02 10:31:03 -04:00
Vladimir Diaz
47471db40f Add import statements for unvendored dependencies in the unit tests 2015-06-02 10:28:02 -04:00
Vladimir Diaz
1c8f41b0c0 Update import statements of unvendored dependencies 2015-06-02 08:29:22 -04:00
Vladimir Diaz
6b0d060c48 Update test_util.py
Remove print statements.
2015-05-04 23:52:20 -04:00
Vladimir Diaz
2f49561aa4 Protect against timing attacks when comparing digests
Thank you Marcin W. for spotting this.
2015-05-04 23:07:52 -04:00
Vladimir Diaz
16685d2ff3 Add configuration option for supported URI schemes
Support only 'http' and 'https' by default.  Thanks Marcin W.
2015-05-04 15:34:22 -04:00
Vladimir Diaz
d9e3ce4ce1 Expand comment for incomplete test case (testing consistent snapshots) in test_updater.py 2015-04-27 20:25:52 -04:00
Vladimir Diaz
c97d9a022d Force build failure if any of the unit tests fail 2015-04-27 18:32:09 -04:00
Vladimir Diaz
230920f74e Minor code coverage improvement to updater.py 2015-04-27 18:30:55 -04:00
Vladimir Diaz
98df2014b6 Fix minors issues with strings and remove print statements 2015-04-06 21:29:21 -04:00
Vladimir Diaz
110c8a196b Improve code coverage for updater.py 2015-04-06 20:05:41 -04:00
Vladimir Diaz
75eb79534c Improve code coverage for repository_lib.py 2015-04-03 13:46:43 -04:00
Vladimir Diaz
3293745d05 Improve code coverage for repository_tool.py 2015-04-02 16:38:18 -04:00
Vladimir Diaz
003847e73f Improve code coverage for download.py 2015-04-02 16:37:47 -04:00
Vladimir Diaz
23083fae12 Improve code coverage for repository_lib.py 2015-04-02 16:37:11 -04:00
Vladimir Diaz
55e9e952b6 Improve code coverage for pycrypto_keys.py 2015-04-02 16:35:45 -04:00
Vladimir Diaz
f6b5927238 Improve code coverage for util.py 2015-04-02 16:34:52 -04:00
Vladimir Diaz
afd8bfd390 Improve code coverage for log.py 2015-04-02 16:33:39 -04:00
Vladimir Diaz
7e8cd6a56d Add test module for tuf exceptions 2015-04-02 16:33:06 -04:00
Vladimir Diaz
3eb8f10710 More coverage improvements 2015-03-02 15:10:27 -05:00
Vladimir Diaz
b7cf7e6588 Improve each module's code coverage to at least 90%
Update unit tests for download.py, repository_lib.py, repository_tool.py, and updater.py.
Re-generate repository data so that compressed metadata may be tested.
2015-02-11 13:22:46 -05:00
Vladimir Diaz
fc80976fc4 Remove extraneous closing parenthesis 2015-02-06 14:51:57 -05:00
Vladimir Diaz
623820c6ac Cosmetic edits to test_interpose_updater.py 2015-02-05 15:24:43 -05:00
Vladimir Diaz
90a283d589 Add initial Python 2+3 compatibility 2015-02-04 17:45:24 -05:00
Vladimir Diaz
4c4286cc63 Merge branch 'develop' of https://github.com/Pankh/tuf into Pankh-develop 2014-12-15 12:54:33 -05:00
Pankh
f6e0fecf07 Add header to test_interpose_updater 2014-10-22 14:44:31 -04:00
Pankh
b843684aee To merge the updates of Master branch 2014-09-29 14:45:24 -04:00
Pankh
7f64aad061 Test cases for tuf.interposition.updater with 98% coverage 2014-09-29 14:34:11 -04:00
Vladimir Diaz
3c9b1d0068 Add missed test coverage for updater.py's init().
Add test condition for missing previous directory in init().
2014-09-02 14:46:36 -04:00
Vladimir Diaz
419b1ca85e Log debug message for roles that are skipped in util.find_delegated_role(). 2014-08-20 12:27:06 -04:00
Vladimir Diaz
30f551131f Update test_keys.py
Strip PEM footer and reorder PEM header / footer test conditions.
2014-07-19 08:52:57 -04:00
vladdd
3fd6839c2b Add test case for keys.formats_rsakey_from_pem()
Add test_formats_rsakey_from_pem() test case and test conditions for improperly formatted PEM.
Add test condition to verify trailing whitespace is removed and matches the expected PEM format generated
internally.  Public PEMs generated externally (with the expected trailing newline) was not previously considered.
2014-07-18 15:24:10 -04:00
vladdd
20d5a6b3e4 Fix self.assertTrue() conditions in test_updater.py
A few test conditions in test_updater.py incorrectly used self.assertTrue() instead of self.assertEqual().
Fix updater.remove_obsolete_targets(), where targets in the destination directory were not being removed because target paths were treated as absolute paths by os.path.join().
2014-07-06 22:25:20 -04:00
Vladimir Diaz
aefb0172cf Merge pull request #233 from vladimir-v-diaz/meskio-filepath
Review and Update Pull Request #232
2014-07-04 18:09:44 -04:00
vladdd
9cf9a6a8b5 Review and update Pull Request #232.
Fix test conditions for updated_targets(), which incorrectly verified the expected number of updated targets with assertTrue().

Update comment for PR fix to clarify os.path.join() behavior and the expected file paths.
2014-07-04 17:50:22 -04:00
Vladimir Diaz
1985c450c9 Merge custom info changes, logger messages, and minor edits. 2014-07-02 11:10:50 -04:00
Vladimir Diaz
59b45fdfe5 Merge branch 'SantiagoTorres-developer-tools' of https://github.com/vladimir-v-diaz/tuf into develop 2014-07-01 07:47:47 -04:00
vladdd
2f520dd140 Review and update pull request #188. 2014-06-30 14:04:01 -04:00
vladdd
fde19957a4 Merge branch 'developer-tools' of https://github.com/SantiagoTorres/tuf into SantiagoTorres-developer-tools 2014-06-30 07:10:56 -04:00
Vladimir Diaz
5d766d3d6f Review and update docstrings and README. 2014-06-25 09:45:55 -04:00
Vladimir Diaz
528e33dd77 Add test condition for custom data in test_updater.py.
The updater client may reference target information (including 'custom') by accessing the dictionary returned by updater.py.

Example:
target = updater.target('LICENSE.txt')
target['filepath']
target['fileinfo']['length']
target['fileinfo']['hashes']
target['fileinfo']['custom']
2014-06-24 10:31:05 -04:00
Vladimir Diaz
337c9f9ffc Regenerate '/tests/repository_data/' to include example of custom data. 2014-06-24 10:17:14 -04:00
Vladimir Diaz
f6a9b7fc58 Verify that generated Targets metadata can contain custom data. 2014-06-24 09:38:47 -04:00
Vladimir Diaz
d5c56e550d Add test condition for repository_tool.Target().add_target() custom data. 2014-06-24 08:58:29 -04:00
vladdd
88d686b258 Initial implementation of custom FILEINFO 2014-06-23 13:33:01 -04:00
Santiago Torres
26eb5b7e35 Added relative filepath support and increased coverage
After seeing the coveralls report I realized the projects were not
relocatable. While this might be convenient for some uses, moving a
project from one place to another might not be optimal. This has been
changed now.

The only place where absolute filepaths are handled now is with flat
project layouts. However, it is possible to overwrite this filepath if
the targets folder is to be changed.
2014-06-21 19:07:34 -04:00
Santiago Torres
f9ce4fcb36 Added the test_developer_tool module
All of the neccessary test cases for the developer tool
2014-06-20 19:39:11 -04:00
Santiago Torres
07e8ef0be7 Added the generate_repository_data.py script and its produce
The generate_repository_data script works in the exact same way as the
generate script and it generates a fresh batch of pre-signed metadata to
test the load_project function.
2014-06-20 19:36:42 -04:00
Vladimir Diaz
c0a61e14e0 Add test coverage for repository_lib._log_status_of_top_level_roles().
Verify that status() does not raise 'tuf.InsufficientKeysError' nor 'tuf.UnsignedMetadataError'.
2014-06-19 11:24:07 -04:00
Vladimir Diaz
b105c7853c Add test condition for repository_lib.create_tuf_client_directory().
Verify that non-OSError.EEXist exceptions are re-raised.
2014-06-19 09:50:20 -04:00
Vladimir Diaz
882871ccfc Add missing test case for remove_target_from_bin(). 2014-06-18 12:39:39 -04:00
Vladimir Diaz
49a3a4990b Fix comment / typo in unsafe_download() test condition 2014-06-18 09:06:49 -04:00
Vladimir Diaz
a57c97749a Fix test_download.py comments for the test case dealing with incorrect file lengths. 2014-06-17 13:45:42 -04:00
Vladimir Diaz
6dafddc10f Add test case for https connection. 2014-06-17 10:28:56 -04:00
Vladimir Diaz
9d087389a9 Add the simple https server module. 2014-06-17 10:25:16 -04:00
Vladimir Diaz
e83045f162 Add self-signed certificates to be used by simple_https_server.py 2014-06-17 10:20:57 -04:00
vladdd
f0ac659110 Move optparse import statement.
Organize import statements of standard Python and TUF modules into separate blocks.
2014-06-16 13:11:35 -04:00
Santiago Torres
5a097faaf8 Added switches to the generate script
Added two switches to the generate script:

  -k (or --keys), which forces the creation of new keys.
  -d (or --dry-run), which skips the actual writing or copying phases

The second option might be useful in the future, and helped me debug the
optparse module, so I left it there.
2014-06-13 15:33:07 -04:00
Vladimir Diaz
e4c98d38ba Add missing test cases for download.py and and updater.py. 2014-06-12 09:33:12 -04:00
Vladimir Diaz
0c6b360952 Add missing test conditions for test_repository_lib.py and minor edits to modules. 2014-06-11 11:29:00 -04:00
Vladimir Diaz
74c0120ed4 Increase sleep time after starting simple server in integration tests. 2014-06-10 09:26:09 -04:00
vladdd
9e0392bb80 Add missing test coverage for pycrypto_keys.py. 2014-06-08 22:16:43 -04:00
vladdd
744be00cbc Initial implementation of authoritative delegations. 2014-06-07 20:29:18 -04:00
vladdd
19c69487b0 Merge branch 'develop' of https://github.com/vladimir-v-diaz/tuf into develop 2014-06-06 18:57:32 -04:00
vladdd
17b230abdd Support Python 2.6. 2014-06-06 18:57:23 -04:00
Vladimir Diaz
1c1cd0f192 Update / fix remaining Python 2 + 3 doctests.
Remove test_slow_retrieval_attack.py print statements.
2014-06-06 08:37:31 -04:00
Vladimir Diaz
0e9a1de4b1 Merge branch 'develop' of https://github.com/vladimir-v-diaz/tuf into develop 2014-06-06 07:33:11 -04:00
Vladimir Diaz
091cfe9aeb Increase sleep time after starting simple server in affected tests. 2014-06-06 07:32:03 -04:00
vladdd
21bbbedbb8 Fix test_util.py test case failure in py2.7. 2014-06-05 19:09:45 -04:00
Vladimir Diaz
797bab5ddc Fix Python 2 + 3 JSON consistency issue and re-generate repository data.
Explicitly specify the JSON separators for Python 2 + 3 consistency.
2014-06-05 11:17:30 -04:00
Vladimir Diaz
66f4b88ef2 Update repository tool diagram and coverage.
Fix text box alignment in diagram.
Omit coverage of repository tool prompt and getpass.
Minor coverage update.
2014-06-03 14:59:56 -04:00
Vladimir Diaz
fbb10a36c9 Refactor repository_tool.py and improve test coverage.
Created repository_lib.py.
2014-06-03 14:32:44 -04:00
Vladimir Diaz
80ad012bc3 Re-generate repository data. 2014-06-03 14:28:46 -04:00
Vladimir Diaz
65f30a7bd8 Improve test coverage.
Update unit tests for pycrypto_keys, schema, ed25519_keys, and affected modules.
2014-05-30 12:47:33 -04:00
Vladimir Diaz
dc167e4a27 Address Python 3.2 byte-string compatibility issues. 2014-05-29 12:59:36 -04:00
Vladimir Diaz
71b1d38c1b Update slow retrieval server and fix integration tests.
Update the slow retrieval server, integration tests, and the download module to address issues with unexpected exceptions and bytes.
2014-05-28 12:11:31 -04:00
vladdd
6b8b2399a2 Finish unit tests for Python2 + 3 support.
All unit tests updated / running for Python 2 + 3.
TODO: Fix non-Python 3 issue with util.py.
2014-05-27 13:55:48 -04:00
vladdd
bc99524e2b Finish initial refactor of slow retrieval attack. 2014-05-13 12:53:50 -04:00
vladdd
e4bd9a7ba2 [WIP] Refactor download.py 2014-05-11 22:59:42 -04:00
vladdd
c5fd17ab3e Merge branch 'develop' of https://github.com/theupdateframework/tuf into develop
Conflicts:
	tests/test_hash.py
	tests/test_keydb.py
	tuf/formats.py
	tuf/keydb.py
	tuf/repository_tool.py
2014-05-10 20:26:06 -04:00
Vladimir Diaz
8684253675 [WIP] Python 2+3.
Mostly unicode-related changes for crypto modules.
2014-05-06 15:24:39 -04:00
Santiago Torres
84d676192f Updated test case for the expiration setter (microseconds truncation)
The new test tries to make the fact that the datetime object given will
contain microseconds. It also tests for the fact that the microseconds
value is truncated after being set.
2014-05-05 11:10:40 -04:00
Santiago Torres
1d5c9a00f6 Updated test case for the expiration setter
The test case for the expiration setter now includes a set case in which
the microseconds value is forced to be one. This is likely to happen
when users try to set expirations using datetime.datetime.today() or
functions that return the actual clock, which have microsecond
resolution.
2014-05-03 12:11:10 -04:00
Vladimir Diaz
718b3df8b6 Improve test coverage.
Add missing 'test_log.py' [WIP]
2014-05-01 13:00:43 -04:00
Vladimir Diaz
d831187949 Improve test coverage. 2014-05-01 12:59:34 -04:00
Vladimir Diaz
a8406604d7 Implement add_target_to_bin(), outlined in Issue #180. 2014-04-30 12:46:37 -04:00
Vladimir Diaz
ab95a4b3aa [WIP] Python 2+3 support.
Python 2+3 unicode.
libraries.
The following modules (and their tests) work in PY2.7+3.3:
keydb, hash, formats, mirrors
2014-04-29 14:27:34 -04:00
Vladimir Diaz
e23b4e5eae Merge branch 'develop' of https://github.com/theupdateframework/tuf into develop
Conflicts:
	tuf/__init__.py
	tuf/client/updater.py
2014-04-29 08:31:29 -04:00
vladdd
5d3664e5a4 [WIP] Python 2+3 support.
maxint and minor additions.
2014-04-28 23:21:16 -04:00
vladdd
1e360846bf Reject expired metadata without loading.
Reject downloaded metadata as early as possible.  The top-level roles were all downloaded as a group and then their
expiration inspected.  All metadata provided by a mirror that has already expired is discarded immediately and the next mirror tried.  The update process stops if a requested role cannot be successfully validated, or one of its parents.

[2014-04-29 02:00:32,308 UTC] [tuf.download] [INFO] [_download_file:745@download.py]
Downloading: http://localhost:8001/metadata/timestamp.json

[2014-04-29 02:00:32,324 UTC] [tuf.download] [INFO] [_check_downloaded_length:676@download.py]
Downloaded 544 bytes out of an upper limit of 16384 bytes.

[2014-04-29 02:00:32,324 UTC] [tuf.client.updater] [INFO] [_get_file:1189@updater.py]
Not decompressing http://localhost:8001/metadata/timestamp.json

[2014-04-29 02:00:32,331 UTC] [tuf.download] [INFO] [_download_file:745@download.py]
Downloading: http://localhost:8001/metadata/snapshot.json

[2014-04-29 02:00:32,333 UTC] [tuf.download] [INFO] [_check_downloaded_length:654@download.py]
Downloaded 1003 bytes out of the expected 1003 bytes.

[2014-04-29 02:00:32,334 UTC] [tuf.client.updater] [INFO] [_get_file:1189@updater.py]
Not decompressing http://localhost:8001/metadata/snapshot.json

[2014-04-29 02:00:32,334 UTC] [tuf.client.updater] [INFO] [_check_hashes:696@updater.py]
The file's sha256 hash is correct: 5b3aec7cf295a25e4b39d875c7474511da9645bc6d27f9e86fb7e439c82e0ec7

[2014-04-29 02:00:32,335 UTC] [tuf.client.updater] [ERROR] [_ensure_not_expired:1789@updater.py]
Metadata 'snapshot' expired on Tue Apr 29 01:59:01 2014 (UTC).

Do not request, download, and install top-level roles if the root of trust has already expired after the inital load. If requested, update an expired root role:

[2014-04-29 01:18:02,457 UTC] [tuf.client.updater] [ERROR] [_ensure_not_expired:1789@updater.py]
Metadata 'root' expired on Mon Apr 28 23:23:57 2014 (UTC).

[2014-04-29 01:18:02,458 UTC] [tuf.client.updater] [INFO] [refresh:628@updater.py]
Expired Root metadata was loaded from disk.  Try to update it now.

[2014-04-29 01:18:02,458 UTC] [tuf.download] [INFO] [_download_file:745@download.py]
Downloading: http://localhost:8001/metadata/root.json

[2014-04-29 01:18:02,461 UTC] [tuf.download] [INFO] [_check_downloaded_length:676@download.py]
Downloaded 1198 bytes out of an upper limit of 512000 bytes.

[2014-04-29 01:18:02,461 UTC] [tuf.client.updater] [INFO] [_get_file:1189@updater.py]
Not decompressing http://localhost:8001/metadata/root.json

[2014-04-29 01:18:02,462 UTC] [tuf.client.updater] [ERROR] [_ensure_not_expired:1789@updater.py]
Metadata 'root' expired on Mon Apr 28 23:23:57 2014 (UTC).

Note: An expired 'root' was provided by the server.  The requested root must also be signed by keys trusted by the client.
2014-04-28 22:31:42 -04:00
Vladimir Diaz
7843bdd272 [WIP] Python 2+3 support.
Add six, convert PY <=2.5 exception handling, dictionary iteration, libraries, remaining 7/8 test modules.
2014-04-23 12:50:05 -04:00
Vladimir Diaz
a7f28b9af4 [WIP] Python 2+3 support.
Add six, convert PY <=2.5 exception handling, dictionary iteration, libraries, 1/2 the tests.
2014-04-22 15:03:42 -04:00
vladdd
e0864ee3ab Update slow retrieval server and attack.
Ensure the target file used in the slow retrieval attack is larger than tuf.conf.SLOW_START_GRACE_PERIOD.  The previous size of the test file might have led to inconsistent triggering of a slow retrieval error.
2014-04-21 05:34:16 -04:00
vladdd
60cfb7e054 Edit aggregate_tests.py comment. 2014-04-20 16:19:56 -04:00
vladdd
08a2bad2c0 Add Travis CI, coveralls, and coverage-related updates. 2014-04-20 16:15:19 -04:00
vladdd
5f94d5be0d Support ISO 8601, vendor iso8601, clean codebase. 2014-04-19 14:27:53 -04:00
Vladimir Diaz
fa37cffd54 Update the integration tests affected by the change to the 'expires' format. 2014-04-15 12:54:27 -04:00
Vladimir Diaz
b6cd82d75c Update the unit tests affected by the change to the 'expires' format. 2014-04-15 12:53:46 -04:00
Vladimir Diaz
25e800a59c Re-generate 'tests/repository_data' to include metadata unix timestamps. 2014-04-15 12:43:12 -04:00
vladdd
6a4c82cc81 Finish test case for write(). 2014-04-11 07:35:02 -04:00
Vladimir Diaz
19bc1f326e [WIP] Add test case for repository.write(). 2014-04-10 12:59:42 -04:00
Vladimir Diaz
e018c76c1e Finish test cases for the methods of Targets(). 2014-04-10 11:34:40 -04:00
Vladimir Diaz
666bb7ba9e Update repository_tool.py.
Add remaining test cases for the methods of repository_tool.Metadata().
Add test case for repository_tool.Repository.get_filepaths_in_directory().
2014-04-09 12:43:31 -04:00
Vladimir Diaz
81c2748859 Add test cases (skeleton) for remaining methods of test_repository_tool.py. 2014-04-08 15:19:40 -04:00
Vladimir Diaz
af8d2fb98e Finish remaining test cases for repository_tool.py functions. 2014-04-08 14:56:39 -04:00
Vladimir Diaz
4ad679062f Continue updating test_repository_tool.py.
Add test cases for the generate_*_metadata() functions.
2014-04-08 12:31:06 -04:00
vladdd
0f3cdd9f61 Continue updating test_repository_tool.py.
Add test cases for the crypto funtions (e.g., generate_and_write_ed25519_keypair()).
Add test case for get_metadata_filenames().
Add test case for get_metadata_fileinfo().
Add setUpClass() and tearDownClass().
Update affected functions that failed testing, and any that needed modifying (such as util.py).
2014-04-07 20:21:39 -04:00
vladdd
ddd8b6bfd0 Add test_repository_tool.py
Add 'test_repository_tool.py' (initial incomplete commit)
Add test cases for the top-level metadata objects (Root(), Targets(), etc.)
Add test case for Repository()
Add test case for get_target_hash()
Minor update to 'repository_tool.py': add default rolename for Targets() and call tuf.util.get_target_hash() in the
repository tool's get_target_hash()
2014-04-07 15:28:46 -04:00
vladdd
5755207fae Refactor test_extraneous_dependencies_attack.py.
Refactored to use the 'unittest' module (test conditions in code, rather
than verifying text output), use pre-generated repository files, and
discontinue use of the old repository tools.  Modify the previous scenario
simulated for the mix-and-match attack.  The metadata that specified the
dependencies of a project modified (previously a text file.)
2014-04-06 21:28:42 -04:00
vladdd
75a7124bb1 Refactor test_mix_and_match_attack.py.
Refactored to use the 'unittest' module (test conditions in code, rather
than verifying text output), use pre-generated repository files, and
discontinue use of the old repository tools.  Modify the previous scenario
simulated for the mix-and-match attack.
2014-04-06 16:17:14 -04:00
vladdd
714df40e2d Refactor test_slow_retrieval_server.py.
Refactored to use the 'unittest' module (test conditions in code, rather
than verifying text output), use pre-generated repository files, and
discontinue use of the old repository tools. Expanded comments and modified
previous setup.

Minor edits to slow_retrieval_server.py.

Add missing else clauses (to detect when TUF fails to prevent an attack) for a couple of the integrations tests.
2014-04-05 21:21:10 -04:00
vladdd
ba19cd7b72 Refactor test_replay_attack.py.
Refactored to use the 'unittest' module (test conditions in code, rather
than verifying text output), use pre-generated repository files, and
discontinue use of the old repository tools. Expanded comments.
2014-04-05 15:27:27 -04:00
Vladimir Diaz
9d2a5e2927 Minor edit to comment in test_indefinite_freeze_attack.py. 2014-04-03 12:35:16 -04:00
Vladimir Diaz
053e2b0ebe Update test_indefinite_freeze_attack.py
Minor edit to comment.
Disable console log messages enabled by the repository tool, which this unit tests needs.
Sleep for at least 1 minute before checking for an expired metadata error, and ensure the function supplied to self.assertraises() is a callable.
2014-04-03 12:30:43 -04:00
Vladimir Diaz
b52194cdf4 Refactor test_endless_data_attack.py
Refactored 'test_endless_data_attack.py' to use the 'unittest' module (test
conditions in code, rather than verifying text output), use pre-generated
repository files, and discontinue use of the old repository tools. Minor
edits to the test cases.
2014-04-03 11:59:50 -04:00
Vladimir Diaz
63afb1e99f Re-add repository data for the tests. 2014-04-03 08:52:16 -04:00
Vladimir Diaz
c44c7de280 Merge branch 'develop' of https://github.com/theupdateframework/tuf into refactor_test_indefinite_freeze_attack 2014-04-03 08:48:57 -04:00
Vladimir Diaz
6f7ac62ac4 Resolve Merge. 2014-04-03 08:32:45 -04:00
Vladimir Diaz
685187eae1 Remove old 'tuf/tests/unit/test_repository' directory. 2014-04-03 08:19:29 -04:00
Vladimir Diaz
2112816f97 Merge pull request #192 from vladimir-v-diaz/refactor_test_arbitrary_package_attacks
Refactor test_arbitrary_package_attack.
2014-04-03 08:15:52 -04:00
Vladimir Diaz
92905345e4 Minor edits to comments. 2014-04-02 11:50:48 -04:00
Vladimir Diaz
1ca98367d6 Initial refactor of test_indefinite_freeze_attack.py 2014-04-01 15:30:59 -04:00
Vladimir Diaz
b7047f7ea2 Edit comments and minor code cleanup.
Edit test_arbitrary_package_attack.py
2014-04-01 08:33:23 -04:00
Vladimir Diaz
8d1ef5bbfc Merge branch 'add_test_cases_to_test_util' of https://github.com/vladimir-v-diaz/tuf into add_test_cases_to_test_util 2014-04-01 07:42:07 -04:00
vladdd
55941d7551 Refactor test_arbitrary_package_attack.
Refactored to use the 'unittest' module (test conditions in code, rather
than verifying text output), use pre-generated repository files, and
discontinue use of the old repository tools.  Fix for issue #111.
2014-03-31 18:28:54 -04:00
vladdd
68d3b5c1e1 Move repository data to 'tuf/tests/repository_data' 2014-03-31 17:29:53 -04:00
vladdd
dfa19b221e Add missing test cases to test_util.py.
Add missing test cases for the following functions:
get_target_hash()
find_delegated_role()
paths_are_consistent_with_hash_prefixes()
ensure_all_targets_allowed()

Add test condition to test_B6_load_json_string().
2014-03-22 14:47:24 -04:00
vladdd
d28311b8ec Remove obsolete helper functions.
Minor edits to comments.
2014-03-18 20:59:36 -04:00
vladdd
ef9922ebe9 Finish refactor of test_updater.py.
test_updater.py now uses repository_tool.py to update the remote repository as needed, and no longer depends on mocking and repository_setup.py.
2014-03-18 12:59:03 -04:00
Vladimir Diaz
eaee52e14e [WIP] Refactor test_updater.py
Continue refactoring the test cases of test_updater.py.
Fix issue where repository_tool.py was not writing new compressed metadata.
Minor edits to TUF modules.
2014-03-13 12:31:36 -04:00
Vladimir Diaz
5e7713a93f [WIP] Refactor test_updater.py and repository_setup.py.
Add generate.py script and pre-generated repository files used by Unit tests (replacing repository_setup.py).
Refactor test_updater.py (10 test cases remaining).
2014-03-11 09:08:53 -04:00
vladdd
2d015797ef Update affected ed25519 modules.
Update modules affected by the changes made to the latest versions of pyca-ed25519 and pyca-pynacl:
Do not use the unsafe key and signature generation functions of pure python ed25519, but do support the signature verification routine.  Developers must use the faster and secure pynacl+libsodium to generate ed25519 keys and signatures.

Temporarily suppress pynacl's import warning error.

Minor edits to comments and code.
2014-03-07 23:21:54 -05:00
vladdd
75c7ea5138 Update test_extraneous_dependencies_attack.py.
Remove text inserted and improperly removed from a previous merge conflict.
2014-02-03 12:45:17 -05:00
vladdd
a22099699e Resolve remaining unit test failures.
Update the remaining unit tests following the many design changes.  The unit tests should next be factored to use repository_tool.py, avoid pseudo repositories and repository objects, monkey patching, etc.
2014-01-31 14:47:48 -05:00
Vladimir Diaz
7b27fcec64 Continue unit test updates. 2014-01-30 13:06:33 -05:00
Vladimir Diaz
36b59f922e Continue updating unit tests and modify ROOT_SCHEMA. 2014-01-30 08:11:35 -05:00
Vladimir Diaz
009ddd9f37 Rename top-level role and functions of repository_tool.py. Update documentation and diagram.
add_key() -> add_verification_key()
remove_key() -> remove_verification_key()
release.json -> snapshot.json
Update repository_tool-diagram.png
Update README following the renamed functions and release role changes.
Minor edits, such as removing lint left over from a previous merge conflict.
2014-01-29 11:26:56 -05:00
Vladimir Diaz
3b5e0c0814 Merge 'develop' and resolve conflicts. 2014-01-27 13:35:11 -05:00
Vladimir Diaz
d380997b75 Minor edits, merge, and resolve conflicts. 2014-01-27 13:15:03 -05:00
zanefisher
43eb5633c4 Modify test code following review from Vladimir 2014-01-07 14:20:20 -05:00
Vladimir Diaz
c58906f9c2 Fix for issue #153
Update the key modules and their unit tests so that only the signature scheme is included in the signature label.

PyCrypto-PKCS#1 PSS -> RSASSA-PSS
ed25519-python and ed25519-pynacl -> ed25519
2013-11-27 12:11:16 -05:00
Vladimir Diaz
191f32aa74 Continue refactor of libtuf.py 2013-11-25 15:01:27 -05:00
Vladimir
3ca6261f79 Merge and resolve conflicts 2013-11-15 10:09:59 -05:00
vladdd
45af91191a Update docstrings and comments in keys.py
Configurable crypto changes previously implemented but the docstrings and comments of keys.py still needed updating.  Minor edit to test_keys.py and a note added about a missing test case.
2013-10-18 14:01:51 -04:00
vladdd
760cd62d4e Rename functions in keys.py and update test_keys.py
create_in_metadata_format --> format_keyval_to_metadata
create_from_metadata_format --> format_metadata_to_key
2013-10-17 14:05:26 -04:00
vladdd
05f7826b59 Update test_pycrypto_keys.py after pycrypto_keys.py changes 2013-10-17 13:01:32 -04:00
vladdd
76d7796c4e Merge branch 'develop' of https://github.com/theupdateframework/tuf into integration-tests-python3 2013-10-14 09:36:29 -04:00
vladdd
dc84e051e6 Update the valid expiration data 2013-10-14 09:20:49 -04:00
vladdd
7e593963a9 Complete test_verify_signature() in test_ed25519_keys.py 2013-10-14 08:41:38 -04:00
vladdd
7e948f342c Add initial test_ed25519_keys.py
test_verify_signature() incomplete.
2013-10-11 13:01:46 -04:00
vladdd
81a15147b2 Add remaining test cases in test_pycrypto_keys.py 2013-10-11 10:15:09 -04:00
vladdd
2f61272c28 Update test cases moved over to test_pycrypto_keys.py
test cases updated with configurable crypto changes.
2013-10-11 09:07:25 -04:00
vladdd
ac6dade0dc Move test cases to test_pycrypto_keys.py 2013-10-10 14:56:56 -04:00
vladdd
a091b1f84b Add test_keys.py and update keys.py 2013-10-10 14:01:55 -04:00
vladdd
31d603c710 Update all unit tests affected by configurable crypto
Add separate 'tuf.conf.py' options for key types.
2013-10-10 12:19:46 -04:00
zanefisher
c941eda8d2 Changes following Santiago\'s review. 2013-10-04 14:00:36 -04:00
zanefisher
0b9d2e223f Python 3 compatibility for arbitrary package and etraneous dependency tests. 2013-10-02 13:03:52 -04:00
zanefisher
b2ac2e82f2 Remove unnecessary import from extraneous dependencies test. 2013-09-30 14:52:37 -04:00
zanefisher
eca682a58a Add case for BadSignatureError to arbitrary package and extraneous dependencies tests. 2013-09-30 13:20:09 -04:00
vladdd
e848dac0f3 test_slow_retrieval_attack.py: Python 3 compatability
Fixed indentation and outdated comment.
2013-09-23 21:23:26 -04:00
vladdd
fc08f5181b test_replay_attack.py: Python 3 compatability
Also fix indentation.
2013-09-23 21:18:52 -04:00
vladdd
f62ed3a019 test_mix_and_match_attack.py: Python 3 compatability 2013-09-23 21:16:55 -04:00
vladdd
7c882b70c7 test_indefinite_freeze_attack.py: Python 3 compatability 2013-09-23 21:13:34 -04:00
vladdd
2f32ea9424 test_extraneous_dependencies_attack.py: python 3 compatability
Also fix print statements.
2013-09-23 21:07:35 -04:00
vladdd
67b886d5e0 test_endless_data_attack.py: Fix indentation
Also help with Python 3 compatability.
2013-09-23 21:02:17 -04:00
vladdd
3f41b96f7f Fix extraneous new lines in test_delegations.py 2013-09-23 20:55:34 -04:00
vladdd
0a94661d99 Fix print statements and help with python 3 compatability
test_arbitrary_package_attack.py.
2013-09-23 20:52:16 -04:00
vladdd
7d691011e5 Resolve conflicts from demo 2 updates 2013-09-23 13:38:18 -04:00
dachshund
d9e952ef5b Fix replay attack integration test.
Merge remote-tracking branch 'origin/demo2' into demo2

Conflicts:
	tests/integration/test_replay_attack.py
2013-09-17 23:02:17 -04:00
dachshund
b0e328be53 Fix replay attack integration test.
Merge remote-tracking branch 'origin/demo2' into demo2

Conflicts:
	tests/integration/test_replay_attack.py
2013-09-17 23:02:17 -04:00
dachshund
7eb834ab84 Fix replay attack integration test. 2013-09-17 22:59:26 -04:00
dachshund
4e42a091a2 Fix replay attack integration test. 2013-09-17 22:59:26 -04:00
vladdd
c2689280b0 Resolve merge conflicts 2013-09-17 21:10:51 -04:00
vladdd
b17b53112c Resolve merge conflicts 2013-09-17 21:10:51 -04:00
vladdd
ac2e7b5e15 Merge branch 'demo2' of https://github.com/theupdateframework/tuf into demo2 2013-09-17 20:23:11 -04:00
vladdd
81831b861e Merge branch 'demo2' of https://github.com/theupdateframework/tuf into demo2 2013-09-17 20:23:11 -04:00
vladdd
071190d18b Fix docstring indentation in test_arbitrary_package_attack.py 2013-09-17 20:20:55 -04:00
vladdd
98ae4a6d68 Fix docstring indentation in test_arbitrary_package_attack.py 2013-09-17 20:20:55 -04:00
dachshund
76326f82d1 Merge #108. 2013-09-17 20:02:54 -04:00
dachshund
91aff1c420 Merge #108. 2013-09-17 20:02:54 -04:00
dachshund
e210decd61 Merge branch 'demo2' of https://github.com/zhengyuyu/tuf into zhengyuyu-demo2 2013-09-17 19:38:26 -04:00
dachshund
61be096ad9 Merge branch 'demo2' of https://github.com/zhengyuyu/tuf into zhengyuyu-demo2 2013-09-17 19:38:26 -04:00
ttgump
017c9a378f fix of connection refused 2013-09-16 11:12:18 -04:00
ttgump
0f71b7604d fix of connection refused 2013-09-16 11:12:18 -04:00
ttgump
2baaa58a20 fetch upstream 2013-09-16 10:57:23 -04:00
ttgump
c393507fcd fetch upstream 2013-09-16 10:57:23 -04:00
vladimir-v-diaz
b9ec0a0b26 Update test_util_test_tools.py following change to util_test_tools.init_repo()
A util_test_tools.init_repo() parameter name was changed from 'tuf' to 'using_tuf', however, test_util_test_tools was not updated following the name change.
2013-09-16 09:09:40 -04:00
vladimir-v-diaz
cc0d7f9e89 Update test_util_test_tools.py following change to util_test_tools.init_repo()
A util_test_tools.init_repo() parameter name was changed from 'tuf' to 'using_tuf', however, test_util_test_tools was not updated following the name change.
2013-09-16 09:09:40 -04:00
zanefisher
f3a8f60583 Clean up after botched merge (oops). Add try/finally to endless data test to ensure temp files are always removed. 2013-09-14 16:58:01 -04:00
zanefisher
0fd5e36909 Clean up after botched merge (oops). Add try/finally to endless data test to ensure temp files are always removed. 2013-09-14 16:58:01 -04:00
ttgump
4c2f878870 util_test_tools.init_repo parameter fix 2013-09-14 15:46:25 -04:00
ttgump
c74a2d495f util_test_tools.init_repo parameter fix 2013-09-14 15:46:25 -04:00
ttgump
cd805e528d indention fix 2013-09-14 12:34:01 -07:00
ttgump
a688a6d06f indention fix 2013-09-14 12:34:01 -07:00
ttgump
dccd5fc7df Merge remote-tracking branch 'origin/demo2' into demo2 2013-09-14 12:31:15 -07:00
ttgump
2fc73dd468 Merge remote-tracking branch 'origin/demo2' into demo2 2013-09-14 12:31:15 -07:00
ttgump
3cf472757a test_mix_and_match_attack and test_indefinite_freeze_attack refactory fix 2013-09-13 19:14:32 -04:00
ttgump
384626cff9 test_mix_and_match_attack and test_indefinite_freeze_attack refactory fix 2013-09-13 19:14:32 -04:00
zanefisher
b991cdc21d Redo accidentally undone changes. 2013-09-13 18:52:47 -04:00
zanefisher
4a08c0c25e Redo accidentally undone changes. 2013-09-13 18:52:47 -04:00
zhengyuyu
f0258ea82c Fix test_delegations.py
Made changes that ensure it raises correct exception based on the refactored version of updater.py and download.py
2013-09-13 18:38:52 -04:00
zhengyuyu
ccbaa6fab4 Fix test_delegations.py
Made changes that ensure it raises correct exception based on the refactored version of updater.py and download.py
2013-09-13 18:38:52 -04:00
dachshund
edec089965 Fix variable shadow bug, use absolute import in two integration tests. 2013-09-13 17:39:57 -04:00
dachshund
b5263e4322 Fix variable shadow bug, use absolute import in two integration tests. 2013-09-13 17:39:57 -04:00
zanefisher
e059cf814b More integration test tidying-up 2013-09-13 17:39:29 -04:00
zanefisher
502a0102ec More integration test tidying-up 2013-09-13 17:39:29 -04:00
zanefisher
a397e208cd Rename boolean perameter 'TUF' to 'using_tuf' in every test. 2013-09-13 15:30:11 -04:00
zanefisher
f4eedf1d62 Rename boolean perameter 'TUF' to 'using_tuf' in every test. 2013-09-13 15:30:11 -04:00
zanefisher
8d8c223123 Merge remote-tracking branch 'upstream/demo2' into demo2 2013-09-13 13:39:44 -04:00
zanefisher
419b1dc24e Merge remote-tracking branch 'upstream/demo2' into demo2 2013-09-13 13:39:44 -04:00
zanefisher
f2517e1717 Clean up extraneous dependencies test following Vlad's review. 2013-09-13 13:38:50 -04:00
zanefisher
32427505ac Clean up extraneous dependencies test following Vlad's review. 2013-09-13 13:38:50 -04:00
vladdd
83ac535d32 Fix test_updater.py test case failure
Rebuild server repository in test_5_all_targets() - other test cases may not have properly restored the contents of the repository.
2013-09-13 09:54:10 -04:00
vladdd
d8841544e4 Fix test_updater.py test case failure
Rebuild server repository in test_5_all_targets() - other test cases may not have properly restored the contents of the repository.
2013-09-13 09:54:10 -04:00
zanefisher
d75e47f2cd Merge remote-tracking branch 'upstream/demo2' into demo2 2013-09-12 14:54:25 -04:00
zanefisher
4f8054755c Merge remote-tracking branch 'upstream/demo2' into demo2 2013-09-12 14:54:25 -04:00
zanefisher
a3fbb50b2a Update extraneous dependecies test to expect the new NoWorkingMirrorError. 2013-09-12 14:53:57 -04:00
zanefisher
a5692a1441 Update extraneous dependecies test to expect the new NoWorkingMirrorError. 2013-09-12 14:53:57 -04:00
vladdd
b89d6fb853 Update test_keystore.py following .key format and keystore changes 2013-09-12 13:02:54 -04:00
vladdd
dc146f97a1 Fix test_util_test_tools.py test case failure
Clear the keystore before initializing the util_test_tools.py repository and again after every test case exits.
2013-09-12 08:14:18 -04:00
vladdd
3111c22c63 Fix test_util_test_tools.py test case failure
Clear the keystore before initializing the util_test_tools.py repository and again after every test case exits.
2013-09-12 08:14:18 -04:00
vladdd
a1132af5af Fix test_keystore.py unit test failure
Ensure the keystore is empty prior to running the test cases.  The courtesy bug is spreading.
2013-09-11 13:33:28 -04:00
vladdd
a749c1d6bf Fix test_keystore.py unit test failure
Ensure the keystore is empty prior to running the test cases.  The courtesy bug is spreading.
2013-09-11 13:33:28 -04:00
vladdd
7e98cb8269 Fix unit test failure in test_roledb.py
Ensure roledb is empty prior to running the test cases.  roledb.py may have been modified by other unit tests that did not properly clean up.
2013-09-11 12:36:44 -04:00
vladdd
b7d86eca36 Fix unit test failure in test_roledb.py
Ensure roledb is empty prior to running the test cases.  roledb.py may have been modified by other unit tests that did not properly clean up.
2013-09-11 12:36:44 -04:00
dachshund
59dfa1f5ba Replace relative with absolute imports for tests. 2013-09-10 17:33:00 -04:00
dachshund
96c0aaaa9e Replace relative with absolute imports for tests. 2013-09-10 17:33:00 -04:00
dachshund
864d3065a8 Merge unit test fix from @zanefisher; fix a unit test bug. 2013-09-10 00:56:30 -04:00
dachshund
9cbffa1660 Merge unit test fix from @zanefisher; fix a unit test bug. 2013-09-10 00:56:30 -04:00
dachshund
9bd35596c9 Merge branch 'demo2' of https://github.com/zanefisher/tuf into demo2
Conflicts:
	tests/unit/test_updater.py
2013-09-10 00:39:49 -04:00
dachshund
a8d32a2220 Merge branch 'demo2' of https://github.com/zanefisher/tuf into demo2
Conflicts:
	tests/unit/test_updater.py
2013-09-10 00:39:49 -04:00
dachshund
78344636de Even better organization of tests; remove evpy.
Require higher versions of PyCrypto.
2013-09-10 00:24:34 -04:00
dachshund
c20f0a1455 Even better organization of tests; remove evpy.
Require higher versions of PyCrypto.
2013-09-10 00:24:34 -04:00