Generalize HTTP server code from apps/ocsp.c to apps/lib/http_server.c#11736
Generalize HTTP server code from apps/ocsp.c to apps/lib/http_server.c#11736DDvO wants to merge 4 commits intoopenssl:masterfrom
Conversation
mattcaswell
left a comment
There was a problem hiding this comment.
This looks good to me. A couple of comments below.
I wonder if @vdukhovni might have some cycles to look at it?
|
Thanks @mattcaswell and @vdukhovni for your reviews and comments. |
mattcaswell
left a comment
There was a problem hiding this comment.
Approved assuming the minor nit is fixed.
Also adds apps/include/http_server.h. This is used so far by apps/ocsp.c and is going to be used for apps/cmp.c and will be helpful also for any future app acting as HTTP server.
Thanks for your swift reaction! |
|
It would have been cool to leverage a ubiquitous light-weight HTTP server library in C, with a suitable license instead of rolling our own, but the only one that comes to mind (libmicrohttpd) is LGPL. Mind you, we only use the HTTP server in "apps", it wouldn't be quite so bad to have it be runtime linked to an LGPL library, but we'd still need to something on systems where that's not available. Anyone know of suitable alternatives? |
Anyone have any experience good/bad with libhttp? The license is MIT, so not a problem... |
|
24 hours has passed since 'approval: done' was set, but as this PR has been updated in that time the label 'approval: ready to merge' is not being automatically set. Please review the updates and set the label manually. |
|
Merged - thanks @mattcaswell and @vdukhovni! |
Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Viktor Dukhovni <[email protected]> (Merged from #11736)
Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Viktor Dukhovni <[email protected]> (Merged from #11736)
Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Viktor Dukhovni <[email protected]> (Merged from #11736)
Also adds apps/include/http_server.h. This is used so far by apps/ocsp.c and is going to be used for apps/cmp.c and will be helpful also for any future app acting as HTTP server. Reviewed-by: Matt Caswell <[email protected]> Reviewed-by: Viktor Dukhovni <[email protected]> (Merged from #11736)
I agree this would make sense at least instead of trying to extend this very rudimentary HTTP server implementation, which would be a mayor endeavor. |
This is a further spin-off PR of #11470 as requested by @mattcaswell: #11470 (comment).
This adds
apps/lib/http_server.candapps/include/http_server.hsimplifying
apps/ocsp.c. This going to be used also forapps/cmp.cand will be helpful as well for any future app acting as an HTTP server.
This PR also contains a couple of related fixes as separate commits:
bio_wait()incrypto/bio/bio_lib.cin caseOPENSSL_NO_SOCKreq' parameter ofOSSL_HTTP_post_asn1()OSSL_CMP_SRV_process_request()on transaction renewal