Fedora Account System
Red Hat Associate
Red Hat Customer
The authentication middleware in search-v2-api unconditionally skips authentication when the request carries an `Upgrade: websocket` header (pkg/rbac/authnMiddleware.go:21). The /federated subrouter applies only AuthenticateUser before HandleFederatedRequest, which is a plain JSON handler that never validates the WebSocket handshake, never re-checks the token, and never consults GetUserData. An unauthenticated attacker can send a standard HTTP POST to /federated with `Upgrade: websocket` to bypass authentication and query federated search results across all configured remote managed hubs. Precondition: FEATURE_FEDERATED_SEARCH=true (default off; enabled for Global Hub deployments). Upstream: stolostron/search-v2-api