Handles DCC / telnet communication. More...
#include <string>
#include <vector>
#include <stack>
#include <list>
#include <map>
#include <time.h>
#include "utils.h"
#include "params.h"
#include "logic.h"
#include "sock.h"
#include "filesys.h"
#include "threads.h"
#include "utils/my_assert.h"
Go to the source code of this file.
Classes | |
class | c_dcc_awaiting_user |
Stores awaiting user on DCC request to process. More... | |
Defines | |
#define | DCC_ACCESS_DENIED 2 |
Access denied. | |
#define | DCC_AGAIN 4 |
Should be called again (because IP address has not been resolved yet). | |
#define | DCC_IO_ERROR 3 |
I/O error while accessing file. | |
#define | DCC_NO_SUCH_FILE 1 |
No such file. | |
Functions | |
void | dcc_apply (string who) |
Called after .apply. Applies new configuration to all connected users on DCC/telnet (also BOTNET) connections. | |
void | dcc_broadcast (string user_mask, string msg, string sender, string bot_mask) |
Broatcasts the message to users that matches mask on DCC/telnet connection. | |
void | dcc_broadcast (const string &msg) |
Broatcasts the message to all connected users on DCC/telnet connection (used for kill message). | |
void | dcc_close_all () |
Closes all DCC/telnet connections. | |
void | dcc_close_servers () |
Closes listening sockets. | |
void | dcc_file_has_been_read (string public_name, string nick) |
Called to set the READ-"ed" flag and notify OWNER(s) if needed. | |
void | dcc_flush_all () |
Flushes all pending DCC/telnet connection caches. | |
string | dcc_get_password (string user) |
Gets MD5-encoded password for user. | |
string | dcc_get_string (string msg, int &dcc_group, int &ip_ver) |
Constructs response to "dcc" or "dcc <group_number>" PRIVMSG. | |
void | dcc_loop () |
Check for pending connections and handles existing ones. | |
void | dcc_make_server (int ipv, int group, const string &bind_ip, unsigned short bind_port, string server_type) |
Binds DCC server. | |
void | dcc_make_telnet_server (int ipv, const string &bind_ip, unsigned short bind_port, bool pure_ssl=false) |
Binds telnet server. | |
void | dcc_notify (string user, int reason, string incomplete_file) |
Notifies user about filesystem events. | |
void | dcc_partyline_message (string channel, string message) |
Message for partyline channel distribution. | |
void | dcc_rehashed (string who) |
Called from logic.cpp after rehashing. Applies new configuration to all connected users on DCC/telnet (also BOTNET) connections. | |
int | dcc_send_file (bool from_dcc, string public_name, string nick, int dcc_group) |
Sends file to remote host. | |
void | dcc_send_msg (c_socket &socket, string msg, int &ec, c_ssl *ssl) |
Sends a message to DCC CHAT / telnet connection and updates statistics. | |
void | dcc_set_bot_logged_in (c_socket *remote) |
Sets logged-in flag for remote bot (for .stat command), as callback from botnet.cpp. | |
void | dcc_update_dynamic_servers (string irc_host) |
Updates bind host to listening dynamic servers. | |
void | dcc_upgrade_bot_join (string nick, string ident, string host, string fullname, string channel) |
Called in UPGRADE state, to inform user who initiated .upgrade command that another instance is on channel. | |
void | dcc_upgrade_bot_mode (string nick, string ident, string host, string fullname, string channel, string mode, string src) |
Called in UPGRADE state, to inform user who initiated .upgrade command that another instance on some channel gets some mode. | |
void | dcc_upgrade_bot_nick (string nick, string ident, string host, string fullname, string new_nick) |
Called in UPGRADE state, to inform user who initiated .upgrade command that another instance changed its nick. | |
void | dcc_user_pong (string user, string origin_bot, string name, string number, string comment) |
Message for partyline user's pong (BOT_VERSION reply). | |
void | dcc_user_pong (string time_, string user, string origin_bot) |
Message for partyline user's pong. | |
void | irc_quoted_callback (const string &str, const string &nick, const string &host_mask, const string &comment) |
Called when 0x01-quoted PRIVMSG has been received to initialise DCC CHAT or DCC SEND connection. |
Handles DCC / telnet communication.
Definition in file dcc.h.