Bug#987849: ssh: misleading "invalid format" message about public key when using private key

xavier renaut <xavier.reportbug-debian.ssh.natch.2021.04.30.16.11.42@pecos.8d.com>
Newsgroups gmane.linux.debian.devel.ssh
Message-ID <161981417644.26826.17261047721157822553.reportbug__8856.81465021975$1619814804$gmane$org@natch.usine.8d.com>
Package: ssh
Version: 1:7.9p1-10+deb10u2
Severity: wishlist

Dear Maintainer,


   * What led up to the situation?

I deployed a new set of ssh-keys on a machine. 
I installed (not on purpose) id_ed25519.pub with the from="ip" in front of the key.



   * What exactly did you do (or not do) that was effective (or
     ineffective)?

I'm trying to ssh from the host_1 to host_2

when running ssh from host_1 :
load pubkey "/home/devops/.ssh/id_ed25519": invalid format
[email protected]: Permission denied (publickey,password).

I assumed my private key was wrong here, thus ending in authentication failure
(turns out it was not related, it was an issue on host_2)

   * What was the outcome of this action?

I started investigating my private key.

   * What outcome did you expect instead?

instead of : 
load pubkey "/home/devops/.ssh/id_ed25519": invalid format

I would like to see a .pub at the end, and also something that says "informational, non-critical, non-related to current operation"

Something like :
+FYI not related
+ .pub at the end of the file name :
+ s/pub/loading Public/

FYI, not related : loading Public key "/home/devops/.ssh/id_ed25519.pub": invalid format





-- System Information:
Debian Release: 10.8
  APT prefers stable
  APT policy: (900, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.19.0-10-amd64 (SMP w/12 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8), LANGUAGE=en_CA:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages ssh depends on:
ii  dpkg            1.19.7
ii  openssh-client  1:7.9p1-10+deb10u2
ii  openssh-server  1:7.9p1-10+deb10u2

ssh recommends no packages.

ssh suggests no packages.

-- no debconf information
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.