Преглед изворни кода

Subject:
Problem using MHD_OPTION_HTTPS_MEM_DHPARAMS in MHD_OPTION_ARRAY
From:
Denis Dowling <[email protected]>
Date:
02/26/2015 01:52 AM
To:
"[email protected]" <[email protected]>

Hi,

I was trying to add a Diffie Hellman key to the libmicrohttpd server using the MHD_OPTION_HTTPS_MEM_DHPARAMS option. I was putting this option into a vector and then passing this to MHD_start_daemon using the MHD_OPTION_ARRAY argument. This was failing and I tracked the problem down to a missing option in the switch statement in parse_options_va().

diff --git a/external/libmicrohttpd-0.9.39/src/microhttpd/daemon.c b/external/li
index 0816a4a..ce76a3b 100644
--- a/external/libmicrohttpd-0.9.39/src/microhttpd/daemon.c
+++ b/external/libmicrohttpd-0.9.39/src/microhttpd/daemon.c
@@ -3178,6 +3178,7 @@ parse_options_va (struct MHD_Daemon *daemon,
case MHD_OPTION_HTTPS_MEM_KEY:
case MHD_OPTION_HTTPS_MEM_CERT:
case MHD_OPTION_HTTPS_MEM_TRUST:
+ case MHD_OPTION_HTTPS_MEM_DHPARAMS:
case MHD_OPTION_HTTPS_PRIORITIES:
case MHD_OPTION_ARRAY:
case MHD_OPTION_HTTPS_CERT_CALLBACK:

Regards,
Denis

Christian Grothoff пре 11 година
родитељ
комит
4152f010b2
2 измењених фајлова са 5 додато и 0 уклоњено
  1. 4 0
      ChangeLog
  2. 1 0
      src/microhttpd/daemon.c

+ 4 - 0
ChangeLog

@@ -1,3 +1,7 @@
+Thu Feb 26 09:55:43 CET 2015
+	Fixing bug that prevented MHD_OPTION_HTTPS_MEM_DHPARAMS
+	from working within a MHD_OPTION_ARRAY. -DD
+
 Sun Feb  8 01:24:38 CET 2015
 	Adding MHD_OPTION_HTTPS_KEY_PASSWORD as proposed by
 	Andrew Basile. -CG/AB

+ 1 - 0
src/microhttpd/daemon.c

@@ -3221,6 +3221,7 @@ parse_options_va (struct MHD_Daemon *daemon,
 		case MHD_OPTION_HTTPS_KEY_PASSWORD:
 		case MHD_OPTION_HTTPS_MEM_CERT:
 		case MHD_OPTION_HTTPS_MEM_TRUST:
+	        case MHD_OPTION_HTTPS_MEM_DHPARAMS:
 		case MHD_OPTION_HTTPS_PRIORITIES:
 		case MHD_OPTION_ARRAY:
                 case MHD_OPTION_HTTPS_CERT_CALLBACK: