|
|||
|
|||
|
Typedefs | |
| typedef sockaddr_in | insp_sockaddr |
| insp_sockaddr for ipv4 | |
| typedef in_addr | insp_inaddr |
| insp_inaddr for ipv4 | |
Functions | |
| bool | MatchCIDRBits (const unsigned char *address, const unsigned char *mask, unsigned int mask_bits) |
| Match raw binary data using CIDR rules. | |
| bool | MatchCIDR (const std::string &address, const std::string &cidr_mask) |
| Match CIDR, without matching username/nickname parts. | |
| bool | MatchCIDR (const std::string &address, const std::string &cidr_mask, bool match_with_username) |
| Match CIDR, including an optional username/nickname part. | |
| int | OpenTCPSocket (char *addr, int socktype=SOCK_STREAM) |
| Create a new valid file descriptor using socket(). | |
| const char * | insp_ntoa (insp_inaddr n) |
| Convert an insp_inaddr into human readable form. | |
| int | insp_aton (const char *a, insp_inaddr *n) |
| Convert a human-readable address into an insp_inaddr. | |
It also contains some types which are often used by the core and modules in place of inet_* functions and types.
|
|
insp_inaddr for ipv4
|
|
|
insp_sockaddr for ipv4
|
|
||||||||||||
|
Convert a human-readable address into an insp_inaddr.
Definition at line 394 of file socket.cpp. References AF_FAMILY. Referenced by DispatcherThread(), Resolver::Resolver(), and SQLConn::SendNotify(). |
|
|
Convert an insp_inaddr into human readable form.
Definition at line 387 of file socket.cpp. References AF_FAMILY. Referenced by DNS::GetName(). |
|
||||||||||||||||
|
Match CIDR, including an optional username/nickname part. This function will compare a human-readable address (plus optional username and nickname) against a human-readable CIDR mask, for example joe!bloggs@1.2.3.4 against *!bloggs@1.2.0.0/16. This method supports both IPV4 and IPV6 addresses.
Definition at line 68 of file cidr.cpp. References match(), MatchCIDR(), and MatchCIDRBits(). |
|
||||||||||||
|
Match CIDR, without matching username/nickname parts. This function will compare a human-readable address against a human- readable CIDR mask, for example 1.2.3.4 against 1.2.0.0/16. This method supports both IPV4 and IPV6 addresses.
Definition at line 56 of file cidr.cpp. Referenced by match(), MatchCIDR(), and TreeSocket::OnIncomingConnection(). |
|
||||||||||||||||
|
Match raw binary data using CIDR rules. This function will use binary comparison to compare the two bit sequences, address and mask, up to mask_bits bits in size. If they match, it will return true.
Definition at line 36 of file cidr.cpp. References inverted_bits. Referenced by MatchCIDR(). |
|
||||||||||||
|
Create a new valid file descriptor using socket().
Definition at line 273 of file socket.cpp. References ERROR. Referenced by BufferedSocket::BufferedSocket(), ListenSocket::ListenSocket(), and DNS::Rehash(). |