Files
ziti/controller/model
Andrew Martinez b676aa2c51 backport openziti/ziti#3952 to v1.6 reject invalid externalIdClaim and stop enrollment panic (#3954)
* backport openziti/ziti#3952 to v1.6 reject invalid externalIdClaim and stop enrollment panic

- moves the error check before the locator assignment in Ca.GetExternalId
  so an unsupported matcher/parser no longer nil-derefs and returns HTTP 500
- guards the claim index against negative and out-of-range values and errors
  when a matched claim resolves to an empty string, so an empty externalId is
  never silently accepted nor mapped to an identity
- adds validateExternalIdClaim, rejecting unsupported locations, unsupported
  matcher/parser combos, missing matcher/parser criteria, and negative indexes
  with HTTP 400 at CA create and update time
- applies the validation to both CA create and update, which previously had
  no externalIdClaim validation on the update path
- tests GetExternalId across the matcher/parser matrix for no-panic and
  correct error/value behavior
- tests CA create and update reject invalid externalIdClaim configurations
- tests that an externalIdClaim resolving to empty fails enrollment cleanly

* backport openziti/ziti#3952 to v1.6 address pr review
2026-06-12 13:53:53 -04:00
..
2023-09-28 23:34:28 -04:00
2023-09-28 23:34:28 -04:00
2022-06-30 17:45:08 -04:00
2022-06-30 17:45:08 -04:00
2022-06-30 17:45:08 -04:00
2025-04-02 15:28:59 -04:00