|
|
7a8c6d |
From 3ca83f42275ac846d63167bee257bb57dc9eb37d Mon Sep 17 00:00:00 2001
|
|
|
7a8c6d |
From: Rob Crittenden <rcritten@redhat.com>
|
|
|
7a8c6d |
Date: Wed, 31 Jul 2019 14:17:39 -0400
|
|
|
7a8c6d |
Subject: [PATCH 28/29] No message=<ca ident> from GetCACaps, GetCACert, drop
|
|
|
7a8c6d |
GetCACertChain
|
|
|
7a8c6d |
|
|
|
7a8c6d |
In the SCEP Gutmann 10 spec there are no message=<ca ident> defined
|
|
|
7a8c6d |
for the GetCACaps or GetCACert commands. The nourse 23 spec still
|
|
|
7a8c6d |
defines this but it is optional. Don't send it at all.
|
|
|
7a8c6d |
|
|
|
7a8c6d |
GetCACertChain doesn't exist at all in gutmann and was dropped in
|
|
|
7a8c6d |
revision 19 by nourse.
|
|
|
7a8c6d |
|
|
|
7a8c6d |
https://pagure.io/certmonger/issue/103
|
|
|
7a8c6d |
---
|
|
|
7a8c6d |
src/scep.c | 14 +++++---------
|
|
|
7a8c6d |
1 file changed, 5 insertions(+), 9 deletions(-)
|
|
|
7a8c6d |
|
|
|
7a8c6d |
diff --git a/src/scep.c b/src/scep.c
|
|
|
7a8c6d |
index fff7ca8..7c9f844 100644
|
|
|
7a8c6d |
--- a/src/scep.c
|
|
|
7a8c6d |
+++ b/src/scep.c
|
|
|
7a8c6d |
@@ -64,7 +64,6 @@
|
|
|
7a8c6d |
|
|
|
7a8c6d |
#define OP_GET_CA_CAPS "GetCACaps"
|
|
|
7a8c6d |
#define OP_GET_CA_CERT "GetCACert"
|
|
|
7a8c6d |
-#define OP_GET_CA_CERT_CHAIN "GetCACertChain"
|
|
|
7a8c6d |
#define OP_GET_INITIAL_CERT "PKIOperation"
|
|
|
7a8c6d |
#define OP_PKCSREQ "PKIOperation"
|
|
|
7a8c6d |
enum known_ops {
|
|
|
7a8c6d |
@@ -356,11 +355,11 @@ main(int argc, const char **argv)
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
case op_get_ca_caps:
|
|
|
7a8c6d |
/* Only step: read capabilities for the daemon. */
|
|
|
7a8c6d |
- params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS "&message=%s", id);
|
|
|
7a8c6d |
+ params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS);
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
case op_get_ca_certs:
|
|
|
7a8c6d |
/* First step: get the root certificate. */
|
|
|
7a8c6d |
- params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CERT "&message=%s", id);
|
|
|
7a8c6d |
+ params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CERT);
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
case op_get_initial_cert:
|
|
|
7a8c6d |
if ((racert == NULL) || (strlen(racert) == 0)) {
|
|
|
7a8c6d |
@@ -378,7 +377,7 @@ main(int argc, const char **argv)
|
|
|
7a8c6d |
return CM_SUBMIT_STATUS_NEED_SCEP_MESSAGES;
|
|
|
7a8c6d |
}
|
|
|
7a8c6d |
/* First step: read capabilities for our use. */
|
|
|
7a8c6d |
- params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS "&message=%s", id);
|
|
|
7a8c6d |
+ params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS);
|
|
|
7a8c6d |
}
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
case op_pkcsreq:
|
|
|
7a8c6d |
@@ -397,7 +396,7 @@ main(int argc, const char **argv)
|
|
|
7a8c6d |
return CM_SUBMIT_STATUS_NEED_SCEP_MESSAGES;
|
|
|
7a8c6d |
}
|
|
|
7a8c6d |
/* First step: read capabilities for our use. */
|
|
|
7a8c6d |
- params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS "&message=%s", id);
|
|
|
7a8c6d |
+ params = talloc_asprintf(ctx, "operation=" OP_GET_CA_CAPS);
|
|
|
7a8c6d |
}
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
}
|
|
|
7a8c6d |
@@ -511,13 +510,10 @@ main(int argc, const char **argv)
|
|
|
7a8c6d |
abort(); /* never reached */
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
case op_get_ca_caps:
|
|
|
7a8c6d |
+ case op_get_ca_certs:
|
|
|
7a8c6d |
/* nothing to do here */
|
|
|
7a8c6d |
params2 = NULL;
|
|
|
7a8c6d |
break;
|
|
|
7a8c6d |
- case op_get_ca_certs:
|
|
|
7a8c6d |
- /* Step two: request the chain. */
|
|
|
7a8c6d |
- params2 = talloc_asprintf(ctx, "operation=" OP_GET_CA_CERT_CHAIN "&message=%s", id);
|
|
|
7a8c6d |
- break;
|
|
|
7a8c6d |
case op_get_initial_cert:
|
|
|
7a8c6d |
/* Step two: actually poll. If we have multiple messages which
|
|
|
7a8c6d |
* we can use, decide which one to use. */
|
|
|
7a8c6d |
--
|
|
|
7a8c6d |
2.17.2
|
|
|
7a8c6d |
|