Commit Graph

70 Commits

Author SHA1 Message Date
Paul Lorenz f56a9aae5d Add test race condition fix 2026-04-14 16:58:17 -04:00
Paul Lorenz e1638173cd Fixes for SDK terminator management. Add support for ziti sdk inspection. Fixes #3609
- removes legacy v1 terminator code path; all terminators now use v2 flow
- refactors edgeTerminator.close() to decouple SDK notification from control plane notification
- adds pending SDK close notification queue with retry when channel is busy
- adds post-create inspect mechanism that verifies SDK still holds the bind after terminator creation
- queues second post-create inspect when establishment takes >30s to catch SDK timeout races
- detects and discards stale reordered binds on the same connection by comparing connIds
- re-establishes replacement terminators when a delete/create race is detected
- eliminates IsEntityPresent pre-filter in removeTerminatorsHandler to prevent raft ordering races
- fixes ValidateTerminators to query identities from the correct manager with the correct filter field
- adds postCreate flag to ValidateTerminatorsV2Request so routers skip redundant SDK inspect
- returns retry-later (nil result) from router validation when inspect is temporarily unavailable
- blocks SyncAllSubscribers until completion and guards RouterDataModel replacement with in-progress flag
- fixes InheritLocalData to enable service access tracking for all subscribed identities
- adds Services.Has check in GetServiceAccessPolicies to prevent false policy grants
- validates policy-to-identity associations in ValidateServicePolicies
- adds `ziti agent tunnel dump-sdk` command for SDK context inspection via IPC agent
- adds `ziti fabric inspect sdk` command to query SDK context through routers
- fixes --expected-per-host CLI flag binding in validate terminators command
- changes bind-access-lost retry hint from NotRetriable to RetryStartOver
- moves trace route response and xgress close handling off channel handler goroutine
- fixes listTerminators test helper to URL-encode filter parameter
- improves sdk-hosting-test validation resilience with login and query retries
- adds terminator_create_flow.md documenting the full lifecycle across SDK, router, and controller
- adds detailed logging for data model sync, service access tracking, and subscriber change detection
2026-03-11 13:10:28 -04:00
Paul Lorenz bdb289ad57 Update deps and rebase on main 2026-02-04 15:48:42 -05:00
Paul Lorenz c69b07b74d Remove created/updated/deleted terminator events which are obsoleted by entity change events. Fixes #3531 2026-02-04 11:16:59 -05:00
Paul Lorenz 2ffc6e1151 Update ziti version to 2.0 2026-01-28 12:34:10 -05:00
Paul Lorenz af09450961 Fix golangci-lint errors 2025-10-17 12:54:25 -04:00
Andrew Martinez bb5cc51a97 adds posture cache, instance, instance data, and event hooks (#3267)
* adds posture cache, instance, instance data, and event hooks

- reworks router security
- abstracts api session and service sessions
- use connection tracker instead of various maps
- doc
- adds service sessions as always JWTs
- addes token logging fields
- removes multiple connection tracking fields
- adds support for router specific posture data/respones
- adds support for router posture check evaluation
- defer dial/bind posture checking for legacy to controller
- fix double session event emitting
- fix session event missing id
2025-10-15 14:01:56 -04:00
Andrew Martinez c4b89e9d01 fixes #2904 limit client certs requested/allowed (#2974)
* fixes #2904 limit client certs requested/allowed

Some clients (browsers) show a popup when interacting with our TLS
servers and a pop-up or other UI to select certificates for
interacting with our server. If not limited, this causes any client cert
available to be shown, allowing the user to choose a certificate
that will never work. This fix limits the issuer's allowed so the popup
never appears or only appears with viable options.

- use new xweb to modify server TLS configs with static and 3rd party
  CAs
- centralize CA certificates for re-use
2025-04-11 14:33:21 -04:00
Paul Lorenz e647d67325 Update to channel/v4 2025-04-02 15:28:59 -04:00
Andrew Martinez 6502098179 Fix.api.session.synth.jwt (#2935)
* fix #2934 fix API Session Cert to OIDC JWT mapping verification
* fix #2931 log invalid token aud, label token vs ext jwt aud
2025-03-26 11:24:17 -04:00
Paul Lorenz 110446a990 Add doc generator for events. Add event doc. Fixes #2593 2025-01-31 12:23:43 -05:00
Paul Lorenz cccf0c06af Update to channel/v3. Fixes #2390 2024-09-09 12:23:25 -04:00
Paul Lorenz 9e7ca0d188 Fix flaky AT 2024-07-15 16:22:41 -04:00
Paul Lorenz db6554ee06 Implement idempotency for sdk terminators. Fixes #1446 2023-12-01 15:44:05 -05:00
Paul Lorenz 07da3cd513 Merge remote-tracking branch 'edge/main' into merge-edge
Updated package names
Merged golangci-lint configurations
2023-09-27 16:54:53 -04:00
Paul Lorenz 81baa1843b Add default identity type. Remove user,service,device types. Fixes #1428 2023-08-22 20:40:33 -04:00
Paul Lorenz b061fe9a39 Move internal/certs to common. Remove some incidental files that weren't used. 2023-08-07 10:20:06 -04:00
Paul Lorenz 1f5eed5956 Move eid to common 2023-08-04 11:46:53 -04:00
Andrew Martinez 95ae025ce9 updates golang sdk to v0.20.0 2023-04-26 13:55:51 -04:00
Andrew Martinez a46a10d9eb use new github.com/openziti/edge-api repository
- fixes import statements
2023-01-24 16:03:20 -05:00
Andrew Martinez 69c31fcf3e uses github.com/openziti/edge-api
- removes old api specific scripts, generated files, etc
2023-01-24 14:45:24 -05:00
Paul Lorenz 63c161224a Add linter and fix issues found by linter 2022-10-10 16:56:51 -04:00
Paul Lorenz bae7e40b61 Update for foundation changes 2022-07-01 15:55:30 -04:00
Paul Lorenz 12df770d04 Update copyright 2022-06-30 17:45:08 -04:00
Andrew Martinez c5f156dd9e adds x509 claims support for external ids to CAs
- adds REST API CA external id field
- adds rest api for external fields
- refactors authentication interfaces for federation
- alters authentication moduels to return AuthResult interfaces
- allows AuthResults to provide external x509 certs as session certs
2022-05-23 13:08:16 -04:00
Paul Lorenz 0243212f83 Use ZitiSession const from golang sdk instead of foundation (so we can remove it from foundation) 2022-05-02 17:20:03 -04:00
Andrew Martinez f095abe8df fix go test failures 2021-09-02 09:11:14 -04:00
Paul Lorenz f2670e66a0 Make policy semantic required for POST/PUT. Fix evaluation on policy PUT if semantic not provided 2021-07-30 09:44:21 -04:00
Andrew Martinez b562fb5c07 splits API specs into composible modules
- splits Open API 2.0 (swagger) into client/management APIs
- uses go-swaggers flatten capabilities
- uses newer version of go-swagger (v0.27.0)
- introduces /edge/client/v1, /edge/management/v1
- non-prefixed URLs default to /edge/client/v1
- splits some shared management/client API handlers
- renames some REST models to "client" instead of "limited"
- passes all apitests, fails dataflow upd test (main fails this as well)
- updates generate rest script for powershell
- todo: test generate rest script for bash
- todo: use xweb (different branch)
2021-05-04 11:30:32 -04:00
Andrew Martinez 54af8801e7 adds posture check type PROCESS_MULTI
- adds a new posture check for dealing with multiple processes
- supports anyOf and allOf semantics
- does not require new posture responses, current process responses
  suffice
- tests
2021-04-20 08:52:23 -04:00
Paul Lorenz 5a2e7d1f92 Separate dataflow tests into separate build tag 2021-04-14 16:57:24 -04:00
Andrew Martinez ba1427d2d9 add posture check disconnect test 2021-03-26 09:38:14 -04:00
Paul Lorenz 680852f80e Allow tunnel to run over xgress directly 2021-03-22 14:33:54 -04:00
Paul Lorenz 8a160d93b1 Fix update terminator. Add test for terminator updates. Remove unused store_events 2021-02-26 09:04:32 -05:00
Andrew Martinez 46166db9cc fixes orphaned ottca enrollments
- deletes ottca enrollment when CA is deleted
- adds API tests
- adds migration to remove currently orphaned ottca enrollments
- migration tested on a v15 database with orphaned ottca enrollments
2021-02-09 13:55:03 -05:00
Andrew Martinez 4051c47dd5 Merge branch 'main' into mfa 2021-01-26 13:52:59 -05:00
Andrew Martinez f2431ab9b3 bulk posture response 2021-01-25 13:55:41 -05:00
Paul Lorenz 891d8eb5ce Add service events when configs are updated/deleted. Add service events test 2021-01-19 14:30:34 -05:00
Andrew Martinez 2d61799c24 add posture check MFA tests 2021-01-19 08:37:29 -05:00
Andrew Martinez 308d7f3a10 mfa initial
- add mfa read endpoints
- add mfa enroll enpoints
- fix mfa library timing issues
- adds mfa at tests
- adds admin mfa management endpoints
- adds admin mfa at tests
- improve at tests
- fix auth check vs auth query
- fix swagger for auth queryies
- fix swagger doc
- adds more api tests for validation
- redo auth query structure
- redo mfa endpoints
- move mfa verify to authenticate router:wq
- add recovery code support and tests
- add partial session authentication status
2021-01-19 08:36:27 -05:00
Andrew Martinez ac187ffa99 posture check implementation
- fix testing bugs
- remove testing timout function setters
- fixes deadlock due to posture data timeouts
- fix replace statements
- use map for posture data change tracking
2020-10-29 09:10:15 -04:00
Andrew Martinez 76823ff435 add ZITI_TEST_LOG_LEVEL, set to fatal for travis, remove prints 2020-10-02 15:43:49 -04:00
Paul Lorenz 50bc204dd5 Add edge terminator validator 2020-09-29 09:27:05 -04:00
Paul Lorenz 14eb819b30 Model performance test, work in progress 2020-07-28 10:01:34 -04:00
Andrew M 0817b9b6c5 Merge branch 'master' into use.shortids 2020-06-17 13:49:20 -04:00
Andrew M 6571dbd72c use shortids 2020-06-16 17:33:45 -04:00
Paul Lorenz c5d08014b5 Update rolling tests 2020-06-15 15:51:23 -04:00
Andrew M 3087972172 all conversion work
- remove old JSON schema, unsused code
- remove unused variables from base router functions
- rework all API entities
- rework all links
- fix lint issues
- adds error conversion logic
- update tests as needed
- fix up go test
- fix backwards compat w/ non json enroller
2020-06-09 14:11:23 -04:00
Andrew M b6d9efaf8c fixed #183, move to openziti 2020-05-26 17:37:35 -04:00
Andrew M 6732d0abfa fixes #158
- update for identities does not allow enrol/auth/default admin to be
  updated
- adds migrations to fix broken data models between ident/auth/enrol
- fixes migration not to be stuck at version 4
2020-05-18 09:17:31 -04:00