2001-12-12 18:18:20 +01:00
|
|
|
/*
|
|
|
|
* ngIRCd -- The Next Generation IRC Daemon
|
2002-01-02 03:44:36 +01:00
|
|
|
* Copyright (c)2001,2002 by Alexander Barton (alex@barton.de)
|
2001-12-12 18:18:20 +01:00
|
|
|
*
|
|
|
|
* Dieses Programm ist freie Software. Sie koennen es unter den Bedingungen
|
|
|
|
* der GNU General Public License (GPL), wie von der Free Software Foundation
|
|
|
|
* herausgegeben, weitergeben und/oder modifizieren, entweder unter Version 2
|
|
|
|
* der Lizenz oder (wenn Sie es wuenschen) jeder spaeteren Version.
|
|
|
|
* Naehere Informationen entnehmen Sie bitter der Datei COPYING. Eine Liste
|
2001-12-31 03:18:51 +01:00
|
|
|
* der an ngIRCd beteiligten Autoren finden Sie in der Datei AUTHORS.
|
2001-12-12 18:18:20 +01:00
|
|
|
*
|
2002-03-10 19:47:02 +01:00
|
|
|
* $Id: conf.h,v 1.12 2002/03/10 18:47:02 alex Exp $
|
2001-12-12 18:18:20 +01:00
|
|
|
*
|
|
|
|
* conf.h: Konfiguration des ngircd (Header)
|
|
|
|
*
|
|
|
|
* $Log: conf.h,v $
|
2002-03-10 19:47:02 +01:00
|
|
|
* Revision 1.12 2002/03/10 18:47:02 alex
|
|
|
|
* *** empty log message ***
|
|
|
|
*
|
2002-03-10 18:50:48 +01:00
|
|
|
* Revision 1.11 2002/03/10 17:50:48 alex
|
2002-03-10 19:47:02 +01:00
|
|
|
* - Server-Gruppen implementiert.
|
2002-03-10 18:50:48 +01:00
|
|
|
*
|
2002-02-28 00:23:53 +01:00
|
|
|
* Revision 1.10 2002/02/27 23:23:53 alex
|
|
|
|
* - Includes fuer einige Header bereinigt.
|
|
|
|
*
|
2002-01-03 03:27:20 +01:00
|
|
|
* Revision 1.9 2002/01/03 02:27:20 alex
|
|
|
|
* - das Server-Passwort kann nun konfiguriert werden.
|
|
|
|
*
|
2002-01-02 03:49:15 +01:00
|
|
|
* Revision 1.8 2002/01/02 02:49:16 alex
|
|
|
|
* - Konfigurationsdatei "Samba like" umgestellt.
|
|
|
|
* - es koennen nun mehrere Server und Oprtatoren konfiguriert werden.
|
2002-01-02 03:44:36 +01:00
|
|
|
*
|
2001-12-31 03:18:51 +01:00
|
|
|
* Revision 1.6 2001/12/31 02:18:51 alex
|
|
|
|
* - viele neue Befehle (WHOIS, ISON, OPER, DIE, RESTART),
|
|
|
|
* - neuen Header "defines.h" mit (fast) allen Konstanten.
|
|
|
|
* - Code Cleanups und viele "kleine" Aenderungen & Bugfixes.
|
|
|
|
*
|
2001-12-30 20:26:11 +01:00
|
|
|
* Revision 1.5 2001/12/30 19:26:11 alex
|
|
|
|
* - Unterstuetzung fuer die Konfigurationsdatei eingebaut.
|
|
|
|
*
|
2001-12-26 23:48:53 +01:00
|
|
|
* Revision 1.4 2001/12/26 22:48:53 alex
|
|
|
|
* - MOTD-Datei ist nun konfigurierbar und wird gelesen.
|
|
|
|
*
|
2001-12-26 15:45:37 +01:00
|
|
|
* Revision 1.3 2001/12/26 14:45:37 alex
|
|
|
|
* - "Code Cleanups".
|
|
|
|
*
|
2001-12-26 04:19:57 +01:00
|
|
|
* Revision 1.2 2001/12/26 03:19:57 alex
|
|
|
|
* - erste Konfigurations-Variablen definiert: PING/PONG-Timeout.
|
|
|
|
*
|
2001-12-12 18:18:20 +01:00
|
|
|
* Revision 1.1 2001/12/12 17:18:20 alex
|
|
|
|
* - Modul fuer Server-Konfiguration begonnen.
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef __conf_h__
|
|
|
|
#define __conf_h__
|
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
#include <time.h>
|
|
|
|
|
2002-02-28 00:23:53 +01:00
|
|
|
#include "conn.h"
|
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
|
|
|
|
typedef struct _Conf_Oper
|
|
|
|
{
|
2002-03-10 18:50:48 +01:00
|
|
|
CHAR name[CLIENT_PASS_LEN]; /* Name (ID) des IRC-OPs */
|
|
|
|
CHAR pwd[CLIENT_PASS_LEN]; /* Passwort */
|
2002-01-02 03:44:36 +01:00
|
|
|
} CONF_OPER;
|
|
|
|
|
|
|
|
typedef struct _Conf_Server
|
|
|
|
{
|
2002-03-10 18:50:48 +01:00
|
|
|
CHAR host[HOST_LEN]; /* Hostname */
|
|
|
|
CHAR ip[16]; /* IP-Adresse (von Resolver) */
|
|
|
|
CHAR name[CLIENT_ID_LEN]; /* IRC-Client-ID */
|
|
|
|
CHAR pwd[CLIENT_PASS_LEN]; /* Passwort */
|
|
|
|
INT port; /* Server-Port */
|
|
|
|
INT group; /* Gruppe des Servers */
|
|
|
|
time_t lasttry; /* Letzter Connect-Versuch */
|
|
|
|
RES_STAT *res_stat; /* Status des Resolver */
|
2002-01-02 03:44:36 +01:00
|
|
|
} CONF_SERVER;
|
|
|
|
|
|
|
|
|
|
|
|
/* Konfigurationsdatei */
|
|
|
|
GLOBAL CHAR Conf_File[FNAME_LEN];
|
|
|
|
|
|
|
|
/* Name ("Nick") des Servers */
|
|
|
|
GLOBAL CHAR Conf_ServerName[CLIENT_ID_LEN];
|
|
|
|
|
|
|
|
/* Servers-Info-Text */
|
|
|
|
GLOBAL CHAR Conf_ServerInfo[CLIENT_INFO_LEN];
|
2001-12-12 18:18:20 +01:00
|
|
|
|
2002-01-03 03:27:20 +01:00
|
|
|
/* Server-Passwort */
|
|
|
|
GLOBAL CHAR Conf_ServerPwd[CLIENT_PASS_LEN];
|
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Datei mit MOTD-Text */
|
|
|
|
GLOBAL CHAR Conf_MotdFile[FNAME_LEN];
|
2001-12-26 23:48:53 +01:00
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Ports, auf denen der Server Verbindungen entgegen nimmt */
|
|
|
|
GLOBAL INT Conf_ListenPorts[MAX_LISTEN_PORTS];
|
|
|
|
GLOBAL INT Conf_ListenPorts_Count;
|
2001-12-26 23:48:53 +01:00
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Timeouts fuer PING und PONG */
|
|
|
|
GLOBAL INT Conf_PingTimeout;
|
|
|
|
GLOBAL INT Conf_PongTimeout;
|
2001-12-26 23:48:53 +01:00
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Sekunden zwischen Verbindungsversuchen zu anderen Servern */
|
|
|
|
GLOBAL INT Conf_ConnectRetry;
|
2001-12-26 23:48:53 +01:00
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Operatoren */
|
|
|
|
GLOBAL CONF_OPER Conf_Oper[MAX_OPERATORS];
|
|
|
|
GLOBAL INT Conf_Oper_Count;
|
2001-12-31 03:18:51 +01:00
|
|
|
|
2002-01-02 03:44:36 +01:00
|
|
|
/* Server */
|
|
|
|
GLOBAL CONF_SERVER Conf_Server[MAX_SERVERS];
|
|
|
|
GLOBAL INT Conf_Server_Count;
|
2001-12-26 04:19:57 +01:00
|
|
|
|
|
|
|
|
2001-12-12 18:18:20 +01:00
|
|
|
GLOBAL VOID Conf_Init( VOID );
|
|
|
|
GLOBAL VOID Conf_Exit( VOID );
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
/* -eof- */
|