handleMSG_CHANNEL_REQUEST method
Implementation
void handleMSG_CHANNEL_REQUEST(MSG_CHANNEL_REQUEST msg) {
if (tracePrint != null) {
tracePrint(
'$hostport: MSG_CHANNEL_REQUEST ${msg.requestType} wantReply=${msg.wantReply}');
}
Channel chan = channels[msg.recipientChannel];
if (chan == sessionChannel &&
sessionChannelRequest != null &&
sessionChannelRequest(this, msg.requestType)) {
if (msg.wantReply) {
writeCipher(MSG_CHANNEL_SUCCESS(chan.remoteId));
}
} else {
if (msg.wantReply) {
writeCipher(MSG_CHANNEL_FAILURE(chan != null ? chan.remoteId : 0));
}
}
}