Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add skip_ssl_verify flag for certificate trust verification #63

Merged
merged 3 commits into from
Aug 13, 2024

Conversation

natalian98
Copy link
Contributor

@natalian98 natalian98 commented Aug 12, 2024

Applicable spec: n/a

Overview

This PR adds skip_ssl_verify as a new config option and smtp lib parameter.

Rationale

Some requirers of the smtp library need additional parameters for smtp configuration. One of them is skip_ssl_verify, which specifies if certificate trust verification is skipped in the integrated SMTP relay. This is a common config option which disables SSL verification, e.g. allowing the use of self-signed certificates.

Juju Events Changes

n/a

Module Changes

n/a

Library Changes

  • added skip_ssl_verify flag

Checklist

Can't add the trivial label as a non-maintainer

@natalian98 natalian98 changed the title Add skip_ssl_verify flag for certificate trust verification Add skip_ssl_verify flag for certificate trust verification Aug 12, 2024
@arturo-seijas
Copy link
Collaborator

/canonical/self-hosted-runners/run-workflows 94e528b

Copy link

Test coverage for 94e528b

Name                                    Stmts   Miss Branch BrPart  Cover   Missing
-----------------------------------------------------------------------------------
lib/charms/smtp_integrator/v0/smtp.py     128      2     24      2    97%   336, 338
src/charm.py                               82      5     26      1    94%   91-93, 102-103
src/charm_state.py                         46      0      6      0   100%
-----------------------------------------------------------------------------------
TOTAL                                     256      7     56      3    97%

Static code analysis report

Run started:2024-08-13 09:12:33.313775

Test results:
  No issues identified.

Code scanned:
  Total lines of code: 913
  Total lines skipped (#nosec): 3
  Total potential issues skipped due to specifically being disabled (e.g., #nosec BXXX): 0

Run metrics:
  Total issues (by severity):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
  Total issues (by confidence):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
Files skipped (0):

@natalian98 natalian98 marked this pull request as ready for review August 13, 2024 09:13
@natalian98 natalian98 requested a review from a team as a code owner August 13, 2024 09:13
Copy link
Member

@yanksyoon yanksyoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@arturo-seijas arturo-seijas merged commit 0bb0e04 into canonical:main Aug 13, 2024
22 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.

None yet

4 participants