Patch submitted upstream: https://lists.mindrot.org/pipermail/openssh-unix- dev/2018-June/036990.html
The patch in my ML post above applies to the OpenBSD version of OpenSSH. I've attached another version that applies to the portable release 7.7p1 here. ** Patch added: "0001-permit-underscore-in-user-environment.patch" https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1771011/+attachment/5155211/+files/0001-permit-underscore-in-user-environment.patch -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to openssh in Ubuntu. https://bugs.launchpad.net/bugs/1771011 Title: Doesn't accept environment variable with underscore in its name in AuthorizedKeysFile Status in openssh package in Ubuntu: Triaged Bug description: If environment variable name defined in AuthorizedKeysFile contains underscore character (environment="FOO_BAR=1" ...), sshd refuses connection and throws following error: authorized_keys:1: bad key options: invalid environment string To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1771011/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp