gokrazy / tools

this repository contains the gok CLI tool of gokrazy
https://gokrazy.org
BSD 3-Clause "New" or "Revised" License
50 stars 27 forks source link

Packer part of gokrazy/gokrazy#7 #14

Closed janisstreib closed 4 years ago

janisstreib commented 4 years ago

This PR adds a -tls option to the packer, which

  1. Generates a self-signed certificate if -tls=self-signd
  2. Packs the certificate into the image (/etc/ssl/web.pem and /etc/ssl/web_key.pem)

The updater pins the generated certificate in the local configuration and implements TLS stripping detection. Certificates can be pinned manually by placing them into the host specific configuration directory. Depends on my pr for internal.

janisstreib commented 4 years ago

I've just noticed, that I added go.mod and go.sum to the project. Should I remove them from this PR?

stapelberg commented 4 years ago

I've just noticed, that I added go.mod and go.sum to the project. Should I remove them from this PR?

I don’t mind the addition, provided you remove the replace statements and update to Go 1.14 first :)

stapelberg commented 4 years ago

FYI: I re-created the host-specific http-password part of your PR in https://github.com/gokrazy/tools/commit/2196ee2eabdb9196536e46d1cea99ac0592e3918 because I wanted to use it right away. I credited you in the commit description, hope you don’t mind me cherry-picking that feature :)

janisstreib commented 4 years ago

Sure, no problem. I also could have finished the PR today if I knew that there is an acute need for that component.

stapelberg commented 4 years ago

Ah, okay :)

I didn’t know whether you’d be able to work on this on short notice.

If you want, continuing the TLS support would be cool! Especially now that it could help users whose only networking option is unencrypted wifi: https://github.com/gokrazy/gokrazy/issues/57

stapelberg commented 4 years ago

Oh, and can you pull in the latest version of gokrazy/internal into the go.mod in this PR please?