Closed art-w closed 2 years ago
Looks fine to me, thanks. The "generic" version (and allowing the client to send such data) can be implemented at a later point, if it is needed. I can as well only find usage of type 1 (standard error), the rest seems to be reserved for private use.
When executing shell commands, the ssh server can send stderr via the extended data channel:
https://github.com/mirage/awa-ssh/blob/d85a95c90a6ef7816c8bc093742fb841ea176680/docs/rfc4254.txt#L412-L432
But currently, the awa client fails with an
"unexpected state and message"
since it doesn't expect anyMsg_channel_extended_data
. Note that this PR only handles theSSH_EXTENDED_DATA_STDERR=1
case as I'm not aware of other extensions, but perhaps it should return a generic`Channel_extended_data (id, data_type_code, data)
and leave the user to interpret the meaning ofdata_type_code
?