mirror of
https://github.com/osmarks/ngircd.git
synced 2025-01-08 14:50:27 +00:00
Use "NOTICE *" before registration instead of "NOTICE AUTH".
AUTH is a valid nickname so sending notices to it is probably not a good idea. Use * as the target instead as done with numerics when the nick is not available. This mimics the behaviour in Charybdis, IRCD-Hybrid, InspIRCd 2.2, Plexus 4, etc.
This commit is contained in:
parent
571b1a8b83
commit
d118cd74b6
@ -193,7 +193,7 @@
|
|||||||
;MorePrivacy = no
|
;MorePrivacy = no
|
||||||
|
|
||||||
# Normally ngIRCd doesn't send any messages to a client until it is
|
# Normally ngIRCd doesn't send any messages to a client until it is
|
||||||
# registered. Enable this option to let the daemon send "NOTICE AUTH"
|
# registered. Enable this option to let the daemon send "NOTICE *"
|
||||||
# messages to clients while connecting.
|
# messages to clients while connecting.
|
||||||
;NoticeAuth = no
|
;NoticeAuth = no
|
||||||
|
|
||||||
|
@ -301,7 +301,7 @@ Default: no.
|
|||||||
.TP
|
.TP
|
||||||
\fBNoticeAuth\fR (boolean)
|
\fBNoticeAuth\fR (boolean)
|
||||||
Normally ngIRCd doesn't send any messages to a client until it is registered.
|
Normally ngIRCd doesn't send any messages to a client until it is registered.
|
||||||
Enable this option to let the daemon send "NOTICE AUTH" messages to clients
|
Enable this option to let the daemon send "NOTICE *" messages to clients
|
||||||
while connecting. Default: no.
|
while connecting. Default: no.
|
||||||
.TP
|
.TP
|
||||||
\fBOperCanUseMode\fR (boolean)
|
\fBOperCanUseMode\fR (boolean)
|
||||||
|
@ -194,7 +194,7 @@ GLOBAL bool Conf_Ident;
|
|||||||
/** Enable "more privacy" mode and "censor" some user-related information */
|
/** Enable "more privacy" mode and "censor" some user-related information */
|
||||||
GLOBAL bool Conf_MorePrivacy;
|
GLOBAL bool Conf_MorePrivacy;
|
||||||
|
|
||||||
/** Enable NOTICE AUTH messages on connect */
|
/** Enable "NOTICE *" messages on connect */
|
||||||
GLOBAL bool Conf_NoticeAuth;
|
GLOBAL bool Conf_NoticeAuth;
|
||||||
|
|
||||||
/** Enable all usage of PAM, even when compiled with support for it */
|
/** Enable all usage of PAM, even when compiled with support for it */
|
||||||
|
@ -1488,15 +1488,15 @@ Conn_StartLogin(CONN_ID Idx)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (Conf_NoticeAuth) {
|
if (Conf_NoticeAuth) {
|
||||||
/* Send "NOTICE AUTH" messages to the client */
|
/* Send "NOTICE *" messages to the client */
|
||||||
#ifdef IDENTAUTH
|
#ifdef IDENTAUTH
|
||||||
if (Conf_Ident)
|
if (Conf_Ident)
|
||||||
(void)Conn_WriteStr(Idx,
|
(void)Conn_WriteStr(Idx,
|
||||||
"NOTICE AUTH :*** Looking up your hostname and checking ident");
|
"NOTICE * :*** Looking up your hostname and checking ident");
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
(void)Conn_WriteStr(Idx,
|
(void)Conn_WriteStr(Idx,
|
||||||
"NOTICE AUTH :*** Looking up your hostname");
|
"NOTICE * :*** Looking up your hostname");
|
||||||
/* Send buffered data to the client, but break on errors
|
/* Send buffered data to the client, but break on errors
|
||||||
* because Handle_Write() would have closed the connection
|
* because Handle_Write() would have closed the connection
|
||||||
* again in this case! */
|
* again in this case! */
|
||||||
@ -2267,7 +2267,7 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events )
|
|||||||
Client_SetHostname(c, readbuf);
|
Client_SetHostname(c, readbuf);
|
||||||
if (Conf_NoticeAuth)
|
if (Conf_NoticeAuth)
|
||||||
(void)Conn_WriteStr(i,
|
(void)Conn_WriteStr(i,
|
||||||
"NOTICE AUTH :*** Found your hostname: %s",
|
"NOTICE * :*** Found your hostname: %s",
|
||||||
My_Connections[i].host);
|
My_Connections[i].host);
|
||||||
#ifdef IDENTAUTH
|
#ifdef IDENTAUTH
|
||||||
++identptr;
|
++identptr;
|
||||||
@ -2293,7 +2293,7 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events )
|
|||||||
}
|
}
|
||||||
if (Conf_NoticeAuth) {
|
if (Conf_NoticeAuth) {
|
||||||
(void)Conn_WriteStr(i,
|
(void)Conn_WriteStr(i,
|
||||||
"NOTICE AUTH :*** Got %sident response%s%s",
|
"NOTICE * :*** Got %sident response%s%s",
|
||||||
*ptr ? "invalid " : "",
|
*ptr ? "invalid " : "",
|
||||||
*ptr ? "" : ": ",
|
*ptr ? "" : ": ",
|
||||||
*ptr ? "" : identptr);
|
*ptr ? "" : identptr);
|
||||||
@ -2302,7 +2302,7 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events )
|
|||||||
Log(LOG_INFO, "IDENT lookup for connection %d: no result.", i);
|
Log(LOG_INFO, "IDENT lookup for connection %d: no result.", i);
|
||||||
if (Conf_NoticeAuth)
|
if (Conf_NoticeAuth)
|
||||||
(void)Conn_WriteStr(i,
|
(void)Conn_WriteStr(i,
|
||||||
"NOTICE AUTH :*** No ident response");
|
"NOTICE * :*** No ident response");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user