protocol: Add "Hello" message at connection start, also for unauthed peers

This commit is contained in:
Audrius Butkevicius
2016-03-25 20:29:07 +00:00
parent 1d17891286
commit b4f9a55e6e
9 changed files with 267 additions and 139 deletions

View File

@@ -189,12 +189,12 @@ func TestClose(t *testing.T) {
}
func TestElementSizeExceededNested(t *testing.T) {
m := ClusterConfigMessage{
m := HelloMessage{
ClientName: "longstringlongstringlongstringinglongstringlongstringlonlongstringlongstringlon",
}
_, err := m.MarshalXDR()
if err == nil {
t.Errorf("ID length %d > max 64, but no error", len(m.Folders[0].ID))
t.Errorf("ID length %d > max 64, but no error", len(m.ClientName))
}
}