Skip to content

Commit 70c657b

Browse files
committed
fix sending RSA signature flag with a non RSA key
1 parent 7598a17 commit 70c657b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/ssh_agent_client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ export class SSHAgentClient {
151151
let offset = writeHeader(req, Protocol.SSH2_AGENTC_SIGN_REQUEST)
152152
offset = writeString(req, key.raw, offset)
153153
offset = writeString(req, data, offset)
154-
req.writeUInt32BE(this.rsaSignatureFlag, offset)
154+
req.writeUInt32BE(key.type === 'ssh-rsa' ? this.rsaSignatureFlag : 0, offset)
155155
return req
156156
}
157157

0 commit comments

Comments
 (0)