+--- Makefile.orig Sat Nov 2 00:02:57 2002
++++ Makefile Tue May 10 13:58:23 2005
+@@ -14,10 +14,10 @@
+ # http://www.openssl.org/ Make sure the SSL_TREE definition points to the
+ # tree with your OpenSSL installation - depending on how you installed it,
+ # it may be in /usr/local instead of /usr/local/ssl.
+-#SSL_TREE = /usr/local/ssl
+-#SSL_DEFS = -DUSE_SSL
+-#SSL_INC = -I${SSL_TREE}/include
+-#SSL_LIBS = -L${SSL_TREE}/lib -lssl -lcrypto
++SSL_TREE = /usr
++SSL_DEFS = -DUSE_SSL
++SSL_INC = -I${SSL_TREE}/include
++SSL_LIBS = -L${SSL_TREE}/lib -lssl -lcrypto
+
+
+ BINDIR = /usr/local/sbin
--- mini_httpd.c.orig Wed Dec 3 19:27:22 2003
+++ mini_httpd.c Sun Dec 18 11:39:28 2005
@@ -74,7 +74,7 @@
+++ /dev/null
---- crypto_openssl.c.orig2 Sat Jun 18 20:46:38 2005
-+++ crypto_openssl.c Sat Jun 18 20:48:08 2005
-@@ -32,6 +32,10 @@
- #include <sys/types.h>
- #include <sys/param.h>
-
-+#include <sys/socket.h>
-+#include <netinet/in.h>
-+#include <arpa/inet.h>
-+
- #include <stdlib.h>
- #include <stdio.h>
- #include <limits.h>
-@@ -494,12 +498,36 @@
- goto end;
- }
-
-- len = gen->d.ia5->length + 1;
-- *altname = racoon_malloc(len);
-- if (!*altname)
-- goto end;
-+ if (gen->type == GEN_IPADD && gen->d.ia5->length == 4 /* IPv4 */) {
-+ char *ipv4_string = inet_ntoa(*((struct in_addr *)gen->d.iPAddress->data));
-+ *altname = NULL;
-+ if (ipv4_string) {
-+ len = strlen(ipv4_string)+1;
-+ *altname = racoon_malloc(len);
-+ }
-+ if (!*altname) {
-+#ifndef EAYDEBUG
-+ plog(LLV_ERROR, LOCATION, NULL, "failed to extract ipv4 alt name from certificate\n");
-+#else
-+ printf("failed to extract ipv4 alt name from certificate\n");
-+#endif
-+ goto end;
-+ }
-+ strcpy(*altname, ipv4_string);
-+#ifndef EAYDEBUG
-+ plog(LLV_DEBUG2, LOCATION, NULL, "extracted ipv4 alt name from certificate: %s\n", *altname);
-+#else
-+ printf("extracted ipv4 alt name from certificate: %s\n", *altname);
-+#endif
-+ }
-+ else {
-+ len = gen->d.ia5->length + 1;
-+ *altname = racoon_malloc(len);
-+ if (!*altname)
-+ goto end;
-
-- strlcpy(*altname, gen->d.ia5->data, len);
-+ strlcpy(*altname, gen->d.ia5->data, len);
-+ }
- *type = gen->type;
-
- error = 0;
+++ /dev/null
---- isakmp_quick.c.orig Tue Jan 11 02:09:50 2005
-+++ isakmp_quick.c Wed Sep 7 17:45:47 2005
-@@ -2031,6 +2031,21 @@
- "no policy found: %s\n", spidx2str(&spidx));
- return ISAKMP_INTERNAL_ERROR;
- }
-+
-+ /* Refresh existing generated policies
-+ */
-+ if (iph2->ph1->rmconf->gen_policy) {
-+ plog(LLV_INFO, LOCATION, NULL,
-+ "Update the generated policy : %s\n",
-+ spidx2str(&spidx));
-+ iph2->spidx_gen = racoon_malloc(sizeof(spidx));
-+ if (!iph2->spidx_gen) {
-+ plog(LLV_ERROR, LOCATION, NULL,
-+ "buffer allocation failed.\n");
-+ return ISAKMP_INTERNAL_ERROR;
-+ }
-+ memcpy(iph2->spidx_gen, &spidx, sizeof(spidx));
-+ }
-
- /* get outbound policy */
- {