28 |
|
#include "s_conf.h" |
29 |
|
#include "s_serv.h" |
30 |
|
#include "resv.h" |
31 |
– |
#include "s_stats.h" |
31 |
|
#include "channel.h" |
32 |
|
#include "client.h" |
33 |
|
#include "common.h" |
37 |
|
#include "irc_string.h" |
38 |
|
#include "sprintf_irc.h" |
39 |
|
#include "s_bsd.h" |
41 |
– |
#include "irc_getnameinfo.h" |
40 |
|
#include "irc_getaddrinfo.h" |
41 |
|
#include "ircd.h" |
42 |
|
#include "list.h" |
746 |
|
*p++ = 'A'; |
747 |
|
if (IsConfCryptLink(aconf)) |
748 |
|
*p++ = 'C'; |
751 |
– |
if (IsConfLazyLink(aconf)) |
752 |
– |
*p++ = 'L'; |
749 |
|
if (aconf->fakename) |
750 |
|
*p++ = 'M'; |
751 |
|
if (IsConfTopicBurst(aconf)) |
838 |
|
source_p->sockhost); |
839 |
|
ilog(L_INFO,"Too many connections on IP from %s.", |
840 |
|
get_client_name(source_p, SHOW_IP)); |
841 |
< |
ServerStats->is_ref++; |
841 |
> |
++ServerStats.is_ref; |
842 |
|
exit_client(source_p, &me, "No more connections allowed on that IP"); |
843 |
|
break; |
844 |
|
|
849 |
|
source_p->sockhost); |
850 |
|
ilog(L_INFO,"Too many connections from %s.", |
851 |
|
get_client_name(source_p, SHOW_IP)); |
852 |
< |
ServerStats->is_ref++; |
852 |
> |
++ServerStats.is_ref; |
853 |
|
exit_client(source_p, &me, |
854 |
|
"No more connections allowed in your connection class"); |
855 |
|
break; |
856 |
|
|
857 |
|
case NOT_AUTHORIZED: |
858 |
< |
{ |
863 |
< |
static char ipaddr[HOSTIPLEN]; |
864 |
< |
ServerStats->is_ref++; |
858 |
> |
++ServerStats.is_ref; |
859 |
|
/* jdc - lists server name & port connections are on */ |
860 |
|
/* a purely cosmetical change */ |
867 |
– |
irc_getnameinfo((struct sockaddr*)&source_p->localClient->ip, |
868 |
– |
source_p->localClient->ip.ss_len, ipaddr, HOSTIPLEN, NULL, 0, |
869 |
– |
NI_NUMERICHOST); |
861 |
|
sendto_realops_flags(UMODE_UNAUTH, L_ALL, |
862 |
|
"Unauthorized client connection from %s [%s] on [%s/%u].", |
863 |
|
get_client_name(source_p, SHOW_IP), |
864 |
< |
ipaddr, |
864 |
> |
source_p->sockhost, |
865 |
|
source_p->localClient->listener->name, |
866 |
|
source_p->localClient->listener->port); |
867 |
|
ilog(L_INFO, |
884 |
|
else |
885 |
|
exit_client(source_p, &me, "You are not authorized to use this server"); |
886 |
|
break; |
887 |
< |
} |
897 |
< |
|
887 |
> |
|
888 |
|
case BANNED_CLIENT: |
889 |
|
/* |
890 |
|
* Don't exit them immediately, play with them a bit. |
897 |
|
} |
898 |
|
else |
899 |
|
exit_client(source_p, &me, "Banned"); |
900 |
< |
ServerStats->is_ref++; |
900 |
> |
++ServerStats.is_ref; |
901 |
|
break; |
902 |
|
|
903 |
|
case 0: |
1226 |
|
* used in the hash. |
1227 |
|
*/ |
1228 |
|
void |
1229 |
< |
count_ip_hash(int *number_ips_stored, unsigned long *mem_ips_stored) |
1229 |
> |
count_ip_hash(unsigned int *number_ips_stored, uint64_t *mem_ips_stored) |
1230 |
|
{ |
1231 |
|
struct ip_entry *ptr; |
1232 |
|
int i; |
2943 |
|
* output - sendq for this client as found from its class |
2944 |
|
* side effects - NONE |
2945 |
|
*/ |
2946 |
< |
unsigned long |
2946 |
> |
unsigned int |
2947 |
|
get_sendq(struct Client *client_p) |
2948 |
|
{ |
2949 |
< |
unsigned long sendq = DEFAULT_SENDQ; |
2949 |
> |
unsigned int sendq = DEFAULT_SENDQ; |
2950 |
|
dlink_node *ptr; |
2951 |
|
struct ConfItem *conf; |
2952 |
|
struct ConfItem *class_conf; |
3278 |
|
* if target_server is NULL and an "ON" is found error |
3279 |
|
* is reported. |
3280 |
|
* if reason pointer is NULL ignore pointer, |
3281 |
< |
* this allows usee of parse_a_line in unkline etc. |
3281 |
> |
* this allows use of parse_a_line in unkline etc. |
3282 |
|
* |
3283 |
|
* - Dianora |
3284 |
|
*/ |