Browse Source

provisioning: better logging around authentication

Sumner Evans 2 years ago
parent
commit
2a44a2bf7d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      provisioning.go

+ 2 - 1
provisioning.go

@@ -111,8 +111,9 @@ func (prov *ProvisioningAPI) AuthMiddleware(h http.Handler) http.Handler {
 			auth = auth[len("Bearer "):]
 		}
 		if auth != prov.bridge.Config.Bridge.Provisioning.SharedSecret {
+			prov.log.Infof("Authentication token does not match shared secret")
 			jsonResponse(w, http.StatusForbidden, map[string]interface{}{
-				"error":   "Invalid auth token",
+				"error":   "Authentication token does not match shared secret",
 				"errcode": "M_FORBIDDEN",
 			})
 			return