Commit Graph

1656 Commits

Author SHA1 Message Date
Sebastian Messmer
ea3de7360c * Block versions don't have to be globally nondecreasing, but only per client id. This solves potential synchronization conflicts in a multi-client setting.
* Use cpputils::Serializer and cpputils::Deserializer instead of std::ifstream for storing/loading the block version list
2016-06-26 22:15:52 -07:00
Sebastian Messmer
de692c1ee4 Store number of entries at beginning of integrity file, so loading can be faster using unordered_map::reserve() 2016-06-26 22:15:52 -07:00
Sebastian Messmer
adb10343d2 Only hash key once if key not found, i.e. use [] instead of find() and then emplace() 2016-06-26 22:15:52 -07:00
Sebastian Messmer
389273a24f Test cases use a fake home directory for their configuration, so they don't clutter the actual home directory. 2016-06-26 22:15:52 -07:00
Sebastian Messmer
9da30e3c17 Remove redundant nullbyte 2016-06-26 22:15:52 -07:00
Sebastian Messmer
57af168cfd Store own client id into the block next to the version number. This will be used to fix synchronization conflicts where the version number on one clients progresses slower than on another client, but synchronizes later. 2016-06-26 22:15:52 -07:00
Sebastian Messmer
a5391a854d Use VersionCountingBlockStore 2016-06-26 22:15:52 -07:00
Sebastian Messmer
13411c4e59 Integrity data from KnownBlockVersions is persisted to a file 2016-06-26 22:15:52 -07:00
Sebastian Messmer
d7f547dd47 Implement a VersionCountingBlockStore that checks that version numbers are nondecreasing. Currently, the block store is not used yet and the state is not stored over different runs of CryFS. This comes with future commits. 2016-06-26 22:15:52 -07:00
Sebastian Messmer
da6390646e Add test cases for command line parser when options are not given. 2016-06-26 22:15:43 -07:00
Sebastian Messmer
f4a7878e37 Compatibility with GCC 6 2016-06-26 21:26:08 -07:00
Sebastian Messmer
0a61987594 Be explicit about types stored in config file 2016-06-26 15:34:53 -07:00
Sebastian Messmer
f6a80a4651 Remove default config values for mandatory values 2016-06-26 15:26:05 -07:00
Sebastian Messmer
9358c10adf Finish test cases for Block::resize() 2016-06-23 21:30:09 -07:00
Sebastian Messmer
acedbbd0c4 Fix EncryptedBlock::resize() and add test cases for it 2016-06-23 21:20:36 -07:00
Sebastian Messmer
fcbca9ddea Improve performance of InMemoryBlockStore and FakeBlockStore by using std::unordered_map instead of std::map and the direct representation of a block Key as Key instead of a string representation. 2016-06-23 12:26:47 -07:00
Sebastian Messmer
3db931c54d Fix mount information reported to operating system 2016-06-22 17:57:00 -07:00
Sebastian Messmer
e4501d51e5 Each file system gets a unique ID. This ID will later be used to store local configuration of a client for that file system. 2016-06-20 16:14:07 -07:00
Sebastian Messmer
b3c5d4b5e3 Refactor TimestampTestUtils 2016-06-09 17:47:29 -07:00
Sebastian Messmer
c5ccd9c2d1 Set cache entry to dirty when timestamps are changed. Otherwise, it wouldn't be written back. 2016-06-09 17:32:35 -07:00
Sebastian Messmer
da187e3142 Merge branch 'develop' of github.com:cryfs/cryfs into develop 2016-06-08 12:35:58 -07:00
Sebastian Messmer
e8ad454e47 TODOs 2016-06-08 12:35:56 -07:00
Sebastian Meßmer
2852120982 Update ChangeLog.txt 2016-06-08 12:33:42 -07:00
Sebastian Messmer
e2ec72edde Remove unused function 2016-06-08 12:29:28 -07:00
Sebastian Messmer
7489de3381 Added timestamp fix to ChangeLog 2016-06-08 12:22:17 -07:00
Sebastian Messmer
5aff394a16 Directory timestamps are updated correctly. Also added test cases for this. 2016-06-08 12:21:57 -07:00
Sebastian Messmer
5a5037c992 Symlinks update atime correctly. Also added a test case for this. 2016-06-07 21:47:23 -07:00
Sebastian Messmer
69f4c7976e File::truncate() updates timestamps correctly. Also added test cases for this. 2016-06-07 21:30:57 -07:00
Sebastian Messmer
6448110975 OpenFile updates timestamps correctly, i.e. on read(), write() and truncate(). Also added test cases for it. 2016-06-07 21:25:02 -07:00
Sebastian Messmer
06a5faf2f8 Generalize timestamp expectations 2016-06-07 20:48:29 -07:00
Sebastian Messmer
9bb2e2e89a Implement fsync() and fdatasync() syscalls for flushing open files 2016-06-07 18:36:59 -07:00
Sebastian Messmer
be31d78349 Make TimestampTestUtils generic 2016-06-07 13:07:22 -07:00
Sebastian Messmer
354f72443e Adapt test cases to new behavior from commit 2642507344 2016-06-07 12:52:06 -07:00
Sebastian Messmer
93f34a4557 Run FsppDeviceTest_Timestamps on all kinds of nodes, not just files 2016-06-07 12:48:21 -07:00
Sebastian Messmer
8bf8081464 Fix sigsev on startup which was introduced by commit 1bb38f39b4 2016-06-07 12:44:35 -07:00
Sebastian Messmer
2642507344 Allow loading file systems from future cryfs versions if user specifically asks for it 2016-06-06 15:31:09 -07:00
Sebastian Messmer
7708287fdd Add test case that loading a node doesn't modify time stamps 2016-06-06 15:20:41 -07:00
Sebastian Messmer
3ec52e94c7 Update ChangeLog 2016-06-04 00:46:07 -07:00
Sebastian Messmer
1bb38f39b4 * Fix FuseTest
* Refactor Fuse: shorter functions, and factor out common functionality of adding a fuse option into own method
2016-06-04 00:45:49 -07:00
Sebastian Messmer
93927e76d6 TODOs 2016-06-02 20:25:14 -07:00
Sebastian Meßmer
3894157589 Merge pull request #61 from mhogomchungu/develop
remove compiler warnings
2016-06-02 20:21:54 -07:00
Sebastian Messmer
1402f54fec Factor out platform inconsistency between Mac and Linux (stat.st_atim vs stat.st_atimespec) 2016-06-02 20:08:51 -07:00
Francis Banyikwa
f2b7aac76a use boost::optional for an optional argument in Fuse class 2016-06-02 21:58:04 +03:00
Francis Banyikwa
92d8f939ac move setting of fuse options to Fuse class 2016-06-02 12:51:44 +03:00
Francis Banyikwa
183d6a9d06 dont hard code "cryfs" name in the fspp library 2016-06-02 11:17:55 +03:00
Francis Banyikwa
c5a6f16cd5 use a macro to silence compiler warnings 2016-06-02 09:54:39 +03:00
Francis Banyikwa
907cf1d07d add project name to top level CMakeLists.txt file 2016-06-01 15:19:17 +03:00
Francis Banyikwa
002dc6ca17 solve issue number 24 2016-06-01 13:37:44 +03:00
Francis Banyikwa
2cf4a2e087 use project name as the first argument to fuse 2016-06-01 11:55:48 +03:00
Francis Banyikwa
de6462e548 remove compiler warnings 2016-06-01 11:34:19 +03:00