Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Security and hardening

git pull over SSH fails because client and server share no signature algorithm for your key

Errorsign_and_send_pubkey: no mutual signature supported

Short answer

OpenSSH found no signature algorithm that both your configured list and the server accept for your key, so it never sent the key. Most often an RSA key meets a server that only knows SHA-1 signatures, which OpenSSH 8.8 switched off. Move to an Ed25519 key, or check your own PubkeyAcceptedAlgorithms list.

  • Applies to OpenSSH 8.8 to 10.x client, Git 2.4x
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    Show the debug lines that name the algorithm problem, the algorithm list your client may use for public keys, and the type of each public key you own.

    ssh -vvv git@git.example.com 2>&1 | grep -E "mutual signature|Skipping .* key"
    ssh -G git.example.com | grep -i pubkeyaccepted
    for f in ~/.ssh/*.pub; do echo "$f: $(cut -d' ' -f1 "$f")"; done
  2. 2Match what you see, then jump to its fix

    1. 1The key type printed is ssh-rsa, the client is OpenSSH 8.8 or newer, and the host is an old SSH server or an older self-hosted Git product.The server only understands SHA-1 RSA signatures, and your client turned them offFix
    2. 2The error also appears against a modern server, and ssh -G prints a short pubkeyacceptedalgorithms list without rsa-sha2-256 or rsa-sha2-512.Your own PubkeyAcceptedAlgorithms list leaves out the algorithm your key needsFix
    3. 3cut prints ssh-dss for your key file, and no algorithm is left once the defaults are applied.The key is a DSA keyFix

What does the error look like?

  • sign_and_send_pubkey: no mutual signature supported
  • debug1: send_pubkey_test: no mutual signature algorithm
  • Skipping <type> key <fingerprint> - corresponding algorithm not supported by server
  • Permission denied (publickey).

Cause 1 of 3

The server only understands SHA-1 RSA signatures, and your client turned them off

1Check

OpenSSH 8.8 disabled RSA signatures made with SHA-1 by default. Existing RSA keys keep working through the SHA-256 and SHA-512 signature types, which OpenSSH has supported since 7.2, but a server that cannot verify those has nothing left to accept.

ssh -V
for f in ~/.ssh/*.pub; do echo "$f: $(cut -d' ' -f1 "$f")"; done

2Fix

The lasting fix is to update the server or to use an Ed25519 key and add its public half to the server or Git account. If you must reach the old host before that, allow the SHA-1 type for that one host only and remove the lines once the server is updated.

ssh-keygen -t ed25519 -C "laptop-2026"

# stopgap in ~/.ssh/config, for this host only
Host git.example.com
    PubkeyAcceptedAlgorithms +ssh-rsa

3Verify

The debug lines from the first step no longer appear and the login completes.

ssh -o IdentitiesOnly=yes -i ~/.ssh/id_ed25519 -T git@git.example.com

Confirmed by openssh.org

Did this fix it?

Cause 2 of 3

Your own PubkeyAcceptedAlgorithms list leaves out the algorithm your key needs

1Check

ssh only signs with an algorithm that passes your PubkeyAcceptedAlgorithms filter, and for the first attempt also the list the server announces. A line in your config or in a system-wide file that replaces the default list can leave the RSA key with nothing to use.

ssh -G git.example.com | grep -i pubkeyaccepted
grep -rn -i "PubkeyAccepted" ~/.ssh/config /etc/ssh/ssh_config /etc/ssh/ssh_config.d/ 2>/dev/null

2Fix

Delete the override, or change it so it adds to the default list instead of replacing it: a leading + appends the names that follow.

# ~/.ssh/config
Host git.example.com
    PubkeyAcceptedAlgorithms +rsa-sha2-256,rsa-sha2-512

3Verify

ssh -G lists the SHA-2 RSA names for the host, and the debug lines are gone.

ssh -G git.example.com | grep -i pubkeyaccepted

Confirmed by raw.githubusercontent.com

Did this fix it?

Cause 3 of 3

The key is a DSA key

1Check

OpenSSH has disabled DSA keys by default since 2015 (release 7.0), and from release 9.8 DSA support is also switched off at compile time unless the build asks for it.

for f in ~/.ssh/*.pub; do echo "$f: $(cut -d' ' -f1 "$f")"; done

2Fix

Create an Ed25519 key and replace the DSA public key on the server or Git account. Re-enabling DSA is a build-time choice on current OpenSSH, so a new key is the practical way out.

ssh-keygen -t ed25519 -C "laptop-2026"
cat ~/.ssh/id_ed25519.pub

3Verify

The first step lists an ssh-ed25519 key, and the login works with it.

ssh -o IdentitiesOnly=yes -i ~/.ssh/id_ed25519 -T git@git.example.com

Confirmed by openssh.org

Did this fix it?

How do I stop it coming back?

  • Use Ed25519 for every new key, and replace old DSA and short-lived RSA keys while you still have access to the servers.
  • Do not set PubkeyAcceptedAlgorithms to a fixed list; if you must change it, use the + form so the defaults stay.
  • Keep SSH servers and Git hosting products on versions that implement the SHA-2 RSA signatures.
  • Scope any SHA-1 stopgap to a single Host block and write down when to remove it.

Sources

How was this page made?

I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.

Related fixes

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.