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 sshd configuration #41

Closed
willthames opened this issue Jul 16, 2021 · 3 comments
Closed

Improve sshd configuration #41

willthames opened this issue Jul 16, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@willthames
Copy link
Contributor

Image I'm using:

Custom image based on pr #39 but that should be pretty much latest now.

Issue or Feature Request:

I would like either a stricter sshd config or the ability to configure a stricter sshd config.

e.g.

Ciphers [email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected]
PermitRootLogin no

I can see two ways to achieve that:

I am willing to implement this but just want to check what your preferences are first.

@jhaynes jhaynes added the enhancement New feature or request label Jul 16, 2021
@jpculp
Copy link
Member

jpculp commented Jul 16, 2021

@willthames, thank you for opening this enhancement request! After some discussion with the team, we agree that this would be a great change. We would prefer hardcoding the PermitRootLogin no directly to the sshd_config above the # Configured by user data line, and setting the ciphers via user-data like so:

{
    "ssh": {
        "authorized-keys-command": "/opt/aws/bin/eic_run_authorized_keys %u %f",
        "authorized-keys-command-user": "ec2-instance-connect",
        "ciphers": [
            "[email protected]",
            "aes128-ctr",
            "aes192-ctr",
            "aes256-ctr",
            "[email protected]",
            "[email protected]"
        ]
    }
}

Is this something you would still be willing to implement or would you rather us work on it?

@willthames
Copy link
Contributor Author

@jpculp - I'm happy with that approach - I'll hopefully submit a PR shortly

@willthames
Copy link
Contributor Author

Closed by #42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants