| CVE |
Vendors |
Products |
Updated |
CVSS v3.1 |
| SaajSoapMessageFactory , AxiomSoapMessageFactory , and DomPoxMessageFactory do not limit the size of the incoming message they parse.
A remote client that sends an oversized message to a Spring Web Services endpoint can cause the application to consume an amount of memory proportional to the data it sends, which may result in an OutOfMemoryError for the request being processed.
Limiting the size of incoming requests is commonly the responsibility of the infrastructure in front of the application, such as a reverse proxy or an API gateway.
For the JMS, Mail, and XMPP transports, the message is already fully received by the underlying client library before Spring Web Services processes it, and its size is subject to the limits of the broker or server.
On the client side, an oversized response requires the application to call a malicious or compromised server.
This issue only affects deployments where all the following are true:
The application receives messages over HTTP from untrusted clients.
No request body size limit is enforced before the message reaches Spring Web Services.
Fixed versions harden the message factories by applying a default maximum message size of 10MB, which can be configured via the maxMessageSize property of each factory. |
| JsonKafkaHeaderMapper and the deprecated DefaultKafkaHeaderMapper check the header type requested in the spring_json_header_types header against the mapper's trusted packages before deserializing a header value. Because java.lang is trusted by default, the type java.lang.Class passes this check. Deserializing a java.lang.Class header resolves the header value as a class name and loads that class, but the class named in the value is not subject to the trusted packages check.
A malicious producer can use this to make the consumer load, and with some Jackson versions initialize, any class on the consumer's classpath, regardless of the trusted packages configuration. The impact depends on the side effects of the static initializers of the classes present on the classpath, such as resource allocation, driver registration, or blocking.
An application is affected if it consumes records from a topic that an attacker can produce to and maps inbound headers with JsonKafkaHeaderMapper or DefaultKafkaHeaderMapper , which is the default when Jackson is on the classpath. |
| Spring Boot Actuator's sanitization mishandles certain characters when running in a Turkish or Azerbaijani locale. |
| Wss4jSecurityInterceptor.verifyCertificateTrust() is the only place inbound WS-Security signing certificates are checked for revocation, but it only validated the first SIGN result found in the message.
When an inbound message carries more than one XML signature, the certificates behind any additional signatures were never checked, so a message can pass validation even when signed with a revoked certificate, as long as another, valid signature is also present.
This affects deployments that validate inbound WS-Security signatures with Wss4jSecurityInterceptor with enableRevocation set, and accept messages that may carry more than one XML signature. |
| ClientRegistration , Spring Security's representation of an OAuth2/OpenID Connect client registration, includes the confidential client secret in the plaintext output of its toString() method.
Because toString() is invoked implicitly by common application and framework behaviors (parameterized logging, string concatenation, exception message construction, and similar), any code path that produces such output for a ClientRegistration instance may inadvertently disclose the client secret to a destination not intended to hold client credential material. |
| When building a container image on a POSIX platform using Buildpacks, layers in excess of approximately 4KB in size are written to a temporary file that can be read by other users. |
| Spring Security's reactive authentication support, AbstractUserDetailsReactiveAuthenticationManager and UserDetailsRepositoryReactiveAuthenticationManager , do not invoke the configured PasswordEncoder when a submitted username cannot be found, unlike its blocking counterpart DaoAuthenticationProvider .
Because password encoding is deliberately CPU-intensive, the response time for a nonexistent username is measurably shorter than for a valid username with an incorrect password.
Preconditions :
The application authenticates using AbstractUserDetailsReactiveAuthenticationManager or a subclass, such as UserDetailsRepositoryReactiveAuthenticationManager (used by reactive .formLogin()).
The authentication endpoint is reachable by the attacker.
An unauthenticated attacker who can measure authentication response times can use this difference to enumerate valid usernames. |
| MailSenderConnection correlates a SOAP response to its request solely by matching the request's JavaMail Message-ID against the In-Reply-To header of messages in the store mailbox.
The default Message-ID generated by JavaMail is predictable, so an attacker who can deliver mail to the client's configured store mailbox and predict or observe that value can inject a forged response that the client accepts as the legitimate reply.
This issue only affects deployments where all the following are true:
The client uses the optional MailMessageSender transport for request/response calls.
An attacker can deliver a message to the mailbox configured as the client's storeUri .
That attacker can predict or observe the Message-ID of a request sent from the same client process. |
| If an administrator marks a compromised SFTP server key as @revoked in the known_hosts resource but the original (non-revoked) line for that key is still present, Spring Integration continues to accept the compromised key. An attacker who has stolen that server's private key can therefore continue to impersonate the SFTP server despite the revocation.
ResourceKnownHostsServerKeyVerifier accepts a server key if any matching known_hosts entry is not revoked. Under OpenSSH semantics, a @revoked marker is an explicit deny that must take precedence over any other matching entry.
An application is affected if it uses setKnownHostsResource() with a known_hosts file containing both a @revoked entry and a residual non-revoked entry for the same host key, and the attacker can intercept the application's outbound SFTP connection while holding the compromised private key. |
| The embedded LDAP server provided by the spring-ldap-test artifact listens on every network interface of the host and accepts a fixed, publicly known administrative credential.
EmbeddedLdapServer is intended as a test fixture for the machine that runs it. However, its listener is not restricted to the loopback interface, and its administrative bind credential is built into the library rather than supplied by the application. Anyone who can reach the listening port can therefore authenticate as the directory administrator.
Preconditions :
The application or test suite starts an EmbeddedLdapServer (directly or through Spring LDAP's test support)
The host running it is reachable over the network by an untrusted party, for example a shared CI agent, a shared development network, or a container with a published port
An attacker who can reach the port can read, add, modify, and delete entries in the embedded directory, and can disrupt tests that depend on its contents. |
| Spring Cloud Gateway's WebsocketRoutingFilter accepts WebSocket handshakes without checking the Origin header. Browsers do not apply the same-origin policy or CORS to WebSocket handshakes. They only send the Origin header and rely on the server to accept or reject the request. Because the gateway does not reject cross-origin handshakes by default, a malicious web page can cause a victim's browser to open a WebSocket connection through the gateway to a backend service, using any credentials the browser attaches automatically, such as cookies.
Applications are affected only if they expose a route with a ws or wss URI through the gateway. Spring Cloud Gateway now rejects cross-origin WebSocket handshakes by default with a 403 Forbidden response, and provides the spring.cloud.gateway.server.webflux.websocket.allowed-origins and spring.cloud.gateway.server.webflux.websocket.allowed-origin-patterns properties ( spring.cloud.gateway.websocket.* for the 4.x and 3.1.x lines) to allow specific origins. |
| Applications may be vulnerable to a Regular Expression Denial of Service (ReDoS) attack
if they use PathPattern with a pattern that contains a {name:regex} variable,
and that regular expression is prone to excessive backtracking.
This applies to request mappings in Spring MVC and Spring WebFlux applications, as well as
PathPatternParser being used directly by applications.
When those conditions are met, an attacker can send crafted request paths that consume
excessive CPU time during request matching. |
| Spring Cloud Config Server can be configured to use property-based SSH settings for its Git repositories by setting spring.cloud.config.server.git.ignoreLocalSshSettings to true . The startup validators that check the host key and host key algorithm settings decide whether to run based on the top-level repository setting instead of the setting of the individual repository being validated.
When the top-level repository keeps the default ( ignoreLocalSshSettings=false ) and a sub-repository sets ignoreLocalSshSettings=true with an incomplete or unsupported host key configuration (for example a hostKeyAlgorithm without a hostKey ), the configuration passes validation at startup. At runtime, no host key is available for that sub-repository, so strict host key checking is disabled and any SSH server key is accepted.
Applications are affected when they use the Config Server with a Git backend over SSH and have a sub-repository configured this way. |
| A client that sets validateResponse on PayloadValidatingInterceptor did not reject a response that failed schema validation.
The errors were logged and the response was returned to the application anyway, and the rest of the interceptor chain was skipped, including any interceptor declared before the validating one.
This issue only affects deployments where all the following are true:
The client declares a PayloadValidatingInterceptor with validateResponse set to true .
A response-securing interceptor, such as Wss4jSecurityInterceptor validating responses, is declared before that validating interceptor in the client's interceptor list.
As Wss4jSecurityInterceptor validates responses by default, a response that failed schema validation therefore reached the application with its WS-Security header never checked.
An attacker able to supply the response can bypass signature and encryption checks by making the payload schema-invalid.
Fixed versions reject such a response with a WebServiceValidationException . |
| Spring Framework applications that use DataBinder 's allowedFields / disallowedFields
mechanism to restrict which properties may be set through data binding may be vulnerable to
a data binding rules bypass when targeting indexed data types.
Specifically, an application is vulnerable when all the following conditions are met:
The application uses Spring's data binding infrastructure to bind user-supplied request parameters onto a target object.
The application configures an exact disallowedFields pattern (or a restrictive
allowedFields pattern) to exclude one or more nested, map-keyed, or list-indexed properties
from binding.
The application does not configure any wildcard disallowedFields pattern, or no stricter allowedFields pattern.
When all conditions are met, an attacker can submit malicious form fields that will write
data on fields that are explicitly excluded from data binding by the application configuration. |
| Spring HATEOAS does not honour Jackson's @JsonProperty(access = Access.READ_ONLY) declaration when deserializing Collection+JSON ( application/vnd.collection+json ) and UBER ( application/vnd.uber+json ) request bodies.
Both media types reconstruct the domain object from the name/value pairs of the incoming representation using an internal, reflection-based property binder rather than Jackson's own bean deserializer.
That binder resolves each property's setter from the JavaBeans property descriptor and invokes it directly, applying only Jackson's @JsonIgnore and @JsonIgnoreProperties exclusions.
Properties declared read-only are not excluded, so a client-supplied value for such a property is accepted and written to the object.
As a result, a client able to submit a Collection+JSON or UBER request body can populate properties that the application declared as server-owned and expected to be ignored on input, such as a role, permission or account-state property.
The same payload submitted as application/json is handled by Jackson's bean deserializer, which correctly ignores those properties, so the exposure is specific to the two affected media types.
Affected applications are those that enable Collection+JSON or UBER hypermedia support and bind request bodies directly onto a domain type declaring a @JsonProperty(access = Access.READ_ONLY) property with a setter.
Applications using only the HAL or HAL-FORMS media types are not affected, as those do not use the affected binder on the deserialization path.
Applications that bind requests onto dedicated input DTOs without read-only properties are also not affected. |
| Spring Boot applications with Actuator can be vulnerable to an "Authentication Bypass" vulnerability when an application
resource that requires authentication is mapped under the same path used by the health endpoint.
More precisely, an application can be vulnerable when all the following are true:
the application is a Jersey-based web application ( spring-boot-starter-jersey ), rather than Spring MVC or WebFlux
the application has the Actuator dependency on the classpath
the application has the Spring Security dependency on the classpath, relying on the default security configuration
the health endpoint is exposed on a path also used by an application-provided resource, either through an additional
health path (for example management.endpoint.health.probes.add-additional-paths=true , or a health group's additional-path ),
or through management.endpoints.web.base-path=/
the application contributes a JAX-RS resource at that same path which requires authentication
Note that mapping application endpoints under infrastructure endpoints like Actuator's is not recommended by the Spring
team, and doing so is likely to interfere with other configurations and cause behavior problems. While the severity for
this advisory is high, we expect this setup to rarely occur in production.
This CVE is related to CVE-2026-22731 and CVE-2026-22733, which addressed similar issues. |
| The fix for CVE-2026-40987 validates only the file name against the local directory. For the remote file outbound gateway MGET command, the local directory itself can be derived from the server-controlled listing entry via the documented #remoteDirectory SpEL variable in a local-directory-expression . Since the directory is canonicalized before the containment check, the check passes even though the directory has already escaped the intended root, and the framework then creates the escaped directory.
As a result, a malicious FTP, SFTP or SMB server can write files with attacker-controlled content to arbitrary paths outside the configured local directory.
Applications are affected if they use the MGET command of an FTP, SFTP or SMB outbound gateway with a local directory expression that references #remoteDirectory (as in the reference documentation examples) and connect to a server that may be malicious or compromised. |
| Spring Framework's WebSocket support does not validate the Origin header by
default if WebSocketHttpRequestHandler is configured directly by the application, rather
than through the WebSocket config via WebSocketHandlerRegistry .
An application is affected if it configures WebSocket handling this way without adding
an origin check. In that case, a page served from a different origin can open a WebSocket
connection resulting in cross-site WebSocket hijacking. Applications that use
the WebSocket config via WebSocketHandlerRegistry are not affected. |
| Spring Framework's WebFlux XML decoding can exceed the configured maxInMemorySize limit.
This is a follow-up to CVE-2026-47891.
An application is affected if it decodes XML request or response bodies with WebFlux
using the Aalto XML parser. In that case, a specially crafted XML payload can cause memory
consumption to grow beyond the configured limit, potentially leading to denial of service. |