CVE-2026-50160: Mass Assignment via Onboarding Endpoint Allows Unauthenticated JWT_SECRET Overwrite
Hoppscotch is an API development ecosystem. In self-hosted deployments of hoppscotch-backend from version 2026.4.1 and earlier, the unauthenticated POST /v1/onboarding/config endpoint is vulnerable to mass assignment. The global NestJS ValidationPipe is configured without whitelist: true, so extra properties on the request body that are not declared in SaveOnboardingConfigRequest are not stripped and are iterated in the service layer as if they were legitimate InfraConfig entries. Because keys such as JWTSECRET and SESSIONSECRET are valid InfraConfigEnum values and are not explicitly rejected during validation, an unauthenticated attacker who can reach a fresh instance before onboarding completes (or when no users exist) can overwrite these values in the database. Overwriting JWTSECRET gives the attacker control of the JWT signing key, allowing them to forge tokens for any user, including administrators, and results in full server compromise. The issue is fixed in hoppscotch 2026.5.0.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
hoppscotch-backendto a version that resolves this vulnerability.Fixed in 2026.5.0Patch CVE-2026-50160 - Configuration
Configure the global NestJS ValidationPipe with whitelist: true so extra/unexpected properties in the request body (e.g., JWT_SECRET, SESSION_SECRET) are stripped during validation and cannot be processed as legitimate InfraConfig entries.
NestJS ValidationPipe (hoppscotch-backend onboarding request validation) whitelist = true
Event History
Frequently Asked Questions
What is the severity of CVE-2026-50160?
CVE-2026-50160 has a CVSS score of 10.0, indicating it is a critical vulnerability.
How do I fix CVE-2026-50160?
To fix CVE-2026-50160, upgrade to the latest version of Hoppscotch that addresses this vulnerability.
What does CVE-2026-50160 affect in Hoppscotch?
CVE-2026-50160 affects the handling of JSON Web Tokens (JWT), allowing for unauthenticated overwriting of data.
Can CVE-2026-50160 be exploited remotely?
Yes, CVE-2026-50160 can be exploited remotely, making it essential to address this vulnerability quickly.
What should I do if I cannot upgrade to fix CVE-2026-50160?
If you cannot upgrade, implement strict access controls and monitor for unusual activity to mitigate risks associated with CVE-2026-50160.