mirror of
https://github.com/vgough/encfs.git
synced 2025-06-19 19:27:48 +02:00
Choose Block32 by default for Apple and Windows (Issue #8)
Default to Block32 when choosing standard or paranoid mode on case-insensitive systems (Apple and Windows)
This commit is contained in:
parent
b015f0c294
commit
3d30e064ba
@ -1016,7 +1016,14 @@ RootPtr createV6Config(EncFS_Context *ctx, const shared_ptr<EncFS_Opts> &opts) {
|
||||
keySize = 256;
|
||||
blockSize = DefaultBlockSize;
|
||||
alg = findCipherAlgorithm("AES", keySize);
|
||||
nameIOIface = BlockNameIO::CurrentInterface();
|
||||
|
||||
// If case-insensitive system, opt for Block32 filename encoding
|
||||
#if defined(__APPLE__) || defined(WIN32)
|
||||
nameIOIface = BlockNameIO::CurrentInterface(true);
|
||||
#else
|
||||
nameIOIface = BlockNameIO::CurrentInterface();
|
||||
#endif
|
||||
|
||||
blockMACBytes = 8;
|
||||
blockMACRandBytes = 0; // using uniqueIV, so this isn't necessary
|
||||
externalIV = true;
|
||||
@ -1029,7 +1036,13 @@ RootPtr createV6Config(EncFS_Context *ctx, const shared_ptr<EncFS_Opts> &opts) {
|
||||
keySize = 192;
|
||||
blockSize = DefaultBlockSize;
|
||||
alg = findCipherAlgorithm("AES", keySize);
|
||||
nameIOIface = BlockNameIO::CurrentInterface();
|
||||
|
||||
// If case-insensitive system, opt for Block32 filename encoding
|
||||
#if defined(__APPLE__) || defined(WIN32)
|
||||
nameIOIface = BlockNameIO::CurrentInterface(true);
|
||||
#else
|
||||
nameIOIface = BlockNameIO::CurrentInterface();
|
||||
#endif
|
||||
|
||||
if (opts->requireMac) {
|
||||
blockMACBytes = 8;
|
||||
|
Loading…
x
Reference in New Issue
Block a user