Skip to content

fix(security): mark no_tls policy as deprecated#877

Merged
kcenon merged 1 commit into
mainfrom
fix/871-no-tls-deprecation
Mar 20, 2026
Merged

fix(security): mark no_tls policy as deprecated#877
kcenon merged 1 commit into
mainfrom
fix/871-no-tls-deprecation

Conversation

@kcenon

@kcenon kcenon commented Mar 20, 2026

Copy link
Copy Markdown
Owner

What

Adds [[deprecated]] attribute to the no_tls struct to emit compiler warnings when used, guiding users toward TLS-enabled policies for production deployments.

Why

Fixes #871 -- Using no_tls in production is a security risk. While the struct must remain available for testing and development, a deprecation warning makes the security implication visible at compile time.

How

  • tls_policy.h: Added [[deprecated("Use require_tls or optional_tls for production deployments")]] to the no_tls struct declaration

Breaking Changes

None -- Existing code compiles and functions identically. Users will see deprecation warnings which can be suppressed if intentional (e.g., test code).

Mark no_tls with [[deprecated]] attribute to guide users toward
require_tls or optional_tls for production deployments.
@kcenon kcenon added bug Something isn't working architecture Architectural changes and design priority:medium Medium priority issue labels Mar 20, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Coverage Report

Metric Value
Line Coverage 61.0%
Target 75% (stretch: 80%)
Coverage Details

Full HTML report is available as a build artifact.

@github-actions

Copy link
Copy Markdown
Contributor

Performance Comparison

Base Branch Results

No base results

PR Branch Results

No PR results

@kcenon kcenon merged commit bd2393b into main Mar 20, 2026
41 checks passed
@kcenon kcenon deleted the fix/871-no-tls-deprecation branch March 20, 2026 08:05
kcenon added a commit that referenced this pull request Apr 13, 2026
Mark no_tls with [[deprecated]] attribute to guide users toward
require_tls or optional_tls for production deployments.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

architecture Architectural changes and design bug Something isn't working priority:medium Medium priority issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(security): add deprecation warning for no_tls policy

1 participant