[Nix-dev] Possible bug in ssh key module

Anand Patil anand.prabhakar.patil at gmail.com
Mon May 11 19:26:15 CEST 2015


Hi Bas, yep, it was just that. Sorry for the false alarm.

Thanks,
Anand

On Mon, May 11, 2015 at 12:52 AM, Bas van Dijk <v.dijk.bas at gmail.com> wrote:
> On 11 May 2015 at 04:45, Anand Patil <anand.prabhakar.patil at gmail.com> wrote:
>> Hi everyone,
>>
>>
>> Just wanted to point out a small possible bug in NixOS version
>> 15.05pre61966.75ebc3c (Dingo). I noticed that when I add an
>> authorizedKeys option to my user like so:
>>
>>     openssh.authorizedKeys.keys = [ "ssh-rsa stuff" ];
>>
>> the contents of /etc/ssh/authorized_keys.d/anand look like
>>
>> ssh-rsa
>> stuff
>>
>> with a newline after the "ssh-rsa",
>
> Hi Anand,
>
> The implementation looks correct. It only adds newlines between the keys:
>
> https://github.com/NixOS/nixpkgs/blob/75ebc3cf1dc1365be5a05018fc8e5409c66025cb/nixos/modules/services/networking/ssh/sshd.nix#L55
>
> Are you sure your string doesn't contain a newline? Maybe your text
> editor added a newline when it wrapped the string.
>
> Bas


More information about the nix-dev mailing list