identd: use UNKNOWN for OS name

Some servers like snircd reject OTHER [1], because OTHER can be
used when the ident string is not stable (e.g. is an audit token
that changes each time the ident is queried).

[1]: 17c92003d3/ircd/s_auth.c (L559)
This commit is contained in:
Simon Ser 2023-02-23 13:27:25 +01:00
parent 21eb384bd6
commit f7fbf2ea72
1 changed files with 4 additions and 1 deletions

View File

@ -129,7 +129,10 @@ func (s *Identd) handle(c net.Conn) {
break
}
fmt.Fprintf(c, "%s : USERID : OTHER : %s\r\n", l, ident)
// The "OTHER" operating system may be rejected by IRC servers, because
// it may be used when the ident string isn't stable. Use "UNKNOWN"
// from RFC 1340 instead.
fmt.Fprintf(c, "%s : USERID : UNKNOWN : %s\r\n", l, ident)
}
}