Fix bug where connection would be closed without returning unhandled response for unknown messages

This commit is contained in:
Max Goedjen 2025-10-25 11:27:12 -07:00
parent 65bc6c1a69
commit 4cba538eb9
No known key found for this signature in database

View File

@ -47,6 +47,7 @@ extension Agent {
logger.debug("Agent returned \(SSHAgent.Response.agentSignResponse.debugDescription)")
case .unknown(let value):
logger.error("Agent received unknown request of type \(value).")
throw UnhandledRequestError()
default:
logger.debug("Agent received valid request of type \(request.debugDescription), but not currently supported.")
throw UnhandledRequestError()