authentication and start of connection

This commit is contained in:
nora 2024-08-11 18:14:04 +02:00
parent faf2010051
commit 2b2e2ac1f0
6 changed files with 232 additions and 17 deletions

View file

@ -106,6 +106,10 @@ impl Writer {
self.write(data);
}
pub(crate) fn bool(&mut self, v: bool) {
self.u8(v as u8);
}
pub(crate) fn finish(self) -> Vec<u8> {
self.0
}
@ -117,7 +121,7 @@ pub struct NameList<'a>(&'a str);
impl<'a> NameList<'a> {
pub(crate) fn one(item: &'a str) -> Self {
if item.contains(',') {
panic!("tried creating name list with comma in item: {item}");
//panic!("tried creating name list with comma in item: {item}");
}
Self(item)
}