Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
e228bf0
KNOX-3395: Add KNOXTOKEN issuance and JWTProvider federation integrat…
Jul 24, 2026
804d921
added more tests and logic around revoke and renew
Aug 9, 2026
c4a0458
Fixed code as per Sandor review
Raghav-maheshwari-08 Aug 11, 2026
2570963
KNOX-3397: Add preauth.auth.header.actor.groups to set actor groups h…
smolnar82 Jul 27, 2026
a68f59c
KNOX-3398: Enable Iceberg REST catalog SSL only when ENCRYPT_ALL_PORT…
smolnar82 Jul 28, 2026
2c9e014
KNOX-3399 - Make RFC 8693 token exchange work for form-encoded reques…
smolnar82 Jul 30, 2026
dbe876d
KNOX-3403: RFC 8693 token exchange: use the impersonated subject as t…
smolnar82 Jul 31, 2026
0c8b243
KNOX-3386: LDAP Proxy pages backends (#1331)
handavid Jul 31, 2026
5e6b457
KNOX-3407: Support for WebSocket mTLS (#1338)
moresandeep Aug 6, 2026
ca28c3c
KNOX-3409: Validate knoxauth theme name to Harden Branding Support (R…
lmccay Aug 11, 2026
97c946e
KNOX-3410: KnoxToken enable/disable endpoints perform no caller autho…
hanicz Aug 11, 2026
7738d50
KNOX-3411: KnoxToken getUserTokens returns every user's token metadat…
hanicz Aug 11, 2026
367f71e
KNOX-3413: KnoxToken passcode verification accepts a valid passcode f…
hanicz Aug 12, 2026
3868838
KNOX-3416: KnoxSSO redirects to untrusted site (#1346)
hanicz Aug 12, 2026
67faccf
KNOX-3417: KnoxLdapRealm builds the LDAP search filter from the clien…
hanicz Aug 14, 2026
92f030e
KNOX-3418: Path traversal → arbitrary file write/overwrite in the Apa…
hanicz Aug 14, 2026
55402a1
Knox as an OAuth 2.0 / OpenID Connect Provider (KnoxIDF) (#1351)
smolnar82 Aug 14, 2026
b74e066
Bump org.apache.httpcomponents.core5:httpcore5 from 5.3.6 to 5.4.3 (#…
dependabot[bot] Aug 17, 2026
648dc7f
Bump org.apache.httpcomponents.client5:httpclient5 from 5.4.3 to 5.6.…
dependabot[bot] Aug 17, 2026
d172e61
KNOX-3394: Correct outdated unittest documentation in Docker Compose …
Raghav-Mah3shwari Aug 17, 2026
98cc4e8
KNOX-3278: Update JLine to 3.30.6 (#1181)
bonampak Aug 19, 2026
29f176b
KNOX-3421 - Upgrade Shiro to 2.2.1 (#1353)
moresandeep Aug 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,16 @@
## Integration Tests
(Please add or update integration tests [`.github/workflows/tests`](.github/workflows/tests) for the feature you are adding. If no unit test is added, please explain why. Check out [`.github/workflows/tests/README.md`](./workflows/tests/README.md) for instructions)

### Opt-in test suites (PR labels)
Some integration suites are expensive and are **not** run on every PR. Add the corresponding label to this PR to run them:

| Label | Runs |
|-------|------|
| `test-federation` | KnoxIDF federation E2E (`test_knoxidf_federation.py`). Stands up a real Keycloak as an external OpenID Provider and drives the full broker flow. Adds a few minutes (image pull + realm import). |
| `skip-tests` | Skips the entire Docker Compose test job. |

**When to add the label:** these labels only take effect on runs triggered by opening the PR, pushing a commit, or reopening the PR — the workflow does not run on a label change. Add the label **before opening the PR** (or before your next push). Adding it after the checks have already finished will **not** start a new run; push a commit or close/reopen the PR to trigger one with the label applied.

## UI changes
(If this patch involves UI changes, please attach a screen-shot; otherwise, remove this)

Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ FROM eclipse-temurin:17-jre

MAINTAINER moresandeep

RUN useradd -ms /bin/bash gateway
# Install dependencies
RUN apt-get update && apt-get install -y git && useradd -ms /bin/bash gateway

# Create temporary directories for extraction
RUN mkdir -p /tmp/knox-artifacts /tmp/knoxshell-artifacts /knox-runtime /knoxshell /knox-runtime/knoxshell
Expand All @@ -41,8 +42,13 @@ ADD .github/workflows/build/gateway-site.xml /knox-runtime/conf/gateway-site.xml
ADD .github/workflows/build/conf/topologies/knoxtoken.xml /knox-runtime/conf/topologies/knoxtoken.xml
ADD .github/workflows/build/conf/topologies/health.xml /knox-runtime/conf/topologies/health.xml
ADD .github/workflows/build/conf/topologies/knoxldap.xml /knox-runtime/conf/topologies/knoxldap.xml
ADD .github/workflows/build/conf/topologies/knoxldapcache.xml /knox-runtime/conf/topologies/knoxldapcache.xml
ADD .github/workflows/build/conf/topologies/remoteauth.xml /knox-runtime/conf/topologies/remoteauth.xml
ADD .github/workflows/build/conf/topologies/k8sauth.xml /knox-runtime/conf/topologies/k8sauth.xml
ADD .github/workflows/build/conf/topologies/knoxidf-ldap.xml /knox-runtime/conf/topologies/knoxidf-ldap.xml
ADD .github/workflows/build/conf/topologies/knoxidf-token.xml /knox-runtime/conf/topologies/knoxidf-token.xml
ADD .github/workflows/build/conf/topologies/knoxsso.xml /knox-runtime/conf/topologies/knoxsso.xml
ADD .github/workflows/build/conf/topologies/knoxidf-sso.xml /knox-runtime/conf/topologies/knoxidf-sso.xml

RUN chown -R gateway /knox-runtime/

Expand Down
82 changes: 82 additions & 0 deletions .github/workflows/build/conf/topologies/knoxidf-ldap.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
<?xml version="1.0" encoding="utf-8"?>
<topology>
<gateway>
<provider>
<role>authentication</role>
<name>ShiroProvider</name>
<enabled>true</enabled>
<param>
<name>main.ldapRealm</name>
<value>org.apache.knox.gateway.shirorealm.KnoxLdapRealm</value>
</param>
<param>
<name>main.ldapRealm.userDnTemplate</name>
<value>uid={0},ou=people,dc=hadoop,dc=apache,dc=org</value>
</param>
<param>
<name>main.ldapRealm.contextFactory.url</name>
<value>ldaps://localhost:33390</value>
</param>
<param>
<name>main.ldapRealm.contextFactory.authenticationMechanism</name>
<value>simple</value>
</param>
<param>
<name>urls./knoxidf/api/v1/.well-known/openid-configuration</name>
<value>anon</value>
</param>
<param>
<name>urls./knoxidf/api/v1/client/register</name>
<value>anon</value>
</param>
<param>
<name>urls./knoxidf/api/v1/authorize/callback</name>
<value>anon</value>
</param>
<param>
<name>urls./knoxidf/api/v1/jwks</name>
<value>anon</value>
</param>
<param>
<name>urls./**</name>
<value>authcBasic</value>
</param>
</provider>
<provider>
<role>identity-assertion</role>
<name>Default</name>
<enabled>true</enabled>
</provider>
</gateway>

<service>
<role>KNOXIDF</role>
<param>
<name>knoxidf.knox.token.ttl</name>
<value>60000</value>
</param>
<param>
<name>knoxidf.knox.token.limit.per.user</name>
<value>-1</value>
</param>
<param>
<!-- This sample topology intentionally allows open, unauthenticated client
registration (the endpoint is wired as 'anon' above). Registration refuses
anonymous callers unless this is explicitly set to true. -->
<name>knoxidf.client.registration.anonymous.allowed</name>
<value>true</value>
</param>
<param>
<!-- Skipping the user-consent screen is a server-side deployment decision, never a
client-supplied request parameter (a client must not be able to bypass consent by
sending auto_consent=true). This sample/CI topology opts in so the automated
authorization-code flow tests can complete without driving the consent UI. -->
<name>knoxidf.auto.consent.enabled</name>
<value>true</value>
</param>
<param>
<name>token.exchange.topology.name</name>
<value>knoxidf-token</value>
</param>
</service>
</topology>
120 changes: 120 additions & 0 deletions .github/workflows/build/conf/topologies/knoxidf-sso.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with this
work for additional information regarding copyright ownership. The ASF
licenses this file to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations under
the License.
-->
<!--
CI-only KnoxIDF topology exercised by the opt-in federation E2E test
(test_knoxidf_federation.py). Unlike knoxidf-ldap.xml (which fronts /authorize with
LDAP Basic auth), this topology fronts /authorize with an SSOCookieProvider. An
unauthenticated /authorize is redirected to the knoxsso login front-end; because a
federated OP (Keycloak) is configured below, the SSOCookieFederationFilter records the
request and offers the OP as a login option, brokering the user out to Keycloak and back
through /authorize/callback.

The federated.op.* settings are KNOXIDF service params so they are exposed as
ServletContext init-params, which is where both AuthorizeResource and the
SSOCookieFederationFilter read them (same webapp, shared ServletContext).
-->
<topology>
<gateway>
<provider>
<role>federation</role>
<name>SSOCookieProvider</name>
<enabled>true</enabled>
<param>
<name>sso.authentication.provider.url</name>
<value>https://knox:8443/gateway/knoxsso/api/v1/websso</value>
</param>
<param>
<name>sso.unauthenticated.path.list</name>
<value>/knoxidf/api/v1/authorize/callback;/knoxidf/api/v1/jwks;/knoxidf/api/v1/.well-known/openid-configuration;/knoxidf/api/v1/client/register</value>
</param>
</provider>
<provider>
<role>identity-assertion</role>
<name>Default</name>
<enabled>true</enabled>
</provider>
</gateway>

<service>
<role>KNOXIDF</role>
<param>
<name>knoxidf.knox.token.ttl</name>
<value>60000</value>
</param>
<param>
<name>knoxidf.knox.token.limit.per.user</name>
<value>-1</value>
</param>
<param>
<name>knoxidf.client.registration.anonymous.allowed</name>
<value>true</value>
</param>
<param>
<name>knoxidf.auto.consent.enabled</name>
<value>true</value>
</param>
<param>
<name>token.exchange.topology.name</name>
<value>knoxidf-token</value>
</param>
<param>
<name>federated.op.names</name>
<value>keycloak</value>
</param>
<param>
<name>federated.op.keycloak.enabled</name>
<value>true</value>
</param>
<param>
<name>federated.op.keycloak.clientId</name>
<value>knox-client</value>
</param>
<param>
<name>federated.op.keycloak.clientSecret</name>
<value>knox-client-secret</value>
</param>
<param>
<name>federated.op.keycloak.authorize.endpoint</name>
<value>http://keycloak:8080/realms/knox/protocol/openid-connect/auth</value>
</param>
<param>
<name>federated.op.keycloak.authorize.callback</name>
<value>https://knox:8443/gateway/knoxidf-sso/knoxidf/api/v1/authorize/callback</value>
</param>
<param>
<name>federated.op.keycloak.token.endpoint</name>
<value>http://keycloak:8080/realms/knox/protocol/openid-connect/token</value>
</param>
<param>
<name>federated.op.keycloak.jwks.endpoint</name>
<value>http://keycloak:8080/realms/knox/protocol/openid-connect/certs</value>
</param>
<param>
<name>federated.op.keycloak.issuer</name>
<value>http://keycloak:8080/realms/knox</value>
</param>
<param>
<name>federated.op.keycloak.userinfo.endpoint</name>
<value>http://keycloak:8080/realms/knox/protocol/openid-connect/userinfo</value>
</param>
<param>
<name>federated.op.keycloak.signature.algorithm</name>
<value>RS256</value>
</param>
</service>
</topology>
38 changes: 38 additions & 0 deletions .github/workflows/build/conf/topologies/knoxidf-token.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?xml version="1.0" encoding="utf-8"?>
<topology>
<gateway>
<provider>
<role>federation</role>
<name>JWTProvider</name>
<enabled>true</enabled>
<param>
<name>knox.token.exp.server-managed</name>
<value>true</value>
</param>
</provider>
<provider>
<role>identity-assertion</role>
<name>Default</name>
<enabled>true</enabled>
</provider>
</gateway>

<service>
<role>KNOXIDF</role>
<param>
<name>knoxidf.knox.token.ttl</name>
<value>86400000</value>
</param>
<param>
<name>knoxidf.knox.token.limit.per.user</name>
<value>-1</value>
</param>
<param>
<!-- Skipping the user-consent screen is a server-side deployment decision, never a
client-supplied request parameter. Kept in sync with knoxidf-ldap.xml so the
KNOXIDF service consents consistently across both topologies. -->
<name>knoxidf.auto.consent.enabled</name>
<value>true</value>
</param>
</service>
</topology>
12 changes: 11 additions & 1 deletion .github/workflows/build/conf/topologies/knoxldap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,19 @@ limitations under the License.
<service>
<role>KNOXTOKEN</role>
<param>
<name>knoxsso.token.ttl</name>
<name>knox.token.ttl</name>
<value>86400000</value>
</param>
<!-- Server-managed state is required for renew / revoke / enable / disable. -->
<param>
<name>knox.token.exp.server-managed</name>
<value>true</value>
</param>
<!-- guest may renew/revoke others' tokens; own-token revoke is always allowed. -->
<param>
<name>knox.token.renewer.whitelist</name>
<value>guest</value>
</param>
</service>
<service>
<role>KNOX-AUTH-SERVICE</role>
Expand Down
Loading
Loading