summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsthen <>2020-01-11 17:37:19 +0000
committersthen <>2020-01-11 17:37:19 +0000
commitada8f0655f3fb8aa20a5f6b3f9e48d5a4bba8308 (patch)
tree75d1b7b9529855a08a9f69ce09bd14ab8e3bd912
parentf86f8c9701dd2cb52bed7ce290e7431d15fcd27d (diff)
downloadopenbsd-ada8f0655f3fb8aa20a5f6b3f9e48d5a4bba8308.tar.gz
openbsd-ada8f0655f3fb8aa20a5f6b3f9e48d5a4bba8308.tar.bz2
openbsd-ada8f0655f3fb8aa20a5f6b3f9e48d5a4bba8308.zip
Set "Content-Type: application/ocsp-request" in ocspcheck(1)'s POSTs,
it is required by the RFC and some CAs require it (e.g. sectigo). From daharmasterkor at gmail com, ok jca@
-rw-r--r--src/usr.sbin/ocspcheck/http.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/usr.sbin/ocspcheck/http.c b/src/usr.sbin/ocspcheck/http.c
index e0df6cfa11..6666bb070c 100644
--- a/src/usr.sbin/ocspcheck/http.c
+++ b/src/usr.sbin/ocspcheck/http.c
@@ -1,4 +1,4 @@
1/* $Id: http.c,v 1.12 2019/06/28 13:32:49 deraadt Exp $ */ 1/* $Id: http.c,v 1.13 2020/01/11 17:37:19 sthen Exp $ */
2/* 2/*
3 * Copyright (c) 2016 Kristaps Dzonsons <kristaps@bsd.lv> 3 * Copyright (c) 2016 Kristaps Dzonsons <kristaps@bsd.lv>
4 * 4 *
@@ -349,6 +349,7 @@ http_open(const struct http *http, const void *p, size_t psz)
349 c = asprintf(&req, 349 c = asprintf(&req,
350 "POST %s HTTP/1.0\r\n" 350 "POST %s HTTP/1.0\r\n"
351 "Host: %s\r\n" 351 "Host: %s\r\n"
352 "Content-Type: application/ocsp-request\r\n"
352 "Content-Length: %zu\r\n" 353 "Content-Length: %zu\r\n"
353 "\r\n", 354 "\r\n",
354 http->path, http->host, psz); 355 http->path, http->host, psz);