Skip to content

refactor(protocol): add certificate authentication provider - #31

Merged
QuiteYellow merged 1 commit into
QuiteYellow:mainfrom
Moballo-LLC:codex/py-05-certificate-auth
Aug 9, 2026
Merged

refactor(protocol): add certificate authentication provider#31
QuiteYellow merged 1 commit into
QuiteYellow:mainfrom
Moballo-LLC:codex/py-05-certificate-auth

Conversation

@Jason-Morcos

@Jason-Morcos Jason-Morcos commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add an immutable CertificateAuth provider with file and in-memory factories, a credential-free representation, and no public or dataclass credential fields
  • let DtlsCoapSession accept auth= and delegate the existing CA, verification callback, cipher, and credential-loading sequence to the provider
  • retain cert_path / key_path and cert_pem / key_pem as a compatibility adapter, with the existing validation and public attributes and no deprecation warning
  • document the provider API and its compatibility rules

Compatibility boundary

This is the pure no-behavior-change CertificateAuth slice agreed in #28, rebased after #23-#25 landed. Existing file and memory constructor paths now create the provider internally; supplying both auth and legacy credential arguments fails immediately.

This PR does not add PSK authentication, Samsung-specific server profiles or identity enforcement, lifecycle changes, probe behavior, or new cipher choices.

Validation

  • python -m pytest -q on Python 3.14: 130 passed
  • dependency-floor suite with cbor2 5.6.0, pyOpenSSL 23.1.0, and pytest 8.0.0: 130 passed
  • current LocalThings consumer suite against this branch: 1,070 passed
  • targeted Ruff checks, compileall, share-safety scan, distribution-content check, and isolated wheel/sdist imports passed

Part of #28.

@Jason-Morcos
Jason-Morcos force-pushed the codex/py-05-certificate-auth branch from abfb3b3 to 8fb37ca Compare August 8, 2026 21:29
@Jason-Morcos
Jason-Morcos marked this pull request as ready for review August 8, 2026 22:39
@QuiteYellow
QuiteYellow merged commit 7f0f1e5 into QuiteYellow:main Aug 9, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants