depenguin-me / depenguin-run

Installer script for mfsBSD image to install FreeBSD 14.0 with zfs-on-root using qemu
MIT License
17 stars 7 forks source link

I need to use password access to MfsBSD #16

Closed click0 closed 2 years ago

click0 commented 2 years ago

A vanilla build of MfsBSD with root password is enough for me. The mandatory requirement to use ssh keys is superfluous.

grembo commented 2 years ago

Using a default well-known password to access root over the public internet is a terrible solution that might lead to severe data leaks and that might put those responsible in jail. Hence the decision to not allow this to happen.

Are you sure that using an ssh key is a problem to you (like, creating a temporary one is a one-liner, placing one you’ll always use on a public endpoint is equally simple). Would creating one automatically help you?

An alternative solution would be to create a random password on each invocation of the script and alter it to make use of that. We could also add a command line parameter to set a password in addition to an ssh key. A fixed default root password over ssh is an absolute no-go.

In all honesty, I fail to see rationale for “I need to use password access to mfsbsd”. So maybe you can elaborate a bit more on that need to make me understand your use case.

grembo commented 2 years ago

p.s. you can always just use -m URL to use vanilla mfsbsd with a default root password, so you (and everyone else ;) ) can access your server with well-known credentials.

click0 commented 2 years ago

p.s. you can always just use -m URL to use vanilla mfsbsd with a default root password, so you (and everyone else ;) ) can access your server with well-known credentials.

In this place there is a mandatory check for the presence of a ssh key.

grembo commented 2 years ago

Not really, you just need to pass in some random non-empty file.

One simple solution would be to remove the need for passing in any ssh authorized keys files if -m URL is given - would that solve your problem?

click0 commented 2 years ago

Not really, you just need to pass in some random non-empty file.

One simple solution would be to remove the need for passing in any ssh authorized keys files if -m URL is given - would that solve your problem?

Using ssh keys to access the Live CD should be optional.

Running qemu i am planning to do one thing:

  1. automatically fix the current OS
  2. fix the current OS manually (via ssh or VNC)
  3. install a new OS (FreeBSD) with your install script.
  4. install another OS (not FreeBSD) with your installation script.
grembo commented 2 years ago

Not really, you just need to pass in some random non-empty file. One simple solution would be to remove the need for passing in any ssh authorized keys files if -m URL is given - would that solve your problem?

Using ssh keys to access the Live CD should be optional.

Running qemu i am planning to do one thing:

  1. automatically fix the current OS
  2. fix the current OS manually (via ssh or VNC)
  3. install a new OS (FreeBSD) with your install script.
  4. install another OS (not FreeBSD) with your installation script.

So will #18 cut it for you? Or do we need something more explicit?

An alternative would be to create keys automatically and store them in a well-known place on the server, so you can simply use them with whatever automation you're planning to use.

click0 commented 2 years ago

So will #18 cut it for you? Or do we need something more explicit?

Your commit is enough for me.

grembo commented 2 years ago

So will #18 cut it for you? Or do we need something more explicit?

Your commit is enough for me.

That sounds like a line from Casablanca ;)