transport improvements

This commit is contained in:
nora 2024-08-30 17:43:09 +02:00
parent 026965bda5
commit 8de8204bc7
6 changed files with 147 additions and 45 deletions

View file

@ -194,6 +194,9 @@ impl<'a> NameList<'a> {
pub fn none() -> NameList<'static> {
NameList("")
}
pub fn contains(&self, name: &str) -> bool {
self.iter().any(|n| n == name)
}
pub fn iter(&self) -> std::str::Split<'a, char> {
self.0.split(',')
}

View file

@ -35,6 +35,8 @@ consts! {
const SSH_MSG_DEBUG = 4;
const SSH_MSG_SERVICE_REQUEST = 5;
const SSH_MSG_SERVICE_ACCEPT = 6;
const SSH_MSG_EXT_INFO = 7;
const SSH_MSG_NEWCOMPRESS = 8;
// 20 to 29 Algorithm negotiation
const SSH_MSG_KEXINIT = 20;