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

Improve certificate related documentation #2585

Merged

Conversation

didier-wenzek
Copy link
Contributor

@didier-wenzek didier-wenzek commented Jan 12, 2024

Proposed changes

  • Add overview
  • Improve section related to self-signed certificate
  • Add howto use CA-signed certificate
  • Improve section related to cloud certificate
  • Polish doc related to MQTT TLS + auth settings
  • Add doc for HTTP TLS + auth settings

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Improvement (general improvements like code refactoring that doesn't explicitly fix a bug or add any new functionality)
  • Documentation Update (if none of the other choices apply)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Paste Link to the issue

Checklist

  • I have read the CONTRIBUTING doc
  • I have signed the CLA (in all commits with git commit -s)
  • I ran cargo fmt as mentioned in CODING_GUIDELINES
  • I used cargo clippy as mentioned in CODING_GUIDELINES
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

Further comments

Copy link

codecov bot commented Jan 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (5eb1219) 75.8% compared to head (5761e2b) 75.8%.

❗ Current head 5761e2b differs from pull request most recent head f79b243. Consider uploading reports for the commit f79b243 to get more accurate results

Additional details and impacted files
Files Coverage Δ
.../tedge_config/src/tedge_config_cli/tedge_config.rs 81.1% <100.0%> (ø)

... and 7 files with indirect coverage changes

Copy link
Contributor

@reubenmiller reubenmiller left a comment

Choose a reason for hiding this comment

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

I've added a few minor comments.

Currently most of the filenames no longer match the scope of the doc, .e.g the file add_self_signed_trusted.md, has a title of Cloud Authentication, and registration.md has a title of Self-signed Device Certificate.

We should fix the filenames so that the slugs (e.g. doc url) and the filenames are semi-related so it is easier for developers to find and maintain the docs.

docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
basicConstraints=CA:FALSE
keyUsage = digitalSignature, keyAgreement
extendedKeyUsage = serverAuth, clientAuth
subjectAltName=DNS:$(hostname),DNS:localhost
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder whether it's worth clarifying how this works in case people wish to use an IP address to connect instead. Firstly, it's not unlikely that people will want to connect by something other than localhost or the hostname of the machine, Secondly, when using an IP it's easy to fall into the trap of using e.g. DNS:192.168.0.25 where this should actually be IP:192.168.0.25 (and if you make mistakes here, you'll get next to no help in the error message to enlighten you as to what is wrong).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added a note

docs/src/operate/security/http_local_authentication.md Outdated Show resolved Hide resolved
docs/src/operate/security/index.md Outdated Show resolved Hide resolved
@didier-wenzek
Copy link
Contributor Author

Currently most of the filenames no longer match the scope of the doc, .e.g the file add_self_signed_trusted.md, has a title of Cloud Authentication, and registration.md has a title of Self-signed Device Certificate.

We should fix the filenames so that the slugs (e.g. doc url) and the filenames are semi-related so it is easier for developers to find and maintain the docs.

This has been fixed with 5ae1828

Copy link
Contributor

@reubenmiller reubenmiller left a comment

Choose a reason for hiding this comment

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

Approved. My comments have now been addressed.

Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
Copy link
Contributor

Robot Results

✅ Passed ❌ Failed ⏭️ Skipped Total Pass % ⏱️ Duration
380 0 3 380 100 54m11.187s

@didier-wenzek didier-wenzek added this pull request to the merge queue Jan 17, 2024
Merged via the queue into thin-edge:main with commit caab654 Jan 17, 2024
17 checks passed
@didier-wenzek didier-wenzek deleted the docs/improve-auth-documentation branch February 7, 2024 09:12
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

3 participants