When pushing a Git repository from OpenWrt to a Raspberry Pi, Bad buf_getwriteptr can appear on the initiating router. Identify the ssh program that produced the error. Logging into the router from your computer tests the opposite direction. A case on 25.12.3 involved the Dropbear client; it did not establish that the remote repository was damaged.
Identify the SSH client on the router
command -v ssh
readlink -f "$(command -v ssh)"
dbclient -V
apk list --installed dropbear
if [ -S "$SSH_AUTH_SOCK" ]; then echo agent-present; else echo no-agent-socket; fi

If the path and version identify OpenSSH, use that client’s diagnostics. For Dropbear, record agent forwarding, destination port, remote account and public key type. The x86/64 test checked the program identity; it did not reproduce the Raspberry Pi failure. A restricted Git account and an interactive login may permit different commands.
Keep the server settings fixed and vary one authentication condition
Keep the working management session and original public key. Temporarily authorize a second supported public key, such as Ed25519, on a test account you administer. Keep its private key on the client that generated it. Verify the server fingerprint through a trusted channel and test each identity from the same client to the same host and port. If an agent is involved, also try a separate session without agent forwarding, using the approved test identity. Match each attempt to its timestamp in the server authentication log.
If one identity works and the other triggers the buffer error, record both software versions, the algorithms and agent use. An 8192-bit RSA key worked in another configuration, so key length alone is inconclusive. For a timeout before the connection opens, check the address, port and route first. Run git ls-remote with the existing remote name or URL. Seeing the expected refs verifies repository read access. Confirm that the original management login still works before removing the test authorization.
Comments