Cannot set ssh key on Vyos 1.5

Why does this fail?

vyos@vyos:~$ configure
[edit]
vyos@vyos# set system login user vyos authentication public-keys mykey key 'AAAAB3NzaC1yc2EAAAADAQABAAACAQCcVpkF/LdgnOucqxkjoE4DHvwxHz8WmwUp7AqUnPnED78DUrB7zAwPifESfeG73+ynKeYD0sE0sBgvRAow8SW0jPc40JM6Wejx9WLD5sMknbfGq62a4k7AooyeA1umCyj7pZ8IPCUgeyy58Q7Npy5rRI3U1wlEtPPiFQfzAMgLrz0ZEgKyUClC91vzx/RS2tsQE6yrmPX48DzBLkkz1Un+GA2OBUBafVTuZfby/FFeGtnMjWP0R3TOKzACdjRW2VBeb4DBtoP5V66kXnujWllOAiuUwTiiSJJtHtRGQ35K9BzJOC+iLxj/QwEGUZMpBcTz/qR7jUpUW/+0S+R4dBK02scIxQxHVY9P6JfdaFz9hEUJIpb2A/Ay7ei6RZitNXgojndcgFMXhiH8bIST+jv07tXMb5mPQAWMXCNvDFBAKpW9Dyy2lhnmuP97qGi6VT2vRapow2E9CssxR1o+t5qN1o4CjAVIjGGU3ax+iud/2RArQKso7DSHx+GL0U1G45wdQ/yMwbC/VMm8Aym5ifxUTargEb7MPy1D5/nR+Fi6wfVMJQ9GiYaiByRVUzLv/TtW5+vLk9rCpV5SsNWSsjOcaCYmeK1yZexWBJZQyytjW5PWj11+C0WQ2C4vy9b7YGwHam2eSvFyKF2BJ5HQUNBV1kdY8jGBNBvUW9PSdJk/CQ=='

  Set failed

[edit]

It’s a good question. I tried the same line on my 1.4 box and it was accepted without issue.

I would raise a bug if you’re able.

Thank you. It is interesting that Vyos 1.5 build scripts is the only version available but something so basic as setting an ssh key fails, and the authorized_keys files in create by the vyos configuration. Moreover, there has been no response as of today as it relates to 1.5 and this issue.

Hi @alpha23 , What version are you running?

i’ve tested on vyos 1.5-rolling-202408040023 and find it working on my side.

runar@vyos# set system login user test authentication public-keys mykey key 'AAAAB3NzaC1yc2EAAAADAQABAAACAQCcVpkF/LdgnOucqxkjoE4DHvwxHz8WmwUp7AqUnPnED78DUrB7zAwPifESfeG73+ynKeYD0sE0sBgvRAow8SW0jPc40JM6Wejx9WLD5sMknbfGq62a4k7AooyeA1umCyj7pZ8IPCUgeyy58Q7Npy5rRI3U1wlEtPPiFQfzAMgLrz0ZEgKyUClC91vzx/RS2tsQE6yrmPX48DzBLkkz1Un+GA2OBUBafVTuZfby/FFeGtnMjWP0R3TOKzACdjRW2VBeb4DBtoP5V66kXnujWllOAiuUwTiiSJJtHtRGQ35K9BzJOC+iLxj/QwEGUZMpBcTz/qR7jUpUW/+0S+R4dBK02scIxQxHVY9P6JfdaFz9hEUJIpb2A/Ay7ei6RZitNXgojndcgFMXhiH8bIST+jv07tXMb5mPQAWMXCNvDFBAKpW9Dyy2lhnmuP97qGi6VT2vRapow2E9CssxR1o+t5qN1o4CjAVIjGGU3ax+iud/2RArQKso7DSHx+GL0U1G45wdQ/yMwbC/VMm8Aym5ifxUTargEb7MPy1D5/nR+Fi6wfVMJQ9GiYaiByRVUzLv/TtW5+vLk9rCpV5SsNWSsjOcaCYmeK1yZexWBJZQyytjW5PWj11+C0WQ2C4vy9b7YGwHam2eSvFyKF2BJ5HQUNBV1kdY8jGBNBvUW9PSdJk/CQ=='
runar@vyos# set system login user test authentication public-keys mykey type ssh-rsa
[edit]
runar@vyos# commit
[edit]
runar@vyos#

i’ve also verified that the key is successfully added to the user.

Can you test it with the user vyos?

Thank you.

Looks like you use some automatisation scripts with incorrect rights for group
The user can be any all woks without issues

Just a quick annotation:
Around two days ago I’ve configured a vyos 1.5-nightly user’s ssh key using a blank instead of the @ symbol (out of curiousity). The command succeeded. But the machine didn’t come up during the next boot, because of an configuration file error. I had to start in rescue mode and replace the blank against the @. Afterwars the machine came up again without problems. Conclusion: ssh key input validation seems to need some tuning.

This topic was automatically closed after 14 days. New replies are no longer allowed.