-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcryptsetup_modifications.patch
More file actions
27 lines (25 loc) · 1.14 KB
/
cryptsetup_modifications.patch
File metadata and controls
27 lines (25 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
diff --git a/lib/crypto_backend/crypto_openssl.c b/lib/crypto_backend/crypto_openssl.c
--- a/lib/crypto_backend/crypto_openssl.c
+++ b/lib/crypto_backend/crypto_openssl.c
@@ -25,7 +25,7 @@ static OSSL_PROVIDER *ossl_default = NULL;
static OSSL_LIB_CTX *ossl_ctx = NULL;
static char backend_version[256] = "OpenSSL";
-#define MAX_THREADS 8
+#define MAX_THREADS -1
#if !HAVE_DECL_OSSL_GET_MAX_THREADS
static int OSSL_set_max_threads(OSSL_LIB_CTX *ctx __attribute__((unused)),
uint64_t max_threads __attribute__((unused))) { return 0; }
diff --git a/lib/crypto_backend/pbkdf_check.c b/lib/crypto_backend/pbkdf_check.c
--- a/lib/crypto_backend/pbkdf_check.c
+++ b/lib/crypto_backend/pbkdf_check.c
@@ -45,9 +45,9 @@ int crypt_pbkdf_get_limits(const char *kdf, struct crypt_pbkdf_limits *limits)
limits->max_iterations = UINT32_MAX;
limits->min_memory = 32; /* hard limit */
limits->min_bench_memory=64*1024; /* 64 MiB minimum for benchmark */
- limits->max_memory = 4*1024*1024; /* 4GiB */
+ limits->max_memory = -1;
limits->min_parallel = 1;
- limits->max_parallel = 4;
+ limits->max_parallel = -1;
return 0;
}