Skip to content

add new method for disabling ability to log in via ssh with password;…#46

Open
lukasz-piotrowski-fujitsu wants to merge 1 commit intodevelopmentfrom
task/3147
Open

add new method for disabling ability to log in via ssh with password;…#46
lukasz-piotrowski-fujitsu wants to merge 1 commit intodevelopmentfrom
task/3147

Conversation

@lukasz-piotrowski-fujitsu
Copy link
Copy Markdown
Collaborator

No description provided.

@lukasz-piotrowski-fujitsu
Copy link
Copy Markdown
Collaborator Author

Implementation checked on New3 environment; tests succeeded; details in ADO, task 3147

Comment thread cfgutils/cfgutils.go Outdated
// DisableSSHLogin disables SSH login via password by extending cloud config
func (sc *StandardCfgManager) DisableSSHLogin() error {

disableSshLoggingViaPassword := []CloudConfigItem{
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Trivial, rename for readability:

Suggested change
disableSshLoggingViaPassword := []CloudConfigItem{
disableSshPasswordAuthentication := []CloudConfigItem{

@fujitsu-domzalskis
Copy link
Copy Markdown
Collaborator

As discussed in private chat - let's check if we can simplify this mechanism by introduction of structure serializing to YAML. This solution probably works but it became quite complicated so we might want to look for another concept.

add constructor for cloudInitFile struct with optional params;
cloudInitFile constructor returns error if verification fails; add unit tests;
@lukasz-piotrowski-fujitsu
Copy link
Copy Markdown
Collaborator Author

New approach with casting cloud-config.yaml to a custom struct, tested on the test environment and production one (New3). Tests succeeded; details in task 3147 on ADO.

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.

2 participants