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

{patch] dropbear adaptions to run as non-root #198

Open
HansH111 opened this issue Dec 1, 2022 · 0 comments
Open

{patch] dropbear adaptions to run as non-root #198

HansH111 opened this issue Dec 1, 2022 · 0 comments

Comments

@HansH111
Copy link
Contributor

HansH111 commented Dec 1, 2022

Attached some minor adaptions to run a non-root dropbear service and also change the location of the hostkeys used to a user enabled or custom location.

Added 2 cmdline options:
-H default location for hostkeys
this enables to specify in default_options.h the bare hostkey filenames.
in svr-runopts it is determined if you start dropbear as root (location /etc/dropbear) or as non-root (location ~/.ssh)

-U: specify a forced userid
So whatever you type in as username, you will be login with the forced userid... and as bonus the envvar SSH_ORGUSER will be set with the typed in username.
So this way you can still run as root, but always be forced to a certain user and also know which user was requested.

We use this to have dropbear acting as a user service, since we don't have any root rights or /etc access.

patchfiles.tgz

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

No branches or pull requests

1 participant