Skip to content

docs: expand Config Server security guide#3247

Open
won-seoop wants to merge 1 commit into
spring-cloud:mainfrom
won-seoop:doc-1902-security-guide
Open

docs: expand Config Server security guide#3247
won-seoop wants to merge 1 commit into
spring-cloud:mainfrom
won-seoop:doc-1902-security-guide

Conversation

@won-seoop

Copy link
Copy Markdown

What

Addresses #1902.

Expands the server/security.adoc page from a single-paragraph stub into a practical security reference guide.

New sections

HTTP Basic Authentication

Shows server-side and client-side configuration, including encrypted passwords and how to supply credentials via environment variables.

OAuth2 / JWT Bearer Token Authentication

Shows the resource server dependency and issuer-uri configuration. Includes a note that the Config Client does not automatically acquire OAuth2 tokens — the user is responsible for wiring up client_credentials grant or similar.

Per-Application Access Control ⚠️

Explains the risk highlighted in #1796: any authenticated client can read any other application's config by using that application's name in the URL path. Shows a concrete SecurityFilterChain example that uses a Spring Security AuthorizationManager to enforce that each principal can only access the {application} path that matches its own name.

TLS / HTTPS

Brief note that TLS must be enabled in production.

Client-Side Configuration

Shows both the bootstrap.yml pattern and the spring.config.import URL pattern for supplying server credentials from environment variables rather than source-controlled files.

Why

The current docs had one paragraph and left readers with no actionable guidance. The per-application access control section fills a specific security gap that has tripped up multiple users (see #1796 and related issues).

🤖 Generated with Claude Code

Expands the server/security.adoc page from a single-paragraph stub into
a practical security reference guide, addressing the request in
spring-cloud#1902.

Adds the following sections:

* HTTP Basic Authentication — configuration on both server and client
  sides, with a note on encrypting the password.

* OAuth2 / JWT Bearer Token Authentication — dependency, JWKS/issuer-uri
  configuration, and a note that the Config Client does not obtain tokens
  automatically.

* Per-Application Access Control — explains the risk raised in spring-cloud#1796
  (any authenticated client can read any other application's config) and
  shows a Spring Security RequestMatcher example that restricts each
  client to paths matching its own principal name.

* TLS / HTTPS — brief guidance to always enable TLS in production.

* Client-Side Configuration — shows both the bootstrap.yml and
  spring.config.import patterns for supplying server credentials from
  environment variables rather than source-controlled files.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants