tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
monotone: fix key encryption
Michael Raskin
4 years ago
5dd7c7a0
430402d9
+19
-1
2 changed files
expand all
collapse all
unified
split
pkgs
applications
version-management
monotone
default.nix
monotone-1.1-adapt-to-botan2.patch
+4
-1
pkgs/applications/version-management/monotone/default.nix
···
30
hash = "sha256:1hfy8vaap3184cd7h3qhz0da7c992idkc6q2nz9frhma45c5vgmd";
31
};
32
33
-
patches = [ ./monotone-1.1-Adapt-to-changes-in-pcre-8.42.patch ];
0
0
0
34
35
postPatch = ''
36
sed -e 's@/usr/bin/less@${less}/bin/less@' -i src/unix/terminal.cc
···
30
hash = "sha256:1hfy8vaap3184cd7h3qhz0da7c992idkc6q2nz9frhma45c5vgmd";
31
};
32
33
+
patches = [
34
+
./monotone-1.1-Adapt-to-changes-in-pcre-8.42.patch
35
+
./monotone-1.1-adapt-to-botan2.patch
36
+
];
37
38
postPatch = ''
39
sed -e 's@/usr/bin/less@${less}/bin/less@' -i src/unix/terminal.cc
+15
pkgs/applications/version-management/monotone/monotone-1.1-adapt-to-botan2.patch
···
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
···
1
+
Botan2 has switched the parameter order in encryption descriptions
2
+
3
+
--- monotone-upstream/src/botan_glue.hh 2021-08-17 19:06:32.736753732 +0200
4
+
+++ monotone-patched/src/botan_glue.hh 2021-08-17 19:07:44.437750535 +0200
5
+
@@ -45,7 +45,9 @@
6
+
// In Botan revision d8021f3e (back when it still used monotone) the name
7
+
// of SHA-1 changed to SHA-160.
8
+
const static char * PBE_PKCS5_KEY_FORMAT =
9
+
-#if BOTAN_VERSION_CODE >= BOTAN_VERSION_CODE_FOR(1,11,0)
10
+
+#if BOTAN_VERSION_CODE >= BOTAN_VERSION_CODE_FOR(2,0,0)
11
+
+ "PBE-PKCS5v20(TripleDES/CBC,SHA-160)";
12
+
+#elif BOTAN_VERSION_CODE >= BOTAN_VERSION_CODE_FOR(1,11,0)
13
+
"PBE-PKCS5v20(SHA-160,TripleDES/CBC)";
14
+
#else
15
+
"PBE-PKCS5v20(SHA-1,TripleDES/CBC)";