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

fix(BA-459): password based SSH login not working #3387

Merged
merged 2 commits into from
Jan 8, 2025

Conversation

kyujin-cho
Copy link
Member

Resolves #3386.

Checklist: (if applicable)

  • Milestone metadata specifying the target backport version
  • Mention to the original issue

@kyujin-cho kyujin-cho added the comp:agent Related to Agent component label Jan 6, 2025
@kyujin-cho kyujin-cho added this to the 24.09 milestone Jan 6, 2025
@kyujin-cho kyujin-cho self-assigned this Jan 6, 2025
@github-actions github-actions bot added the size:XS ~10 LoC label Jan 6, 2025
@kyujin-cho kyujin-cho requested a review from achimnol January 6, 2025 09:40
@@ -55,7 +55,7 @@ if [ $USER_ID -eq 0 ]; then
/opt/backend.ai/bin/python -s /opt/kernel/fantompass.py > "$HOME/.password"
export ALPHA_NUMERIC_VAL=$(cat $HOME/.password)
chmod 0644 "$HOME/.password"
echo "work:$ALPHA_NUMERIC_VAL" | chpasswd
echo "work:$ALPHA_NUMERIC_VAL" | chpasswd -c SHA512
Copy link
Collaborator

Choose a reason for hiding this comment

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

In the case where the issue occurred, there shouldn’t be a problem since there were no previously stored hash values, right?
In the normal operation scenario, hash values would have been stored, but changing the hashing algorithm shouldn’t cause any issues?

Copy link
Member Author

@kyujin-cho kyujin-cho Jan 8, 2025

Choose a reason for hiding this comment

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

I can find that Ubuntu introduced SHA512 password hashing algorithm at 8.10 and RHEL from 5. So yes, at least for the Linux distros supported by Backend.AI, it will be fine to fix the password hashing method as SHA512.

Copy link
Collaborator

@HyeockJinKim HyeockJinKim left a comment

Choose a reason for hiding this comment

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

lgtm

@kyujin-cho kyujin-cho added this pull request to the merge queue Jan 8, 2025
Merged via the queue into main with commit 96d2162 Jan 8, 2025
20 checks passed
@kyujin-cho kyujin-cho deleted the fix/ssh-password-login-not-working branch January 8, 2025 05:20
lablup-octodog pushed a commit that referenced this pull request Jan 8, 2025
Backported-from: main (24.12)
Backported-to: 24.09
Backport-of: 3387
github-merge-queue bot pushed a commit that referenced this pull request Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:agent Related to Agent component size:XS ~10 LoC
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Password based authentication not working when connecting to container with SSH
2 participants