annotate Resources/Patches/libp11-0.4.0.patch @ 4113:bfa8ca8e8ee6 Orthanc-1.6.0

closing Orthanc-1.6.0
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 07 Jul 2020 13:08:38 +0200
parents cc6d4edfe8fe
children b100555c4d6a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2026
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 diff -urEb libp11-0.4.0.orig/src/atfork.c libp11-0.4.0/src/atfork.c
3723
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
2 --- libp11-0.4.0.orig/src/atfork.c 2020-03-05 20:48:55.447852662 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
3 +++ libp11-0.4.0/src/atfork.c 2020-03-05 20:49:05.983770656 +0100
2026
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 @@ -25,7 +25,7 @@
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 #include <sys/stat.h>
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 #include <sys/types.h>
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 #include <unistd.h>
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 -#include <atfork.h>
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 +#include "atfork.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 #ifdef __sun
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 # pragma fini(lib_deinit)
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 diff -urEb libp11-0.4.0.orig/src/engine.h libp11-0.4.0/src/engine.h
3723
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
14 --- libp11-0.4.0.orig/src/engine.h 2020-03-05 20:48:55.447852662 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
15 +++ libp11-0.4.0/src/engine.h 2020-03-05 20:49:05.983770656 +0100
2026
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 @@ -29,7 +29,7 @@
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 #define _ENGINE_PKCS11_H
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 #ifndef _WIN32
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 -#include "config.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 +//#include "config.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22 #endif
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24 #include "libp11.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
25 diff -urEb libp11-0.4.0.orig/src/libp11-int.h libp11-0.4.0/src/libp11-int.h
3723
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
26 --- libp11-0.4.0.orig/src/libp11-int.h 2020-03-05 20:48:55.447852662 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
27 +++ libp11-0.4.0/src/libp11-int.h 2020-03-05 20:49:05.983770656 +0100
2026
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 @@ -20,7 +20,7 @@
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29 #define _LIBP11_INT_H
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 #ifndef _WIN32
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 -#include "config.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 +//#include "config.h"
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 #endif
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 #include "libp11.h"
3723
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
37 diff -urEb libp11-0.4.0.orig/src/p11_key.c libp11-0.4.0/src/p11_key.c
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
38 --- libp11-0.4.0.orig/src/p11_key.c 2020-03-05 20:48:55.447852662 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
39 +++ libp11-0.4.0/src/p11_key.c 2020-03-05 20:49:24.959625180 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
40 @@ -21,6 +21,10 @@
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
41 #include <string.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
42 #include <openssl/bn.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
43
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
44 +#if OPENSSL_VERSION_NUMBER >= 0x10100000L // OpenSSL 1.0.2
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
45 +# include <crypto/rsa/rsa_locl.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
46 +#endif
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
47 +
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
48 #ifdef _WIN32
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
49 #define strncasecmp strnicmp
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
50 #endif
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
51 diff -urEb libp11-0.4.0.orig/src/p11_rsa.c libp11-0.4.0/src/p11_rsa.c
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
52 --- libp11-0.4.0.orig/src/p11_rsa.c 2020-03-05 20:48:55.447852662 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
53 +++ libp11-0.4.0/src/p11_rsa.c 2020-03-05 20:49:20.095662204 +0100
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
54 @@ -27,6 +27,10 @@
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
55 #include <openssl/evp.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
56 #include <openssl/rsa.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
57
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
58 +#if OPENSSL_VERSION_NUMBER >= 0x10100000L // OpenSSL 1.0.2
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
59 +# include <crypto/rsa/rsa_locl.h>
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
60 +#endif
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
61 +
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
62 static int rsa_ex_index = 0;
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
63
cc6d4edfe8fe fix pkcs11 compilation
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2026
diff changeset
64 #if OPENSSL_VERSION_NUMBER < 0x10100003L