Commit graph

2235 commits

Author SHA1 Message Date
Owen
7672b08e03
Support redirecting to a block page 2026-11-23 17:23:45 -05:00
Owen
f0d346ba8d
Blocking
Some checks failed
Mirror Node Base Image (Docker Hub to GHCR) / mirror (push) Has been cancelled
2026-11-23 12:21:38 -05:00
Owen
9b57cfb4b1
Merge branch 'api-docs' into 1-28 2026-11-23 11:36:24 -05:00
Owen
87d1210bea
Cant delete until unassociated; show the disconnect 2026-11-23 11:27:50 -05:00
Owen
9b2c14db65
Implement pan-1725 pan-1745 pan-1847 2026-11-20 17:24:58 -05:00
Owen
c39c68b71c
Adjust to pull from db 2026-11-20 15:31:30 -05:00
Owen
1c765ef3b8
Add response types to api documentation 2026-11-20 09:10:47 -05:00
Owen
ff2d4f08db
disable_login_org_names flag 2026-11-18 11:27:24 -05:00
Owen
9c9bd6c8f5
Merge branch '1-27' into dev 2026-11-17 17:47:01 -05:00
Owen
adc862e37c
Read round trip from primary db
Some checks failed
Mirror Node Base Image (Docker Hub to GHCR) / mirror (push) Has been cancelled
2026-11-17 17:07:19 -05:00
Owen
e864d0655d
Support config on machine clients 2026-11-17 16:54:51 -05:00
miloschwartz
b0fc9e27a7
rename flag, remove idp association, and add permissions ui checkbox 2026-11-17 15:02:29 -05:00
Milo Schwartz
c162eabb9b
Merge pull request #3867 from digitalglue-software/feat/idp-session-exchange-upstream
feat(idp): add org-scoped integration endpoint to mint session for external IdP user
2026-11-17 15:01:02 -05:00
Owen
7b54a45e7f
WS gateway 2026-11-17 14:47:44 -05:00
Owen
9c3f85068f
Support addons and monthly billing 2026-11-13 14:00:30 -05:00
Owen
a3bf2311a8
Support addons and monthly billing 2026-11-13 12:24:24 -05:00
Owen
f44f626124
Push client settings 2026-11-12 17:29:02 -05:00
Owen
026942511c
Support adjustable license keys 2026-11-10 16:46:01 -05:00
Owen
db8168b05e
Update the cli based on the cli version 2026-11-10 09:45:23 -05:00
Owen
00620dd87d
Update the cli based on the cli version 2026-11-10 09:45:06 -05:00
Owen Schwartz
a5530ab10c
Merge pull request #4084 from fosrl/rule-labels
Support selecting labels for alert rules
2026-11-09 17:31:35 -05:00
Owen
8ae5a08b29
Get latest versions from the Fossorial API instead of GitHub 2026-11-09 16:23:49 -05:00
Owen
52dfcca0bc
Check site access before adding an olm peer 2026-11-09 16:23:49 -05:00
Owen
34c2fb8e6b
Rate limit user lookups per IP 2026-11-09 16:23:49 -05:00
Owen
dbfb7ce400
Scope domain reads and rule deletes to their owner 2026-11-09 16:23:48 -05:00
Owen
3906c3633f
Strip cookies from AI gateway upstream requests 2026-11-09 16:23:48 -05:00
Owen
a00bfa942d
Leave OIDC client credentials out of the internal IdP route 2026-11-09 16:23:48 -05:00
Owen
856d1dd716
Block duplicate hostnames on non-inference resources 2026-11-09 16:23:48 -05:00
Owen
bfe6dda7e8
Require a target's site to be in the same org 2026-11-09 16:23:48 -05:00
Owen
0076018373
Rate limit header auth attempts 2026-11-09 16:23:48 -05:00
miloschwartz
b1a6e82fbd
add user and agent table filters 2026-11-04 09:44:11 -05:00
miloschwartz
ddc4934ab8
make session revalidation private 2026-11-03 16:49:26 -05:00
miloschwartz
8538fff0ef
store metadata on session 2026-11-03 09:56:56 -05:00
Owen
189eb9cb05
Support selecting labels for alert rules 2026-11-03 09:23:17 -05:00
miloschwartz
da94c496b3
ui improvements to resource sessions 2026-11-02 17:29:20 -05:00
miloschwartz
388349ff23
support auto provision toggle per org for org idp mode 2026-11-02 16:19:05 -05:00
Owen
4726cb4fc1
Support matching on the base wildcard resources 2026-11-02 15:30:16 -05:00
Owen
095ca2204f
Resource session page 2026-11-02 15:00:09 -05:00
Owen
8c11260ede
Add resource session tracking page 2026-11-02 14:59:01 -05:00
Owen
5b8833f302
SSH log 2026-11-02 14:56:55 -05:00
gk1
34a0c1e630 feat(idp): root-gated create-session for an external IdP user (per review)
Reworks the org-scoped exchange-token endpoint into a root-gated create-session route,
addressing the review on the earlier version:

- Requires a ROOT API key holding the createIdpSession action, not an org-scoped key.
  Minting a session is impersonation, so it is deliberately root-only.
- Gated behind flags.enable_idp_create_session (off by default, self-hosted only;
  refused when build === "saas").
- Drops orgId entirely: the user must belong to the identity provider, not an
  organization. The route becomes /idp/:idpId/oidc/create-session.

Removes the now-unused org-scoped createSessionForIdpUser helper.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-10-30 16:55:25 -07:00
gk1
89d25eb760 feat(idp): add org-scoped integration endpoint to mint session for external IdP user
Add POST /v1/org/:orgId/idp/:idpId/oidc/exchange-token to the Integration
API so a trusted backend (e.g. an external IdP) can bridge an already-
authenticated external IdP session into Pangolin without the interactive
browser OIDC flow. Returns a Pangolin user session token { token, expiresAt }
in the JSON body, and registers the route in the OpenAPI spec with described
path parameters, request body, success response and error responses.

The endpoint is org-scoped and least-privilege: the caller holds an org-scoped
API key granted only the createIdpSession action, one org per deployment.
Guarded with verifyApiKeyOrgAccess + verifyApiKeyIdpAccess +
verifyApiKeyHasAction(createIdpSession) + logActionAudit, matching the other
/org/:orgId/idp/:idpId integration routes. orgId comes from the path;
verifyApiKeyIdpAccess confirms the org owns :idpId. Registration is gated
behind build !== "saas". A new createIdpSession action is added to ActionsEnum
(auto-seeded by ensureActions on self-hosted builds).

Claim-mapping/autoprovision is intentionally out of scope: the helper only
verifies the user exists, that users.idpId matches, and that a userOrgs
membership row exists for orgId, rejecting 401/404 otherwise. The caller must
pre-provision the user.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-10-30 16:55:25 -07:00
miloschwartz
b3c6b3f242
Merge branch '1.26' into dev 2026-10-30 15:07:38 -04:00
Milo Schwartz
9115808301
Merge pull request #4027 from S-NoF3aR/feature/idp-session-revalidation
Revalidate OIDC sessions with the IdP using refresh tokens
2026-10-30 14:44:23 -04:00
miloschwartz
451f89481c
support special google session revalidation 2026-10-30 14:43:55 -04:00
miloschwartz
440e874aa1
add toggle to idp settings 2026-10-30 14:07:04 -04:00
Owen
8b784611c2
Support prices for custom models 2026-10-29 10:56:51 -04:00
Severin Enzler
7176fa4a40 Revalidate OIDC sessions with the IdP using refresh tokens
Pangolin consults the IdP only at login and keeps its own session
afterwards, so disabling a user or revoking their sessions in the IdP
does not end their Pangolin sessions.

Store the IdP refresh token at OIDC login as a grant and redeem it at
most every server.idp_session_revalidation_minutes (default 5). If the
IdP rejects it with invalid_grant, the grant is marked revoked and all
sessions backed by it and their resource sessions are deleted. Other
errors (IdP unreachable or slower than 10 seconds, invalid_client after
a secret change) keep the sessions valid and are retried after at most
a minute instead of on every request.

Only the instance holding a lease on the grant in the primary database
redeems its refresh token, and it writes the result only while it still
holds the lease, so instances never redeem the same token concurrently.
The per-request lookup reads from a replica through safeRead.

Device logins of the Pangolin clients share the grant of the browser
session that approved them, read from the primary database, so a rotated
refresh token is never redeemed twice by separate sessions.

The Entra ID provider type hardcodes its scopes, so it now requests
offline_access to get a refresh token.
2026-10-29 11:33:30 +01:00
miloschwartz
3cacaedb8b
recover olm based on last seen
Some checks failed
Mirror Node Base Image (Docker Hub to GHCR) / mirror (push) Has been cancelled
2026-10-28 16:48:18 -04:00
Owen
c64fd9cce6
Adjust how multi record items are stored 2026-10-28 13:42:59 -04:00