summaryrefslogtreecommitdiffstats
path: root/src/polarssl-1-fixes.patch
diff options
context:
space:
mode:
authorTony Theodore <tonyt@logyst.com>2015-12-02 07:57:00 (GMT)
committerTony Theodore <tonyt@logyst.com>2015-12-02 07:57:00 (GMT)
commita59294b1d1b8e3b8cb870a1ac1112afa83baa288 (patch)
treeeb36e00e68a592c522145fa7bb9e75e7bea10aa9 /src/polarssl-1-fixes.patch
parent199f9635585583e1bb1de0e4f11ed1203dd89688 (diff)
downloadmxe-a59294b1d1b8e3b8cb870a1ac1112afa83baa288.zip
mxe-a59294b1d1b8e3b8cb870a1ac1112afa83baa288.tar.gz
mxe-a59294b1d1b8e3b8cb870a1ac1112afa83baa288.tar.bz2
polarssl: enable zlib and really build .dll
Diffstat (limited to 'src/polarssl-1-fixes.patch')
-rw-r--r--src/polarssl-1-fixes.patch52
1 files changed, 52 insertions, 0 deletions
diff --git a/src/polarssl-1-fixes.patch b/src/polarssl-1-fixes.patch
new file mode 100644
index 0000000..1e2d42b
--- /dev/null
+++ b/src/polarssl-1-fixes.patch
@@ -0,0 +1,52 @@
+This file is part of MXE.
+See index.html for further information.
+
+Contains ad hoc patches for cross building.
+
+From 0516b3ebc54e3acdf3882b218e0f30133a23fa61 Mon Sep 17 00:00:00 2001
+From: MXE
+Date: Wed, 2 Dec 2015 18:47:45 +1100
+Subject: [PATCH 1/2] Security fix for CVE-2015-1182 from:
+
+https://polarssl.org/tech-updates/security-advisories/polarssl-security-advisory-2014-04
+
+diff --git a/library/asn1parse.c b/library/asn1parse.c
+index a3a2b56..e2117bf 100644
+--- a/library/asn1parse.c
++++ b/library/asn1parse.c
+@@ -278,6 +278,8 @@ int asn1_get_sequence_of( unsigned char **p,
+ if( cur->next == NULL )
+ return( POLARSSL_ERR_ASN1_MALLOC_FAILED );
+
++ memset( cur->next, 0, sizeof( asn1_sequence ) );
++
+ cur = cur->next;
+ }
+ }
+--
+2.4.9 (Apple Git-60)
+
+
+From e13da28ce07af59a1ee9736d41fc80e7a2861e7b Mon Sep 17 00:00:00 2001
+From: MXE
+Date: Wed, 2 Dec 2015 18:50:21 +1100
+Subject: [PATCH 2/2] fix shared lib install locations
+
+
+diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt
+index 33d96b4..262b463 100644
+--- a/library/CMakeLists.txt
++++ b/library/CMakeLists.txt
+@@ -131,6 +131,8 @@ if(USE_SHARED_POLARSSL_LIBRARY)
+ endif()
+
+ install(TARGETS polarssl
+- DESTINATION ${LIB_INSTALL_DIR}
++ ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
++ LIBRARY DESTINATION ${LIB_INSTALL_DIR}
++ RUNTIME DESTINATION bin
+ PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
+ endif(USE_SHARED_POLARSSL_LIBRARY)
+--
+2.4.9 (Apple Git-60)
+