Interface ServerTransportSecurityValidator
- All Known Implementing Classes:
DefaultServerTransportSecurityValidator
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Interface for validating HTTP requests in server transports. Implementations can
validate Origin headers, Host headers, or any other security-related headers according
to the MCP specification.
- Author:
- Daniel Garnier-Moiroux
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ServerTransportSecurityValidatorA no-op validator that accepts all requests without validation. -
Method Summary
Modifier and TypeMethodDescriptionvoidvalidateHeaders(Map<String, List<String>> headers) Validates the HTTP headers from an incoming request.
-
Field Details
-
NOOP
A no-op validator that accepts all requests without validation.
-
-
Method Details
-
validateHeaders
Validates the HTTP headers from an incoming request.- Parameters:
headers- A map of header names to their values (multi-valued headers supported)- Throws:
ServerTransportSecurityException- if validation fails
-