Explorar el Código

Merge pull request #2069 from smallstep/mariano/urn

Change URN for acme errors
Mariano Cano hace 2 años
padre
commit
7eccbc51fe
Se han modificado 2 ficheros con 2 adiciones y 2 borrados
  1. 1 1
      acme/order.go
  2. 1 1
      acme/order_test.go

+ 1 - 1
acme/order.go

@@ -312,7 +312,7 @@ func (o *Order) Finalize(ctx context.Context, db DB, csr *x509.CertificateReques
 			//nolint:govet // ignore non-constant format string
 			//nolint:govet // ignore non-constant format string
 			acmeError := NewDetailedError(ErrorUnauthorizedType, webhookErr.Error())
 			acmeError := NewDetailedError(ErrorUnauthorizedType, webhookErr.Error())
 			acmeError.AddSubproblems(Subproblem{
 			acmeError.AddSubproblems(Subproblem{
-				Type:   fmt.Sprintf("urn:smallstep:webhook:error:%s", webhookErr.Code),
+				Type:   fmt.Sprintf("urn:smallstep:acme:error:%s", webhookErr.Code),
 				Detail: webhookErr.Message,
 				Detail: webhookErr.Message,
 			})
 			})
 			return acmeError
 			return acmeError

+ 1 - 1
acme/order_test.go

@@ -636,7 +636,7 @@ func TestOrder_Finalize(t *testing.T) {
 					},
 					},
 				},
 				},
 				err: NewDetailedError(ErrorUnauthorizedType, "The message (theCode)").AddSubproblems(Subproblem{
 				err: NewDetailedError(ErrorUnauthorizedType, "The message (theCode)").AddSubproblems(Subproblem{
-					Type:   "urn:smallstep:webhook:error:theCode",
+					Type:   "urn:smallstep:acme:error:theCode",
 					Detail: "The message",
 					Detail: "The message",
 				}),
 				}),
 			}
 			}