Skip to content

Centrifugo's InsecureSkipTokenSignatureVerify flag silently disables JWT verification with no warning

Low severity GitHub Reviewed Published Mar 12, 2026 in centrifugal/centrifugo • Updated Mar 13, 2026

Package

gomod github.com/centrifugal/centrifugo/v6 (Go)

Affected versions

<= 6.6.2

Patched versions

6.7.0

Description

Summary

Centrifugo supports a configuration flag insecure_skip_token_signature_verify that completely disables JWT signature verification. When enabled, Centrifugo accepts any JWT token regardless of signature validity — including tokens signed with wrong keys, random signatures, or no signature at all. Critically, no warning is logged at startup or runtime when this flag is active, making it invisible to operators and security auditors.

Note: This vulnerability requires the operator to have explicitly set insecure_skip_token_signature_verify=true. The core issue is the absence of any warning when this flag is active, making accidental production exposure undetectable.

Details

The flag is defined in internal/configtypes/types.go:

InsecureSkipTokenSignatureVerify bool `mapstructure:"insecure_skip_token_signature_verify"`

It is passed directly to token verification in internal/client/handler.go:

token, err := h.tokenVerifier.VerifyConnectToken(e.Token, 
    cfg.Client.InsecureSkipTokenSignatureVerify)

In token_verifier_jwt.go, when skipVerify=true the entire signature block is bypassed:

if !skipVerify {
    // This block never executes
    err = verifier.verifySignature(token)
}

The flag is configurable via multiple vectors making accidental exposure likely:

  • Config file: insecure_skip_token_signature_verify: true
  • Environment variable: CENTRIFUGO_INSECURE_SKIP_TOKEN_SIGNATURE_VERIFY=true
  • YAML, TOML config formats

Despite hmac_secret_key being configured, startup logs show "enabled JWT verifiers" — falsely implying verification is active.

PoC

Config with legitimate HMAC key but skip flag enabled:

{
  "client": {
    "insecure_skip_token_signature_verify": true,
    "token": { "hmac_secret_key": "legitimate-production-secret-key" }
  }
}

Token signed with completely wrong key is fully accepted:

VULNERABILITY CONFIRMED!
Connected as user: {'client': '899dec73...', 'version': '0.0.0 OSS'}

No security warning emitted when insecure_skip_token_signature_verify=true:
1

Token signed with wrong key accepted, authentication bypass confirmed:
2

skipVerify flag propagated from config to all token verification calls:
3

Impact

  • Any unauthenticated user can connect as any arbitrary user ID
  • Complete authentication bypass — attacker sets any sub claim value
  • No indicators in logs that the server is operating insecurely
  • Easily triggered accidentally via environment variable injection
    in containerized deployments (e.g. misconfigured Kubernetes secrets)
  • Affects all connection types: WebSocket, HTTP-streaming, SSE, GRPC

Suggested Fix

  1. Emit a loud startup warning when flag is enabled:
if cfg.Client.InsecureSkipTokenSignatureVerify {
    log.Warn().Msg("SECURITY WARNING: JWT signature verification is " +
        "DISABLED via insecure_skip_token_signature_verify - " + 
        "DO NOT use in production!")
}
  1. Consider requiring an additional explicit insecure_mode: true flag to prevent accidental single-flag misconfiguration
  2. Log a warning on every accepted token when skip is active

References

@FZambia FZambia published to centrifugal/centrifugo Mar 12, 2026
Published to the GitHub Advisory Database Mar 13, 2026
Reviewed Mar 13, 2026
Last updated Mar 13, 2026

Severity

Low

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:N

EPSS score

Weaknesses

Improper Authorization

The product does not perform or incorrectly performs an authorization check when an actor attempts to access a resource or perform an action. Learn more on MITRE.

CVE ID

No known CVE

GHSA ID

GHSA-q926-c743-49qj

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.