irc-dev-cvs Mailing List for IRC-Dev ircd development (Page 9)
Brought to you by:
zolty
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(22) |
Sep
|
Oct
(2) |
Nov
|
Dec
(2) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(30) |
Feb
(4) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(27) |
Dec
(17) |
2004 |
Jan
|
Feb
(4) |
Mar
|
Apr
(4) |
May
(8) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(14) |
Dec
(2) |
2005 |
Jan
(18) |
Feb
(2) |
Mar
(12) |
Apr
(18) |
May
(16) |
Jun
(3) |
Jul
(2) |
Aug
|
Sep
(3) |
Oct
(9) |
Nov
|
Dec
|
2007 |
Jan
|
Feb
|
Mar
|
Apr
(8) |
May
|
Jun
|
Jul
(3) |
Aug
|
Sep
(5) |
Oct
|
Nov
(3) |
Dec
(2) |
2008 |
Jan
(6) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(4) |
Jul
(8) |
Aug
(14) |
Sep
(4) |
Oct
(11) |
Nov
(1) |
Dec
|
From: Toni G. <zo...@us...> - 2003-12-16 10:24:45
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-12-16 10:24:44 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/win32 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:12:23
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:12:09 UTC Modified files: ChangeLog ChangeLog.es include/patchlevel.h ircd/channel.c Added files: libs/zlib/ChangeLog libs/zlib/FAQ libs/zlib/INDEX libs/zlib/Make_vms.com libs/zlib/Makefile libs/zlib/Makefile.in libs/zlib/Makefile.riscos libs/zlib/README libs/zlib/adler32.c libs/zlib/algorithm.txt libs/zlib/compress.c libs/zlib/configure libs/zlib/crc32.c libs/zlib/deflate.c libs/zlib/deflate.h libs/zlib/descrip.mms libs/zlib/example.c libs/zlib/gzio.c libs/zlib/infblock.c libs/zlib/infblock.h libs/zlib/infcodes.c libs/zlib/infcodes.h libs/zlib/inffast.c libs/zlib/inffast.h libs/zlib/inffixed.h libs/zlib/inflate.c libs/zlib/inftrees.c libs/zlib/inftrees.h libs/zlib/infutil.c libs/zlib/infutil.h libs/zlib/maketree.c libs/zlib/minigzip.c libs/zlib/trees.c libs/zlib/trees.h libs/zlib/uncompr.c libs/zlib/zconf.h libs/zlib/zlib.3 libs/zlib/zlib.h libs/zlib/zlib.html libs/zlib/zutil.c libs/zlib/zutil.h libs/zlib/amiga/Makefile.pup libs/zlib/amiga/Makefile.sas libs/zlib/contrib/README.contrib libs/zlib/contrib/visual-basic.txt libs/zlib/contrib/asm386/gvmat32.asm libs/zlib/contrib/asm386/gvmat32c.c libs/zlib/contrib/asm386/mkgvmt32.bat libs/zlib/contrib/asm386/zlibvc.def libs/zlib/contrib/asm386/zlibvc.dsp libs/zlib/contrib/asm386/zlibvc.dsw libs/zlib/contrib/asm586/README.586 libs/zlib/contrib/asm586/match.S libs/zlib/contrib/asm686/README.686 libs/zlib/contrib/asm686/match.S libs/zlib/contrib/delphi/zlib.mak libs/zlib/contrib/delphi/zlibdef.pas libs/zlib/contrib/delphi2/d_zlib.bpr libs/zlib/contrib/delphi2/d_zlib.cpp libs/zlib/contrib/delphi2/readme.txt libs/zlib/contrib/delphi2/zlib.bpg libs/zlib/contrib/delphi2/zlib.bpr libs/zlib/contrib/delphi2/zlib.cpp libs/zlib/contrib/delphi2/zlib.pas libs/zlib/contrib/delphi2/zlib32.bpr libs/zlib/contrib/delphi2/zlib32.cpp libs/zlib/contrib/iostream/test.cpp libs/zlib/contrib/iostream/zfstream.cpp libs/zlib/contrib/iostream/zfstream.h libs/zlib/contrib/iostream2/zstream.h libs/zlib/contrib/iostream2/zstream_test.cpp libs/zlib/contrib/minizip/ChangeLogUnzip libs/zlib/contrib/minizip/Makefile libs/zlib/contrib/minizip/miniunz.c libs/zlib/contrib/minizip/minizip.c libs/zlib/contrib/minizip/readme.txt libs/zlib/contrib/minizip/unzip.c libs/zlib/contrib/minizip/unzip.def libs/zlib/contrib/minizip/unzip.h libs/zlib/contrib/minizip/zip.c libs/zlib/contrib/minizip/zip.def libs/zlib/contrib/minizip/zip.h libs/zlib/contrib/minizip/zlibvc.def libs/zlib/contrib/minizip/zlibvc.dsp libs/zlib/contrib/minizip/zlibvc.dsw libs/zlib/contrib/untgz/Makefile libs/zlib/contrib/untgz/makefile.w32 libs/zlib/contrib/untgz/untgz.c libs/zlib/msdos/Makefile.b32 libs/zlib/msdos/Makefile.bor libs/zlib/msdos/Makefile.dj2 libs/zlib/msdos/Makefile.emx libs/zlib/msdos/Makefile.msc libs/zlib/msdos/Makefile.tc libs/zlib/msdos/Makefile.w32 libs/zlib/msdos/Makefile.wat libs/zlib/msdos/zlib.def libs/zlib/msdos/zlib.rc libs/zlib/nt/Makefile.emx libs/zlib/nt/Makefile.gcc libs/zlib/nt/Makefile.nt libs/zlib/nt/zlib.dnt libs/zlib/os2/Makefile.os2 libs/zlib/os2/zlib.def Log message: Author: zoltan <zo...@ir...> Log message: 2003-11-15 Toni Garcia <zo...@ir...> 1.0.alpha7 * Se incluye el source de la libreria zlib. ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.7 ircd-ircdev/ChangeLog:1.8 --- ircd-ircdev/ChangeLog:1.7 Tue Nov 11 13:36:21 2003 +++ ircd-ircdev/ChangeLog Fri Nov 14 19:11:54 2003 @@ -1,10 +1,13 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.7 2003/11/11 21:36:21 zolty Exp $ +# $Id: ChangeLog,v 1.8 2003/11/15 03:11:54 zolty Exp $ # # Insert new changes at beginning of the change list. # +2003-11-15 Toni Garcia <zo...@ir...> 1.0.alpha7 + * Incluyed zlib library source. + 2003-11-11 Toni Garcia <zo...@ir...> 1.0.alpha6 * Includes TEA encryptation. * Separates Undernet special code with defines. Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.7 ircd-ircdev/ChangeLog.es:1.8 --- ircd-ircdev/ChangeLog.es:1.7 Tue Nov 11 13:36:21 2003 +++ ircd-ircdev/ChangeLog.es Fri Nov 14 19:11:54 2003 @@ -1,10 +1,13 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.7 2003/11/11 21:36:21 zolty Exp $ +# $Id: ChangeLog.es,v 1.8 2003/11/15 03:11:54 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2003-11-15 Toni Garcia <zo...@ir...> 1.0.alpha7 + * Se incluye el source de la libreria zlib. + 2003-11-11 Toni Garcia <zo...@ir...> 1.0.alpha6 * Se incluye la encriptacion TEA en el ircd. * Se separa el codigo especial de Undernet con defines. Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.7 ircd-ircdev/include/patchlevel.h:1.8 --- ircd-ircdev/include/patchlevel.h:1.7 Tue Nov 11 13:36:21 2003 +++ ircd-ircdev/include/patchlevel.h Fri Nov 14 19:11:54 2003 @@ -15,10 +15,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: patchlevel.h,v 1.7 2003/11/11 21:36:21 zolty Exp $ + * $Id: patchlevel.h,v 1.8 2003/11/15 03:11:54 zolty Exp $ * */ -#define PATCHLEVEL ".alpha6" +#define PATCHLEVEL ".alpha7" #define RELEASE "1.0" Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.3 ircd-ircdev/ircd/channel.c:1.4 --- ircd-ircdev/ircd/channel.c:1.3 Tue Nov 11 13:36:21 2003 +++ ircd-ircdev/ircd/channel.c Fri Nov 14 19:11:54 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: channel.c,v 1.3 2003/11/11 21:36:21 zolty Exp $ + * $Id: channel.c,v 1.4 2003/11/15 03:11:54 zolty Exp $ */ #include "config.h" @@ -1045,7 +1045,6 @@ msgq_append(&me, mb, tbuf); } } - member = member->next_member; } if (full) break; Index: ircd-ircdev/libs/zlib/ChangeLog diff -u /dev/null ircd-ircdev/libs/zlib/ChangeLog:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/ChangeLog Fri Nov 14 19:11:54 2003 @@ -0,0 +1,481 @@ + + ChangeLog file for zlib + +Changes in 1.1.4 (11 March 2002) +- ZFREE was repeated on same allocation on some error conditions. + This creates a security problem described in + http://www.zlib.org/advisory-2002-03-11.txt +- Returned incorrect error (Z_MEM_ERROR) on some invalid data +- Avoid accesses before window for invalid distances with inflate window + less than 32K. +- force windowBits > 8 to avoid a bug in the encoder for a window size + of 256 bytes. (A complete fix will be available in 1.1.5). + +Changes in 1.1.3 (9 July 1998) +- fix "an inflate input buffer bug that shows up on rare but persistent + occasions" (Mark) +- fix gzread and gztell for concatenated .gz files (Didier Le Botlan) +- fix gzseek(..., SEEK_SET) in write mode +- fix crc check after a gzeek (Frank Faubert) +- fix miniunzip when the last entry in a zip file is itself a zip file + (J Lillge) +- add contrib/asm586 and contrib/asm686 (Brian Raiter) + See http://www.muppetlabs.com/~breadbox/software/assembly.html +- add support for Delphi 3 in contrib/delphi (Bob Dellaca) +- add support for C++Builder 3 and Delphi 3 in contrib/delphi2 (Davide Moretti) +- do not exit prematurely in untgz if 0 at start of block (Magnus Holmgren) +- use macro EXTERN instead of extern to support DLL for BeOS (Sander Stoks) +- added a FAQ file + +- Support gzdopen on Mac with Metrowerks (Jason Linhart) +- Do not redefine Byte on Mac (Brad Pettit & Jason Linhart) +- define SEEK_END too if SEEK_SET is not defined (Albert Chin-A-Young) +- avoid some warnings with Borland C (Tom Tanner) +- fix a problem in contrib/minizip/zip.c for 16-bit MSDOS (Gilles Vollant) +- emulate utime() for WIN32 in contrib/untgz (Gilles Vollant) +- allow several arguments to configure (Tim Mooney, Frodo Looijaard) +- use libdir and includedir in Makefile.in (Tim Mooney) +- support shared libraries on OSF1 V4 (Tim Mooney) +- remove so_locations in "make clean" (Tim Mooney) +- fix maketree.c compilation error (Glenn, Mark) +- Python interface to zlib now in Python 1.5 (Jeremy Hylton) +- new Makefile.riscos (Rich Walker) +- initialize static descriptors in trees.c for embedded targets (Nick Smith) +- use "foo-gz" in example.c for RISCOS and VMS (Nick Smith) +- add the OS/2 files in Makefile.in too (Andrew Zabolotny) +- fix fdopen and halloc macros for Microsoft C 6.0 (Tom Lane) +- fix maketree.c to allow clean compilation of inffixed.h (Mark) +- fix parameter check in deflateCopy (Gunther Nikl) +- cleanup trees.c, use compressed_len only in debug mode (Christian Spieler) +- Many portability patches by Christian Spieler: + . zutil.c, zutil.h: added "const" for zmem* + . Make_vms.com: fixed some typos + . Make_vms.com: msdos/Makefile.*: removed zutil.h from some dependency lists + . msdos/Makefile.msc: remove "default rtl link library" info from obj files + . msdos/Makefile.*: use model-dependent name for the built zlib library + . msdos/Makefile.emx, nt/Makefile.emx, nt/Makefile.gcc: + new makefiles, for emx (DOS/OS2), emx&rsxnt and mingw32 (Windows 9x / NT) +- use define instead of typedef for Bytef also for MSC small/medium (Tom Lane) +- replace __far with _far for better portability (Christian Spieler, Tom Lane) +- fix test for errno.h in configure (Tim Newsham) + +Changes in 1.1.2 (19 March 98) +- added contrib/minzip, mini zip and unzip based on zlib (Gilles Vollant) + See http://www.winimage.com/zLibDll/unzip.html +- preinitialize the inflate tables for fixed codes, to make the code + completely thread safe (Mark) +- some simplifications and slight speed-up to the inflate code (Mark) +- fix gzeof on non-compressed files (Allan Schrum) +- add -std1 option in configure for OSF1 to fix gzprintf (Martin Mokrejs) +- use default value of 4K for Z_BUFSIZE for 16-bit MSDOS (Tim Wegner + Glenn) +- added os2/Makefile.def and os2/zlib.def (Andrew Zabolotny) +- add shared lib support for UNIX_SV4.2MP (MATSUURA Takanori) +- do not wrap extern "C" around system includes (Tom Lane) +- mention zlib binding for TCL in README (Andreas Kupries) +- added amiga/Makefile.pup for Amiga powerUP SAS/C PPC (Andreas Kleinert) +- allow "make install prefix=..." even after configure (Glenn Randers-Pehrson) +- allow "configure --prefix $HOME" (Tim Mooney) +- remove warnings in example.c and gzio.c (Glenn Randers-Pehrson) +- move Makefile.sas to amiga/Makefile.sas + +Changes in 1.1.1 (27 Feb 98) +- fix macros _tr_tally_* in deflate.h for debug mode (Glenn Randers-Pehrson) +- remove block truncation heuristic which had very marginal effect for zlib + (smaller lit_bufsize than in gzip 1.2.4) and degraded a little the + compression ratio on some files. This also allows inlining _tr_tally for + matches in deflate_slow. +- added msdos/Makefile.w32 for WIN32 Microsoft Visual C++ (Bob Frazier) + +Changes in 1.1.0 (24 Feb 98) +- do not return STREAM_END prematurely in inflate (John Bowler) +- revert to the zlib 1.0.8 inflate to avoid the gcc 2.8.0 bug (Jeremy Buhler) +- compile with -DFASTEST to get compression code optimized for speed only +- in minigzip, try mmap'ing the input file first (Miguel Albrecht) +- increase size of I/O buffers in minigzip.c and gzio.c (not a big gain + on Sun but significant on HP) + +- add a pointer to experimental unzip library in README (Gilles Vollant) +- initialize variable gcc in configure (Chris Herborth) + +Changes in 1.0.9 (17 Feb 1998) +- added gzputs and gzgets functions +- do not clear eof flag in gzseek (Mark Diekhans) +- fix gzseek for files in transparent mode (Mark Diekhans) +- do not assume that vsprintf returns the number of bytes written (Jens Krinke) +- replace EXPORT with ZEXPORT to avoid conflict with other programs +- added compress2 in zconf.h, zlib.def, zlib.dnt +- new asm code from Gilles Vollant in contrib/asm386 +- simplify the inflate code (Mark): + . Replace ZALLOC's in huft_build() with single ZALLOC in inflate_blocks_new() + . ZALLOC the length list in inflate_trees_fixed() instead of using stack + . ZALLOC the value area for huft_build() instead of using stack + . Simplify Z_FINISH check in inflate() + +- Avoid gcc 2.8.0 comparison bug a little differently than zlib 1.0.8 +- in inftrees.c, avoid cc -O bug on HP (Farshid Elahi) +- in zconf.h move the ZLIB_DLL stuff earlier to avoid problems with + the declaration of FAR (Gilles VOllant) +- install libz.so* with mode 755 (executable) instead of 644 (Marc Lehmann) +- read_buf buf parameter of type Bytef* instead of charf* +- zmemcpy parameters are of type Bytef*, not charf* (Joseph Strout) +- do not redeclare unlink in minigzip.c for WIN32 (John Bowler) +- fix check for presence of directories in "make install" (Ian Willis) + +Changes in 1.0.8 (27 Jan 1998) +- fixed offsets in contrib/asm386/gvmat32.asm (Gilles Vollant) +- fix gzgetc and gzputc for big endian systems (Markus Oberhumer) +- added compress2() to allow setting the compression level +- include sys/types.h to get off_t on some systems (Marc Lehmann & QingLong) +- use constant arrays for the static trees in trees.c instead of computing + them at run time (thanks to Ken Raeburn for this suggestion). To create + trees.h, compile with GEN_TREES_H and run "make test". +- check return code of example in "make test" and display result +- pass minigzip command line options to file_compress +- simplifying code of inflateSync to avoid gcc 2.8 bug + +- support CC="gcc -Wall" in configure -s (QingLong) +- avoid a flush caused by ftell in gzopen for write mode (Ken Raeburn) +- fix test for shared library support to avoid compiler warnings +- zlib.lib -> zlib.dll in msdos/zlib.rc (Gilles Vollant) +- check for TARGET_OS_MAC in addition to MACOS (Brad Pettit) +- do not use fdopen for Metrowerks on Mac (Brad Pettit)) +- add checks for gzputc and gzputc in example.c +- avoid warnings in gzio.c and deflate.c (Andreas Kleinert) +- use const for the CRC table (Ken Raeburn) +- fixed "make uninstall" for shared libraries +- use Tracev instead of Trace in infblock.c +- in example.c use correct compressed length for test_sync +- suppress +vnocompatwarnings in configure for HPUX (not always supported) + +Changes in 1.0.7 (20 Jan 1998) +- fix gzseek which was broken in write mode +- return error for gzseek to negative absolute position +- fix configure for Linux (Chun-Chung Chen) +- increase stack space for MSC (Tim Wegner) +- get_crc_table and inflateSyncPoint are EXPORTed (Gilles Vollant) +- define EXPORTVA for gzprintf (Gilles Vollant) +- added man page zlib.3 (Rick Rodgers) +- for contrib/untgz, fix makedir() and improve Makefile + +- check gzseek in write mode in example.c +- allocate extra buffer for seeks only if gzseek is actually called +- avoid signed/unsigned comparisons (Tim Wegner, Gilles Vollant) +- add inflateSyncPoint in zconf.h +- fix list of exported functions in nt/zlib.dnt and mdsos/zlib.def + +Changes in 1.0.6 (19 Jan 1998) +- add functions gzprintf, gzputc, gzgetc, gztell, gzeof, gzseek, gzrewind and + gzsetparams (thanks to Roland Giersig and Kevin Ruland for some of this code) +- Fix a deflate bug occuring only with compression level 0 (thanks to + Andy Buckler for finding this one). +- In minigzip, pass transparently also the first byte for .Z files. +- return Z_BUF_ERROR instead of Z_OK if output buffer full in uncompress() +- check Z_FINISH in inflate (thanks to Marc Schluper) +- Implement deflateCopy (thanks to Adam Costello) +- make static libraries by default in configure, add --shared option. +- move MSDOS or Windows specific files to directory msdos +- suppress the notion of partial flush to simplify the interface + (but the symbol Z_PARTIAL_FLUSH is kept for compatibility with 1.0.4) +- suppress history buffer provided by application to simplify the interface + (this feature was not implemented anyway in 1.0.4) +- next_in and avail_in must be initialized before calling inflateInit or + inflateInit2 +- add EXPORT in all exported functions (for Windows DLL) +- added Makefile.nt (thanks to Stephen Williams) +- added the unsupported "contrib" directory: + contrib/asm386/ by Gilles Vollant <in...@wi...> + 386 asm code replacing longest_match(). + contrib/iostream/ by Kevin Ruland <ke...@ro...> + A C++ I/O streams interface to the zlib gz* functions + contrib/iostream2/ by Tyge Løvset <Tyg...@cm...> + Another C++ I/O streams interface + contrib/untgz/ by "Pedro A. Aranda Guti\irrez" <pa...@ti...> + A very simple tar.gz file extractor using zlib + contrib/visual-basic.txt by Carlos Rios <c_...@so...> + How to use compress(), uncompress() and the gz* functions from VB. +- pass params -f (filtered data), -h (huffman only), -1 to -9 (compression + level) in minigzip (thanks to Tom Lane) + +- use const for rommable constants in deflate +- added test for gzseek and gztell in example.c +- add undocumented function inflateSyncPoint() (hack for Paul Mackerras) +- add undocumented function zError to convert error code to string + (for Tim Smithers) +- Allow compilation of gzio with -DNO_DEFLATE to avoid the compression code. +- Use default memcpy for Symantec MSDOS compiler. +- Add EXPORT keyword for check_func (needed for Windows DLL) +- add current directory to LD_LIBRARY_PATH for "make test" +- create also a link for libz.so.1 +- added support for FUJITSU UXP/DS (thanks to Toshiaki Nomura) +- use $(SHAREDLIB) instead of libz.so in Makefile.in (for HPUX) +- added -soname for Linux in configure (Chun-Chung Chen, +- assign numbers to the exported functions in zlib.def (for Windows DLL) +- add advice in zlib.h for best usage of deflateSetDictionary +- work around compiler bug on Atari (cast Z_NULL in call of s->checkfn) +- allow compilation with ANSI keywords only enabled for TurboC in large model +- avoid "versionString"[0] (Borland bug) +- add NEED_DUMMY_RETURN for Borland +- use variable z_verbose for tracing in debug mode (L. Peter Deutsch). +- allow compilation with CC +- defined STDC for OS/2 (David Charlap) +- limit external names to 8 chars for MVS (Thomas Lund) +- in minigzip.c, use static buffers only for 16-bit systems +- fix suffix check for "minigzip -d foo.gz" +- do not return an error for the 2nd of two consecutive gzflush() (Felix Lee) +- use _fdopen instead of fdopen for MSC >= 6.0 (Thomas Fanslau) +- added makelcc.bat for lcc-win32 (Tom St Denis) +- in Makefile.dj2, use copy and del instead of install and rm (Frank Donahoe) +- Avoid expanded $Id: ChangeLog,v 1.1 2003/11/15 03:11:54 zolty Exp $. Use "rcs -kb" or "cvs admin -kb" to avoid Id expansion. +- check for unistd.h in configure (for off_t) +- remove useless check parameter in inflate_blocks_free +- avoid useless assignment of s->check to itself in inflate_blocks_new +- do not flush twice in gzclose (thanks to Ken Raeburn) +- rename FOPEN as F_OPEN to avoid clash with /usr/include/sys/file.h +- use NO_ERRNO_H instead of enumeration of operating systems with errno.h +- work around buggy fclose on pipes for HP/UX +- support zlib DLL with BORLAND C++ 5.0 (thanks to Glenn Randers-Pehrson) +- fix configure if CC is already equal to gcc + +Changes in 1.0.5 (3 Jan 98) +- Fix inflate to terminate gracefully when fed corrupted or invalid data +- Use const for rommable constants in inflate +- Eliminate memory leaks on error conditions in inflate +- Removed some vestigial code in inflate +- Update web address in README + +Changes in 1.0.4 (24 Jul 96) +- In very rare conditions, deflate(s, Z_FINISH) could fail to produce an EOF + bit, so the decompressor could decompress all the correct data but went + on to attempt decompressing extra garbage data. This affected minigzip too. +- zlibVersion and gzerror return const char* (needed for DLL) +- port to RISCOS (no fdopen, no multiple dots, no unlink, no fileno) +- use z_error only for DEBUG (avoid problem with DLLs) + +Changes in 1.0.3 (2 Jul 96) +- use z_streamp instead of z_stream *, which is now a far pointer in MSDOS + small and medium models; this makes the library incompatible with previous + versions for these models. (No effect in large model or on other systems.) +- return OK instead of BUF_ERROR if previous deflate call returned with + avail_out as zero but there is nothing to do +- added memcmp for non STDC compilers +- define NO_DUMMY_DECL for more Mac compilers (.h files merged incorrectly) +- define __32BIT__ if __386__ or i386 is defined (pb. with Watcom and SCO) +- better check for 16-bit mode MSC (avoids problem with Symantec) + +Changes in 1.0.2 (23 May 96) +- added Windows DLL support +- added a function zlibVersion (for the DLL support) +- fixed declarations using Bytef in infutil.c (pb with MSDOS medium model) +- Bytef is define's instead of typedef'd only for Borland C +- avoid reading uninitialized memory in example.c +- mention in README that the zlib format is now RFC1950 +- updated Makefile.dj2 +- added algorithm.doc + +Changes in 1.0.1 (20 May 96) [1.0 skipped to avoid confusion] +- fix array overlay in deflate.c which sometimes caused bad compressed data +- fix inflate bug with empty stored block +- fix MSDOS medium model which was broken in 0.99 +- fix deflateParams() which could generated bad compressed data. +- Bytef is define'd instead of typedef'ed (work around Borland bug) +- added an INDEX file +- new makefiles for DJGPP (Makefile.dj2), 32-bit Borland (Makefile.b32), + Watcom (Makefile.wat), Amiga SAS/C (Makefile.sas) +- speed up adler32 for modern machines without auto-increment +- added -ansi for IRIX in configure +- static_init_done in trees.c is an int +- define unlink as delete for VMS +- fix configure for QNX +- add configure branch for SCO and HPUX +- avoid many warnings (unused variables, dead assignments, etc...) +- no fdopen for BeOS +- fix the Watcom fix for 32 bit mode (define FAR as empty) +- removed redefinition of Byte for MKWERKS +- work around an MWKERKS bug (incorrect merge of all .h files) + +Changes in 0.99 (27 Jan 96) +- allow preset dictionary shared between compressor and decompressor +- allow compression level 0 (no compression) +- add deflateParams in zlib.h: allow dynamic change of compression level + and compression strategy. +- test large buffers and deflateParams in example.c +- add optional "configure" to build zlib as a shared library +- suppress Makefile.qnx, use configure instead +- fixed deflate for 64-bit systems (detected on Cray) +- fixed inflate_blocks for 64-bit systems (detected on Alpha) +- declare Z_DEFLATED in zlib.h (possible parameter for deflateInit2) +- always return Z_BUF_ERROR when deflate() has nothing to do +- deflateInit and inflateInit are now macros to allow version checking +- prefix all global functions and types with z_ with -DZ_PREFIX +- make falloc completely reentrant (inftrees.c) +- fixed very unlikely race condition in ct_static_init +- free in reverse order of allocation to help memory manager +- use zlib-1.0/* instead of zlib/* inside the tar.gz +- make zlib warning-free with "gcc -O3 -Wall -Wwrite-strings -Wpointer-arith + -Wconversion -Wstrict-prototypes -Wmissing-prototypes" +- allow gzread on concatenated .gz files +- deflateEnd now returns Z_DATA_ERROR if it was premature +- deflate is finally (?) fully deterministic (no matches beyond end of input) +- Document Z_SYNC_FLUSH +- add uninstall in Makefile +- Check for __cpluplus in zlib.h +- Better test in ct_align for partial flush +- avoid harmless warnings for Borland C++ +- initialize hash_head in deflate.c +- avoid warning on fdopen (gzio.c) for HP cc -Aa +- include stdlib.h for STDC compilers +- include errno.h for Cray +- ignore error if ranlib doesn't exist +- call ranlib twice for NeXTSTEP +- use exec_prefix instead of prefix for libz.a +- renamed ct_* as _tr_* to avoid conflict with applications +- clear z->msg in inflateInit2 before any error return +- initialize opaque in example.c, gzio.c, deflate.c and inflate.c +- fixed typo in zconf.h (_GNUC__ => __GNUC__) +- check for WIN32 in zconf.h and zutil.c (avoid farmalloc in 32-bit mode) +- fix typo in Make_vms.com (f$trnlnm -> f$getsyi) +- in fcalloc, normalize pointer if size > 65520 bytes +- don't use special fcalloc for 32 bit Borland C++ +- use STDC instead of __GO32__ to avoid redeclaring exit, calloc, etc... +- use Z_BINARY instead of BINARY +- document that gzclose after gzdopen will close the file +- allow "a" as mode in gzopen. +- fix error checking in gzread +- allow skipping .gz extra-field on pipes +- added reference to Perl interface in README +- put the crc table in FAR data (I dislike more and more the medium model :) +- added get_crc_table +- added a dimension to all arrays (Borland C can't count). +- workaround Borland C bug in declaration of inflate_codes_new & inflate_fast +- guard against multiple inclusion of *.h (for precompiled header on Mac) +- Watcom C pretends to be Microsoft C small model even in 32 bit mode. +- don't use unsized arrays to avoid silly warnings by Visual C++: + warning C4746: 'inflate_mask' : unsized array treated as '__far' + (what's wrong with far data in far model?). +- define enum out of inflate_blocks_state to allow compilation with C++ + +Changes in 0.95 (16 Aug 95) +- fix MSDOS small and medium model (now easier to adapt to any compiler) +- inlined send_bits +- fix the final (:-) bug for deflate with flush (output was correct but + not completely flushed in rare occasions). +- default window size is same for compression and decompression + (it's now sufficient to set MAX_WBITS in zconf.h). +- voidp -> voidpf and voidnp -> voidp (for consistency with other + typedefs and because voidnp was not near in large model). + +Changes in 0.94 (13 Aug 95) +- support MSDOS medium model +- fix deflate with flush (could sometimes generate bad output) +- fix deflateReset (zlib header was incorrectly suppressed) +- added support for VMS +- allow a compression level in gzopen() +- gzflush now calls fflush +- For deflate with flush, flush even if no more input is provided. +- rename libgz.a as libz.a +- avoid complex expression in infcodes.c triggering Turbo C bug +- work around a problem with gcc on Alpha (in INSERT_STRING) +- don't use inline functions (problem with some gcc versions) +- allow renaming of Byte, uInt, etc... with #define. +- avoid warning about (unused) pointer before start of array in deflate.c +- avoid various warnings in gzio.c, example.c, infblock.c, adler32.c, zutil.c +- avoid reserved word 'new' in trees.c + +Changes in 0.93 (25 June 95) +- temporarily disable inline functions +- make deflate deterministic +- give enough lookahead for PARTIAL_FLUSH +- Set binary mode for stdin/stdout in minigzip.c for OS/2 +- don't even use signed char in inflate (not portable enough) +- fix inflate memory leak for segmented architectures + +Changes in 0.92 (3 May 95) +- don't assume that char is signed (problem on SGI) +- Clear bit buffer when starting a stored block +- no memcpy on Pyramid +- suppressed inftest.c +- optimized fill_window, put longest_match inline for gcc +- optimized inflate on stored blocks. +- untabify all sources to simplify patches + +Changes in 0.91 (2 May 95) +- Default MEM_LEVEL is 8 (not 9 for Unix) as documented in zlib.h +- Document the memory requirements in zconf.h +- added "make install" +- fix sync search logic in inflateSync +- deflate(Z_FULL_FLUSH) now works even if output buffer too short +- after inflateSync, don't scare people with just "lo world" +- added support for DJGPP + +Changes in 0.9 (1 May 95) +- don't assume that zalloc clears the allocated memory (the TurboC bug + was Mark's bug after all :) +- let again gzread copy uncompressed data unchanged (was working in 0.71) +- deflate(Z_FULL_FLUSH), inflateReset and inflateSync are now fully implemented +- added a test of inflateSync in example.c +- moved MAX_WBITS to zconf.h because users might want to change that. +- document explicitly that zalloc(64K) on MSDOS must return a normalized + pointer (zero offset) +- added Makefiles for Microsoft C, Turbo C, Borland C++ +- faster crc32() + +Changes in 0.8 (29 April 95) +- added fast inflate (inffast.c) +- deflate(Z_FINISH) now returns Z_STREAM_END when done. Warning: this + is incompatible with previous versions of zlib which returned Z_OK. +- work around a TurboC compiler bug (bad code for b << 0, see infutil.h) + (actually that was not a compiler bug, see 0.81 above) +- gzread no longer reads one extra byte in certain cases +- In gzio destroy(), don't reference a freed structure +- avoid many warnings for MSDOS +- avoid the ERROR symbol which is used by MS Windows + +Changes in 0.71 (14 April 95) +- Fixed more MSDOS compilation problems :( There is still a bug with + TurboC large model. + +Changes in 0.7 (14 April 95) +- Added full inflate support. +- Simplified the crc32() interface. The pre- and post-conditioning + (one's complement) is now done inside crc32(). WARNING: this is + incompatible with previous versions; see zlib.h for the new usage. + +Changes in 0.61 (12 April 95) +- workaround for a bug in TurboC. example and minigzip now work on MSDOS. + +Changes in 0.6 (11 April 95) +- added minigzip.c +- added gzdopen to reopen a file descriptor as gzFile +- added transparent reading of non-gziped files in gzread. +- fixed bug in gzread (don't read crc as data) +- fixed bug in destroy (gzio.c) (don't return Z_STREAM_END for gzclose). +- don't allocate big arrays in the stack (for MSDOS) +- fix some MSDOS compilation problems + +Changes in 0.5: +- do real compression in deflate.c. Z_PARTIAL_FLUSH is supported but + not yet Z_FULL_FLUSH. +- support decompression but only in a single step (forced Z_FINISH) +- added opaque object for zalloc and zfree. +- added deflateReset and inflateReset +- added a variable zlib_version for consistency checking. +- renamed the 'filter' parameter of deflateInit2 as 'strategy'. + Added Z_FILTERED and Z_HUFFMAN_ONLY constants. + +Changes in 0.4: +- avoid "zip" everywhere, use zlib instead of ziplib. +- suppress Z_BLOCK_FLUSH, interpret Z_PARTIAL_FLUSH as block flush + if compression method == 8. +- added adler32 and crc32 +- renamed deflateOptions as deflateInit2, call one or the other but not both +- added the method parameter for deflateInit2. +- added inflateInit2 +- simplied considerably deflateInit and inflateInit by not supporting + user-provided history buffer. This is supported only in deflateInit2 + and inflateInit2. + +Changes in 0.3: +- prefix all macro names with Z_ +- use Z_FINISH instead of deflateEnd to finish compression. +- added Z_HUFFMAN_ONLY +- added gzerror() Index: ircd-ircdev/libs/zlib/FAQ diff -u /dev/null ircd-ircdev/libs/zlib/FAQ:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/FAQ Fri Nov 14 19:11:54 2003 @@ -0,0 +1,100 @@ + + Frequently Asked Questions about zlib + + +If your question is not there, please check the zlib home page +http://www.zlib.org which may have more recent information. +The lastest zlib FAQ is at http://www.gzip.org/zlib/zlib_faq.html + + + 1. Is zlib Y2K-compliant? + + Yes. zlib doesn't handle dates. + + 2. Where can I get a Windows DLL version? + + The zlib sources can be compiled without change to produce a DLL. If you + want a precompiled DLL, see http://www.winimage.com/zLibDll/ . Questions + about the zlib DLL should be sent to Gilles Vollant (in...@wi...). + + 3. Where can I get a Visual Basic interface to zlib? + + See + * http://www.winimage.com/zLibDll/cmp-z-it.zip + * http://www.dogma.net/markn/articles/zlibtool/zlibtool.htm + * contrib/visual-basic.txt in the zlib distribution + + 4. compress() returns Z_BUF_ERROR + + Make sure that before the call of compress, the length of the compressed + buffer is equal to the total size of the compressed buffer and not + zero. For Visual Basic, check that this parameter is passed by reference + ("as any"), not by value ("as long"). + + 5. deflate() or inflate() returns Z_BUF_ERROR + + Before making the call, make sure that avail_in and avail_out are not + zero. When setting the parameter flush equal to Z_FINISH, also make sure + that avail_out is big enough to allow processing all pending input. + + 6. Where's the zlib documentation (man pages, etc.)? + + It's in zlib.h for the moment, and Francis S. Lin has converted it to a + web page zlib.html. Volunteers to transform this to Unix-style man pages, + please contact Jean-loup Gailly (jl...@gz...). Examples of zlib usage + are in the files example.c and minigzip.c. + + 7. Why don't you use GNU autoconf or libtool or ...? + + Because we would like to keep zlib as a very small and simple + package. zlib is rather portable and doesn't need much configuration. + + 8. I found a bug in zlib. + + Most of the time, such problems are due to an incorrect usage of + zlib. Please try to reproduce the problem with a small program and send + the corresponding source to us at zl...@gz... . Do not send + multi-megabyte data files without prior agreement. + + 9. Why do I get "undefined reference to gzputc"? + + If "make test" produces something like + + example.o(.text+0x154): undefined reference to `gzputc' + + check that you don't have old files libz.* in /usr/lib, /usr/local/lib or + /usr/X11R6/lib. Remove any old versions, then do "make install". + +10. I need a Delphi interface to zlib. + + See the directories contrib/delphi and contrib/delphi2 in the zlib + distribution. + +11. Can zlib handle .zip archives? + + See the directory contrib/minizip in the zlib distribution. + +12. Can zlib handle .Z files? + + No, sorry. You have to spawn an uncompress or gunzip subprocess, or adapt + the code of uncompress on your own. + +13. How can I make a Unix shared library? + + make clean + ./configure -s + make + +14. Why does "make test" fail on Mac OS X? + + Mac OS X already includes zlib as a shared library, and so -lz links the + shared library instead of the one that the "make" compiled. For zlib + 1.1.3, the two are incompatible due to different compile-time + options. Simply change the -lz in the Makefile to libz.a, and it will use + the compiled library instead of the shared one and the "make test" will + succeed. + +15. I have a question about OttoPDF + + We are not the authors of OttoPDF. The real author is on the OttoPDF web + site Joel Hainley jha...@my.... Index: ircd-ircdev/libs/zlib/INDEX diff -u /dev/null ircd-ircdev/libs/zlib/INDEX:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/INDEX Fri Nov 14 19:11:54 2003 @@ -0,0 +1,86 @@ +ChangeLog history of changes +INDEX this file +FAQ Frequently Asked Questions about zlib +Make_vms.com script for Vax/VMS +Makefile makefile for Unix (generated by configure) +Makefile.in makefile for Unix (template for configure) +Makefile.riscos makefile for RISCOS +README guess what +algorithm.txt description of the (de)compression algorithm +configure configure script for Unix +descrip.mms makefile for Vax/VMS +zlib.3 mini man page for zlib (volunteers to write full + man pages from zlib.h welcome. write to jl...@gz...) + +amiga/Makefile.sas makefile for Amiga SAS/C +amiga/Makefile.pup makefile for Amiga powerUP SAS/C PPC + +msdos/Makefile.w32 makefile for Microsoft Visual C++ 32-bit +msdos/Makefile.b32 makefile for Borland C++ 32-bit +msdos/Makefile.bor makefile for Borland C/C++ 16-bit +msdos/Makefile.dj2 makefile for DJGPP 2.x +msdos/Makefile.emx makefile for EMX 0.9c (32-bit DOS/OS2) +msdos/Makefile.msc makefile for Microsoft C 16-bit +msdos/Makefile.tc makefile for Turbo C +msdos/Makefile.wat makefile for Watcom C +msdos/zlib.def definition file for Windows DLL +msdos/zlib.rc definition file for Windows DLL + +nt/Makefile.nt makefile for Windows NT +nt/zlib.dnt definition file for Windows NT DLL +nt/Makefile.emx makefile for EMX 0.9c/RSXNT 1.41 (Win32 Intel) +nt/Makefile.gcc makefile for Windows NT using GCC (mingw32) + + + zlib public header files (must be kept): +zconf.h +zlib.h + + private source files used to build the zlib library: +adler32.c +compress.c +crc32.c +deflate.c +deflate.h +gzio.c +infblock.c +infblock.h +infcodes.c +infcodes.h +inffast.c +inffast.h +inflate.c +inftrees.c +inftrees.h +infutil.c +infutil.h +maketree.c +trees.c +uncompr.c +zutil.c +zutil.h + + source files for sample programs: +example.c +minigzip.c + + unsupported contribution by third parties + +contrib/asm386/ by Gilles Vollant <in...@wi...> + 386 asm code replacing longest_match(). + +contrib/minizip/ by Gilles Vollant <in...@wi...> + Mini zip and unzip based on zlib + See http://www.winimage.com/zLibDll/unzip.html + +contrib/iostream/ by Kevin Ruland <ke...@ro...> + A C++ I/O streams interface to the zlib gz* functions + +contrib/iostream2/ by Tyge Løvset <Tyg...@cm...> + Another C++ I/O streams interface + +contrib/untgz/ by "Pedro A. Aranda Guti\irrez" <pa...@ti...> + A very simple tar.gz extractor using zlib + +contrib/visual-basic.txt by Carlos Rios <c_...@so...> + How to use compress(), uncompress() and the gz* functions from VB. Index: ircd-ircdev/libs/zlib/Make_vms.com diff -u /dev/null ircd-ircdev/libs/zlib/Make_vms.com:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/Make_vms.com Fri Nov 14 19:11:54 2003 @@ -0,0 +1,115 @@ +$! make libz under VMS +$! written by Martin P.J. Zinser <m.z...@gs...> +$! +$! Look for the compiler used +$! +$ ccopt = "" +$ if f$getsyi("HW_MODEL").ge.1024 +$ then +$ ccopt = "/prefix=all"+ccopt +$ comp = "__decc__=1" +$ if f$trnlnm("SYS").eqs."" then define sys sys$library: +$ else +$ if f$search("SYS$SYSTEM:DECC$COMPILER.EXE").eqs."" +$ then +$ comp = "__vaxc__=1" +$ if f$trnlnm("SYS").eqs."" then define sys sys$library: +$ else +$ if f$trnlnm("SYS").eqs."" then define sys decc$library_include: +$ ccopt = "/decc/prefix=all"+ccopt +$ comp = "__decc__=1" +$ endif +$ endif +$! +$! Build the thing plain or with mms +$! +$ write sys$output "Compiling Zlib sources ..." +$ if f$search("SYS$SYSTEM:MMS.EXE").eqs."" +$ then +$ dele example.obj;*,minigzip.obj;* +$ CALL MAKE adler32.OBJ "CC ''CCOPT' adler32" - + adler32.c zlib.h zconf.h +$ CALL MAKE compress.OBJ "CC ''CCOPT' compress" - + compress.c zlib.h zconf.h +$ CALL MAKE crc32.OBJ "CC ''CCOPT' crc32" - + crc32.c zlib.h zconf.h +$ CALL MAKE deflate.OBJ "CC ''CCOPT' deflate" - + deflate.c deflate.h zutil.h zlib.h zconf.h +$ CALL MAKE gzio.OBJ "CC ''CCOPT' gzio" - + gzio.c zutil.h zlib.h zconf.h +$ CALL MAKE infblock.OBJ "CC ''CCOPT' infblock" - + infblock.c zutil.h zlib.h zconf.h infblock.h +$ CALL MAKE infcodes.OBJ "CC ''CCOPT' infcodes" - + infcodes.c zutil.h zlib.h zconf.h inftrees.h +$ CALL MAKE inffast.OBJ "CC ''CCOPT' inffast" - + inffast.c zutil.h zlib.h zconf.h inffast.h +$ CALL MAKE inflate.OBJ "CC ''CCOPT' inflate" - + inflate.c zutil.h zlib.h zconf.h infblock.h +$ CALL MAKE inftrees.OBJ "CC ''CCOPT' inftrees" - + inftrees.c zutil.h zlib.h zconf.h inftrees.h +$ CALL MAKE infutil.OBJ "CC ''CCOPT' infutil" - + infutil.c zutil.h zlib.h zconf.h inftrees.h infutil.h +$ CALL MAKE trees.OBJ "CC ''CCOPT' trees" - + trees.c deflate.h zutil.h zlib.h zconf.h +$ CALL MAKE uncompr.OBJ "CC ''CCOPT' uncompr" - + uncompr.c zlib.h zconf.h +$ CALL MAKE zutil.OBJ "CC ''CCOPT' zutil" - + zutil.c zutil.h zlib.h zconf.h +$ write sys$output "Building Zlib ..." +$ CALL MAKE libz.OLB "lib/crea libz.olb *.obj" *.OBJ +$ write sys$output "Building example..." +$ CALL MAKE example.OBJ "CC ''CCOPT' example" - + example.c zlib.h zconf.h +$ call make example.exe "LINK example,libz.olb/lib" example.obj libz.olb +$ write sys$output "Building minigzip..." +$ CALL MAKE minigzip.OBJ "CC ''CCOPT' minigzip" - + minigzip.c zlib.h zconf.h +$ call make minigzip.exe - + "LINK minigzip,libz.olb/lib,x11vms:xvmsutils.olb/lib" - + minigzip.obj libz.olb +$ else +$ mms/macro=('comp') +$ endif +$ write sys$output "Zlib build completed" +$ exit +$! +$! +$MAKE: SUBROUTINE !SUBROUTINE TO CHECK DEPENDENCIES +$ V = 'F$Verify(0) +$! P1 = What we are trying to make +$! P2 = Command to make it +$! P3 - P8 What it depends on +$ +$ If F$Search(P1) .Eqs. "" Then Goto Makeit +$ Time = F$CvTime(F$File(P1,"RDT")) +$arg=3 +$Loop: +$ Argument = P'arg +$ If Argument .Eqs. "" Then Goto Exit +$ El=0 +$Loop2: +$ File = F$Element(El," ",Argument) +$ If File .Eqs. " " Then Goto Endl +$ AFile = "" +$Loop3: +$ OFile = AFile +$ AFile = F$Search(File) +$ If AFile .Eqs. "" .Or. AFile .Eqs. OFile Then Goto NextEl +$ If F$CvTime(F$File(AFile,"RDT")) .Ges. Time Then Goto Makeit +$ Goto Loop3 +$NextEL: +$ El = El + 1 +$ Goto Loop2 +$EndL: +$ arg=arg+1 +$ If arg .Le. 8 Then Goto Loop +$ Goto Exit +$ +$Makeit: +$ VV=F$VERIFY(0) +$ write sys$output P2 +$ 'P2 +$ VV='F$Verify(VV) +$Exit: +$ If V Then Set Verify +$ENDSUBROUTINE Index: ircd-ircdev/libs/zlib/Makefile diff -u /dev/null ircd-ircdev/libs/zlib/Makefile:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/Makefile Fri Nov 14 19:11:54 2003 @@ -0,0 +1,175 @@ +# Makefile for zlib +# Copyright (C) 1995-2002 Jean-loup Gailly. +# For conditions of distribution and use, see copyright notice in zlib.h + +# To compile and test, type: +# ./configure; make test +# The call of configure is optional if you don't have special requirements +# If you wish to build zlib as a shared library, use: ./configure -s + +# To install /usr/local/lib/libz.* and /usr/local/include/zlib.h, type: +# make install +# To install in $HOME instead of /usr/local, use: +# make install prefix=$HOME + +CC=cc + +CFLAGS=-O +#CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7 +#CFLAGS=-g -DDEBUG +#CFLAGS=-O3 -Wall -Wwrite-strings -Wpointer-arith -Wconversion \ +# -Wstrict-prototypes -Wmissing-prototypes + +LDFLAGS=-L. -lz +LDSHARED=$(CC) +CPP=$(CC) -E + +VER=1.1.4 +LIBS=libz.a +SHAREDLIB=libz.so + +AR=ar rc +RANLIB=ranlib +TAR=tar +SHELL=/bin/sh + +prefix = /usr/local +exec_prefix = ${prefix} +libdir = ${exec_prefix}/lib +includedir = ${prefix}/include + +OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \ + zutil.o inflate.o infblock.o inftrees.o infcodes.o infutil.o inffast.o + +OBJA = +# to use the asm code: make OBJA=match.o + +TEST_OBJS = example.o minigzip.o + +DISTFILES = README FAQ INDEX ChangeLog configure Make*[a-z0-9] *.[ch] *.mms \ + algorithm.txt zlib.3 zlib.html \ + msdos/Make*[a-z0-9] msdos/zlib.def msdos/zlib.rc \ + nt/Make*[a-z0-9] nt/zlib.dnt amiga/Make*.??? os2/M*.os2 os2/zlib.def \ + contrib/RE*.contrib contrib/*.txt contrib/asm386/*.asm contrib/asm386/*.c \ + contrib/asm386/*.bat contrib/asm386/zlibvc.d?? contrib/asm[56]86/*.?86 \ + contrib/asm[56]86/*.S contrib/iostream/*.cpp \ + contrib/iostream/*.h contrib/iostream2/*.h contrib/iostream2/*.cpp \ + contrib/untgz/Makefile contrib/untgz/*.c contrib/untgz/*.w32 \ + contrib/minizip/[CM]*[pe] contrib/minizip/*.[ch] contrib/minizip/*.[td]?? \ + contrib/delphi*/*.??? + +all: example minigzip + +test: all + @LD_LIBRARY_PATH=.:$(LD_LIBRARY_PATH) ; export LD_LIBRARY_PATH; \ + echo hello world | ./minigzip | ./minigzip -d || \ + echo ' *** minigzip test FAILED ***' ; \ + if ./example; then \ + echo ' *** zlib test OK ***'; \ + else \ + echo ' *** zlib test FAILED ***'; \ + fi + +libz.a: $(OBJS) $(OBJA) + $(AR) $@ $(OBJS) $(OBJA) + -@ ($(RANLIB) $@ || true) >/dev/null 2>&1 + +match.o: match.S + $(CPP) match.S > _match.s + $(CC) -c _match.s + mv _match.o match.o + rm -f _match.s + +$(SHAREDLIB).$(VER): $(OBJS) + $(LDSHARED) -o $@ $(OBJS) + rm -f $(SHAREDLIB) $(SHAREDLIB).1 + ln -s $@ $(SHAREDLIB) + ln -s $@ $(SHAREDLIB).1 + +example: example.o $(LIBS) + $(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS) + +minigzip: minigzip.o $(LIBS) + $(CC) $(CFLAGS) -o $@ minigzip.o $(LDFLAGS) + +install: $(LIBS) + -@if [ ! -d $(includedir) ]; then mkdir $(includedir); fi + -@if [ ! -d $(libdir) ]; then mkdir $(libdir); fi + cp zlib.h zconf.h $(includedir) + chmod 644 $(includedir)/zlib.h $(includedir)/zconf.h + cp $(LIBS) $(libdir) + cd $(libdir); chmod 755 $(LIBS) + -@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1 + cd $(libdir); if test -f $(SHAREDLIB).$(VER); then \ + rm -f $(SHAREDLIB) $(SHAREDLIB).1; \ + ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB); \ + ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB).1; \ + (ldconfig || true) >/dev/null 2>&1; \ + fi +# The ranlib in install is needed on NeXTSTEP which checks file times +# ldconfig is for Linux + +uninstall: + cd $(includedir); \ + v=$(VER); \ + if test -f zlib.h; then \ + v=`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`; \ + rm -f zlib.h zconf.h; \ + fi; \ + cd $(libdir); rm -f libz.a; \ + if test -f $(SHAREDLIB).$$v; then \ + rm -f $(SHAREDLIB).$$v $(SHAREDLIB) $(SHAREDLIB).1; \ + fi + +clean: + rm -f *.o *~ example minigzip libz.a libz.so* foo.gz so_locations \ + _match.s maketree + +distclean: clean + +zip: + mv Makefile Makefile~; cp -p Makefile.in Makefile + rm -f test.c ztest*.c contrib/minizip/test.zip + v=`sed -n -e 's/\.//g' -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\ + zip -ul9 zlib$$v $(DISTFILES) + mv Makefile~ Makefile + +dist: + mv Makefile Makefile~; cp -p Makefile.in Makefile + rm -f test.c ztest*.c contrib/minizip/test.zip + d=zlib-`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\ + rm -f $$d.tar.gz; \ + if test ! -d ../$$d; then rm -f ../$$d; ln -s `pwd` ../$$d; fi; \ + files=""; \ + for f in $(DISTFILES); do files="$$files $$d/$$f"; done; \ + cd ..; \ + GZIP=-9 $(TAR) chofz $$d/$$d.tar.gz $$files; \ + if test ! -d $$d; then rm -f $$d; fi + mv Makefile~ Makefile + +tags: + etags *.[ch] + +depend: + makedepend -- $(CFLAGS) -- *.[ch] + +# DO NOT DELETE THIS LINE -- make depend depends on it. + +adler32.o: zlib.h zconf.h +compress.o: zlib.h zconf.h +crc32.o: zlib.h zconf.h +deflate.o: deflate.h zutil.h zlib.h zconf.h +example.o: zlib.h zconf.h +gzio.o: zutil.h zlib.h zconf.h +infblock.o: infblock.h inftrees.h infcodes.h infutil.h zutil.h zlib.h zconf.h +infcodes.o: zutil.h zlib.h zconf.h +infcodes.o: inftrees.h infblock.h infcodes.h infutil.h inffast.h +inffast.o: zutil.h zlib.h zconf.h inftrees.h +inffast.o: infblock.h infcodes.h infutil.h inffast.h +inflate.o: zutil.h zlib.h zconf.h infblock.h +inftrees.o: zutil.h zlib.h zconf.h inftrees.h +infutil.o: zutil.h zlib.h zconf.h infblock.h inftrees.h infcodes.h infutil.h +minigzip.o: zlib.h zconf.h +trees.o: deflate.h zutil.h zlib.h zconf.h trees.h +uncompr.o: zlib.h zconf.h +zutil.o: zutil.h zlib.h zconf.h Index: ircd-ircdev/libs/zlib/Makefile.in diff -u /dev/null ircd-ircdev/libs/zlib/Makefile.in:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/Makefile.in Fri Nov 14 19:11:54 2003 @@ -0,0 +1,175 @@ +# Makefile for zlib +# Copyright (C) 1995-2002 Jean-loup Gailly. +# For conditions of distribution and use, see copyright notice in zlib.h + +# To compile and test, type: +# ./configure; make test +# The call of configure is optional if you don't have special requirements +# If you wish to build zlib as a shared library, use: ./configure -s + +# To install /usr/local/lib/libz.* and /usr/local/include/zlib.h, type: +# make install +# To install in $HOME instead of /usr/local, use: +# make install prefix=$HOME + +CC=cc + +CFLAGS=-O +#CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7 +#CFLAGS=-g -DDEBUG +#CFLAGS=-O3 -Wall -Wwrite-strings -Wpointer-arith -Wconversion \ +# -Wstrict-prototypes -Wmissing-prototypes + +LDFLAGS=-L. -lz +LDSHARED=$(CC) +CPP=$(CC) -E + +VER=1.1.4 +LIBS=libz.a +SHAREDLIB=libz.so + +AR=ar rc +RANLIB=ranlib +TAR=tar +SHELL=/bin/sh + +prefix = /usr/local +exec_prefix = ${prefix} +libdir = ${exec_prefix}/lib +includedir = ${prefix}/include + +OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \ + zutil.o inflate.o infblock.o inftrees.o infcodes.o infutil.o inffast.o + +OBJA = +# to use the asm code: make OBJA=match.o + +TEST_OBJS = example.o minigzip.o + +DISTFILES = README FAQ INDEX ChangeLog configure Make*[a-z0-9] *.[ch] *.mms \ + algorithm.txt zlib.3 zlib.html \ + msdos/Make*[a-z0-9] msdos/zlib.def msdos/zlib.rc \ + nt/Make*[a-z0-9] nt/zlib.dnt amiga/Make*.??? os2/M*.os2 os2/zlib.def \ + contrib/RE*.contrib contrib/*.txt contrib/asm386/*.asm contrib/asm386/*.c \ + contrib/asm386/*.bat contrib/asm386/zlibvc.d?? contrib/asm[56]86/*.?86 \ + contrib/asm[56]86/*.S contrib/iostream/*.cpp \ + contrib/iostream/*.h contrib/iostream2/*.h contrib/iostream2/*.cpp \ + contrib/untgz/Makefile contrib/untgz/*.c contrib/untgz/*.w32 \ + contrib/minizip/[CM]*[pe] contrib/minizip/*.[ch] contrib/minizip/*.[td]?? \ + contrib/delphi*/*.??? + +all: example minigzip + +test: all + @LD_LIBRARY_PATH=.:$(LD_LIBRARY_PATH) ; export LD_LIBRARY_PATH; \ + echo hello world | ./minigzip | ./minigzip -d || \ + echo ' *** minigzip test FAILED ***' ; \ + if ./example; then \ + echo ' *** zlib test OK ***'; \ + else \ + echo ' *** zlib test FAILED ***'; \ + fi + +libz.a: $(OBJS) $(OBJA) + $(AR) $@ $(OBJS) $(OBJA) + -@ ($(RANLIB) $@ || true) >/dev/null 2>&1 + +match.o: match.S + $(CPP) match.S > _match.s + $(CC) -c _match.s + mv _match.o match.o + rm -f _match.s + +$(SHAREDLIB).$(VER): $(OBJS) + $(LDSHARED) -o $@ $(OBJS) + rm -f $(SHAREDLIB) $(SHAREDLIB).1 + ln -s $@ $(SHAREDLIB) + ln -s $@ $(SHAREDLIB).1 + +example: example.o $(LIBS) + $(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS) + +minigzip: minigzip.o $(LIBS) + $(CC) $(CFLAGS) -o $@ minigzip.o $(LDFLAGS) + +install: $(LIBS) + -@if [ ! -d $(includedir) ]; then mkdir $(includedir); fi + -@if [ ! -d $(libdir) ]; then mkdir $(libdir); fi + cp zlib.h zconf.h $(includedir) + chmod 644 $(includedir)/zlib.h $(includedir)/zconf.h + cp $(LIBS) $(libdir) + cd $(libdir); chmod 755 $(LIBS) + -@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1 + cd $(libdir); if test -f $(SHAREDLIB).$(VER); then \ + rm -f $(SHAREDLIB) $(SHAREDLIB).1; \ + ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB); \ + ln -s $(SHAREDLIB).$(VER) $(SHAREDLIB).1; \ + (ldconfig || true) >/dev/null 2>&1; \ + fi +# The ranlib in install is needed on NeXTSTEP which checks file times +# ldconfig is for Linux + +uninstall: + cd $(includedir); \ + v=$(VER); \ + if test -f zlib.h; then \ + v=`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`; \ + rm -f zlib.h zconf.h; \ + fi; \ + cd $(libdir); rm -f libz.a; \ + if test -f $(SHAREDLIB).$$v; then \ + rm -f $(SHAREDLIB).$$v $(SHAREDLIB) $(SHAREDLIB).1; \ + fi + +clean: + rm -f *.o *~ example minigzip libz.a libz.so* foo.gz so_locations \ + _match.s maketree + +distclean: clean + +zip: + mv Makefile Makefile~; cp -p Makefile.in Makefile + rm -f test.c ztest*.c contrib/minizip/test.zip + v=`sed -n -e 's/\.//g' -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\ + zip -ul9 zlib$$v $(DISTFILES) + mv Makefile~ Makefile + +dist: + mv Makefile Makefile~; cp -p Makefile.in Makefile + rm -f test.c ztest*.c contrib/minizip/test.zip + d=zlib-`sed -n '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`;\ + rm -f $$d.tar.gz; \ + if test ! -d ../$$d; then rm -f ../$$d; ln -s `pwd` ../$$d; fi; \ + files=""; \ + for f in $(DISTFILES); do files="$$files $$d/$$f"; done; \ + cd ..; \ + GZIP=-9 $(TAR) chofz $$d/$$d.tar.gz $$files; \ + if test ! -d $$d; then rm -f $$d; fi + mv Makefile~ Makefile + +tags: + etags *.[ch] + +depend: + makedepend -- $(CFLAGS) -- *.[ch] + +# DO NOT DELETE THIS LINE -- make depend depends on it. + +adler32.o: zlib.h zconf.h +compress.o: zlib.h zconf.h +crc32.o: zlib.h zconf.h +deflate.o: deflate.h zutil.h zlib.h zconf.h +example.o: zlib.h zconf.h +gzio.o: zutil.h zlib.h zconf.h +infblock.o: infblock.h inftrees.h infcodes.h infutil.h zutil.h zlib.h zconf.h +infcodes.o: zutil.h zlib.h zconf.h +infcodes.o: inftrees.h infblock.h infcodes.h infutil.h inffast.h +inffast.o: zutil.h zlib.h zconf.h inftrees.h +inffast.o: infblock.h infcodes.h infutil.h inffast.h +inflate.o: zutil.h zlib.h zconf.h infblock.h +inftrees.o: zutil.h zlib.h zconf.h inftrees.h +infutil.o: zutil.h zlib.h zconf.h infblock.h inftrees.h infcodes.h infutil.h +minigzip.o: zlib.h zconf.h +trees.o: deflate.h zutil.h zlib.h zconf.h trees.h +uncompr.o: zlib.h zconf.h +zutil.o: zutil.h zlib.h zconf.h Index: ircd-ircdev/libs/zlib/Makefile.riscos diff -u /dev/null ircd-ircdev/libs/zlib/Makefile.riscos:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/Makefile.riscos Fri Nov 14 19:11:54 2003 @@ -0,0 +1,151 @@ +# Project: zlib_1_03 +# Patched for zlib 1.1.2 rw...@sh... 19980430 +# test works out-of-the-box, installs `somewhere' on demand + +# Toolflags: +CCflags = -c -depend !Depend -IC: -g -throwback -DRISCOS -fah +C++flags = -c -depend !Depend -IC: -throwback +Linkflags = -aif -c++ -o $@ +ObjAsmflags = -throwback -NoCache -depend !Depend +CMHGflags = +LibFileflags = -c -l -o $@ +Squeezeflags = -o $@ + +# change the line below to where _you_ want the library installed. +libdest = lib:zlib + +# Final targets: +@.lib: @.o.adler32 @.o.compress @.o.crc32 @.o.deflate @.o.gzio \ + @.o.infblock @.o.infcodes @.o.inffast @.o.inflate @.o.inftrees @.o.infutil @.o.trees \ + @.o.uncompr @.o.zutil + LibFile $(LibFileflags) @.o.adler32 @.o.compress @.o.crc32 @.o.deflate \ + @.o.gzio @.o.infblock @.o.infcodes @.o.inffast @.o.inflate @.o.inftrees @.o.infutil \ + @.o.trees @.o.uncompr @.o.zutil +test: @.minigzip @.example @.lib + @copy @.lib @.libc A~C~DF~L~N~P~Q~RS~TV + @echo running tests: hang on. + @/@.minigzip -f -9 libc + @/@.minigzip -d libc-gz + @/@.minigzip -f -1 libc + @/@.minigzip -d libc-gz + @/@.minigzip -h -9 libc + @/@.minigzip -d libc-gz + @/@.minigzip -h -1 libc + @/@.minigzip -d libc-gz + @/@.minigzip -9 libc + @/@.minigzip -d libc-gz + @/@.minigzip -1 libc + @/@.minigzip -d libc-gz + @diff @.lib @.libc + @echo that should have reported '@.lib and @.libc identical' if you have diff. + @/@.example @.fred @.fred + @echo that will have given lots of hello!'s. + +@.minigzip: @.o.minigzip @.lib C:o.Stubs + Link $(Linkflags) @.o.minigzip @.lib C:o.Stubs +@.example: @.o.example @.lib C:o.Stubs + Link $(Linkflags) @.o.example @.lib C:o.Stubs + +install: @.lib + cdir $(libdest) + cdir $(libdest).h + @copy @.h.zlib $(libdest).h.zlib A~C~DF~L~N~P~Q~RS~TV + @copy @.h.zconf $(libdest).h.zconf A~C~DF~L~N~P~Q~RS~TV + @copy @.lib $(libdest).lib A~C~DF~L~N~P~Q~RS~TV + @echo okay, installed zlib in $(libdest) + +clean:; remove @.minigzip + remove @.example + remove @.libc + -wipe @.o.* F~r~cV + remove @.fred + +# User-editable dependencies: +.c.o: + cc $(ccflags) -o $@ $< + +# Static dependencies: + +# Dynamic dependencies: +o.example: c.example +o.example: h.zlib +o.example: h.zconf +o.minigzip: c.minigzip +o.minigzip: h.zlib +o.minigzip: h.zconf +o.adler32: c.adler32 +o.adler32: h.zlib +o.adler32: h.zconf +o.compress: c.compress +o.compress: h.zlib +o.compress: h.zconf +o.crc32: c.crc32 +o.crc32: h.zlib +o.crc32: h.zconf +o.deflate: c.deflate +o.deflate: h.deflate +o.deflate: h.zutil +o.deflate: h.zlib +o.deflate: h.zconf +o.gzio: c.gzio +o.gzio: h.zutil +o.gzio: h.zlib +o.gzio: h.zconf +o.infblock: c.infblock +o.infblock: h.zutil +o.infblock: h.zlib +o.infblock: h.zconf +o.infblock: h.infblock +o.infblock: h.inftrees +o.infblock: h.infcodes +o.infblock: h.infutil +o.infcodes: c.infcodes +o.infcodes: h.zutil +o.infcodes: h.zlib +o.infcodes: h.zconf +o.infcodes: h.inftrees +o.infcodes: h.infblock +o.infcodes: h.infcodes +o.infcodes: h.infutil +o.infcodes: h.inffast +o.inffast: c.inffast +o.inffast: h.zutil +o.inffast: h.zlib +o.inffast: h.zconf +o.inffast: h.inftrees +o.inffast: h.infblock +o.inffast: h.infcodes +o.inffast: h.infutil +o.inffast: h.inffast +o.inflate: c.inflate +o.inflate: h.zutil +o.inflate: h.zlib +o.inflate: h.zconf +o.inflate: h.infblock +o.inftrees: c.inftrees +o.inftrees: h.zutil +o.inftrees: h.zlib +o.inftrees: h.zconf +o.inftrees: h.inftrees +o.inftrees: h.inffixed +o.infutil: c.infutil +o.infutil: h.zutil +o.infutil: h.zlib +o.infutil: h.zconf +o.infutil: h.infblock +o.infutil: h.inftrees +o.infutil: h.infcodes +o.infutil: h.infutil +o.trees: c.trees +o.trees: h.deflate +o.trees: h.zutil +o.trees: h.zlib +o.trees: h.zconf +o.trees: h.trees +o.uncompr: c.uncompr +o.uncompr: h.zlib +o.uncompr: h.zconf +o.zutil: c.zutil +o.zutil: h.zutil +o.zutil: h.zlib +o.zutil: h.zconf Index: ircd-ircdev/libs/zlib/README diff -u /dev/null ircd-ircdev/libs/zlib/README:1.1 --- /dev/null Fri Nov 14 19:12:09 2003 +++ ircd-ircdev/libs/zlib/README Fri Nov 14 19:11:54 2003 @@ -0,0 +1,147 @@ +zlib 1.1.4 is a general purpose data compression library. All the code +is thread safe. The data format used by the zlib library +is described by RFCs (Request for Comments) 1950 to 1952 in the files +http://www.ietf.org/rfc/rfc1950.txt (zlib format), rfc1951.txt (deflate +format) and rfc1952.txt (gzip format). These documents are also available in +other formats from ftp://ftp.uu.net/graphics/png/documents/zlib/zdoc-index.html + +All functions of the compression library are documented in the file zlib.h +(volunteer to write man pages welcome, contact jl...@gz...). A usage +example of the library is given in the file example.c which also tests that +the library is working correctly. Another example is given in the file +minigzip.c. The compression library itself is composed of all source files +except example.c and minigzip.c. + +To compile all files and run the test program, follow the instructions +given at the top of Makefile. In short "make test; make install" +should work for most machines. For Unix: "./configure; make test; make install" +For MSDOS, use one of the special makefiles such as Makefile.msc. +For VMS, use Make_vms.com or descrip.mms. + +Questions about zlib should be sent to <zl...@gz...>, or to +Gilles Vollant <in...@wi...> for the Windows DLL version. +The zlib home page is http://www.zlib.org or http://www.gzip.org/zlib/ +Before reporting a problem, please check this site to verify that +you have the latest version of zlib; otherwise get the latest version and +check whether the problem still exists or not. + +PLEASE read the zlib FAQ http://www.gzip.org/zlib/zlib_faq.html +before asking for help. + +Mark Nelson <ma...@ie...> wrote an article about zlib for the Jan. 1997 +issue of Dr. Dobb's Journal; a copy of the article is available in +http://dogma.net/markn/articles/zlibtool/zlibtool.htm + +The changes made in version 1.1.4 are documented in the file ChangeLog. +The only changes made since 1.1.3 are bug corrections: + +- ZFREE was repeated on same allocation on some error conditions. + This creates a security problem described in + http://www.zlib.org/advisory-2002-03-11.txt +- Returned incorrect error (Z_MEM_ERROR) on some invalid data +- Avoid accesses before window for invalid distances with inflate window + less than 32K. +- force windowBits > 8 to avoid a bug in the encoder for a window size + of 256 bytes. (A complete fix will be available in 1.1.5). + +The beta version 1.1.5beta includes many more changes. A new official +version 1.1.5 will be released as soon as extensive testing has been +completed on it. + + +Unsupported third party contributions are provided in directory "contrib". + +A Java implementation of zlib is available in the Java Development Kit +http://www.javasoft.com/products/JDK/1.1/docs/api/Package-java.util.zip.html +See the zlib home page http://www.zlib.org for details. + +A Perl interface to zlib written by Paul Marquess <pma...@bf...> +is in the CPAN (Comprehensive Perl Archive Network) sites +http://www.cpan.org/modules/by-mo... [truncated message content] |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/iostream added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/untgz added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/asm686 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/delphi2 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/iostream2 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/minizip added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:51
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/delphi added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:50
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:50 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/asm586 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:03:50
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:03:49 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib/asm386 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:02:16
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:02:14 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/contrib added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:02:16
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:02:14 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/msdos added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:02:15
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:02:15 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/os2 added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:02:15
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:02:14 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/nt added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:02:15
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:02:14 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib/amiga added to the repository |
From: Toni G. <zo...@us...> - 2003-11-15 03:01:32
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-15 03:01:30 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/zlib added to the repository |
From: Toni G. <zo...@us...> - 2003-11-12 05:39:45
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-11 21:36:31 UTC Modified files: ChangeLog ChangeLog.es configure configure.in include/channel.h include/client.h include/handlers.h include/ircd_features.h include/numeric.h include/patchlevel.h include/res.h include/s_user.h include/struct.h include/whocmds.h ircd/Makefile.in ircd/channel.c ircd/gline.c ircd/ircd.c ircd/ircd_features.c ircd/ircd_log.c ircd/ircd_relay.c ircd/ircd_snprintf.c ircd/jupe.c ircd/listener.c ircd/m_account.c ircd/m_burst.c ircd/m_destruct.c ircd/m_join.c ircd/m_kick.c ircd/m_links.c ircd/m_map.c ircd/m_mode.c ircd/m_names.c ircd/m_nick.c ircd/m_opmode.c ircd/m_part.c ircd/m_ping.c ircd/m_userhost.c ircd/m_userip.c ircd/m_who.c ircd/m_whois.c ircd/parse.c ircd/s_auth.c ircd/s_bsd.c ircd/s_debug.c ircd/s_err.c ircd/s_misc.c ircd/s_serv.c ircd/s_stats.c ircd/s_user.c ircd/uping.c ircd/whocmds.c Added files: include/destruct_event.h include/ircd_tea.h ircd/destruct_event.c ircd/ircd_tea.c Log message: Author: zoltan <zo...@ir...> Log message: 2003-11-11 Toni Garcia <zo...@ir...> 1.0.alpha6 * Se incluye la encriptacion TEA en el ircd. * Se separa el codigo especial de Undernet con defines. * Sincronizacion con algunos parches del u2.10.12. * Sincronizacion con u2.10.11.06. ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.6 ircd-ircdev/ChangeLog:1.7 --- ircd-ircdev/ChangeLog:1.6 Sun Nov 2 10:34:46 2003 +++ ircd-ircdev/ChangeLog Tue Nov 11 13:36:21 2003 @@ -1,10 +1,16 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.6 2003/11/02 18:34:46 zolty Exp $ +# $Id: ChangeLog,v 1.7 2003/11/11 21:36:21 zolty Exp $ # # Insert new changes at beginning of the change list. # +2003-11-11 Toni Garcia <zo...@ir...> 1.0.alpha6 + * Includes TEA encryptation. + * Separates Undernet special code with defines. + * Synchronization with some patches of u2.10.12. + * Synchronization with u2.10.11.06. + 2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha5 * Check lex and yacc (configure.in). * Fix bison bug (ircd_parser.y). Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.6 ircd-ircdev/ChangeLog.es:1.7 --- ircd-ircdev/ChangeLog.es:1.6 Sun Nov 2 10:34:46 2003 +++ ircd-ircdev/ChangeLog.es Tue Nov 11 13:36:21 2003 @@ -1,10 +1,16 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.6 2003/11/02 18:34:46 zolty Exp $ +# $Id: ChangeLog.es,v 1.7 2003/11/11 21:36:21 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2003-11-11 Toni Garcia <zo...@ir...> 1.0.alpha6 + * Se incluye la encriptacion TEA en el ircd. + * Se separa el codigo especial de Undernet con defines. + * Sincronizacion con algunos parches del u2.10.12. + * Sincronizacion con u2.10.11.06. + 2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha5 * Chequeo de lex y yacc en el configure.in. * Fix de un bug de bison (ircd_parser.y). Index: ircd-ircdev/configure diff -u ircd-ircdev/configure:1.5 ircd-ircdev/configure:1.6 --- ircd-ircdev/configure:1.5 Sun Nov 2 10:34:47 2003 +++ ircd-ircdev/configure Tue Nov 11 13:36:21 2003 @@ -3055,117 +3055,6 @@ -echo "$as_me:$LINENO: checking for library containing res_mkquery" >&5 -echo $ECHO_N "checking for library containing res_mkquery... $ECHO_C" >&6 -if test "${ac_cv_search_res_mkquery+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_func_search_save_LIBS=$LIBS -ac_cv_search_res_mkquery=no -cat >conftest.$ac_ext <<_ACEOF -#line $LINENO "configure" -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char res_mkquery (); -int -main () -{ -res_mkquery (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_search_res_mkquery="none required" -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext -if test "$ac_cv_search_res_mkquery" = no; then - for ac_lib in resolv; do - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - cat >conftest.$ac_ext <<_ACEOF -#line $LINENO "configure" -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any gcc2 internal prototype to avoid an error. */ -#ifdef __cplusplus -extern "C" -#endif -/* We use char because int might match the return type of a gcc2 - builtin and then its argument prototype would still apply. */ -char res_mkquery (); -int -main () -{ -res_mkquery (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && - { ac_try='test -s conftest$ac_exeext' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_search_res_mkquery="-l$ac_lib" -break -else - echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -fi -rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext - done -fi -LIBS=$ac_func_search_save_LIBS -fi -echo "$as_me:$LINENO: result: $ac_cv_search_res_mkquery" >&5 -echo "${ECHO_T}$ac_cv_search_res_mkquery" >&6 -if test "$ac_cv_search_res_mkquery" != no; then - test "$ac_cv_search_res_mkquery" = "none required" || LIBS="$ac_cv_search_res_mkquery $LIBS" - -else - { { echo "$as_me:$LINENO: error: Unable to find library containing res_mkquery()" >&5 -echo "$as_me: error: Unable to find library containing res_mkquery()" >&2;} - { (exit 1); exit 1; }; } -fi - - ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -7487,11 +7376,6 @@ echo "$as_me:$LINENO: result: Linux ($host) found." >&5 echo "${ECHO_T}Linux ($host) found." >&6 unet_poll_syscall=yes -# if test x"$ac_cv_header_sys_epoll_h" = xyes; then -# unet_poll_syscall=no -# else -# unet_poll_syscall=yes -# fi OSDEP_C=os_linux.c ;; @@ -9558,25 +9442,45 @@ echo "IRC-Dev ircd is now hopefully configured for your system." echo "" echo " Host system: $host_os" -echo " Prefix: $prefix" +echo " Engines supported:" +if test x"$unet_cv_enable_epoll" = xyes; then +echo " epoll()" +fi +if test x"$unet_cv_enable_kqueue" = xyes; then +echo " kqueue()" +fi +if test x"$unet_cv_enable_devpoll" = xyes; then +echo " /dev/poll" +fi +if test x"$unet_cv_enable_poll" = xyes; then +echo " poll()" +fi +echo "" echo " Asserts: $unet_cv_enable_asserts" echo " Warnings: $unet_cv_enable_warnings" echo " Debug: $unet_cv_enable_debug" echo " Profile: $unet_cv_enable_profile" echo " Pedantic: $unet_cv_enable_pedantic" +echo " Inlines: $unet_cv_enable_inlines" +echo " Debugging symbols: $unet_cv_enable_symbols" echo " ADNS: $unet_cv_enable_adns" -echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" -echo " Chroot: $unet_cv_with_chroot" echo "" -echo " Domain: $unet_cv_with_domain" -echo " Binaries path: $prefix/bin" +echo " Prefix: $prefix" +echo " Binaries path: $unet_bindir" echo " IRCD Binary: $unet_spath" +echo " Lib path: $unet_libdir" echo " Data path: $unet_cv_with_dpath" -echo " Config path: $unet_cv_with_cpath" -echo " Log path: $unet_cv_with_lpath" +echo " Config file: $unet_cpath" +echo " Debug log file: $unet_lpath" +echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" +echo " Chroot: $unet_cv_with_chroot" +echo "" echo " Maximum connections: $unet_cv_with_maxcon" +echo " Domain: $unet_cv_with_domain" +#echo " IRC Environment: DDB (Distributed DataBase)" +#echo " IRC Environment: Services (Ex TerraIRCU)" +#echo " IRC Environment: Undernet" +#echo " IRC Environment: None (BUG, mail to zo...@ir...)" echo "" -echo " poll() engine: $unet_cv_enable_poll" -echo " epoll() engine: $unet_cv_enable_epoll" -echo " kqueue() engine: $unet_cv_enable_kqueue" -echo " /dev/poll engine: $unet_cv_enable_devpoll" + + Index: ircd-ircdev/configure.in diff -u ircd-ircdev/configure.in:1.5 ircd-ircdev/configure.in:1.6 --- ircd-ircdev/configure.in:1.5 Sun Nov 2 10:34:47 2003 +++ ircd-ircdev/configure.in Tue Nov 11 13:36:21 2003 @@ -19,7 +19,7 @@ dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. dnl -dnl $Id: configure.in,v 1.5 2003/11/02 18:34:47 zolty Exp $ +dnl $Id: configure.in,v 1.6 2003/11/11 21:36:21 zolty Exp $ dnl Make sure we are in the correct directory (someone could have run dnl 'configure' with a wrong '--srcdir'). @@ -106,11 +106,6 @@ dnl Do all the checks necessary to figure out -lnsl / -lsocket stuff AC_LIBRARY_NET -dnl Look for res_mkquery. Done after AC_LIBRARY_NET in case res_mkquery -dnl is in one of those libraries somewhere. -AC_SEARCH_LIBS(res_mkquery, resolv, , -[AC_MSG_ERROR([Unable to find library containing res_mkquery()])]) - dnl Checks for header files. AC_HEADER_STDC AC_CHECK_HEADERS(poll.h sys/devpoll.h sys/event.h sys/epoll.h) @@ -156,11 +151,6 @@ *-linux*) AC_MSG_RESULT([Linux ($host) found.]) unet_poll_syscall=yes -# if test x"$ac_cv_header_sys_epoll_h" = xyes; then -# unet_poll_syscall=no -# else -# unet_poll_syscall=yes -# fi OSDEP_C=os_linux.c ;; @@ -719,25 +709,45 @@ echo "IRC-Dev ircd is now hopefully configured for your system." echo "" echo " Host system: $host_os" -echo " Prefix: $prefix" +echo " Engines supported:" +if test x"$unet_cv_enable_epoll" = xyes; then +echo " epoll()" +fi +if test x"$unet_cv_enable_kqueue" = xyes; then +echo " kqueue()" +fi +if test x"$unet_cv_enable_devpoll" = xyes; then +echo " /dev/poll" +fi +if test x"$unet_cv_enable_poll" = xyes; then +echo " poll()" +fi +echo "" echo " Asserts: $unet_cv_enable_asserts" echo " Warnings: $unet_cv_enable_warnings" echo " Debug: $unet_cv_enable_debug" echo " Profile: $unet_cv_enable_profile" echo " Pedantic: $unet_cv_enable_pedantic" +echo " Inlines: $unet_cv_enable_inlines" +echo " Debugging symbols: $unet_cv_enable_symbols" echo " ADNS: $unet_cv_enable_adns" -echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" -echo " Chroot: $unet_cv_with_chroot" echo "" -echo " Domain: $unet_cv_with_domain" -echo " Binaries path: $prefix/bin" +echo " Prefix: $prefix" +echo " Binaries path: $unet_bindir" echo " IRCD Binary: $unet_spath" +echo " Lib path: $unet_libdir" echo " Data path: $unet_cv_with_dpath" -echo " Config path: $unet_cv_with_cpath" -echo " Log path: $unet_cv_with_lpath" +echo " Config file: $unet_cpath" +echo " Debug log file: $unet_lpath" +echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" +echo " Chroot: $unet_cv_with_chroot" +echo "" echo " Maximum connections: $unet_cv_with_maxcon" +echo " Domain: $unet_cv_with_domain" +#echo " IRC Environment: DDB (Distributed DataBase)" +#echo " IRC Environment: Services (Ex TerraIRCU)" +#echo " IRC Environment: Undernet" +#echo " IRC Environment: None (BUG, mail to zo...@ir...)" echo "" -echo " poll() engine: $unet_cv_enable_poll" -echo " epoll() engine: $unet_cv_enable_epoll" -echo " kqueue() engine: $unet_cv_enable_kqueue" -echo " /dev/poll engine: $unet_cv_enable_devpoll" + + Index: ircd-ircdev/include/channel.h diff -u ircd-ircdev/include/channel.h:1.2 ircd-ircdev/include/channel.h:1.3 --- ircd-ircdev/include/channel.h:1.2 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/include/channel.h Tue Nov 11 13:36:21 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: channel.h,v 1.2 2003/11/01 17:19:35 zolty Exp $ + * $Id: channel.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_channel_h #define INCLUDED_channel_h @@ -40,6 +40,9 @@ #define MODEBUFLEN 200 #define KEYLEN 23 +#if defined(UNDERNET) +#define PASSLEN 23 +#endif #define CHANNELLEN 200 #define MAXJOINARGS 15 /* number of slots for join buffer */ @@ -67,6 +70,11 @@ #define CHFL_BANNED 0x1000 /* Channel member is banned */ #define CHFL_SILENCE_IPMASK 0x2000 /* silence mask is an IP-number mask */ #define CHFL_USER_PARTING 0x4000 /* User is already parting that channel */ +#if defined(UNDERNET) +#define CHFL_BURST_ALREADY_OPPED 0x08000 /* In oob BURST, but was already joined and opped */ +#define CHFL_BURST_ALREADY_VOICED 0x10000 /* In oob BURST, but was already joined and voiced */ +#define CHFL_CHANNEL_MANAGER 0x20000 /* Set when creating channel or using Apass */ +#endif #define CHFL_OVERLAP (CHFL_CHANOP | CHFL_VOICE) #define CHFL_BANVALIDMASK (CHFL_BANVALID | CHFL_BANNED) @@ -90,18 +98,31 @@ #define MODE_SAVE 0x20000 /* save this mode-with-arg 'til later */ #define MODE_FREE 0x40000 /* string needs to be passed to MyFree() */ #define MODE_BURSTADDED 0x80000 /* channel was created by a BURST */ +#if defined(UNDERNET) +#define MODE_UPASS 0x100000 +#define MODE_APASS 0x200000 +#endif /* * mode flags which take another parameter (With PARAmeterS) */ #define MODE_WPARAS (MODE_CHANOP|MODE_VOICE|MODE_BAN|MODE_KEY|MODE_LIMIT) +#if defined(UNDERNET) +#define infochanmodes feature_bool(FEAT_OPLEVELS) ? "Abiklmnopstuvr" : "biklmnopstvr" +#define infochanmodeswithparams feature_bool(FEAT_OPLEVELS) ? "Abklouv" : "bklov" +#else +#define infochanmodes "biklmnopstvr" +#define infochanmodeswithparams "bklov" +#endif + #define HoldChannel(x) (!(x)) /* name invisible */ #define SecretChannel(x) ((x) && ((x)->mode.mode & MODE_SECRET)) /* channel not shown but names are */ #define HiddenChannel(x) ((x) && ((x)->mode.mode & MODE_PRIVATE)) /* channel visible */ -#define ShowChannel(v,c) (PubChannel(c) || find_channel_member((v),(c))) +#define ShowChannel(v,c) (PubChannel(c) || find_channel_member((v),(c)) || \ + (IsAnOper(v) && HasPriv(v, PRIV_LIST_CHAN))) #define PubChannel(x) ((!x) || ((x)->mode.mode & \ (MODE_PRIVATE | MODE_SECRET)) == 0) #define is_listed(x) ((x)->mode.mode & MODE_LISTED) @@ -170,18 +191,32 @@ struct Membership* next_channel; struct Membership* prev_channel; unsigned int status; +#if defined(UNDERNET) + unsigned short oplevel; +#endif }; +#if defined(UNDERNET) +#define MAXOPLEVELDIGITS 3 +#define MAXOPLEVEL 999 +#endif + #define IsZombie(x) ((x)->status & CHFL_ZOMBIE) #define IsDeopped(x) ((x)->status & CHFL_DEOPPED) #define IsBanned(x) ((x)->status & CHFL_BANNED) #define IsBanValid(x) ((x)->status & CHFL_BANVALID) #define IsChanOp(x) ((x)->status & CHFL_CHANOP) +#if defined(UNDERNET) +#define OpLevel(x) ((x)->oplevel) +#endif #define HasVoice(x) ((x)->status & CHFL_VOICE) #define IsServOpOk(x) ((x)->status & CHFL_SERVOPOK) #define IsBurstJoined(x) ((x)->status & CHFL_BURST_JOINED) #define IsVoicedOrOpped(x) ((x)->status & CHFL_VOICED_OR_OPPED) #define IsUserParting(x) ((x)->status & CHFL_USER_PARTING) +#if defined(UNDERNET) +#define IsChannelManager(x) ((x)->status & CHFL_CHANNEL_MANAGER) +#endif #define SetBanned(x) ((x)->status |= CHFL_BANNED) #define SetBanValid(x) ((x)->status |= CHFL_BANVALID) @@ -190,6 +225,10 @@ #define SetBurstJoined(x) ((x)->status |= CHFL_BURST_JOINED) #define SetZombie(x) ((x)->status |= CHFL_ZOMBIE) #define SetUserParting(x) ((x)->status |= CHFL_USER_PARTING) +#if defined(UNDERNET) +#define SetChannelManager(x) ((x)->status |= CHFL_CHANNEL_MANAGER) +#define SetOpLevel(x, v) (void)((x)->oplevel = (v)) +#endif #define ClearBanned(x) ((x)->status &= ~CHFL_BANNED) #define ClearBanValid(x) ((x)->status &= ~CHFL_BANVALID) @@ -202,12 +241,17 @@ unsigned int mode; unsigned int limit; char key[KEYLEN + 1]; +#if defined(UNDERNET) + char upass[PASSLEN + 1]; + char apass[PASSLEN + 1]; +#endif }; struct Channel { struct Channel* next; struct Channel* prev; struct Channel* hnext; + struct DestructEvent* destruct_event; time_t creationtime; time_t topic_time; unsigned int users; @@ -294,7 +338,7 @@ */ extern void clean_channelname(char* name); extern void channel_modes(struct Client *cptr, char *mbuf, char *pbuf, - int buflen, struct Channel *chptr); + int buflen, struct Channel *chptr, struct Membership *member); extern int set_mode(struct Client* cptr, struct Client* sptr, struct Channel* chptr, int parc, char* parv[], char* mbuf, char* pbuf, char* npbuf, int* badop); @@ -305,9 +349,10 @@ extern struct Membership* find_member_link(struct Channel * chptr, const struct Client* cptr); extern int sub1_from_channel(struct Channel* chptr); +extern int destruct_channel(struct Channel* chptr); extern int can_join(struct Client *sptr, struct Channel *chptr, char *key); extern void add_user_to_channel(struct Channel* chptr, struct Client* who, - unsigned int flags); + unsigned int flags, int oplevel); extern void cancel_mode(struct Client *sptr, struct Channel *chptr, char m, const char *param, int *count); extern void add_token_to_sendbuf(char *token, size_t *sblenp, int *firstp, @@ -336,7 +381,12 @@ extern int is_chan_op(struct Client *cptr, struct Channel *chptr); extern int is_zombie(struct Client *cptr, struct Channel *chptr); extern int has_voice(struct Client *cptr, struct Channel *chptr); -extern int IsInvited(struct Client* cptr, struct Channel* chptr); +/* + NOTE: pointer is compared, and not dereferenced, called by + add_target with a void*, since targets could be anything, + this function can't make any assumptions that it has a channel +*/ +extern int IsInvited(struct Client* cptr, const void* chptr); extern void send_channel_modes(struct Client *cptr, struct Channel *chptr); extern char *pretty_mask(char *mask); extern void del_invite(struct Client *cptr, struct Channel *chptr); @@ -361,7 +411,8 @@ extern int mode_parse(struct ModeBuf *mbuf, struct Client *cptr, struct Client *sptr, struct Channel *chptr, - int parc, char *parv[], unsigned int flags); + int parc, char *parv[], unsigned int flags, + struct Membership* member); #define MODE_PARSE_SET 0x01 /* actually set channel modes */ #define MODE_PARSE_STRICT 0x02 /* +m +n +t style not supported */ Index: ircd-ircdev/include/client.h diff -u ircd-ircdev/include/client.h:1.2 ircd-ircdev/include/client.h:1.3 --- ircd-ircdev/include/client.h:1.2 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/include/client.h Tue Nov 11 13:36:21 2003 @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: client.h,v 1.2 2003/11/02 00:47:33 zolty Exp $ + * $Id: client.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_client_h #define INCLUDED_client_h @@ -81,6 +81,8 @@ #define FLAGSET_SET(set, flag) (set).bits[FLAGSET_INDEX(flag)] |= FLAGSET_MASK(flag) #define FLAGSET_CLEAR(set, flag) (set).bits[FLAGSET_INDEX(flag)] &= ~FLAGSET_MASK(flag) +#define infousermodes "dioswkgx" + enum Priv { PRIV_CHAN_LIMIT, /* no channel limit on oper */ PRIV_MODE_LCHAN, /* oper can mode local chans */ @@ -110,6 +112,7 @@ PRIV_DISPLAY, /* "Is an oper" displayed */ PRIV_SEE_OPERS, /* display hidden opers */ PRIV_WIDE_GLINE, /* oper can set wider G-lines */ + PRIV_LIST_CHAN, /* oper can list secret channels */ PRIV_FORCE_OPMODE, /* oper can override a Q-line */ PRIV_FORCE_LOCAL_OPMODE,/* oper can override a local channel Q-line */ PRIV_LAST_PRIV /* must be the same as the last priv */ @@ -146,7 +149,9 @@ FLAG_CHSERV, /* Disallow KICK or MODE -o on the user; don't display channels in /whois */ FLAG_DEBUG, /* send global debug/anti-hack info */ +#if defined(UNDERNET) FLAG_ACCOUNT, /* account name has been set */ +#endif FLAG_HIDDENHOST, /* user's host is hidden */ FLAG_LAST_FLAG, FLAG_LOCAL_UMODES = FLAG_LOCOP, /* First local mode flag */ @@ -424,12 +429,18 @@ #define SendWallops(x) HasFlag(x, FLAG_WALLOP) #define IsHub(x) HasFlag(x, FLAG_HUB) #define IsService(x) HasFlag(x, FLAG_SERVICE) +#if defined(UNDERNET) #define IsAccount(x) HasFlag(x, FLAG_ACCOUNT) +#endif #define IsHiddenHost(x) HasFlag(x, FLAG_HIDDENHOST) #define IsPingSent(x) HasFlag(x, FLAG_PINGSENT) #define IsPrivileged(x) (IsAnOper(x) || IsServer(x)) +#if !defined(UNDERNET) +#define HasHiddenHost(x) (IsHiddenHost(x)) +#else #define HasHiddenHost(x) (IsAccount(x) && IsHiddenHost(x)) +#endif #define SetAccess(x) SetFlag(x, FLAG_CHKACCESS) #define SetBurst(x) SetFlag(x, FLAG_BURST) @@ -448,9 +459,14 @@ #define SetServNotice(x) SetFlag(x, FLAG_SERVNOTICE) #define SetHub(x) SetFlag(x, FLAG_HUB) #define SetService(x) SetFlag(x, FLAG_SERVICE) +#if defined(UNDERNET) #define SetAccount(x) SetFlag(x, FLAG_ACCOUNT) +#endif #define SetHiddenHost(x) SetFlag(x, FLAG_HIDDENHOST) #define SetPingSent(x) SetFlag(x, FLAG_PINGSENT) + +#define SeeOper(sptr,acptr) (IsAnOper(acptr) && (HasPriv(acptr, PRIV_DISPLAY) \ + || HasPriv(sptr, PRIV_SEE_OPERS))) #define ClearAccess(x) ClrFlag(x, FLAG_CHKACCESS) #define ClearBurst(x) ClrFlag(x, FLAG_BURST) Index: ircd-ircdev/include/destruct_event.h diff -u /dev/null ircd-ircdev/include/destruct_event.h:1.1 --- /dev/null Tue Nov 11 13:36:32 2003 +++ ircd-ircdev/include/destruct_event.h Tue Nov 11 13:36:21 2003 @@ -0,0 +1,36 @@ +#ifndef INCLUDED_destruct_event_h +#define INCLUDED_destruct_event_h +/* + * IRC - Internet Relay Chat, include/destruct_event.h + * Copyright (C) 2002 Carlo Wood <ca...@al...> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * + * $Id: destruct_event.h,v 1.1 2003/11/11 21:36:21 zolty Exp $ + */ + +#ifndef INCLUDED_config_h +#include "config.h" +#endif +#ifndef INCLUDED_channel_h +#include "channel.h" +#endif + +extern void schedule_destruct_event_1m(struct Channel* chptr); +extern void schedule_destruct_event_48h(struct Channel* chptr); +extern void remove_destruct_event(struct Channel* chptr); +extern void exec_expired_destruct_events(struct Event* ev); + +#endif /* INCLUDED_destruct_event_h */ Index: ircd-ircdev/include/handlers.h diff -u ircd-ircdev/include/handlers.h:1.2 ircd-ircdev/include/handlers.h:1.3 --- ircd-ircdev/include/handlers.h:1.2 Tue Oct 7 11:52:17 2003 +++ ircd-ircdev/include/handlers.h Tue Nov 11 13:36:21 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: handlers.h,v 1.2 2003/10/07 18:52:17 zolty Exp $ + * $Id: handlers.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_handlers_h #define INCLUDED_handlers_h @@ -184,7 +184,9 @@ /* * Server commands */ +#if defined(UNDERNET) extern int ms_account(struct Client*, struct Client*, int, char*[]); +#endif extern int ms_admin(struct Client*, struct Client*, int, char*[]); extern int ms_asll(struct Client*, struct Client*, int, char*[]); extern int ms_away(struct Client*, struct Client*, int, char*[]); Index: ircd-ircdev/include/ircd_features.h diff -u ircd-ircdev/include/ircd_features.h:1.3 ircd-ircdev/include/ircd_features.h:1.4 --- ircd-ircdev/include/ircd_features.h:1.3 Sat Nov 1 07:26:45 2003 +++ ircd-ircdev/include/ircd_features.h Tue Nov 11 13:36:21 2003 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: ircd_features.h,v 1.3 2003/11/01 15:26:45 zolty Exp $ + * $Id: ircd_features.h,v 1.4 2003/11/11 21:36:21 zolty Exp $ */ struct Client; @@ -49,6 +49,9 @@ FEAT_HIDDEN_IP, FEAT_AUTOHIDE, FEAT_CONNEXIT_NOTICES, +#if defined(UNDERNET) + FEAT_OPLEVELS, +#endif FEAT_LOCAL_CHANNELS, /* features that probably should not be touched */ @@ -92,6 +95,7 @@ FEAT_UNLIMIT_OPER_QUERY, FEAT_LOCAL_KILL_ONLY, FEAT_CONFIG_OPERCMDS, + FEAT_LIST_CHAN, /* features that affect global opers on this server */ FEAT_OPER_KILL, @@ -111,6 +115,7 @@ FEAT_OPER_SET, FEAT_OPERS_SEE_IN_SECRET_CHANNELS, FEAT_OPER_WIDE_GLINE, + FEAT_OPER_LIST_CHAN, /* features that affect local opers on this server */ FEAT_LOCOP_KILL, @@ -125,6 +130,7 @@ FEAT_LOCOP_SET, FEAT_LOCOP_SEE_IN_SECRET_CHANNELS, FEAT_LOCOP_WIDE_GLINE, + FEAT_LOCOP_LIST_CHAN, /* HEAD_IN_SAND Features */ FEAT_HIS_SNOTICES, Index: ircd-ircdev/include/ircd_tea.h diff -u /dev/null ircd-ircdev/include/ircd_tea.h:1.1 --- /dev/null Tue Nov 11 13:36:32 2003 +++ ircd-ircdev/include/ircd_tea.h Tue Nov 11 13:36:21 2003 @@ -0,0 +1,30 @@ +/* + * IRC - Internet Relay Chat, ircd/ircd_tea.h + * + * See file AUTHORS in IRC package for additional names of + * the programmers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 1, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * + * $Id: ircd_tea.h,v 1.1 2003/11/11 21:36:21 zolty Exp $ + */ +#ifndef INCLUDED_ircd_tea_h +#define INCLUDED_ircd_tea_h + +extern void ircd_tea(unsigned int v[], unsigned int k[], unsigned int x[]); +extern void ircd_untea(unsigned int v[], unsigned int k[], unsigned int x[]); + +#endif /* INCLUDED_ircd_tea_h */ + Index: ircd-ircdev/include/numeric.h diff -u ircd-ircdev/include/numeric.h:1.2 ircd-ircdev/include/numeric.h:1.3 --- ircd-ircdev/include/numeric.h:1.2 Tue Oct 7 11:52:18 2003 +++ ircd-ircdev/include/numeric.h Tue Nov 11 13:36:21 2003 @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: numeric.h,v 1.2 2003/10/07 18:52:18 zolty Exp $ + * $Id: numeric.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_numeric_h #define INCLUDED_numeric_h @@ -63,6 +63,9 @@ #define RPL_MAP 15 /* Undernet extension */ #define RPL_MAPMORE 16 /* Undernet extension */ #define RPL_MAPEND 17 /* Undernet extension */ +#if defined(UNDERNET) +#define RPL_APASSWARN 30 /* Undernet extension */ +#endif /* RPL_YOURID 42 IRCnet extension */ /* RPL_ATTEMPTINGJUNC 50 aircd extension */ /* RPL_ATTEMPTINGREROUTE 51 aircd extension */ @@ -449,6 +452,13 @@ ERR_WHOLIMEXCEED 523 dalnet */ #define ERR_QUARANTINED 524 /* Undernet extension -Vampire */ +#if defined(UNDERNET) +#define ERR_NOTLOWEROPLEVEL 550 /* Undernet extension */ +#define ERR_NOTMANAGER 551 /* Undernet extension */ +#define ERR_CHANSECURED 552 /* Undernet extension */ +#define ERR_UPASSSET 553 /* Undernet extension */ +#define ERR_UPASSNOTSET 554 /* Undernet extension */ +#endif #define RPL_LOGON 600 /* Dalnet extension */ #define RPL_LOGOFF 601 /* Dalnet extension */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.6 ircd-ircdev/include/patchlevel.h:1.7 --- ircd-ircdev/include/patchlevel.h:1.6 Sun Nov 2 10:34:47 2003 +++ ircd-ircdev/include/patchlevel.h Tue Nov 11 13:36:21 2003 @@ -15,10 +15,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: patchlevel.h,v 1.6 2003/11/02 18:34:47 zolty Exp $ + * $Id: patchlevel.h,v 1.7 2003/11/11 21:36:21 zolty Exp $ * */ -#define PATCHLEVEL ".alpha5" +#define PATCHLEVEL ".alpha6" #define RELEASE "1.0" Index: ircd-ircdev/include/res.h diff -u ircd-ircdev/include/res.h:1.2 ircd-ircdev/include/res.h:1.3 --- ircd-ircdev/include/res.h:1.2 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/include/res.h Tue Nov 11 13:36:21 2003 @@ -1,7 +1,7 @@ /* * irc2.7.2/ircd/res.h (C)opyright 1992 Darren Reed. * - * $Id: res.h,v 1.2 2003/11/02 00:47:33 zolty Exp $ + * $Id: res.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_res_h #define INCLUDED_res_h @@ -16,7 +16,7 @@ struct DNSQuery { void* vptr; /* pointer used by callback to identify request */ - void (*callback)(void* vptr, struct hostent* reply); /* callback to call */ + void (*callback)(void* vptr, struct hostent* he); /* callback to call */ }; extern int ResolverFileDescriptor; /* GLOBAL - file descriptor (s_bsd.c) */ Index: ircd-ircdev/include/s_user.h diff -u ircd-ircdev/include/s_user.h:1.1.1.1 ircd-ircdev/include/s_user.h:1.2 --- ircd-ircdev/include/s_user.h:1.1.1.1 Mon Sep 8 03:34:28 2003 +++ ircd-ircdev/include/s_user.h Tue Nov 11 13:36:21 2003 @@ -1,7 +1,7 @@ /* * s_user.h * - * $Id: s_user.h,v 1.1.1.1 2003/09/08 10:34:28 zolty Exp $ + * $Id: s_user.h,v 1.2 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_s_user_h #define INCLUDED_s_user_h @@ -77,7 +77,7 @@ InfoFormatter fmt); extern int add_silence(struct Client* sptr, const char* mask); -extern int hide_hostmask(struct Client *cptr, unsigned int flag); +extern int hide_hostmask(struct Client *cptr, unsigned int flags); extern int set_user_mode(struct Client *cptr, struct Client *sptr, int parc, char *parv[]); extern int is_silenced(struct Client *sptr, struct Client *acptr); Index: ircd-ircdev/include/struct.h diff -u ircd-ircdev/include/struct.h:1.2 ircd-ircdev/include/struct.h:1.3 --- ircd-ircdev/include/struct.h:1.2 Tue Oct 7 11:52:18 2003 +++ ircd-ircdev/include/struct.h Tue Nov 11 13:36:21 2003 @@ -18,7 +18,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: struct.h,v 1.2 2003/10/07 18:52:18 zolty Exp $ + * $Id: struct.h,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_struct_h #define INCLUDED_struct_h @@ -77,7 +77,9 @@ char username[USERLEN + 1]; char host[HOSTLEN + 1]; char realhost[HOSTLEN + 1]; +#if defined(UNDERNET) char account[ACCOUNTLEN + 1]; +#endif }; #endif /* INCLUDED_struct_h */ Index: ircd-ircdev/include/whocmds.h diff -u ircd-ircdev/include/whocmds.h:1.1.1.1 ircd-ircdev/include/whocmds.h:1.2 --- ircd-ircdev/include/whocmds.h:1.1.1.1 Mon Sep 8 03:34:28 2003 +++ ircd-ircdev/include/whocmds.h Tue Nov 11 13:36:21 2003 @@ -1,7 +1,7 @@ /* * whocmds.h * - * $Id: whocmds.h,v 1.1.1.1 2003/09/08 10:34:28 zolty Exp $ + * $Id: whocmds.h,v 1.2 2003/11/11 21:36:21 zolty Exp $ */ #ifndef INCLUDED_whocmds_h #define INCLUDED_whocmds_h @@ -36,15 +36,22 @@ #define WHO_FIELD_DIS 256 #define WHO_FIELD_REN 512 #define WHO_FIELD_IDL 1024 +#if defined(UNDERNET) #define WHO_FIELD_ACC 2048 +#endif #define WHO_FIELD_DEF ( WHO_FIELD_NIC | WHO_FIELD_UID | WHO_FIELD_HOS | WHO_FIELD_SER ) #define IS_VISIBLE_USER(s,ac) ((s==ac) || (!IsInvisible(ac))) -#define SEE_LUSER(s, ac, b) (IS_VISIBLE_USER(s, ac) || ((b & WHOSELECT_EXTRA) && MyConnect(ac) && (HasPriv((s), PRIV_SHOW_INVIS) || HasPriv((s), PRIV_SHOW_ALL_INVIS)))) - -#define SEE_USER(s, ac, b) (SEE_LUSER(s, ac, b) || ((b & WHOSELECT_EXTRA) && HasPriv((s), PRIV_SHOW_ALL_INVIS))) +#define SEE_LUSER(s, ac, b) (IS_VISIBLE_USER(s, ac) || \ + ((b & WHOSELECT_EXTRA) && MyConnect(ac) && \ + (HasPriv((s), PRIV_SHOW_INVIS) || \ + HasPriv((s), PRIV_SHOW_ALL_INVIS)))) + +#define SEE_USER(s, ac, b) (SEE_LUSER(s, ac, b) || \ + ((b & WHOSELECT_EXTRA) && \ + HasPriv((s), PRIV_SHOW_ALL_INVIS))) #define SHOW_MORE(sptr, counter) (HasPriv(sptr, PRIV_UNLIMIT_QUERY) || (!(counter-- < 0)) ) Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.6 ircd-ircdev/ircd/Makefile.in:1.7 --- ircd-ircdev/ircd/Makefile.in:1.6 Sun Nov 2 10:34:47 2003 +++ ircd-ircdev/ircd/Makefile.in Tue Nov 11 13:36:21 2003 @@ -58,7 +58,8 @@ CC = @CC@ CFLAGS = @CFLAGS@ -CPPFLAGS = -I. -I.. -I${top_srcdir}/include -I${top_srcdir}/libs/adns/src @CPPFLAGS@ +CPPFLAGS = -I. -I.. -I${top_srcdir}/include @CPPFLAGS@ +#CPPFLAGS = -I. -I.. -I${top_srcdir}/include -I${top_srcdir}/libs/adns/src @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ @@ -91,6 +92,7 @@ client.c \ crule.c \ dbuf.c \ + destruct_event.c \ fda.c \ fileio.c \ gline.c \ @@ -105,6 +107,7 @@ ircd_signal.c \ ircd_snprintf.c \ ircd_string.c \ + ircd_tea.c \ ircd_xopen.c \ jupe.c \ lex.yy.c \ Index: ircd-ircdev/ircd/channel.c diff -u ircd-ircdev/ircd/channel.c:1.2 ircd-ircdev/ircd/channel.c:1.3 --- ircd-ircdev/ircd/channel.c:1.2 Sat Nov 1 09:19:36 2003 +++ ircd-ircdev/ircd/channel.c Tue Nov 11 13:36:21 2003 @@ -17,12 +17,13 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: channel.c,v 1.2 2003/11/01 17:19:36 zolty Exp $ + * $Id: channel.c,v 1.3 2003/11/11 21:36:21 zolty Exp $ */ #include "config.h" #include "channel.h" #include "client.h" +#include "destruct_event.h" #include "hash.h" #include "ircd.h" #include "ircd_alloc.h" @@ -185,14 +186,17 @@ /* * Subtract one user from channel i (and free channel * block, if channel became empty). + * + * defined(UNDERNET) + * Returns: true (1) if channel still has members. + * false (0) if the channel is now empty. + * !defined(UNDERNET) * Returns: true (1) if channel still exists * false (0) if the channel was destroyed + * !defined(UNDERNET) */ int sub1_from_channel(struct Channel* chptr) { - struct SLink *tmp; - struct SLink *obtmp; - if (chptr->users > 1) /* Can be 0, called for an empty channel too */ { assert(0 != chptr->members); @@ -200,6 +204,46 @@ return 1; } +#if defined(UNDERNET) + chptr->users = 0; + + /* + * Also channels without Apass set need to be kept alive, + * otherwise Bad Guys(tm) would be able to takeover + * existing channels too easily, and then set an Apass! + * However, if a channel without Apass becomes empty + * then we try to be kind to them and remove possible + * limiting modes. + */ + chptr->mode.mode &= ~MODE_INVITEONLY; + chptr->mode.limit = 0; + /* + * We do NOT reset a possible key or bans because when + * the 'channel owners' can't get in because of a key + * or ban then apparently there was a fight/takeover + * on the channel and we want them to contact IRC opers + * who then will educate them on the use of Apass/upass. + */ + + if (feature_bool(FEAT_OPLEVELS)) { + if (TStime() - chptr->creationtime < 172800) /* Channel younger than 48 hours? */ + schedule_destruct_event_1m(chptr); /* Get rid of it in approximately 4-5 minutes */ + else + schedule_destruct_event_48h(chptr); /* Get rid of it in approximately 48 hours */ + } else + destruct_channel(chptr); +#else + destruct_channel(chptr); +#endif + + return 0; +} + +int destruct_channel(struct Channel* chptr) +{ + struct SLink *tmp; + struct SLink *obtmp; + assert(0 == chptr->members); /* Channel became (or was) empty: Remove channel */ @@ -425,6 +469,7 @@ s = make_nick_user_host(nu_host, cli_name(cptr), (cli_user(cptr))->username, (cli_user(cptr))->host); +#if defined(UNDERNET) if (IsAccount(cptr)) { if (HasHiddenHost(cptr)) sr = make_nick_user_host(nu_realhost, cli_name(cptr), @@ -438,6 +483,7 @@ tmphost); } } +#endif /* defined(UNDERNET) */ for (tmp = chptr->banlist; tmp; tmp = tmp->next) { if ((tmp->flags & CHFL_BAN_IPMASK)) { @@ -473,7 +519,7 @@ * chain. */ void add_user_to_channel(struct Channel* chptr, struct Client* who, - unsigned int flags) + unsigned int flags, int oplevel) { assert(0 != chptr); assert(0 != who); @@ -492,6 +538,9 @@ member->user = who; member->channel = chptr; member->status = flags; +#if defined(UNDERNET) + member->oplevel = oplevel; +#endif member->next_member = chptr->members; if (member->next_member) @@ -505,6 +554,8 @@ member->prev_channel = 0; (cli_user(who))->channel = member; + if (chptr->destruct_event) + remove_destruct_event(chptr); ++chptr->users; ++((cli_user(who))->joined); } @@ -621,6 +672,12 @@ { assert(0 != member); +#if defined(UNDERNET) + /* Discourage using the Apass to get op. They should use the upass. */ + if (IsChannelManager(member) && *member->channel->mode.upass) + return 0; +#endif + if (IsVoicedOrOpped(member)) return 1; /* @@ -651,10 +708,16 @@ member = find_channel_member(cptr, chptr); - /* You can't speak if your off channel and +n (no external messages) or +m (moderated). */ + /* + * You can't speak if you're off channel, and it is +n (no external messages) + * or +m (moderated). + */ if (!member) { - if ((chptr->mode.mode & (MODE_NOPRIVMSGS|MODE_MODERATED)) || - ((chptr->mode.mode & MODE_REGONLY) && !IsAccount(cptr))) + if ((chptr->mode.mode & (MODE_NOPRIVMSGS|MODE_MODERATED)) +#if defined(UNDERNET) + || ((chptr->mode.mode & MODE_REGONLY) && !IsAccount(cptr)) +#endif + ) return 0; else return !is_banned(cptr, chptr, NULL); @@ -686,8 +749,10 @@ * with the parameters in pbuf. */ void channel_modes(struct Client *cptr, char *mbuf, char *pbuf, int buflen, - struct Channel *chptr) + struct Channel *chptr, struct Membership *member) { + int previous_parameter = 0; + assert(0 != mbuf); assert(0 != pbuf); assert(0 != chptr); @@ -710,6 +775,7 @@ if (chptr->mode.limit) { *mbuf++ = 'l'; ircd_snprintf(0, pbuf, buflen, "%u", chptr->mode.limit); + previous_parameter = 1; } if (*chptr->mode.key) { @@ -720,17 +786,51 @@ strcat(pbuf, chptr->mode.key); } else strcat(pbuf, "*"); + previous_parameter = 1; + } +#if defined(UNDERNET) + if (*chptr->mode.apass) { + *mbuf++ = 'A'; + if (previous_parameter) + strcat(pbuf, " "); + if (IsServer(cptr)) { + strcat(pbuf, chptr->mode.apass); + } else + strcat(pbuf, "*"); + previous_parameter = 1; + } + if (*chptr->mode.upass) { + *mbuf++ = 'u'; + if (previous_parameter) + strcat(pbuf, " "); + if (IsServer(cptr) || (member && IsChanOp(member) && OpLevel(member) == 0)) { + strcat(pbuf, chptr->mode.upass); + } else + strcat(pbuf, "*"); } +#endif /* UNDERNET */ *mbuf = '\0'; } +#if defined(UNDERNET) +int compare_member_oplevel(const void *mp1, const void *mp2) +{ + struct Membership const* member1 = *(struct Membership const**)mp1; + struct Membership const* member2 = *(struct Membership const**)mp2; + if (member1->oplevel == member2->oplevel) + return 0; + return (member1->oplevel < member2->oplevel) ? -1 : 1; +} +#endif /* UNDERNET */ + /* * send "cptr" a full list of the modes for channel chptr. */ void send_channel_modes(struct Client *cptr, struct Channel *chptr) { + /* The order in which modes are generated is now mandatory */ static unsigned int current_flags[4] = - { 0, CHFL_CHANOP | CHFL_VOICE, CHFL_VOICE, CHFL_CHANOP }; + { 0, CHFL_VOICE, CHFL_CHANOP, CHFL_CHANOP | CHFL_VOICE }; int first = 1; int full = 1; int flag_cnt = 0; @@ -741,6 +841,12 @@ char modebuf[MODEBUFLEN]; char parabuf[MODEBUFLEN]; struct MsgBuf *mb; +#if defined(UNDERNET) + int number_of_ops = 0; + int opped_members_index = 0; + struct Membership** opped_members = NULL; + int last_oplevel = 0; +#endif assert(0 != cptr); assert(0 != chptr); @@ -752,7 +858,7 @@ lp2 = chptr->banlist; *modebuf = *parabuf = '\0'; - channel_modes(cptr, modebuf, parabuf, sizeof(parabuf), chptr); + channel_modes(cptr, modebuf, parabuf, sizeof(parabuf), chptr, 0); for (first = 1; full; first = 0) /* Loop for multiple messages */ { @@ -764,7 +870,7 @@ mb = msgq_make(&me, "%C " TOK_BURST " %H %Tu", &me, chptr, chptr->creationtime); - if (first && modebuf[1]) /* Add simple modes (iklmnpst) + if (first && modebuf[1]) /* Add simple modes (Aiklmnpstu) if first message */ { /* prefix: "<Y> B <channel> <TS>[ <modes>[ <params>]]" */ @@ -777,14 +883,134 @@ /* * Attach nicks, comma seperated " nick[:modes],nick[:modes],..." * + * First find all opless members. + * + * defined(UNDERNET) + * Run 2 times over all members, to group the members with + * and without voice together. + * Then run 2 times over all opped members (which are ordered + * by op-level) to also group voice and non-voice together. + * + * !defined(UNDERNET) * Run 4 times over all members, to group the members with the * same mode together */ - for (first = 1; flag_cnt < 4; - member = chptr->members, new_mode = 1, flag_cnt++) +#if defined(UNDERNET) + for (first = 1; flag_cnt < 4; new_mode = 1, flag_cnt++) { + while(member) + { + if (flag_cnt < 2 && IsChanOp(member)) + { + /* + * The first loop (to find all non-voice/op), we count the ops. + * The second loop (to find all voiced non-ops), store the ops + * in a dynamic array. + */ + if (flag_cnt == 0) + ++number_of_ops; + else + opped_members[opped_members_index++] = member; + } + /* Only handle the members with the flags that we are interested in. */ + if ((member->status & CHFL_VOICED_OR_OPPED) == current_flags[flag_cnt]) + { + if (msgq_bufleft(mb) < NUMNICKLEN + 3 + MAXOPLEVELDIGITS) + /* The 3 + MAXOPLEVELDIGITS is a possible ",:v999". */ + { + full = 1; /* Make sure we continue after + sending it so far */ + /* Ensure the new BURST line contains the current + * ":mode", except when there is no mode yet. */ + new_mode = (flag_cnt > 0) ? 1 : 0; + break; /* Do not add this member to this message */ + } + msgq_append(&me, mb, "%c%C", first ? ' ' : ',', member->user); + first = 0; /* From now on, use commas to add new nicks */ + + /* + * Do we have a nick with a new mode ? + * Or are we starting a new BURST line? + */ + if (new_mode) + { + /* + * This means we are at the _first_ member that has only + * voice, or the first member that has only ops, or the + * first member that has voice and ops (so we get here + * at most three times, plus once for every start of + * a continued BURST line where only these modes is current. + * In the two cases where the current mode includes ops, + * we need to add the _absolute_ value of the oplevel to the mode. + */ + char tbuf[3 + MAXOPLEVELDIGITS] = ":"; + int loc = 1; + + if (HasVoice(member)) /* flag_cnt == 1 or 3 */ + tbuf[loc++] = 'v'; + if (IsChanOp(member)) /* flag_cnt == 2 or 3 */ + { + /* append the absolute value of the oplevel */ + loc += ircd_snprintf(0, tbuf + loc, sizeof(tbuf) - loc, "%u", member->oplevel); + last_oplevel = member->oplevel; + } + tbuf[loc] = '\0'; + msgq_append(&me, mb, tbuf); + new_mode = 0; + } + else if (flag_cnt > 1 && last_oplevel != member->oplevel) + { + /* + * This can't be the first member of a (continued) BURST + * message because then either flag_cnt == 0 or new_mode == 1 + * Now we need to append the incremental value of the oplevel. + */ + char tbuf[2 + MAXOPLEVELDIGITS]; + ircd_snprintf(0, tbuf, sizeof(tbuf), ":%u", member->oplevel - last_oplevel); + last_oplevel = member->oplevel; + msgq_append(&me, mb, tbuf); + } + } + /* Go to the next `member'. */ + if (flag_cnt < 2) + member = member->next_member; + else + member = opped_members[++opped_members_index]; + } + if (full) + break; + + /* Point `member' at the start of the list again. */ + if (flag_cnt == 0) + { + member = chptr->members; + /* Now, after one loop, we know the number of ops and can + * allocate the dynamic array with pointer to the ops. */ + opped_members = (struct Membership**) + MyMalloc((number_of_ops + 1) * sizeof(struct Membership*)); + opped_members[number_of_ops] = NULL; /* Needed for loop termination */ + } + else + { + /* At the end of the second loop, sort the opped members with + * increasing op-level, so that we will output them in the + * correct order (and all op-level increments stay positive) */ + if (flag_cnt == 1) + qsort(opped_members, number_of_ops, + sizeof(struct Membership*), compare_member_oplevel); + /* The third and fourth loop run only over the opped members. */ + member = opped_members[(opped_members_index = 0)]; + } + + } /* loop over 0,+v,+o,+ov */ + +#else /* !UNDERNET */ + for (first = 1; flag_cnt < 4; + member = chptr->members, new_mode = 1, flag_cnt++) + { for (; member; member = member->next_member) { + if ((member->status & CHFL_VOICED_OR_OPPED) != current_flags[flag_cnt]) continue; /* Skip members with different flags */ @@ -819,10 +1045,12 @@ msgq_append(&me, mb, tbuf); } } + member = member->next_member; } if (full) break; } +#endif /* UNDERNET */ if (!full) { @@ -848,6 +1076,12 @@ msgq_clean(mb); } /* Continue when there was something that didn't fit (full==1) */ + +#if defined(UNDERNET) + if (opped_members) + MyFree(opped_members); +#endif + } /* @@ -1024,8 +1258,10 @@ if (chptr->mode.limit && chptr->users >= chptr->mode.limit) return overrideJoin + ERR_CHANNELISFULL; +#if defined(UNDERNET) if ((chptr->mode.mode & MODE_REGONLY) && !IsAccount(sptr)) return overrideJoin + ERR_NEEDREGGEDNICK; +#endif if (is_banned(sptr, chptr, NULL)) return overrideJoin + ERR_BANNEDFROMCHAN; @@ -1172,7 +1408,8 @@ { for (; chptr; chptr = chptr->next) { - if (!cli_user(cptr)) + if (!cli_user(cptr) || (!(HasPriv(cptr, PRIV_LIST_CHAN) && IsAnOper(cptr)) && + SecretChannel(chptr) && !find_channel_member(cptr, chptr))) continue; if (chptr->users > args->min_users && chptr->users < args->max_users && chptr->creationtime > args->min_time && @@ -1220,7 +1457,7 @@ * via 'a', or on server 'B' via either 'b' or 'c', or on server D via 'd'. * * a) On server A : set CHFL_ZOMBIE for `who' (lp) and pass on the KICK. - * Remove the user immedeately when no users are left on the channel. + * Remove the user immediately when no users are left on the channel. * b) On server B : remove the user (who/lp) from the channel, send a * PART upstream (to A) and pass on the KICK. * c) KICKed by `client'; On server B : remove the user (who/lp) from the @@ -1309,7 +1546,7 @@ * of course, str2 is not NULL) */ static void -build_string(char *strptr, int *strptr_i, char *str1, char *str2, char c) +build_string(char *strptr, int *strptr_i, const char *str1, const char *str2, char c) { if (c) strptr[(*strptr_i)++] = c; @@ -1345,6 +1582,10 @@ /* MODE_KEY, 'k', */ /* MODE_BAN, 'b', */ /* MODE_LIMIT, 'l', */ +#if defined(UNDERNET) +/* MODE_APASS, 'A', */ +/* MODE_UPASS, 'u', */ +#endif 0x0, 0x0 }; int i; @@ -1419,13 +1660,34 @@ bufptr[(*bufptr_i)++] = MB_TYPE(mbuf, i) & MODE_CHANOP ? 'o' : 'v'; totalbuflen -= IRCD_MAX(5, tmp) + 1; } +#if defined(UNDERNET) + } else if (MB_TYPE(mbuf, i) & (MODE_BAN | MODE_APASS | MODE_UPASS)) { +#else } else if (MB_TYPE(mbuf, i) & MODE_BAN) { +#endif tmp = strlen(MB_STRING(mbuf, i)); if ((totalbuflen - tmp) <= 0) /* don't overflow buffer */ MB_TYPE(mbuf, i) |= MODE_SAVE; /* save for later */ else { +#if defined(UNDERNET) + char mode_char; + switch(MB_TYPE(mbuf, i) & (MODE_BAN | MODE_APASS | MODE_UPASS)) + { + case MODE_APASS: + mode_char = 'A'; + break; + case MODE_UPASS: + mode_char = 'u'; + break; + default: + mode_char = 'b'; + break; + } + bufptr[(*bufptr_i)++] = mode_char; +#else bufptr[(*bufptr_i)++] = 'b'; +#endif totalbuflen -= tmp + 1; } } else if (MB_TYPE(mbuf, i) & MODE_KEY) { @@ -1492,6 +1754,12 @@ build_string(strptr, strptr_i, mbuf->mb_dest & MODEBUF_DEST_NOKEY ? "*" : MB_STRING(mbuf, i), 0, ' '); +#if defined(UNDERNET) + /* deal with invisible passwords */ + else if (MB_TYPE(mbuf, i) & (MODE_APASS | MODE_UPASS)) + build_string(strptr, strptr_i, "*", 0, ' '); +#endif + /* * deal with limit; note we cannot include the limit parameter if we're * removing it @@ -1575,7 +1843,11 @@ build_string(strptr, strptr_i, NumNick(MB_CLIENT(mbuf, i)), ' '); /* deal with modes that take strings */ +#if defined(UNDERNET) + else if (MB_TYPE(mbuf, i) & (MODE_KEY | MODE_BAN | MODE_APASS | MODE_UPASS)) +#else else if (MB_TYPE(mbuf, i) & (MODE_KEY | MODE_BAN)) +#endif build_string(strptr, strptr_i, MB_STRING(mbuf, i), 0, ' '); /* @@ -1676,6 +1948,9 @@ assert(0 != chan); assert(0 != dest); + if (IsLocalChannel(chan->chname)) + dest &= ~MODEBUF_DEST_SERVER; + mbuf->mb_add = 0; mbuf->mb_rem = 0; mbuf->mb_source = source; @@ -1803,6 +2078,10 @@ MODE_INVITEONLY, 'i', MODE_NOPRIVMSGS, 'n', MODE_KEY, 'k', +#if defined(UNDERNET) + MODE_APASS, 'A', + MODE_UPASS, 'u', +#endif /* MODE_BAN, 'b', */ MODE_LIMIT, 'l', MODE_REGONLY, 'r', @@ -1812,6 +2091,9 @@ int i, bufpos = 0, len; int *flag_p; char *key = 0, limitbuf[20]; +#if defined(UNDERNET) + char *apass = 0, *upass = 0; +#endif assert(0 != mbuf); assert(0 != buf); @@ -1822,12 +2104,22 @@ for (i = 0; i < mbuf->mb_count; i++) { /* find keys and limits */ if (MB_TYPE(mbuf, i) & MODE_ADD) { +#if defined(UNDERNET) + add |= MB_TYPE(mbuf, i) & (MODE_KEY | MODE_LIMIT | MODE_APASS | MODE_UPASS); +#else add |= MB_TYPE(mbuf, i) & (MODE_KEY | MODE_LIMIT); +#endif if (MB_TYPE(mbuf, i) & MODE_KEY) /* keep strings */ key = MB_STRING(mbuf, i); else if (MB_TYPE(mbuf, i) & MODE_LIMIT) ircd_snprintf(0, limitbuf, sizeof(limitbuf), "%u", MB_UINT(mbuf, i)); +#if defined(UNDERNET) + else if (MB_TYPE(mbuf, i) & MODE_UPASS) + upass = MB_STRING(mbuf, i); + else if (MB_TYPE(mbuf, i) & MODE_APASS) + apass = MB_STRING(mbuf, i); +#endif } } @@ -1845,6 +2137,12 @@ build_string(buf, &bufpos, key, 0, ' '); else if (buf[i] == 'l') build_string(buf, &bufpos, limitbuf, 0, ' '); +#if defined(UNDERNET) + else if (buf[i] == 'u') + build_string(buf, &bufpos, upass, 0, ' '); + else if (buf[i] == 'A') + build_string(buf, &bufpos, apass, 0, ' '); +#endif } buf[bufpos] = '\0'; @@ -1880,12 +2178,17 @@ #define DONE_BANLIST 0x04 /* We've sent the ban list */ #define DONE_NOTOPER 0x08 /* We've sent a "Not oper" error */ #define DONE_BANCLEAN 0x10 /* We've cleaned bans... */ +#if defined(UNDERNET) +#define DONE_UPASS 0x20 /* We've set user pass */ +#define DONE_APASS 0x40 /* We've set admin pass */ +#endif struct ParseState { struct ModeBuf *mbuf; struct Client *cptr; struct Client *sptr; struct Channel *chptr; + struct Membership *member; int parc; char **parv; unsigned int flags; @@ -2023,7 +2326,7 @@ /* clean up the key string */ s = t_str; - while (*++s > ' ' && *s != ':' && --t_len) + while (*s > ' ' && *s != ':' && --t_len) s++; *s = '\0'; @@ -2074,6 +2377,233 @@ } } +#if defined(UNDERNET) +/* + * Helper function to convert user passes + */ +static void +mode_parse_upass(struct ParseState *state, int *flag_p) +{ + char *t_str, *s; + int t_len; + + if (MyUser(state->sptr) && state->max_args <= 0) /* drop if too many args */ + return; + + if (state->parc <= 0) { /* warn if not enough args */ + if (MyUser(state->sptr)) + need_more_params(state->sptr, state->dir == MODE_ADD ? "MODE +u" : + "MODE -u"); + return; + } + + t_str = state->parv[state->args_used++]; /* grab arg */ + state->parc--; + state->max_args--; + + /* If they're not an oper, they can't change modes */ + if (state->flags & (MODE_PARSE_NOTOPER | MODE_PARSE_NOTMEMBER)) { + send_notoper(state); + return; + } + + /* If they are not the channel manager, they are not allowed to change it */ + if (MyUser(state->sptr) && !IsChannelManager(state->member)) { + if (*state->chptr->mode.apass) { + send_reply(state->sptr, ERR_NOTMANAGER, state->chptr->chname, + "Use /JOIN", state->chptr->chname, "<AdminPass>."); + } else { + send_reply(state->sptr, ERR_NOTMANAGER, state->chptr->chname, + "Re-create the channel. The channel must be *empty* for", + TStime() - state->chptr->creationtime >= 171000 ? "48 contiguous hours" : "a minute or two", + "before it can be recreated."); + } + return; + } + + if (state->done & DONE_UPASS) /* allow upass to be set only once */ + return; + state->done |= DONE_UPASS; + + t_len = PASSLEN + 1; + + /* clean up the upass string */ + s = t_str; + while (*s > ' ' && *s != ':' && --t_len) + s++; + *s = '\0'; + + if (!*t_str) { /* warn if empty */ + if (MyUser(state->sptr)) + need_more_params(state->sptr, state->dir == MODE_ADD ? "MODE +u" : + "MODE -u"); + return; + } + + if (!state->mbuf) + return; + + if (!(state->flags & MODE_PARSE_FORCE)) + /* can't add the upass while apass is not set */ + if (state->dir == MODE_ADD && !*state->chptr->mode.apass) { + send_reply(state->sptr, ERR_UPASSNOTSET, state->chptr->chname, state->chptr->chname); + return; + } + /* can't add a upass if one is set, nor can one remove the wrong upass */ + if ((state->dir == MODE_ADD && *state->chptr->mode.upass) || + (state->dir == MODE_DEL && + ircd_strcmp(state->chptr->mode.upass, t_str))) { + send_reply(state->sptr, ERR_KEYSET, state->chptr->chname); + return; + } + + if (!(state->flags & MODE_PARSE_WIPEOUT) && state->dir == MODE_ADD && + !ircd_strcmp(state->chptr->mode.upass, t_str)) + return; /* no upass change */ + + if (state->flags & MODE_PARSE_BOUNCE) { + if (*state->chptr->mode.upass) /* reset old upass */ + modebuf_mode_string(state->mbuf, MODE_DEL | flag_p[0], + state->chptr->mode.upass, 0); + else /* remove new bogus upass */ + modebuf_mode_string(state->mbuf, MODE_ADD | flag_p[0], t_str, 0); + } else /* send new upass */ + modebuf_mode_string(state->mbuf, state->dir | flag_p[0], t_str, 0); + + if (state->flags & MODE_PARSE_SET) { + if (state->dir == MODE_ADD) /* set the new upass */ + ircd_strncpy(state->chptr->mode.upass, t_str, PASSLEN); + else /* remove the old upass */ + *state->chptr->mode.upass = '\0'; + } +} + +/* + * Helper function to convert admin passes + */ +static void +mode_parse_apass(struct ParseState *state, int *flag_p) +{ + char *t_str, *s; + int t_len; + + if (MyUser(state->sptr) && state->max_args <= 0) /* drop if too many args */ + return; + + if (state->parc <= 0) { /* warn if not enough args */ + if (MyUser(state->sptr)) + need_more_params(state->sptr, state->dir == MODE_ADD ? "MODE +A" : + "MODE -A"); + return; + } + + t_str = state->parv[state->args_used++]; /* grab arg */ + state->parc--; + state->max_args--; + + /* If they're not an oper, they can't change modes */ + if (state->flags & (MODE_PARSE_NOTOPER | MODE_PARSE_NOTMEMBER)) { + send_notoper(state); + return; + } + + /* Don't allow to change the Apass if the channel is older than 48 hours. */ + if (TStime() - state->chptr->creationtime >= 172800 && !IsAnOper(state->sptr)) { + send_reply(state->sptr, ERR_CHANSECURED, state->chptr->chname); + return; + } + + /* If they are not the channel manager, they are not allowed to change it */ + if (MyUser(state->sptr) && !IsChannelManager(state->member)) { + if (*state->chptr->mode.apass) { + send_reply(state->sptr, ERR_NOTMANAGER, state->chptr->chname, + "Use /JOIN", state->chptr->chname, "<AdminPass>."); + } else { + send_reply(state->sptr, ERR_NOTMANAGER, state->chptr->chname, + "Re-create the channel. The channel must be *empty* for", + "at least a whole minute", "before it can be recreated."); + } + return; + } + + if (state->done & DONE_APASS) /* allow apass to be set only once */ + return; + state->done |= DONE_APASS; + + t_len = PASSLEN + 1; + + /* clean up the apass string */ + s = t_str; + while (*s > ' ' && *s != ':' && --t_len) + s++; + *s = '\0'; + + if (!*t_str) { /* warn if empty */ + if (MyUser(state->sptr)) + need_more_params(state->sptr, state->dir == MODE_ADD ? "MODE +A" : + "MODE -A"); + return; + } + + if (!state->mbuf) + return; + + if (!(state->flags & MODE_PARSE_FORCE)) { + ... [truncated message content] |
From: Toni G. <zo...@us...> - 2003-11-12 05:07:25
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-11 21:37:18 UTC Modified files: TODO.es Log message: menos todo ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.3 ircd-ircdev/TODO.es:1.4 --- ircd-ircdev/TODO.es:1.3 Sat Nov 8 16:54:29 2003 +++ ircd-ircdev/TODO.es Tue Nov 11 13:37:08 2003 @@ -1,7 +1,7 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.3 2003/11/09 00:54:29 zolty Exp $ +# $Id: TODO.es,v 1.4 2003/11/11 21:37:08 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # @@ -11,8 +11,6 @@ 1/Nov/2003 - Bug al conectar sale umode -Oo. - Enlazar la libreria de adns al ircd. -- Bug en el configure al elegir entre poll() y epoll() en linux que tienen fuentes pero - no estan activados. - Bug en las U-lines (uworld y jupes). ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2003-11-09 01:43:25
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-09 00:54:39 UTC Modified files: TODO.es Log message: Mas todo ---------------------- diff included ---------------------- Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.2 ircd-ircdev/TODO.es:1.3 --- ircd-ircdev/TODO.es:1.2 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/TODO.es Sat Nov 8 16:54:29 2003 @@ -1,13 +1,73 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.2 2003/11/02 00:47:33 zolty Exp $ +# $Id: TODO.es,v 1.3 2003/11/09 00:54:29 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # +Bugs Conocidos: +-------------------------------------------------------------------------------------- 1/Nov/2003 -Bug al conectar sale umode -Oo. -Enlazar la libreria de adns al ircd. -Bug en el configure al elegir entre poll() y epoll() en linux que tienen fuentes pero no estan activados. -Bug en las U-lines (uworld y jupes). +- Bug al conectar sale umode -Oo. +- Enlazar la libreria de adns al ircd. +- Bug en el configure al elegir entre poll() y epoll() en linux que tienen fuentes pero + no estan activados. +- Bug en las U-lines (uworld y jupes). + + + +Features para General: +-------------------------------------------------------------------------------------- +- Caracter '~' en los nicks. +- Mostrar @+#canal en NAMES, WHOIS y WHO. +- Los clientes con +k han de poder "hablar" en canales. +- Mostrar tiempo en formato humano en las G-lines. +- Soporte de E-lines (excepciones a K-lines). +- Modo +X de ver ips. +- Modo +R de usuarios. +- ¿Modo +M de canales?. +- Enviar un Closing Link en los QUIT. +- ¿Ampliacion comando OPER para elegir clase? +- Comando USERS. +- No permitir invitar a canales desde fuera. +- Poner uuna Feature para elegir entre salir o no el nombre del servidor en los notices + de auth y dnslookup al conectar. +- Cuando nos silencian, que salga un numerico. +- Completar el MAP, salir numeric, nº de usuarios, porcentajes. +- Estudiar sobre la conveniencia de mandar privmsg globales al nick en vez de a la mascara. +- Si un global lo manda un ircop, que salga el prefijo de Mensaje global con la mascara o + avisar mediante wallops global. +- Estudiar sobre la conveniencia de mezclar numericos (3 y 5). Puede romper la estandarizacion + del protocolo P10. +- Posibilidad de BURST de topics. +- Modo de canal +D para conferencias. Mirar Asuka o Universal ircu de Run. +- Implementar la libreria libevent cuando este terminado (Da soporte IPv6). + + +Features para Undernet: +-------------------------------------------------------------------------------------- +- Soporte de modos de canal +A y +u y todo lo relacionado con el. +- S-lines (Spoof Lines). + + + + +Features Services (ex Terraircu): +-------------------------------------------------------------------------------------- +- Buscar una forma para cifrar IPs con un cambio de clave de cifrado incluido. +- Comando SVSNICK. +- Comando SVSMODE. +- Comando SVSVHOST para cambiar la virtualhost. Estudiar alguna forma de propagarse en + el burst. +- Comando /IDENTIFY y autentificacion NICK nick clave. +- Comprobar el comando OPMODE haga lo que hacia el SAMODE. + + + +Features Distributed DataBase (Similar a BDD): +-------------------------------------------------------------------------------------- +- Estudiar un protocolo para DDB. +- Comando de consulta de DDB. +- Nicks registrados y protegidos. +- Comando GHOST ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2003-11-02 18:34:58
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-02 18:34:57 UTC Modified files: ChangeLog ChangeLog.es config.h.in configure configure.in include/patchlevel.h ircd/Makefile.in ircd/ircd_parser.y Log message: Author: Log message: ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.5 ircd-ircdev/ChangeLog:1.6 --- ircd-ircdev/ChangeLog:1.5 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/ChangeLog Sun Nov 2 10:34:46 2003 @@ -1,10 +1,14 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.5 2003/11/02 00:47:33 zolty Exp $ +# $Id: ChangeLog,v 1.6 2003/11/02 18:34:46 zolty Exp $ # # Insert new changes at beginning of the change list. # +2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha5 + * Check lex and yacc (configure.in). + * Fix bison bug (ircd_parser.y). + 2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha4 * Privilegies user feature. * Changed DNS resolution. Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.5 ircd-ircdev/ChangeLog.es:1.6 --- ircd-ircdev/ChangeLog.es:1.5 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/ChangeLog.es Sun Nov 2 10:34:46 2003 @@ -1,10 +1,14 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.5 2003/11/02 00:47:33 zolty Exp $ +# $Id: ChangeLog.es,v 1.6 2003/11/02 18:34:46 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha5 + * Chequeo de lex y yacc en el configure.in. + * Fix de un bug de bison (ircd_parser.y). + 2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha4 * Implementacion de Privilegios. * Cambios en la resolucion DNS. Index: ircd-ircdev/config.h.in diff -u ircd-ircdev/config.h.in:1.2 ircd-ircdev/config.h.in:1.3 --- ircd-ircdev/config.h.in:1.2 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/config.h.in Sun Nov 2 10:34:46 2003 @@ -19,7 +19,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: config.h.in,v 1.2 2003/11/01 17:19:35 zolty Exp $ + * $Id: config.h.in,v 1.3 2003/11/02 18:34:46 zolty Exp $ */ /* Define if you have the setrlimit function */ @@ -228,6 +228,10 @@ /* Define to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel and VAX). */ #undef WORDS_BIGENDIAN + +/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a + `char[]'. */ +#undef YYTEXT_POINTER /* Define to `int' if <sys/types.h> doesn't define. */ #undef gid_t Index: ircd-ircdev/configure diff -u ircd-ircdev/configure:1.4 ircd-ircdev/configure:1.5 --- ircd-ircdev/configure:1.4 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/configure Sun Nov 2 10:34:47 2003 @@ -309,7 +309,7 @@ # include <unistd.h> #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP AWK SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S RMPROG SHPROG OSDEP_C ENGINE_C RES_C ADNS_SUBDIR INSTALL_RULE SYMLINK IRCDMODE IRCDOWN IRCDGRP DPATH LIBOBJS LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP AWK SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S LEX LEXLIB LEX_OUTPUT_ROOT YACC RMPROG SHPROG OSDEP_C ENGINE_C RES_C ADNS_SUBDIR INSTALL_RULE SYMLINK IRCDMODE IRCDOWN IRCDGRP DPATH LIBOBJS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -6775,6 +6775,290 @@ echo "${ECHO_T}no, using $LN_S" >&6 fi +for ac_prog in flex lex +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_LEX+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$LEX"; then + ac_cv_prog_LEX="$LEX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LEX="$ac_prog" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +LEX=$ac_cv_prog_LEX +if test -n "$LEX"; then + echo "$as_me:$LINENO: result: $LEX" >&5 +echo "${ECHO_T}$LEX" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + test -n "$LEX" && break +done +test -n "$LEX" || LEX=":" + +if test -z "$LEXLIB" +then + echo "$as_me:$LINENO: checking for yywrap in -lfl" >&5 +echo $ECHO_N "checking for yywrap in -lfl... $ECHO_C" >&6 +if test "${ac_cv_lib_fl_yywrap+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lfl $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char yywrap (); +int +main () +{ +yywrap (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_fl_yywrap=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_lib_fl_yywrap=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_fl_yywrap" >&5 +echo "${ECHO_T}$ac_cv_lib_fl_yywrap" >&6 +if test $ac_cv_lib_fl_yywrap = yes; then + LEXLIB="-lfl" +else + echo "$as_me:$LINENO: checking for yywrap in -ll" >&5 +echo $ECHO_N "checking for yywrap in -ll... $ECHO_C" >&6 +if test "${ac_cv_lib_l_yywrap+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ll $LIBS" +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char yywrap (); +int +main () +{ +yywrap (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_l_yywrap=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_lib_l_yywrap=no +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_l_yywrap" >&5 +echo "${ECHO_T}$ac_cv_lib_l_yywrap" >&6 +if test $ac_cv_lib_l_yywrap = yes; then + LEXLIB="-ll" +fi + +fi + +fi + +if test "x$LEX" != "x:"; then + echo "$as_me:$LINENO: checking lex output file root" >&5 +echo $ECHO_N "checking lex output file root... $ECHO_C" >&6 +if test "${ac_cv_prog_lex_root+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + # The minimal lex program is just a single line: %%. But some broken lexes +# (Solaris, I think it was) want two %% lines, so accommodate them. +cat >conftest.l <<_ACEOF +%% +%% +_ACEOF +{ (eval echo "$as_me:$LINENO: \"$LEX conftest.l\"") >&5 + (eval $LEX conftest.l) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +if test -f lex.yy.c; then + ac_cv_prog_lex_root=lex.yy +elif test -f lexyy.c; then + ac_cv_prog_lex_root=lexyy +else + { { echo "$as_me:$LINENO: error: cannot find output from $LEX; giving up" >&5 +echo "$as_me: error: cannot find output from $LEX; giving up" >&2;} + { (exit 1); exit 1; }; } +fi +fi +echo "$as_me:$LINENO: result: $ac_cv_prog_lex_root" >&5 +echo "${ECHO_T}$ac_cv_prog_lex_root" >&6 +rm -f conftest.l +LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root + +echo "$as_me:$LINENO: checking whether yytext is a pointer" >&5 +echo $ECHO_N "checking whether yytext is a pointer... $ECHO_C" >&6 +if test "${ac_cv_prog_lex_yytext_pointer+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + # POSIX says lex can declare yytext either as a pointer or an array; the +# default is implementation-dependent. Figure out which it is, since +# not all implementations provide the %pointer and %array declarations. +ac_cv_prog_lex_yytext_pointer=no +echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c +ac_save_LIBS=$LIBS +LIBS="$LIBS $LEXLIB" +cat >conftest.$ac_ext <<_ACEOF +`cat $LEX_OUTPUT_ROOT.c` +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_prog_lex_yytext_pointer=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_save_LIBS +rm -f "${LEX_OUTPUT_ROOT}.c" + +fi +echo "$as_me:$LINENO: result: $ac_cv_prog_lex_yytext_pointer" >&5 +echo "${ECHO_T}$ac_cv_prog_lex_yytext_pointer" >&6 +if test $ac_cv_prog_lex_yytext_pointer = yes; then + +cat >>confdefs.h <<\_ACEOF +#define YYTEXT_POINTER 1 +_ACEOF + +fi + +fi +for ac_prog in 'bison -y' byacc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_YACC+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_YACC="$ac_prog" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + +fi +fi +YACC=$ac_cv_prog_YACC +if test -n "$YACC"; then + echo "$as_me:$LINENO: result: $YACC" >&5 +echo "${ECHO_T}$YACC" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + + test -n "$YACC" && break +done +test -n "$YACC" || YACC="yacc" + for ac_prog in rm do # Extract the first word of "$ac_prog", so it can be a program name with args. @@ -8735,6 +9019,10 @@ s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t s,@INSTALL_DATA@,$INSTALL_DATA,;t t s,@LN_S@,$LN_S,;t t +s,@LEX@,$LEX,;t t +s,@LEXLIB@,$LEXLIB,;t t +s,@LEX_OUTPUT_ROOT@,$LEX_OUTPUT_ROOT,;t t +s,@YACC@,$YACC,;t t s,@RMPROG@,$RMPROG,;t t s,@SHPROG@,$SHPROG,;t t s,@OSDEP_C@,$OSDEP_C,;t t Index: ircd-ircdev/configure.in diff -u ircd-ircdev/configure.in:1.4 ircd-ircdev/configure.in:1.5 --- ircd-ircdev/configure.in:1.4 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/configure.in Sun Nov 2 10:34:47 2003 @@ -19,7 +19,7 @@ dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. dnl -dnl $Id: configure.in,v 1.4 2003/11/02 00:47:33 zolty Exp $ +dnl $Id: configure.in,v 1.5 2003/11/02 18:34:47 zolty Exp $ dnl Make sure we are in the correct directory (someone could have run dnl 'configure' with a wrong '--srcdir'). @@ -139,6 +139,8 @@ AC_PROG_MAKE_SET AC_PROG_INSTALL AC_PROG_LN_S +AC_PROG_LEX +AC_PROG_YACC AC_PATH_PROGS(RMPROG, rm, /bin/rm) AC_PATH_PROGS(SHPROG, sh, /bin/sh) Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.5 ircd-ircdev/include/patchlevel.h:1.6 --- ircd-ircdev/include/patchlevel.h:1.5 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/include/patchlevel.h Sun Nov 2 10:34:47 2003 @@ -15,10 +15,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: patchlevel.h,v 1.5 2003/11/02 00:47:33 zolty Exp $ + * $Id: patchlevel.h,v 1.6 2003/11/02 18:34:47 zolty Exp $ * */ -#define PATCHLEVEL ".alpha4" +#define PATCHLEVEL ".alpha5" #define RELEASE "1.0" Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.5 ircd-ircdev/ircd/Makefile.in:1.6 --- ircd-ircdev/ircd/Makefile.in:1.5 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/ircd/Makefile.in Sun Nov 2 10:34:47 2003 @@ -32,15 +32,14 @@ RM = @RMPROG@ AWK = @AWK@ LN_S = @LN_S@ +LEX = @LEX@ +YACC = @YACC@ MV = mv CHMOD = chmod CHOWN = chown CHGRP = chgrp MKDIR = mkdir TOUCH = touch -LEX = flex -#YACC = bison -y -YACC = bison-1.35 -y GREP = grep OSDEP_C = @OSDEP_C@ ENGINE_C = @ENGINE_C@ Index: ircd-ircdev/ircd/ircd_parser.y diff -u ircd-ircdev/ircd/ircd_parser.y:1.2 ircd-ircdev/ircd/ircd_parser.y:1.3 --- ircd-ircdev/ircd/ircd_parser.y:1.2 Sat Nov 1 16:47:33 2003 +++ ircd-ircdev/ircd/ircd_parser.y Sun Nov 2 10:34:47 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, * USA. - * $Id: ircd_parser.y,v 1.2 2003/11/02 00:47:33 zolty Exp $ + * $Id: ircd_parser.y,v 1.3 2003/11/02 18:34:47 zolty Exp $ */ %{ @@ -141,17 +141,42 @@ %token FEATURES %token QUARANTINE /* and now a lot of priviledges... */ -%token TPRIV_CHAN_LIMIT, TPRIV_MODE_LCHAN, TPRIV_DEOP_LCHAN, TPRIV_WALK_LCHAN -%token TPRIV_KILL, TPRIV_LOCAL_KILL, TPRIV_REHASH, TPRIV_RESTART, TPRIV_DIE -%token TPRIV_GLINE, TPRIV_LOCAL_GLINE, TPRIV_JUPE, TPRIV_LOCAL_JUPE -%token TPRIV_LOCAL_OPMODE, TPRIV_OPMODE, TPRIV_SET, TPRIV_WHOX, TPRIV_BADCHAN +%token TPRIV_CHAN_LIMIT +%token TPRIV_MODE_LCHAN +%token TPRIV_DEOP_LCHAN +%token TPRIV_WALK_LCHAN +%token TPRIV_KILL +%token TPRIV_LOCAL_KILL +%token TPRIV_REHASH +%token TPRIV_RESTART +%token TPRIV_DIE +%token TPRIV_GLINE +%token TPRIV_LOCAL_GLINE +%token TPRIV_JUPE +%token TPRIV_LOCAL_JUPE +%token TPRIV_LOCAL_OPMODE +%token TPRIV_OPMODE +%token TPRIV_SET +%token TPRIV_WHOX +%token TPRIV_BADCHAN %token TPRIV_LOCAL_BADCHAN -%token TPRIV_SEE_CHAN, TPRIV_SHOW_INVIS, TPRIV_SHOW_ALL_INVIS, TPRIV_PROPAGATE -%token TPRIV_UNLIMIT_QUERY, TPRIV_DISPLAY, TPRIV_SEE_OPERS, TPRIV_WIDE_GLINE +%token TPRIV_SEE_CHAN +%token TPRIV_SHOW_INVIS +%token TPRIV_SHOW_ALL_INVIS +%token TPRIV_PROPAGATE +%token TPRIV_UNLIMIT_QUERY +%token TPRIV_DISPLAY +%token TPRIV_SEE_OPERS +%token TPRIV_WIDE_GLINE /* and some types... */ %type <num> sizespec -%type <num> timespec, timefactor, factoredtimes, factoredtime -%type <num> expr, yesorno, privtype +%type <num> timespec +%type <num> timefactor +%type <num> factoredtimes +%type <num> factoredtime +%type <num> expr +%type <num> yesorno +%type <num> privtype %left '+' '-' %left '*' '/' @@ -192,59 +217,59 @@ sizespec: expr - = { + { $$ = $1; } | expr BYTES - = { + { $$ = $1; } | expr KBYTES - = { + { $$ = $1 * 1024; } | expr MBYTES - = { + { $$ = $1 * 1024 * 1024; } | expr GBYTES - = { + { $$ = $1 * 1024 * 1024 * 1024; } | expr TBYTES - = { + { $$ = $1 * 1024 * 1024 * 1024; } ; /* this is an arithmatic expression */ expr: NUMBER - = { + { $$ = $1; } | expr '+' expr - = { + { $$ = $1 + $3; } | expr '-' expr - = { + { $$ = $1 - $3; } | expr '*' expr - = { + { $$ = $1 * $3; } | expr '/' expr - = { + { $$ = $1 / $3; } /* leave this out until we find why it makes BSD yacc dump core -larne | '-' expr %prec NEG - = { + { $$ = -$2; } */ | '(' expr ')' - = { + { $$ = $2; } ; ----------------------- End of diff ----------------------- |
From: Toni G. <zo...@us...> - 2003-11-02 00:47:48
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-02 00:47:44 UTC Modified files: ChangeLog ChangeLog.es Makefile.in TODO.es configure configure.in include/client.h include/patchlevel.h include/res.h include/s_bsd.h include/s_conf.h ircd/.cvsignore ircd/Makefile.in ircd/client.c ircd/ircd.c ircd/ircd_lexer.l ircd/ircd_parser.y ircd/list.c ircd/m_connect.c ircd/m_oper.c ircd/s_auth.c ircd/s_bsd.c ircd/s_conf.c ircd/s_user.c libs/adns/README Added files: ircd/res_adns.c ircd/res_libresolv.c Removed files: ircd/res.c Log message: Author: zoltan <zo...@ir...> Log message: 2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha4 * Implementacion de Privilegios. * Cambios en la resolucion DNS. * Se incluye el source de la libreria adns. ---------------------- diff included ---------------------- Index: ircd-ircdev/ChangeLog diff -u ircd-ircdev/ChangeLog:1.4 ircd-ircdev/ChangeLog:1.5 --- ircd-ircdev/ChangeLog:1.4 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/ChangeLog Sat Nov 1 16:47:33 2003 @@ -1,10 +1,15 @@ # # ChangeLog for ircd-ircdev # -# $Id: ChangeLog,v 1.4 2003/11/01 17:19:35 zolty Exp $ +# $Id: ChangeLog,v 1.5 2003/11/02 00:47:33 zolty Exp $ # # Insert new changes at beginning of the change list. # +2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha4 + * Privilegies user feature. + * Changed DNS resolution. + * Incluyed adns library source. + 2003-11-01 Toni Garcia <zo...@ir...> 1.0.alpha3 * Implementation epoll() engine. * Upgrade to Undernet u2.10.11.05. Index: ircd-ircdev/ChangeLog.es diff -u ircd-ircdev/ChangeLog.es:1.4 ircd-ircdev/ChangeLog.es:1.5 --- ircd-ircdev/ChangeLog.es:1.4 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/ChangeLog.es Sat Nov 1 16:47:33 2003 @@ -1,10 +1,15 @@ # # Log de Cambios para ircd-ircdev # -# $Id: ChangeLog.es,v 1.4 2003/11/01 17:19:35 zolty Exp $ +# $Id: ChangeLog.es,v 1.5 2003/11/02 00:47:33 zolty Exp $ # # Insertar los nuevos cambios al principio de esta lista de cambios. # +2003-11-02 Toni Garcia <zo...@ir...> 1.0.alpha4 + * Implementacion de Privilegios. + * Cambios en la resolucion DNS. + * Se incluye el source de la libreria adns. + 2003-11-01 Toni Garcia <zo...@ir...> 1.0.alpha3 * Implementacion del engine de epoll(). * Actualizacion al u2.10.11.05 de Undernet. Index: ircd-ircdev/Makefile.in diff -u ircd-ircdev/Makefile.in:1.1.1.1 ircd-ircdev/Makefile.in:1.2 --- ircd-ircdev/Makefile.in:1.1.1.1 Mon Sep 8 03:34:25 2003 +++ ircd-ircdev/Makefile.in Sat Nov 1 16:47:33 2003 @@ -26,11 +26,12 @@ SHELL = @SHPROG@ RM = @RMPROG@ AWK = @AWK@ +adns_subdir = @ADNS_SUBDIR@ @SET_MAKE@ #### End of system configuration section. #### -SUBDIRS = doc ircd -IRCD_MAKEFILES = Makefile doc/Makefile ircd/Makefile +SUBDIRS = doc ${adns_subdir} ircd +IRCD_MAKEFILES = Makefile doc/Makefile libs/adns/Makefile ircd/Makefile all: build Index: ircd-ircdev/TODO.es diff -u ircd-ircdev/TODO.es:1.1 ircd-ircdev/TODO.es:1.2 --- ircd-ircdev/TODO.es:1.1 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/TODO.es Sat Nov 1 16:47:33 2003 @@ -1,12 +1,13 @@ # # TODO para ircd-ircdev # -# $Id: TODO.es,v 1.1 2003/11/01 17:19:35 zolty Exp $ +# $Id: TODO.es,v 1.2 2003/11/02 00:47:33 zolty Exp $ # # Insertar las nuevas entradas al principio de la lista TODO. # 1/Nov/2003 +Bug al conectar sale umode -Oo. +Enlazar la libreria de adns al ircd. Bug en el configure al elegir entre poll() y epoll() en linux que tienen fuentes pero no estan activados. - -Bug en las U-lines (uworld y jupes) +Bug en las U-lines (uworld y jupes). Index: ircd-ircdev/configure diff -u ircd-ircdev/configure:1.3 ircd-ircdev/configure:1.4 --- ircd-ircdev/configure:1.3 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/configure Sat Nov 1 16:47:33 2003 @@ -309,7 +309,7 @@ # include <unistd.h> #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP AWK SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S RMPROG SHPROG OSDEP_C ENGINE_C INSTALL_RULE SYMLINK IRCDMODE IRCDOWN IRCDGRP DPATH LIBOBJS LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP AWK SET_MAKE INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S RMPROG SHPROG OSDEP_C ENGINE_C RES_C ADNS_SUBDIR INSTALL_RULE SYMLINK IRCDMODE IRCDOWN IRCDGRP DPATH LIBOBJS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -7556,6 +7556,139 @@ ENGINE_C="engine_epoll.c $ENGINE_C" fi +#AC_MSG_CHECKING([whether to enable the adns resolver engine]) +#AC_ARG_ENABLE([adns], +#[ --disable-adns Disable adns resolver], +#[unet_cv_enable_adns=$enable_adns], +#[AC_CACHE_VAL(unet_cv_enable_adns, +#[unet_cv_enable_adns=yes])]) + +#AC_MSG_RESULT([$unet_cv_enable_adns]) + +#if test x"$unet_cv_enable_adns" != xno; then +# AC_DEFINE([USE_ADNS], , [Define to enable the adns resolver]) +# AC_CONFIG_SUBDIRS([libs/adns]) +# RES_C="res_adns.c" +# LIBS="../libs/adns/src/libadns.a $LIBS" +# ADNS_SUBDIR="libs/adns" +#else + RES_C="res_libresolv.c" + ADNS_SUBDIR="" + + echo "$as_me:$LINENO: checking for library containing res_mkquery" >&5 +echo $ECHO_N "checking for library containing res_mkquery... $ECHO_C" >&6 +if test "${ac_cv_search_res_mkquery+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_func_search_save_LIBS=$LIBS +ac_cv_search_res_mkquery=no +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char res_mkquery (); +int +main () +{ +res_mkquery (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_search_res_mkquery="none required" +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext +if test "$ac_cv_search_res_mkquery" = no; then + for ac_lib in resolv; do + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char res_mkquery (); +int +main () +{ +res_mkquery (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_search_res_mkquery="-l$ac_lib" +break +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +fi +rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext + done +fi +LIBS=$ac_func_search_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_search_res_mkquery" >&5 +echo "${ECHO_T}$ac_cv_search_res_mkquery" >&6 +if test "$ac_cv_search_res_mkquery" != no; then + test "$ac_cv_search_res_mkquery" = "none required" || LIBS="$ac_cv_search_res_mkquery $LIBS" + +else + { { echo "$as_me:$LINENO: error: Unable to find library containing res_mkquery()" >&5 +echo "$as_me: error: Unable to find library containing res_mkquery()" >&2;} + { (exit 1); exit 1; }; } +fi + +#fi + + + echo "$as_me:$LINENO: checking what name to give the symlink" >&5 echo $ECHO_N "checking what name to give the symlink... $ECHO_C" >&6 @@ -8606,6 +8739,8 @@ s,@SHPROG@,$SHPROG,;t t s,@OSDEP_C@,$OSDEP_C,;t t s,@ENGINE_C@,$ENGINE_C,;t t +s,@RES_C@,$RES_C,;t t +s,@ADNS_SUBDIR@,$ADNS_SUBDIR,;t t s,@INSTALL_RULE@,$INSTALL_RULE,;t t s,@SYMLINK@,$SYMLINK,;t t s,@IRCDMODE@,$IRCDMODE,;t t @@ -9141,6 +9276,7 @@ echo " Debug: $unet_cv_enable_debug" echo " Profile: $unet_cv_enable_profile" echo " Pedantic: $unet_cv_enable_pedantic" +echo " ADNS: $unet_cv_enable_adns" echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" echo " Chroot: $unet_cv_with_chroot" echo "" Index: ircd-ircdev/configure.in diff -u ircd-ircdev/configure.in:1.3 ircd-ircdev/configure.in:1.4 --- ircd-ircdev/configure.in:1.3 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/configure.in Sat Nov 1 16:47:33 2003 @@ -19,7 +19,7 @@ dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. dnl -dnl $Id: configure.in,v 1.3 2003/11/01 17:19:35 zolty Exp $ +dnl $Id: configure.in,v 1.4 2003/11/02 00:47:33 zolty Exp $ dnl Make sure we are in the correct directory (someone could have run dnl 'configure' with a wrong '--srcdir'). @@ -386,6 +386,34 @@ ENGINE_C="engine_epoll.c $ENGINE_C" fi +dnl --disable-adns check... +#AC_MSG_CHECKING([whether to enable the adns resolver engine]) +#AC_ARG_ENABLE([adns], +#[ --disable-adns Disable adns resolver], +#[unet_cv_enable_adns=$enable_adns], +#[AC_CACHE_VAL(unet_cv_enable_adns, +#[unet_cv_enable_adns=yes])]) + +#AC_MSG_RESULT([$unet_cv_enable_adns]) + +#if test x"$unet_cv_enable_adns" != xno; then +# AC_DEFINE([USE_ADNS], , [Define to enable the adns resolver]) +# AC_CONFIG_SUBDIRS([libs/adns]) +# RES_C="res_adns.c" +# LIBS="../libs/adns/src/libadns.a $LIBS" +# ADNS_SUBDIR="libs/adns" +#else + RES_C="res_libresolv.c" + ADNS_SUBDIR="" + + dnl Look for res_mkquery. Done after AC_LIBRARY_NET in case res_mkquery + dnl is in one of those libraries somewhere. + AC_SEARCH_LIBS(res_mkquery, resolv, , + [AC_MSG_ERROR([Unable to find library containing res_mkquery()])]) +#fi +AC_SUBST(RES_C) +AC_SUBST(ADNS_SUBDIR) + dnl --with-symlink lets us set the name of the symlink; defaults to "ircd" AC_MSG_CHECKING([what name to give the symlink]) AC_ARG_WITH([symlink], @@ -695,6 +723,7 @@ echo " Debug: $unet_cv_enable_debug" echo " Profile: $unet_cv_enable_profile" echo " Pedantic: $unet_cv_enable_pedantic" +echo " ADNS: $unet_cv_enable_adns" echo " Owner/mode: $unet_cv_with_owner.$unet_cv_with_group ($unet_cv_with_mode)" echo " Chroot: $unet_cv_with_chroot" echo "" Index: ircd-ircdev/include/client.h diff -u ircd-ircdev/include/client.h:1.1.1.1 ircd-ircdev/include/client.h:1.2 --- ircd-ircdev/include/client.h:1.1.1.1 Mon Sep 8 03:34:27 2003 +++ ircd-ircdev/include/client.h Sat Nov 1 16:47:33 2003 @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: client.h,v 1.1.1.1 2003/09/08 10:34:27 zolty Exp $ + * $Id: client.h,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ #ifndef INCLUDED_client_h #define INCLUDED_client_h @@ -53,7 +53,6 @@ struct Server; struct User; struct Whowas; -struct DNSReply; struct hostent; struct Privs; struct AuthRequest; @@ -66,6 +65,22 @@ * source file, or in the source file itself (when only used in that file). */ +typedef unsigned long flagpage_t; + +#define FLAGSET_NBITS (8 * sizeof(flagpage_t)) +#define FLAGSET_INDEX(flag) (flag / FLAGSET_NBITS) +#define FLAGSET_MASK(flag) (1<<(flag % FLAGSET_NBITS)) + +#define DECLARE_FLAGSET(name,max) \ + struct name \ + { \ + unsigned long bits[((max + FLAGSET_NBITS - 1) / FLAGSET_NBITS)]; \ + }; + +#define FLAGSET_ISSET(set,flag) ((set).bits[FLAGSET_INDEX(flag)] & FLAGSET_MASK(flag)) +#define FLAGSET_SET(set, flag) (set).bits[FLAGSET_INDEX(flag)] |= FLAGSET_MASK(flag) +#define FLAGSET_CLEAR(set, flag) (set).bits[FLAGSET_INDEX(flag)] &= ~FLAGSET_MASK(flag) + enum Priv { PRIV_CHAN_LIMIT, /* no channel limit on oper */ PRIV_MODE_LCHAN, /* oper can mode local chans */ @@ -91,28 +106,15 @@ PRIV_BADCHAN, /* oper can BADCHAN */ PRIV_LOCAL_BADCHAN, /* oper can local BADCHAN */ PRIV_SEE_CHAN, /* oper can see in secret chans */ - PRIV_PROPAGATE, /* propagate oper status */ PRIV_DISPLAY, /* "Is an oper" displayed */ PRIV_SEE_OPERS, /* display hidden opers */ - PRIV_WIDE_GLINE, /* oper can set wider G-lines */ - PRIV_FORCE_OPMODE, /* oper can override a Q-line */ PRIV_FORCE_LOCAL_OPMODE,/* oper can override a local channel Q-line */ - PRIV_LAST_PRIV /* must be the same as the last priv */ }; -#define _PRIV_NBITS (8 * sizeof(unsigned long)) - -#define _PRIV_IDX(priv) ((priv) / _PRIV_NBITS) -#define _PRIV_BIT(priv) (1 << ((priv) % _PRIV_NBITS)) - -struct Privs { - unsigned long priv_mask[(PRIV_LAST_PRIV + _PRIV_NBITS - 1) / _PRIV_NBITS]; -}; - enum Flag { FLAG_PINGSENT, /* Unreplied ping sent */ FLAG_DEADSOCKET, /* Local socket is dead--Exiting soon */ @@ -136,6 +138,7 @@ FLAG_LOCOP, /* Local operator -- SRB */ FLAG_SERVNOTICE, /* server notices such as kill */ + FLAG_OPER, /* Operator */ FLAG_INVISIBLE, /* makes user invisible */ FLAG_WALLOP, /* send wallops to them */ @@ -145,15 +148,13 @@ FLAG_DEBUG, /* send global debug/anti-hack info */ FLAG_ACCOUNT, /* account name has been set */ FLAG_HIDDENHOST, /* user's host is hidden */ - - _FLAG_COUNT, + FLAG_LAST_FLAG, FLAG_LOCAL_UMODES = FLAG_LOCOP, /* First local mode flag */ FLAG_GLOBAL_UMODES = FLAG_OPER /* First global mode flag */ }; -struct Flags { - unsigned long flag_bits[((_FLAG_COUNT + _PRIV_NBITS - 1) / _PRIV_NBITS)]; -}; +DECLARE_FLAGSET(Privs, PRIV_LAST_PRIV); +DECLARE_FLAGSET(Flags, FLAG_LAST_FLAG); struct Connection { /* @@ -188,7 +189,7 @@ struct SLink* con_confs; /* Configuration record associated */ HandlerType con_handler; /* message index into command table for parsing */ - struct DNSReply* con_dns_reply; /* DNS reply used during client + struct hostent* con_dns_reply; /* DNS reply used during client registration */ struct ListingArgs* con_listing; unsigned int con_max_sendq; /* cached max send queue for client */ @@ -393,12 +394,9 @@ /* * flags macros. */ -#define FlagSet(fset, flag) ((fset)->flag_bits[_PRIV_IDX(flag)] |= \ - _PRIV_BIT(flag)) -#define FlagClr(fset, flag) ((fset)->flag_bits[_PRIV_IDX(flag)] &= \ - ~(_PRIV_BIT(flag))) -#define FlagHas(fset, flag) ((fset)->flag_bits[_PRIV_IDX(flag)] & \ - _PRIV_BIT(flag)) +#define FlagSet(fset, flag) FLAGSET_SET(*fset, flag) +#define FlagClr(fset, flag) FLAGSET_CLEAR(*fset, flag) +#define FlagHas(fset, flag) FLAGSET_ISSET(*fset, flag) #define SetFlag(cli, flag) FlagSet(&cli_flags(cli), flag) #define ClrFlag(cli, flag) FlagClr(&cli_flags(cli), flag) #define HasFlag(cli, flag) FlagHas(&cli_flags(cli), flag) @@ -428,9 +426,10 @@ #define IsService(x) HasFlag(x, FLAG_SERVICE) #define IsAccount(x) HasFlag(x, FLAG_ACCOUNT) #define IsHiddenHost(x) HasFlag(x, FLAG_HIDDENHOST) -#define HasHiddenHost(x) (IsAccount(x) && IsHiddenHost(x)) +#define IsPingSent(x) HasFlag(x, FLAG_PINGSENT) #define IsPrivileged(x) (IsAnOper(x) || IsServer(x)) +#define HasHiddenHost(x) (IsAccount(x) && IsHiddenHost(x)) #define SetAccess(x) SetFlag(x, FLAG_CHKACCESS) #define SetBurst(x) SetFlag(x, FLAG_BURST) @@ -451,6 +450,7 @@ #define SetService(x) SetFlag(x, FLAG_SERVICE) #define SetAccount(x) SetFlag(x, FLAG_ACCOUNT) #define SetHiddenHost(x) SetFlag(x, FLAG_HIDDENHOST) +#define SetPingSent(x) SetFlag(x, FLAG_PINGSENT) #define ClearAccess(x) ClrFlag(x, FLAG_CHKACCESS) #define ClearBurst(x) ClrFlag(x, FLAG_BURST) @@ -466,6 +466,7 @@ #define ClearWallops(x) ClrFlag(x, FLAG_WALLOP) #define ClearServNotice(x) ClrFlag(x, FLAG_SERVNOTICE) #define ClearHiddenHost(x) ClrFlag(x, FLAG_HIDDENHOST) +#define ClearPingSent(x) ClrFlag(x, FLAG_PINGSENT) /* free flags */ #define FREEFLAG_SOCKET 0x0001 /* socket needs to be freed */ @@ -510,12 +511,9 @@ #define SNO_OPER (SNO_CONNEXIT|SNO_OLDREALOP) #define SNO_NOISY (SNO_SERVKILL|SNO_UNAUTH) -#define PrivSet(pset, priv) ((pset)->priv_mask[_PRIV_IDX(priv)] |= \ - _PRIV_BIT(priv)) -#define PrivClr(pset, priv) ((pset)->priv_mask[_PRIV_IDX(priv)] &= \ - ~(_PRIV_BIT(priv))) -#define PrivHas(pset, priv) ((pset)->priv_mask[_PRIV_IDX(priv)] & \ - _PRIV_BIT(priv)) +#define PrivSet(fset, flag) FLAGSET_SET(*fset, flag) +#define PrivClr(fset, flag) FLAGSET_CLEAR(*fset, flag) +#define PrivHas(fset, flag) FLAGSET_ISSET(*fset, flag) #define GrantPriv(cli, priv) (PrivSet(&(cli_privs(cli)), priv)) #define RevokePriv(cli, priv) (PrivClr(&(cli_privs(cli)), priv)) @@ -532,7 +530,7 @@ extern void client_drop_sendq(struct Connection* con); extern void client_add_sendq(struct Connection* con, struct Connection** con_p); -extern void client_set_privs(struct Client* client); +extern void client_set_privs(struct Client* client, struct ConfItem *oper); extern int client_report_privs(struct Client* to, struct Client* client); #endif /* INCLUDED_client_h */ Index: ircd-ircdev/include/patchlevel.h diff -u ircd-ircdev/include/patchlevel.h:1.4 ircd-ircdev/include/patchlevel.h:1.5 --- ircd-ircdev/include/patchlevel.h:1.4 Sat Nov 1 09:19:35 2003 +++ ircd-ircdev/include/patchlevel.h Sat Nov 1 16:47:33 2003 @@ -15,10 +15,10 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: patchlevel.h,v 1.4 2003/11/01 17:19:35 zolty Exp $ + * $Id: patchlevel.h,v 1.5 2003/11/02 00:47:33 zolty Exp $ * */ -#define PATCHLEVEL ".alpha3" +#define PATCHLEVEL ".alpha4" #define RELEASE "1.0" Index: ircd-ircdev/include/res.h diff -u ircd-ircdev/include/res.h:1.1.1.1 ircd-ircdev/include/res.h:1.2 --- ircd-ircdev/include/res.h:1.1.1.1 Mon Sep 8 03:34:27 2003 +++ ircd-ircdev/include/res.h Sat Nov 1 16:47:33 2003 @@ -1,7 +1,7 @@ /* * irc2.7.2/ircd/res.h (C)opyright 1992 Darren Reed. * - * $Id: res.h,v 1.1.1.1 2003/09/08 10:34:27 zolty Exp $ + * $Id: res.h,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ #ifndef INCLUDED_res_h #define INCLUDED_res_h @@ -14,26 +14,20 @@ struct Client; struct hostent; -struct DNSReply { - struct hostent* hp; /* hostent struct */ - int ref_count; /* reference count */ -}; - struct DNSQuery { void* vptr; /* pointer used by callback to identify request */ - void (*callback)(void* vptr, struct DNSReply* reply); /* callback to call */ + void (*callback)(void* vptr, struct hostent* reply); /* callback to call */ }; extern int ResolverFileDescriptor; /* GLOBAL - file descriptor (s_bsd.c) */ extern void get_res(void); -extern struct DNSReply* gethost_byname(const char* name, - const struct DNSQuery* req); -extern struct DNSReply* gethost_byaddr(const char* name, - const struct DNSQuery* req); +extern void gethost_byname(const char* name, const struct DNSQuery* req); +extern void gethost_byaddr(const char* name, const struct DNSQuery* req); extern int init_resolver(void); extern void restart_resolver(void); extern time_t timeout_resolver(time_t now); + /* * delete_resolver_queries - delete all outstanding queries for the * pointer arg, DO NOT call this from a resolver callback function the Index: ircd-ircdev/include/s_bsd.h diff -u ircd-ircdev/include/s_bsd.h:1.1.1.1 ircd-ircdev/include/s_bsd.h:1.2 --- ircd-ircdev/include/s_bsd.h:1.1.1.1 Mon Sep 8 03:34:27 2003 +++ ircd-ircdev/include/s_bsd.h Sat Nov 1 16:47:33 2003 @@ -1,7 +1,7 @@ /* * s_bsd.h * - * $Id: s_bsd.h,v 1.1.1.1 2003/09/08 10:34:27 zolty Exp $ + * $Id: s_bsd.h,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ #ifndef INCLUDED_s_bsd_h #define INCLUDED_s_bsd_h @@ -17,7 +17,6 @@ struct Client; struct ConfItem; struct Listener; -struct DNSReply; struct MsgQ; /* @@ -79,8 +78,7 @@ * Proto types */ extern unsigned int deliver_it(struct Client *cptr, struct MsgQ *buf); -extern int connect_server(struct ConfItem* aconf, struct Client* by, - struct DNSReply* reply); +extern int connect_server(struct ConfItem* aconf, struct Client* by); extern void release_dns_reply(struct Client* cptr); extern int net_close_unregistered_connections(struct Client* source); extern void close_connection(struct Client *cptr); Index: ircd-ircdev/include/s_conf.h diff -u ircd-ircdev/include/s_conf.h:1.2 ircd-ircdev/include/s_conf.h:1.3 --- ircd-ircdev/include/s_conf.h:1.2 Sat Nov 1 07:26:45 2003 +++ ircd-ircdev/include/s_conf.h Sat Nov 1 16:47:33 2003 @@ -1,7 +1,7 @@ /* * s_conf.h * - * $Id: s_conf.h,v 1.2 2003/11/01 15:26:45 zolty Exp $ + * $Id: s_conf.h,v 1.3 2003/11/02 00:47:33 zolty Exp $ */ #ifndef INCLUDED_s_conf_h #define INCLUDED_s_conf_h @@ -64,6 +64,9 @@ int dns_pending; /* a dns request is pending */ unsigned short port; char bits; /* Number of bits for ipkills */ + struct Privs privs; /* Priviledges for opers. */ + /* Used to detect if a privilege has been touched. */ + struct Privs privs_dirty; }; struct ServerConf { Index: ircd-ircdev/ircd/.cvsignore diff -u ircd-ircdev/ircd/.cvsignore:1.1 ircd-ircdev/ircd/.cvsignore:1.2 --- ircd-ircdev/ircd/.cvsignore:1.1 Sat Nov 1 09:19:36 2003 +++ ircd-ircdev/ircd/.cvsignore Sat Nov 1 16:47:33 2003 @@ -1,6 +1,10 @@ - chkconf - table_gen - chattr.tab.c +Makefile +stamp-m +version.c +ircd +chkconf +table_gen +chattr.tab.c lex.yy.c y.tab.c y.tab.h Index: ircd-ircdev/ircd/Makefile.in diff -u ircd-ircdev/ircd/Makefile.in:1.4 ircd-ircdev/ircd/Makefile.in:1.5 --- ircd-ircdev/ircd/Makefile.in:1.4 Sat Nov 1 09:19:36 2003 +++ ircd-ircdev/ircd/Makefile.in Sat Nov 1 16:47:33 2003 @@ -44,6 +44,7 @@ GREP = grep OSDEP_C = @OSDEP_C@ ENGINE_C = @ENGINE_C@ +RES_C = @RES_C@ @SET_MAKE@ BINDIR = @bindir@ @@ -58,7 +59,7 @@ CC = @CC@ CFLAGS = @CFLAGS@ -CPPFLAGS = -I. -I.. -I${top_srcdir}/include @CPPFLAGS@ +CPPFLAGS = -I. -I.. -I${top_srcdir}/include -I${top_srcdir}/libs/adns/src @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ @@ -80,6 +81,10 @@ engine_kqueue.c \ engine_select.c +RES_SRC = \ + res_adns.c \ + res_libresolv.c + IRCD_SRC = \ IPcheck.c \ channel.c \ @@ -187,7 +192,6 @@ parse.c \ querycmds.c \ random.c \ - res.c \ s_auth.c \ s_bsd.c \ s_conf.c \ @@ -209,7 +213,7 @@ CHKCONF_SRC = chkconf.c -SRC = ${IRCD_SRC} ${OSDEP_C} ${ENGINE_C} +SRC = ${IRCD_SRC} ${OSDEP_C} ${ENGINE_C} ${RES_C} OBJS = ${SRC:%.c=%.o} Index: ircd-ircdev/ircd/client.c diff -u ircd-ircdev/ircd/client.c:1.1.1.1 ircd-ircdev/ircd/client.c:1.2 --- ircd-ircdev/ircd/client.c:1.1.1.1 Mon Sep 8 03:34:28 2003 +++ ircd-ircdev/ircd/client.c Sat Nov 1 16:47:33 2003 @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: client.c,v 1.1.1.1 2003/09/08 10:34:28 zolty Exp $ + * $Id: client.c,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ #include "config.h" @@ -101,16 +101,21 @@ } } -static struct { +enum FeatureFlag +{ + FEATFLAG_NULL, + FEATFLAG_DISABLES_PRIV, + FEATFLAG_ENABLES_PRIV, + FEATFLAG_GLOBAL_OPERS, + FEATFLAG_LOCAL_OPERS, + FEATFLAG_ALL_OPERS +}; + +static struct +{ enum Priv priv; enum Feature feat; - enum { - FEATFLAG_DISABLES_PRIV, - FEATFLAG_ENABLES_PRIV, - FEATFLAG_GLOBAL_OPERS, - FEATFLAG_LOCAL_OPERS, - FEATFLAG_ALL_OPERS - } flag; + enum FeatureFlag flag; } feattab[] = { { PRIV_WHOX, FEAT_LAST_F, FEATFLAG_ALL_OPERS }, { PRIV_DISPLAY, FEAT_LAST_F, FEATFLAG_ALL_OPERS }, @@ -163,7 +168,7 @@ { PRIV_SEE_CHAN, FEAT_LOCOP_SEE_IN_SECRET_CHANNELS, FEATFLAG_LOCAL_OPERS }, { PRIV_WIDE_GLINE, FEAT_LOCOP_WIDE_GLINE, FEATFLAG_LOCAL_OPERS }, - { PRIV_LAST_PRIV, FEAT_LAST_F, 0 } + { PRIV_LAST_PRIV, FEAT_LAST_F, FEATFLAG_NULL } }; /* client_set_privs(struct Client* client) @@ -171,62 +176,75 @@ * Sets the privileges for opers. */ void -client_set_privs(struct Client* client) +client_set_privs(struct Client *client, struct ConfItem *oper) { - struct Privs privs; - struct Privs antiprivs; int i; - memset(&privs, 0, sizeof(struct Privs)); - memset(&antiprivs, 0, sizeof(struct Privs)); + memset(&(cli_privs(client)), 0, sizeof(struct Privs)); - if (!IsAnOper(client)) { /* clear privilege mask */ - memset(&(cli_privs(client)), 0, sizeof(struct Privs)); + if (!IsAnOper(client)) return; - } else if (!MyConnect(client)) { + else if (!MyConnect(client)) + { memset(&(cli_privs(client)), 255, sizeof(struct Privs)); PrivClr(&(cli_privs(client)), PRIV_SET); return; } + else if (oper == NULL) + return; - /* This sequence is temporary until the .conf is carefully rewritten */ + /* Copy across privs from the config. */ + cli_privs(client) = oper->privs; - for (i = 0; feattab[i].priv != PRIV_LAST_PRIV; i++) { - if (feattab[i].flag == FEATFLAG_ENABLES_PRIV) { + /* Now go through the features and set the non-dirty flags to their feature + * determined defaults... + */ + for (i = 0; feattab[i].priv != PRIV_LAST_PRIV; i++) + { + if (PrivHas(&oper->privs_dirty, feattab[i].priv)) + continue; + if (feattab[i].feat != FEAT_LAST_F && !feature_bool(feattab[i].feat)) + continue; + switch (feattab[i].flag) + { + case FEATFLAG_ENABLES_PRIV: if (!feature_bool(feattab[i].feat)) - PrivSet(&antiprivs, feattab[i].priv); - } else if (feattab[i].feat == FEAT_LAST_F || feature_bool(feattab[i].feat)) { - if (feattab[i].flag == FEATFLAG_DISABLES_PRIV) { - PrivSet(&antiprivs, feattab[i].priv); - } else if (feattab[i].flag == FEATFLAG_ALL_OPERS) { - if (IsAnOper(client)) - PrivSet(&privs, feattab[i].priv); - } else if (feattab[i].flag == FEATFLAG_GLOBAL_OPERS) { - if (IsOper(client)) - PrivSet(&privs, feattab[i].priv); - } else if (feattab[i].flag == FEATFLAG_LOCAL_OPERS) { - if (IsLocOp(client)) - PrivSet(&privs, feattab[i].priv); - } + continue; + PrivSet(&cli_privs(client), feattab[i].priv); + continue; + case FEATFLAG_DISABLES_PRIV: + PrivClr(&cli_privs(client), feattab[i].priv); + continue; + case FEATFLAG_ALL_OPERS: + if (IsAnOper(client)) + PrivSet(&cli_privs(client), feattab[i].priv); + continue; + case FEATFLAG_GLOBAL_OPERS: + if (IsOper(client)) + PrivSet(&cli_privs(client), feattab[i].priv); + continue; + case FEATFLAG_LOCAL_OPERS: + if (IsLocOp(client)) + PrivSet(&cli_privs(client), feattab[i].priv); + continue; + default: + continue; /* ?? */ } } - - /* This is the end of the gross section */ - if (PrivHas(&privs, PRIV_PROPAGATE)) - PrivSet(&privs, PRIV_DISPLAY); /* force propagating opers to display */ - else { /* if they don't propagate oper status, prevent desyncs */ - PrivSet(&antiprivs, PRIV_KILL); - PrivSet(&antiprivs, PRIV_GLINE); - PrivSet(&antiprivs, PRIV_JUPE); - PrivSet(&antiprivs, PRIV_OPMODE); - PrivSet(&antiprivs, PRIV_BADCHAN); + /* This should be handled in the config, but lets be sure... */ + if (PrivHas(&cli_privs(client), PRIV_PROPAGATE)) + /* force propagating opers to display */ + PrivSet(&cli_privs(client), PRIV_DISPLAY); + else + { + /* if they don't propagate oper status, prevent desyncs */ + PrivClr(&cli_privs(client), PRIV_KILL); + PrivClr(&cli_privs(client), PRIV_GLINE); + PrivClr(&cli_privs(client), PRIV_JUPE); + PrivClr(&cli_privs(client), PRIV_OPMODE); + PrivClr(&cli_privs(client), PRIV_BADCHAN); } - - for (i = 0; i <= _PRIV_IDX(PRIV_LAST_PRIV); i++) - privs.priv_mask[i] &= ~antiprivs.priv_mask[i]; - - cli_privs(client) = privs; } static struct { @@ -240,8 +258,8 @@ P(GLINE), P(LOCAL_GLINE), P(JUPE), P(LOCAL_JUPE), P(OPMODE), P(LOCAL_OPMODE), P(SET), P(WHOX), P(BADCHAN), P(LOCAL_BADCHAN), P(SEE_CHAN), P(PROPAGATE), - P(DISPLAY), P(SEE_OPERS), P(WIDE_GLINE), P(FORCE_OPMODE), - P(FORCE_LOCAL_OPMODE), + P(DISPLAY), P(SEE_OPERS), P(FORCE_OPMODE), P(FORCE_LOCAL_OPMODE), + P(WIDE_GLINE), #undef P { 0, 0 } }; Index: ircd-ircdev/ircd/ircd.c diff -u ircd-ircdev/ircd/ircd.c:1.2 ircd-ircdev/ircd/ircd.c:1.3 --- ircd-ircdev/ircd/ircd.c:1.2 Sat Nov 1 07:26:46 2003 +++ ircd-ircdev/ircd/ircd.c Sat Nov 1 16:47:33 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: ircd.c,v 1.2 2003/11/01 15:26:46 zolty Exp $ + * $Id: ircd.c,v 1.3 2003/11/02 00:47:33 zolty Exp $ */ #include "config.h" @@ -302,7 +302,7 @@ (*pconf = con_conf)->next = 0; } - if (connect_server(con_conf, 0, 0)) + if (connect_server(con_conf, 0)) sendto_opmask_butone(0, SNO_OLDSNO, "Connection to %s activated.", con_conf->name); } @@ -355,7 +355,7 @@ Debug((DEBUG_DEBUG, "check_pings(%s)=status:%s limit: %d current: %d", cli_name(cptr), - HasFlag(cptr, FLAG_PINGSENT) ? "[Ping Sent]" : "[]", + IsPingSent(cptr) ? "[Ping Sent]" : "[]", max_ping, (int)(CurrentTime - cli_lasttime(cptr)))); /* Ok, the thing that will happen most frequently, is that someone will @@ -416,11 +416,11 @@ continue; } - if (!HasFlag(cptr, FLAG_PINGSENT)) { + if (!IsPingSent(cptr)) { /* If we havent PINGed the connection and we havent heard from it in a * while, PING it to make sure it is still alive. */ - SetFlag(cptr, FLAG_PINGSENT); + SetPingSent(cptr); /* If we're late in noticing don't hold it against them :) */ cli_lasttime(cptr) = CurrentTime - max_ping; Index: ircd-ircdev/ircd/ircd_lexer.l diff -u ircd-ircdev/ircd/ircd_lexer.l:1.1 ircd-ircdev/ircd/ircd_lexer.l:1.2 --- ircd-ircdev/ircd/ircd_lexer.l:1.1 Sat Nov 1 07:26:46 2003 +++ ircd-ircdev/ircd/ircd_lexer.l Sat Nov 1 16:47:33 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, * USA. - * $Id: ircd_lexer.l,v 1.1 2003/11/01 15:26:46 zolty Exp $ + * $Id: ircd_lexer.l,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ %{ @@ -123,5 +123,31 @@ quarantine return QUARANTINE; features return FEATURES; channel return CHANNEL; +bypass_local_channel_limits return TPRIV_CHAN_LIMIT; +set_local_channel_modes return TPRIV_MODE_LCHAN; +protected_local_channel return TPRIV_DEOP_LCHAN; +bypass_join_local_channels return TPRIV_WALK_LCHAN; +global_kill return TPRIV_KILL; +local_kill return TPRIV_LOCAL_KILL; +rehash return TPRIV_REHASH; +restart return TPRIV_RESTART; +die return TPRIV_DIE; +gline return TPRIV_GLINE; +local_gline return TPRIV_LOCAL_GLINE; +jupe_server return TPRIV_JUPE; +local_jupe_server return TPRIV_LOCAL_JUPE; +hack_channel_modes return TPRIV_OPMODE; +change_settings return TPRIV_SET; +extended_who_information return TPRIV_WHOX; +gline_channels return TPRIV_BADCHAN; +local_gline_channels return TPRIV_LOCAL_BADCHAN; +see_private_channels return TPRIV_SEE_CHAN; +see_invisible_users return TPRIV_SHOW_INVIS; +list_all_invisible_users return TPRIV_SHOW_ALL_INVIS; +globally_opered return TPRIV_PROPAGATE; +unlimited_who_queries return TPRIV_UNLIMIT_QUERY; +oper_status_display return TPRIV_DISPLAY; +see_other_opers return TPRIV_SEE_OPERS; +wide_glines return TPRIV_WIDE_GLINE; \n lineno++; . return yytext[0]; Index: ircd-ircdev/ircd/ircd_parser.y diff -u ircd-ircdev/ircd/ircd_parser.y:1.1 ircd-ircdev/ircd/ircd_parser.y:1.2 --- ircd-ircdev/ircd/ircd_parser.y:1.1 Sat Nov 1 07:26:46 2003 +++ ircd-ircdev/ircd/ircd_parser.y Sat Nov 1 16:47:33 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, * USA. - * $Id: ircd_parser.y,v 1.1 2003/11/01 15:26:46 zolty Exp $ + * $Id: ircd_parser.y,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ %{ @@ -141,7 +141,6 @@ %token FEATURES %token QUARANTINE /* and now a lot of priviledges... */ -/* %token TPRIV_CHAN_LIMIT, TPRIV_MODE_LCHAN, TPRIV_DEOP_LCHAN, TPRIV_WALK_LCHAN %token TPRIV_KILL, TPRIV_LOCAL_KILL, TPRIV_REHASH, TPRIV_RESTART, TPRIV_DIE %token TPRIV_GLINE, TPRIV_LOCAL_GLINE, TPRIV_JUPE, TPRIV_LOCAL_JUPE @@ -149,14 +148,10 @@ %token TPRIV_LOCAL_BADCHAN %token TPRIV_SEE_CHAN, TPRIV_SHOW_INVIS, TPRIV_SHOW_ALL_INVIS, TPRIV_PROPAGATE %token TPRIV_UNLIMIT_QUERY, TPRIV_DISPLAY, TPRIV_SEE_OPERS, TPRIV_WIDE_GLINE -*/ /* and some types... */ %type <num> sizespec %type <num> timespec, timefactor, factoredtimes, factoredtime -/* %type <num> expr, yesorno, privtype -*/ -%type <num> expr, yesorno %left '+' '-' %left '*' '/' @@ -499,10 +494,7 @@ } }; operitems: operitem | operitems operitem; -/* operitem: opername | operpass | operlocal | operhost | operclass | operpriv; -*/ -operitem: opername | operpass | operlocal | operhost | operclass; opername: NAME '=' QSTRING ';' { @@ -546,7 +538,6 @@ aconf->conn_class = find_class(yylval.text); }; -/* operpriv: privtype '=' yesorno ';' { if ($3 == 1) @@ -588,7 +579,7 @@ TPRIV_DISPLAY { $$ = PRIV_DISPLAY; } | TPRIV_SEE_OPERS { $$ = PRIV_SEE_OPERS; } | TPRIV_WIDE_GLINE { $$ = PRIV_WIDE_GLINE; }; -*/ + yesorno: YES { $$ = 1; } | NO { $$ = 0; }; /* The port block... */ Index: ircd-ircdev/ircd/list.c diff -u ircd-ircdev/ircd/list.c:1.1.1.1 ircd-ircdev/ircd/list.c:1.2 --- ircd-ircdev/ircd/list.c:1.1.1.1 Mon Sep 8 03:34:29 2003 +++ ircd-ircdev/ircd/list.c Sat Nov 1 16:47:33 2003 @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: list.c,v 1.1.1.1 2003/09/08 10:34:29 zolty Exp $ + * $Id: list.c,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ #include "config.h" @@ -154,8 +154,10 @@ Debug((DEBUG_LIST, "Deallocating connection %p", con)); - if (con_dns_reply(con)) - --(con_dns_reply(con)->ref_count); + if (con_dns_reply(con)) { + MyFree(con_dns_reply(con)); + con_dns_reply(con) = 0; + } if (-1 < con_fd(con)) close(con_fd(con)); MsgQClear(&(con_sendQ(con))); @@ -314,9 +316,9 @@ assert(!cli_next(cptr) || cli_verify(cli_next(cptr))); assert(!IsMe(cptr)); - /* Only remove from the list if it actually IS in the list. - * cli_next(cptr) cannot be NULL here if cptr is in the list, - * only &me is at the end, and we never try to remove &me -GW + /* Only try remove cptr from the list if it IS in the list. + * cli_next(cptr) cannot be NULL here, as &me is always the end + * the list, and we never remove &me. -GW */ if(cli_next(cptr)) { Index: ircd-ircdev/ircd/m_connect.c diff -u ircd-ircdev/ircd/m_connect.c:1.1.1.1 ircd-ircdev/ircd/m_connect.c:1.2 --- ircd-ircdev/ircd/m_connect.c:1.1.1.1 Mon Sep 8 03:34:29 2003 +++ ircd-ircdev/ircd/m_connect.c Sat Nov 1 16:47:33 2003 @@ -20,7 +20,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: m_connect.c,v 1.1.1.1 2003/09/08 10:34:29 zolty Exp $ + * $Id: m_connect.c,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ /* @@ -202,7 +202,7 @@ log_write(LS_NETWORK, L_INFO, 0, "CONNECT From %C : %s %s", sptr, parv[1], parv[2] ? parv[2] : ""); - if (connect_server(aconf, sptr, 0)) { + if (connect_server(aconf, sptr)) { sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :*** Connecting to %s.", sptr, aconf->name); } @@ -332,7 +332,7 @@ tmpport = aconf->port; aconf->port = port; - if (connect_server(aconf, sptr, 0)) { + if (connect_server(aconf, sptr)) { sendcmdto_one(&me, CMD_NOTICE, sptr, "%C :*** Connecting to %s.", sptr, aconf->name); } Index: ircd-ircdev/ircd/m_oper.c diff -u ircd-ircdev/ircd/m_oper.c:1.1.1.1 ircd-ircdev/ircd/m_oper.c:1.2 --- ircd-ircdev/ircd/m_oper.c:1.1.1.1 Mon Sep 8 03:34:29 2003 +++ ircd-ircdev/ircd/m_oper.c Sat Nov 1 16:47:33 2003 @@ -20,7 +20,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * - * $Id: m_oper.c,v 1.1.1.1 2003/09/08 10:34:29 zolty Exp $ + * $Id: m_oper.c,v 1.2 2003/11/02 00:47:33 zolty Exp $ */ /* @@ -180,7 +180,7 @@ SetFlag(sptr, FLAG_DEBUG); set_snomask(sptr, SNO_OPERDEFAULT, SNO_ADD); - client_set_privs(sptr); + client_set_privs(sptr, aconf); cli_max_sendq(sptr) = 0; /* Get the sendq from the oper's class */ send_umode_out(cptr, sptr, &old_mode, HasPriv(sptr, PRIV_PROPAGATE)); send_reply(sptr, RPL_YOUREOPER); Index: ircd-ircdev/ircd/res.c diff -u ircd-ircdev/ircd/res.c:1.1.1.1 ircd-ircdev/ircd/res.c:removed --- ircd-ircdev/ircd/res.c:1.1.1.1 Mon Sep 8 03:34:30 2003 +++ ircd-ircdev/ircd/res.c Sat Nov 1 16:47:44 2003 @@ -1,1824 +0,0 @@ -/* - * src/res.c (C)opyright 1992 Darren Reed. All rights reserved. - * This file may not be distributed without the author's permission in any - * shape or form. The author takes no responsibility for any damage or loss - * of property which results from the use of this software. - * - * $Id: res.c,v 1.1.1.1 2003/09/08 10:34:30 zolty Exp $ - * - * July 1999 - Rewrote a bunch of stuff here. Change hostent builder code, - * added callbacks and reference counting of returned hostents. - * --Bleep (Thomas Helvey <to...@in...>) - */ -#include "config.h" - -#include "res.h" -#include "client.h" -#include "ircd.h" -#include "ircd_alloc.h" -#include "ircd_events.h" -#include "ircd_log.h" -#include "ircd_osdep.h" -#include "ircd_reply.h" -#include "ircd_snprintf.h" -#include "ircd_string.h" -#include "msg.h" -#include "numeric.h" -#include "s_bsd.h" -#include "s_debug.h" -#include "s_misc.h" -#include "send.h" -#include "struct.h" -#include "support.h" -#include "sys.h" - -#include <assert.h> -#include <errno.h> -#include <string.h> -#include <stdlib.h> -#include <sys/time.h> -#include <sys/socket.h> -#include <fcntl.h> -#include <unistd.h> -#include <regex.h> - -#include <arpa/nameser.h> -#include <resolv.h> -#include <netdb.h> -#include <arpa/inet.h> - -#include <limits.h> -#if (CHAR_BIT != 8) -#error this code needs to be able to address individual octets -#endif - -/* - * Some systems do not define INADDR_NONE (255.255.255.255) - * INADDR_NONE is actually a valid address, but it should never - * be returned from any nameserver. - * NOTE: The bit pattern for INADDR_NONE and INADDR_ANY (0.0.0.0) should be - * the same on all hosts so we shouldn't need to use htonl or ntohl to - * compare or set the values. - */ -#ifndef INADDR_NONE -#define INADDR_NONE ((unsigned int) 0xffffffff) -#endif - -#define MAXPACKET 1024 /* rfc sez 512 but we expand names so ... */ -#define RES_MAXALIASES 35 /* maximum aliases allowed */ -#define RES_MAXADDRS 35 /* maximum addresses allowed */ -/* - * OSF1 doesn't have RES_NOALIASES - */ -#ifndef RES_NOALIASES -#define RES_NOALIASES 0 -#endif - -/* - * macros used to calulate offsets into fixed query buffer - */ -#define ALIAS_BLEN ((RES_MAXALIASES + 1) * sizeof(char*)) -#define ADDRS_BLEN ((RES_MAXADDRS + 1) * sizeof(struct in_addr*)) - -#define ADDRS_OFFSET (ALIAS_BLEN + ADDRS_BLEN) -#define ADDRS_DLEN (RES_MAXADDRS * sizeof(struct in_addr)) -#define NAMES_OFFSET (ADDRS_OFFSET + ADDRS_DLEN) -#define MAXGETHOSTLEN (NAMES_OFFSET + MAXPACKET) - -#define AR_TTL 600 /* TTL in seconds for dns cache entries */ - -/* - * the following values should be prime - */ -#define ARES_CACSIZE 307 -#define MAXCACHED 281 - -/* - * RFC 1104/1105 wasn't very helpful about what these fields - * should be named, so for now, we'll just name them this way. - * we probably should look at what named calls them or something. - */ -#define TYPE_SIZE 2 -#define CLASS_SIZE 2 -#define TTL_SIZE 4 -#define RDLENGTH_SIZE 2 -#define ANSWER_FIXED_SIZE (TYPE_SIZE + CLASS_SIZE + TTL_SIZE + RDLENGTH_SIZE) - -/* - * Building the Hostent - * The Hostent struct is arranged like this: - * +-------------------------------+ - * Hostent: | struct hostent h | - * |-------------------------------| - * | char *buf | - * +-------------------------------+ - * - * allocated: - * - * +-------------------------------+ - * buf: | h_aliases pointer array | Max size: ALIAS_BLEN; - * | NULL | contains `char *'s - * |-------------------------------| - * | h_addr_list pointer array | Max size: ADDRS_BLEN; - * | NULL | contains `struct in_addr *'s - * |-------------------------------| - * | h_addr_list addresses | Max size: ADDRS_DLEN; - * | | contains `struct in_addr's - * |-------------------------------| - * | storage for hostname strings | Max size: ALIAS_DLEN; - * +-------------------------------+ contains `char's - * - * For requests the size of the h_aliases, and h_addr_list pointer - * array sizes are set to MAXALISES and MAXADDRS respectively, and - * buf is a fixed size with enough space to hold the largest expected - * reply from a nameserver, see RFC 1034 and RFC 1035. - * For cached entries the sizes are dependent on the actual number - * of aliases and addresses. If new aliases and addresses are found - * for cached entries, the buffer is grown and the new entries are added. - * The hostent struct is filled in with the addresses of the entries in - * the Hostent buf as follows: - * h_name - contains a pointer to the start of the hostname string area, - * or NULL if none is set. The h_name is followed by the - * aliases, in the storage for hostname strings area. - * h_aliases - contains a pointer to the start of h_aliases pointer array. - * This array contains pointers to the storage for hostname - * strings area and is terminated with a NULL. The first alias - * is stored directly after the h_name. - * h_addr_list - contains a pointer to the start of h_addr_list pointer array. - * This array contains pointers to in_addr structures in the - * h_addr_list addresses area and is terminated with a NULL. - * - * Filling the buffer this way allows for proper alignment of the h_addr_list - * addresses. - * - * This arrangement allows us to alias a Hostent struct pointer as a - * real struct hostent* without lying. It also allows us to change the - * values contained in the cached entries and requests without changing - * the actual hostent pointer, which is saved in a client struct and can't - * be changed without blowing things up or a lot more fiddling around. - * It also allows for defered allocation of the fixed size buffers until - * they are really needed. - * Nov. 17, 1997 --Bleep - */ - -struct Hostent { - struct hostent h; /* the hostent struct we are passing around */ - char* buf; /* buffer for data pointed to from hostent */ -}; - -struct ResRequest { - struct ResRequest* next; - int id; - int sent; /* number of requests sent */ - time_t ttl; - char type; - char retries; /* retry counter */ - char sends; /* number of sends (>1 means resent) */ - char resend; /* send flag. 0 == dont resend */ - time_t sentat; - time_t timeout; - struct in_addr addr; - char* name; - struct DNSQuery query; /* query callback for this request */ - struct Hostent he; -}; - -struct CacheEntry { - struct CacheEntry* hname_next; - struct CacheEntry* hnum_next; - struct CacheEntry* list_next; - time_t expireat; - time_t ttl; - struct Hostent he; - struct DNSReply reply; -}; - -struct CacheTable { - struct CacheEntry* num_list; - struct CacheEntry* name_list; -}; - - -int ResolverFileDescriptor = -1; /* GLOBAL - used in s_bsd.c */ - -static struct Socket resSock; /* Socket describing resolver */ -static struct Timer resExpireDNS; /* Timer for DNS expiration */ -static struct Timer resExpireCache; /* Timer for cache expiration */ - -static time_t nextDNSCheck = 0; -static time_t nextCacheExpire = 1; - -/* - * Keep a spare file descriptor open. res_init calls fopen to read the - * resolv.conf file. If ircd is hogging all the file descriptors below 256, - * on systems with crippled FILE structures this will cause wierd bugs. - * This is definitely needed for Solaris which uses an unsigned char to - * hold the file descriptor. --Dianora - */ -static int spare_fd = -1; - -static int cachedCount = 0; -static struct CacheTable hashtable[ARES_CACSIZE]; -static struct CacheEntry* cacheTop; -static struct ResRequest* requestListHead; /* head of resolver request list */ -static struct ResRequest* requestListTail; /* tail of resolver request list */ - - -static void add_request(struct ResRequest* request); -static void rem_request(struct ResRequest* request); -static struct ResRequest* make_request(const struct DNSQuery* query); -static time_t timeout_query_list(time_t now); -static time_t expire_cache(time_t now); -static void rem_cache(struct CacheEntry*); -static void do_query_name(const struct DNSQuery* query, - const char* name, - struct ResRequest* request); -static void do_query_number(const struct DNSQuery* query, - const struct in_addr*, - struct ResRequest* request); -static void query_name(const char* name, - int query_class, - int query_type, - struct ResRequest* request); -static void resend_query(struct ResRequest* request); -static struct CacheEntry* make_cache(struct ResRequest* request); -static struct CacheEntry* find_cache_name(const char* name); -static struct CacheEntry* find_cache_number(struct ResRequest* request, - const char* addr); -static struct ResRequest* find_id(int); - -static struct cacheinfo { - int ca_adds; - int ca_dels; - int ca_expires; - int ca_lookups; - int ca_na_hits; - int ca_nu_hits; - int ca_updates; -} cainfo; - -static struct resinfo { - int re_errors; - int re_nu_look; - int re_na_look; - int re_replies; - int re_requests; - int re_resends; - int re_sent; - int re_timeouts; - int re_shortttl; - int re_unkrep; -} reinfo; - - -/* - * From bind 8.3, these aren't declared in earlier versions of bind - */ -extern u_short _getshort(const u_char *); -extern u_int _getlong(const u_char *); -/* - * int - * res_isourserver(ina) - * looks up "ina" in _res.ns_addr_list[] - * returns: - * 0 : not found - * >0 : found - * author: - * paul vixie, 29may94 - */ -static int -res_ourserver(const struct __res_state* statp, const struct sockaddr_in* inp) -{ - struct sockaddr_in ina; - int ns; - - ina = *inp; - for (ns = 0; ns < statp->nscount; ns++) { - const struct sockaddr_in *srv = &statp->nsaddr_list[ns]; - - if (srv->sin_family == ina.sin_family && - srv->sin_port == ina.sin_port && - (srv->sin_addr.s_addr == INADDR_ANY || - srv->sin_addr.s_addr == ina.sin_addr.s_addr)) - return (1); - } - return (0); -} - -/* Socket callback for resolver */ -static void res_callback(struct Event* ev) -{ - assert(ev_type(ev) == ET_READ || ev_type(ev) == ET_ERROR); - - resolver_read(); -} - -/* - * start_resolver - do everything we need to read the resolv.conf file - * and initialize the resolver file descriptor if needed - */ -static void start_resolver(void) -{ - Debug((DEBUG_DNS, "Resolver: start_resolver")); - /* - * close the spare file descriptor so res_init can read resolv.conf - * successfully. Needed on Solaris - */ - if (spare_fd > -1) - close(spare_fd); - - res_init(); /* res_init always returns 0 */ - /* - * make sure we have a valid file descriptor below 256 so we can - * do this again. Needed on Solaris - */ - spare_fd = open("/dev/null",O_RDONLY,0); - if ((spare_fd < 0) || (spare_fd > 255)) { - char sparemsg[80]; - ircd_snprintf(0, sparemsg, sizeof(sparemsg), "invalid spare_fd %d", - spare_fd); - server_restart(sparemsg); - } - - if (!_res.nscount) { - _res.nscount = 1; - _res.nsaddr_list[0].sin_addr.s_addr = inet_addr("127.0.0.1"); - } - _res.options |= RES_NOALIASES; - - if (ResolverFileDescriptor < 0) { - ResolverFileDescriptor = socket(AF_INET, SOCK_DGRAM, 0); - if (-1 == ResolverFileDescriptor) { - report_error("Resolver: error creating socket for %s: %s", - cli_name(&me), errno); - return; - } - if (!os_set_nonblocking(ResolverFileDescriptor)) - report_error("Resolver: error setting non-blocking for %s: %s", - cli_name(&me), errno); - if (!socket_add(&resSock, res_callback, 0, SS_DATAGRAM, - SOCK_EVENT_READABLE, ResolverFileDescriptor)) - report_error("Resolver: unable to queue resolver file descriptor for %s", - cli_name(&me), ENFILE); - } -} - -/* Call the query timeout function */ -static void expire_DNS_callback(struct Event* ev) -{ - time_t next; - - next = timeout_query_list(CurrentTime); - - timer_add(&resExpireDNS, expire_DNS_callback, 0, TT_ABSOLUTE, next); -} - -/* Call the cache expire function */ -static void expire_cache_callback(struct Event* ev) -{ - time_t next; - - next = expire_cache(CurrentTime); - - timer_add(&resExpireCache, expire_cache_callback, 0, TT_ABSOLUTE, next); -} - -/* - * init_resolver - initialize resolver and resolver library - */ -int init_resolver(void) -{ - Debug((DEBUG_DNS, "Resolver: init_resolver")); -#ifdef LRAND48 - srand48(CurrentTime); -#endif - memset(&cainfo, 0, sizeof(cainfo)); - memset(hashtable, 0, sizeof(hashtable)); - memset(&reinfo, 0, sizeof(reinfo)); - - requestListHead = requestListTail = 0; - - /* initiate the resolver timers */ - timer_add(timer_init(&resExpireDNS), expire_DNS_callback, 0, - TT_RELATIVE, 1); - timer_add(timer_init(&resExpireCache), expire_cache_callback, 0, - TT_RELATIVE, 1); - - errno = h_errno = 0; - - start_resolver(); - Debug((DEBUG_DNS, "Resolver: fd %d errno: %d h_errno: %d: %s", - ResolverFileDescriptor, errno, h_errno, - (strerror(errno)) ? strerror(errno) : "Unknown")); - return ResolverFileDescriptor; -} - -/* - * restart_resolver - flush the cache, reread resolv.conf, reopen socket - */ -void restart_resolver(void) -{ - /* flush_cache(); flush the dns cache */ - start_resolver(); -} - -static int validate_hostent(const struct hostent* hp) -{ - const char* name; - int i = 0; - assert(0 != hp); - for (name = hp->h_name; name; name = hp->h_aliases[i++]) { - if (!string_is_hostname(name)) - return 0; - } - return 1; -} - -/* - * add_request - place a new request in the request list - */ -static void add_request(struct ResRequest* request) -{ - assert(0 != request); - if (!requestListHead) - requestListHead = requestListTail = request; - else { - requestListTail->next = request; - requestListTail = request; - } - request->next = NULL; - ++reinfo.re_requests; -} - -/* - * rem_request - remove a request from the list. - * This must also free any memory that has been allocated for - * temporary storage of DNS results. - */ -static void rem_request(struct ResRequest* request) -{ - struct ResRequest** current; - struct ResRequest* prev = NULL; - - assert(0 != request); - for (current = &requestListHead; *current; ) { - if (*current == request) { - *current = request->next; - if (requestListTail == request) - requestListTail = prev; - break; - } - prev = *current; - current = &(*current)->next; - } - MyFree(request->he.buf); - MyFree(request->name); - MyFree(request); -} - -/* - * make_request - Create a DNS request record for the server. - */ -static struct ResRequest* make_request(const struct DNSQuery* query) -{ - struct ResRequest* request; - assert(0 != query); - request = (struct ResRequest*) MyMalloc(sizeof(struct ResRequest)); - memset(request, 0, sizeof(struct ResRequest)); - - request->sentat = CurrentTime; - request->retries = 3; - request->resend = 1; - request->timeout = 5; /* start at 5 per RFC1123 */ - request->addr.s_addr = INADDR_NONE; - request->he.h.h_addrtype = AF_INET; - request->he.h.h_length = sizeof(struct in_addr); - request->query.vptr = query->vptr; - request->query.callback = query->callback; - -#if defined(NULL_POINTER_NOT_ZERO) - request->next = NULL; - request->he.buf = NULL; - request->he.h.h_name = NULL; - request->he.h.h_aliases = NULL; - request->he.h.h_addr_list = NULL; -#endif - add_request(request); - return request; -} - -/* - * timeout_query_list - Remove queries from the list which have been - * there too long without being resolved. - */ -static time_t timeout_query_list(time_t now) -{ - struct ResRequest* request; - struct ResRequest* next_request = 0; - time_t next_time = 0; - time_t timeout = 0; - - Debug((DEBUG_DNS, "Resolver: timeout_query_list at %s", myctime(now))); - for (request = requestListHead; request; request = next_request) { - next_request = request->next; - timeout = request->sentat + request->timeout; - if (timeout < now) { - if (--request->retries <= 0) { - ++reinfo.re_timeouts; - (*request->query.callback)(request->query.vptr, 0); - rem_request(request); - continue; - } - else { - request->sentat = now; - request->timeout += request->timeout; - resend_query(request); - } - } - if (!next_time || timeout < next_time) { - next_time = timeout; - } - } - return (next_time > now) ? next_time : (now + AR_TTL); -} - -/* - * expire_cache - removes entries from the cache which are older - * than their expiry times. returns the time at which the server - * should next poll the cache. - */ -static time_t expire_cache(time_t now) -{ - struct CacheEntry* cp; - struct CacheEntry* cp_next; - time_t expire = 0; - - Debug((DEBUG_DNS, "Resolver: expire_cache at %s", myctime(now))); - for (cp = cacheTop; cp; cp = cp_next) { - cp_next = cp->list_next; - if (cp->expireat < now) { - ++cainfo.ca_expires; - rem_cache(cp); - } - else if (!expire || expire > cp->expireat) - expire = cp->expireat; - } - return (expire > now) ? expire : (now + AR_TTL); -} - -/* - * timeout_resolver - check request list and cache for expired entries - */ -time_t timeout_resolver(time_t now) -{ - if (nextDNSCheck < now) - nextDNSCheck = timeout_query_list(now); - if (nextCacheExpire < now) - nextCacheExpire = expire_cache(now); - return IRCD_MIN(nextDNSCheck, nextCacheExpire); -} - - -/* - * delete_resolver_queries - cleanup outstanding queries - * for which there no longer exist clients or conf lines. - */ -void delete_resolver_queries(const void* vptr) -{ - struct ResRequest* request; - struct ResRequest* next_request; - - for (request = requestListHead; request; request = next_request) { - next_request = request->next; - if (vptr == request->query.vptr) - rem_request(request); - } -} - -/* - * send_res_msg - sends msg to all nameservers found in the "_res" structure. - * This should reflect /etc/resolv.conf. We will get responses - * which arent needed but is easier than checking to see if nameserver - * isnt present. Returns number of messages successfully sent to - * nameservers or -1 if no successful sends. - */ -static int send_res_msg(const u_char* msg, int len, int rcount) -{ - int i; - int sent = 0; - int max_queries = IRCD_MIN(_res.nscount, rcount); - - assert(0 != msg); - /* - * RES_PRIMARY option is not implemented - * if (_res.options & RES_PRIMARY || 0 == max_queries) - */ - if (0 == max_queries) - max_queries = 1; - - Debug((DEBUG_DNS, "Resolver: sendto %d", max_queries)); - - for (i = 0; i < max_queries; i++) { - if (sendto(ResolverFileDescriptor, msg, len, 0, - (struct sockaddr*) &(_res.nsaddr_list[i]), - sizeof(struct sockaddr_in)) == len) { - ++reinfo.re_sent; - ++sent; - } - else - log_write(LS_RESOLVER, L_ERROR, 0, "Resolver: send failed %m"); - } - return sent; -} - -/* - * find_id - find a dns request id (id is determined by dn_mkquery) - */ -static struct ResRequest* find_id(int id) -{ - struct ResRequest* request; - - for (request = requestListHead; request; request = request->next) { - if (request->id == id) - return request; - } - return NULL; -} - -/* - * gethost_byname - get host address from name - */ -struct DNSReply* gethost_byname(const char* name, - const struct DNSQuery* query) -{ - struct CacheEntry* cp; - assert(0 != name); - - Debug((DEBUG_DNS, "Resolver: gethost_byname %s", name)); - ++reinfo.re_na_look; - if ((cp = find_cache_name(name))) - return &(cp->reply); - - do_query_name(query, name, NULL); - nextDNSCheck = 1; - return NULL; -} - -/* - * gethost_byaddr - get host name from address - */ -struct DNSReply* gethost_byaddr(const char* addr, - const struct DNSQuery* query) -{ - struct CacheEntry *cp; - - assert(0 != addr); - - Debug((DEBUG_DNS, "Resolver: gethost_byaddr %s", ircd_ntoa(addr))); - - ++reinfo.re_nu_look; - if ((cp = find_cache_number(NULL, addr))) - return &(cp->reply); - - do_query_number(query, (const struct in_addr*) addr, NULL); - nextDNSCheck = 1; - return NULL; -} - -/* - * do_query_name - nameserver lookup name - */ -static void do_query_name(const struct DNSQuery* query, - const char* name, struct ResRequest* request) -{ - ... [truncated message content] |
From: Toni G. <zo...@us...> - 2003-11-01 17:28:29
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-01 17:28:22 UTC Added files: libs/adns/.cvsignore libs/adns/COPYING libs/adns/Makefile libs/adns/Makefile.in libs/adns/README libs/adns/README.html libs/adns/README.ircu libs/adns/aclocal.m4 libs/adns/configure libs/adns/configure.in libs/adns/settings.make.in libs/adns/src/.cvsignore libs/adns/src/Makefile.in libs/adns/src/adns.h libs/adns/src/adns.make libs/adns/src/check.c libs/adns/src/config.h libs/adns/src/config.h.in libs/adns/src/dlist.h libs/adns/src/event.c libs/adns/src/general.c libs/adns/src/internal.h libs/adns/src/parse.c libs/adns/src/poll.c libs/adns/src/query.c libs/adns/src/reply.c libs/adns/src/setup.c libs/adns/src/transmit.c libs/adns/src/tvarith.h libs/adns/src/types.c Log message: Incluimos la libreria de resolucion DNS "adns". ---------------------- diff included ---------------------- Index: ircd-ircdev/libs/adns/.cvsignore diff -u /dev/null ircd-ircdev/libs/adns/.cvsignore:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/.cvsignore Sat Nov 1 09:28:12 2003 @@ -0,0 +1,3 @@ +config.log +config.status +settings.make Index: ircd-ircdev/libs/adns/COPYING diff -u /dev/null ircd-ircdev/libs/adns/COPYING:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/COPYING Sat Nov 1 09:28:12 2003 @@ -0,0 +1,340 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + <one line to give the program's name and a brief idea of what it does.> + Copyright (C) 19yy <name of author> + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + <signature of Ty Coon>, 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. Index: ircd-ircdev/libs/adns/Makefile diff -u /dev/null ircd-ircdev/libs/adns/Makefile:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/Makefile Sat Nov 1 09:28:12 2003 @@ -0,0 +1,69 @@ +# Generated automatically from Makefile.in by configure. +# Makefile - top-level Makefile +# +# This file is +# Copyright (C) 1997-2000 Ian Jackson <ia...@da...> +# +# It is part of adns, which is +# Copyright (C) 1997-2000 Ian Jackson <ia...@da...> +# Copyright (C) 1999-2000 Tony Finch <do...@do...> +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software Foundation, +# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +# Remember to change ADNS_VERSION_STRING in client/client.h too, and +# possibly library soname (MAJOR and MINOR in settings.make.in). +DISTVERSION= 1.0 + +srcdir= . + +SUBDIRS= src + +build: all + +all install uninstall clean distclean mostlyclean maintainer-clean distprep: + set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d $@; done + $(MAKE) $@-here + +all-here install-here uninstall-here distprep-here: README + +clean-here mostlyclean-here: + rm -f *~ ./#*# core *.orig *.rej adns-*.tar.gz + rm -rf dist_tmp + +distclean-here maintainer-clean-here: clean-here + rm -f settings.make config.h config.cache config.log config.status + +install-strip: + $(MAKE) INSTALL_PROGRAM_FLAGS=-s + +dist_tmp=dist_tmp/adns-$(DISTVERSION) +dist: distprep + rm -rf dist_tmp* + mkdir dist_tmp $(dist_tmp) + find \( -name CVS -o -name dist_tmp* \) -prune -o -type d -print | \ + sed -e 's#.*#mkdir -p $(dist_tmp)/&#' | sh + find \( -name CVS -o -name dist_tmp* \) -prune -o -type f -print | \ + sed -e 's#.*#ln & $(dist_tmp)/&#' | sh + $(MAKE) -C dist_tmp/adns-$(DISTVERSION) distclean + cd dist_tmp && tar cf ../$(dist_tmp).tar `basename $(dist_tmp)` + gzip -9 $(dist_tmp).tar + mv $(dist_tmp).tar.gz . + +README: README.html + lynx -dump -number_links -cfg=/dev/null $(srcdir)/README.html >README.tmp + mv -f README.tmp README + +TAGS info dvi: + # do nothing Index: ircd-ircdev/libs/adns/Makefile.in diff -u /dev/null ircd-ircdev/libs/adns/Makefile.in:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/Makefile.in Sat Nov 1 09:28:12 2003 @@ -0,0 +1,69 @@ +# Makefile - top-level Makefile +# +# This file is +# Copyright (C) 1997-2000 Ian Jackson <ia...@da...> +# +# It is part of adns, which is +# Copyright (C) 1997-2000 Ian Jackson <ia...@da...> +# Copyright (C) 1999-2000 Tony Finch <do...@do...> +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software Foundation, +# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +# Remember to change ADNS_VERSION_STRING in client/client.h too, and +# possibly library soname (MAJOR and MINOR in settings.make.in). +DISTVERSION= 1.0 + +srcdir= @srcdir@ +VPATH= @srcdir@ + +SUBDIRS= src + +build: all + +all install uninstall clean distclean mostlyclean maintainer-clean distprep: + set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d $@; done + $(MAKE) $@-here + +all-here install-here uninstall-here distprep-here: README + +clean-here mostlyclean-here: + rm -f *~ ./#*# core *.orig *.rej adns-*.tar.gz + rm -rf dist_tmp + +distclean-here maintainer-clean-here: clean-here + rm -f settings.make config.h config.cache config.log config.status + +install-strip: + $(MAKE) INSTALL_PROGRAM_FLAGS=-s + +dist_tmp=dist_tmp/adns-$(DISTVERSION) +dist: distprep + rm -rf dist_tmp* + mkdir dist_tmp $(dist_tmp) + find \( -name CVS -o -name dist_tmp* \) -prune -o -type d -print | \ + sed -e 's#.*#mkdir -p $(dist_tmp)/&#' | sh + find \( -name CVS -o -name dist_tmp* \) -prune -o -type f -print | \ + sed -e 's#.*#ln & $(dist_tmp)/&#' | sh + $(MAKE) -C dist_tmp/adns-$(DISTVERSION) distclean + cd dist_tmp && tar cf ../$(dist_tmp).tar `basename $(dist_tmp)` + gzip -9 $(dist_tmp).tar + mv $(dist_tmp).tar.gz . + +README: README.html + lynx -dump -number_links -cfg=/dev/null $(srcdir)/README.html >README.tmp + mv -f README.tmp README + +TAGS info dvi: + # do nothing Index: ircd-ircdev/libs/adns/README diff -u /dev/null ircd-ircdev/libs/adns/README:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/README Sat Nov 1 09:28:12 2003 @@ -0,0 +1,167 @@ + + GNU adns + + Advanced, easy to use, asynchronous-capable DNS client library and + utilities. + + adns is a resolver library for C (and C++) programs, and a collection + of useful DNS resolver utilities. + +C library + + In contrast with the standard interfaces, gethostbyname et al and + libresolv, it has the following features: + * It is reasonably easy to use for simple programs which just want + to translate names to addresses, look up MX records, etc. + * It can be used in an asynchronous, non-blocking, manner. Many + queries can be handled simultaneously. + * Responses are decoded automatically into a natural representation + for a C program - there is no need to deal with DNS packet + formats. + * Sanity checking (eg, name syntax checking, reverse/forward + correspondence, CNAME pointing to CNAME) is performed + automatically. + * Time-to-live, CNAME and other similar information is returned in + an easy-to-use form, without getting in the way. + * There is no global state in the library; resolver state is an + opaque data structure which the client creates explicitly. A + program can have several instances of the resolver. + * Errors are reported to the application in a way that distinguishes + the various causes of failure properly. + * Understands conventional resolv.conf, but this can overridden by + environment variables. + * Flexibility. For example, the application can tell adns to: ignore + environment variables (for setuid programs), disable hostname + syntax sanity checks to return arbitrary data, override or ignore + resolv.conf in favour of supplied configuration, etc. + * Believed to be correct ! For example, will correctly back off to + TCP in case of long replies or queries, or to other nameservers if + several are available. It has sensible handling of bad responses + etc. + +DNS utility programs + + adns also comes with a number of utility programs for use from the + command line and in scripts: + * adnslogres is a much faster version of Apache's logresolv program. + * adnsresfilter is a filter which copies its input to its output, + replacing IP addresses by the corresponding names, without unduly + delaying the output. For example, you can usefully pipe the output + of netstat -n, tcpdump -ln, and the like, into it. + * adnshost is a general-purpose DNS lookup utility which can be used + easily in from the command line and from shell scripts to do + simple lookups. In a more advanced mode it can be used as a + general-purpose DNS helper program for scripting languages which + can invoke and communicate with subprocesses. See the [1]adnshost + usage message for a summary of its capabilities. + +Documentation + + I'm afraid there is no manual yet. However, competent C programmers + should be able to use the library based on the [2]commented adns.h + header file, and the usage messages for the programs should be + sufficient. + +Feedback + + I'd be pleased if you would let me know if you're using my library in + your project, and what you think of it. + + If you are subscribed to adns-discuss please send feedback, including + bug reports, there; otherwise send mail to + adn...@ch.... If you'd prefer that your + message wasn't forwarded to the adns-bugreports list, send it to + adn...@ch.... + +Mailinglists + + I have set up mailinglists adns-announce and adns-discuss. The + announcements list is moderated and will contain only announcements of + important bugs, new versions, etc. The bug reports address mentioned + above is also a mailing list; feel free to subscribe to it. + + There are [3]archives and subscription web pages, or you can subscribe + by sending mail containing the word `subscribe' to + adn...@ch... or + adn...@ch.... + +Download + + Available for download from [4]chiark.greenend.org.uk are: + * The [5]current release as a gzipped tarfile. + * [6]adns.h API header file with comments, and [7]usage message for + adnshost (currently there is no manual, sorry). + * All versions released so far are also available via [8]anonymous + FTP and [9]HTTP, + * A mirror of my CVS repository is available via rsync from + rsync.chiark.greenend.org.uk::ftp/users/ian/cvs-pub/adns (use FTP + first to find your way around), or via [10]cvsweb. + + adns is also available from the [11]GNU Project FTP servers and their + [12]mirrors. + +Technical note + + adns requires a real nameserver like [13]BIND or [14]Dents running on + the same system or a nearby one, which must be willing to provide + `recursive service'. I.e., adns is a `stub resolver'. All properly + configured UN*X and GNU systems will already have such nameserver(s); + they are usually listed in /etc/resolv.conf. + +Copyright and licensing + + adns is Copyright 1997-2000 Ian Jackson, Copyright 1999-2000 Tony + Finch, and Copyright (C) 1991 Massachusetts Institute of Technology. + + adns is free software; you can redistribute it and/or modify it under + the terms of the GNU General Public License as published by the Free + Software Foundation; either version 2 of the License, or (at your + option) any later version. + + This program and documentation is distributed in the hope that it will + be useful, but without any warranty; without even the implied warranty + of merchantability or fitness for a particular purpose. See the + [15]GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with adns, or one should be available above; if not, write to + the [16]Free Software Foundation, 59 Temple Place - Suite 330, Boston, + MA 02111-1307, USA, or email adn...@ch.... + _________________________________________________________________ + + [17]Ian Jackson / [18]adn...@ch...; more [19]free + software by me. + + [20]GNU home page; [21]chiark home page; [22]site or mirror home page + + This web page is Copyright (C)1996-2000 Ian Jackson. See the + [23]Copyright/acknowledgements. + + Use any browser - [24]Campaign for a non-browser-specific WWW + +References + + 1. http://www.chiark.greenend.org.uk/~ian/adns/adnshost.txt + 2. http://www.chiark.greenend.org.uk/~ian/adns/adns.h.txt + 3. http://www.chiark.greenend.org.uk/mailman/listinfo + 4. http://www.chiark.greenend.org.uk/~ian/adns/ + 5. http://www.chiark.greenend.org.uk/~ian/adns/adns.tar.gz + 6. http://www.chiark.greenend.org.uk/~ian/adns/adns.h.txt + 7. http://www.chiark.greenend.org.uk/~ian/adns/adnshost.txt + 8. ftp://ftp.chiark.greenend.org.uk/users/ian/adns/ + 9. http://www.chiark.greenend.org.uk/~ian/adns/ftp/ + 10. http://www.chiark.greenend.org.uk/ucgi/~ijackson/cvsweb/adns/ + 11. http://www.gnu.org/ + 12. http://www.gnu.org/order/ftp.html + 13. http://www.isc.org/view.cgi?/products/BIND/index.phtml + 14. http://www.dents.org/ + 15. http://www.chiark.greenend.org.uk/~ian/COPYING.txt + 16. http://www.fsf.org/ + 17. http://www.chiark.greenend.org.uk/ + 18. mailto:adn...@ch... + 19. http://www.chiark.greenend.org.uk/~ian/software/ + 20. http://www.gnu.org/ + 21. http://www.chiark.greenend.org.uk/ + 22. file://localhost/ + 23. http://www.chiark.greenend.org.uk/~ian/sw-www-copy.html + 24. http://www.anybrowser.org/campaign/ Index: ircd-ircdev/libs/adns/README.html diff -u /dev/null ircd-ircdev/libs/adns/README.html:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/README.html Sat Nov 1 09:28:12 2003 @@ -0,0 +1,222 @@ +<html> +<head> +<title>adns - advanced, alternative, asynchronous resolver</title> +<link rev="made" href="mailto:adn...@ch..."> +</head> +<body> +<h1>GNU adns</h1> + +<strong>Advanced, easy to use, asynchronous-capable DNS client +library and utilities.</strong> + +<!-- Note: this file is maintained in Ian Jackson's private CVS. --> +<!-- --> +<!-- It is served on the GNU site and also from my own system, --> +<!-- under the URL http://www.chiark.greenend.org.uk/adns/ --> +<!-- Please ensure that all links continine to be correct --> +<!-- both for www.gnu.org and chiark. --> +<!-- --> +<!-- $Id: README.html,v 1.1 2003/11/01 17:28:12 zolty Exp $ --> + +<p> + +adns is a resolver library for C (and C++) programs, and a collection +of useful DNS resolver utilities. + + +<h2>C library</h2> + +In contrast with the standard interfaces, gethostbyname et al and +libresolv, it has the following features: + +<ul> + +<li>It is reasonably easy to use for simple programs which just want +to translate names to addresses, look up MX records, etc. + +<li>It can be used in an asynchronous, non-blocking, manner. Many +queries can be handled simultaneously. + +<li>Responses are decoded automatically into a natural representation +for a C program - there is no need to deal with DNS packet formats. + +<li>Sanity checking (eg, name syntax checking, reverse/forward +correspondence, CNAME pointing to CNAME) is performed automatically. + +<li>Time-to-live, CNAME and other similar information is returned in +an easy-to-use form, without getting in the way. + +<li>There is no global state in the library; resolver state is an +opaque data structure which the client creates explicitly. A program +can have several instances of the resolver. + +<li>Errors are reported to the application in a way that distinguishes +the various causes of failure properly. + +<li>Understands conventional resolv.conf, but this can overridden by +environment variables. + +<li>Flexibility. For example, the application can tell adns to: +ignore environment variables (for setuid programs), disable hostname +syntax sanity checks to return arbitrary data, override or ignore +resolv.conf in favour of supplied configuration, etc. + +<li>Believed to be correct ! For example, will correctly back off to +TCP in case of long replies or queries, or to other nameservers if +several are available. It has sensible handling of bad responses etc. + +</ul> + +<h2>DNS utility programs</h2> + +adns also comes with a number of utility programs for use from the +command line and in scripts: + +<ul> + +<li><code>adnslogres</code> is a much faster version of Apache's +logresolv program. + +<li><code>adnsresfilter</code> is a filter which copies its input to +its output, replacing IP addresses by the corresponding names, without +unduly delaying the output. For example, you can usefully pipe the +output of netstat -n, tcpdump -ln, and the like, into it. + +<li><code>adnshost</code> is a general-purpose DNS lookup utility +which can be used easily in from the command line and from shell +scripts to do simple lookups. In a more advanced mode it can be used +as a general-purpose DNS helper program for scripting languages which +can invoke and communicate with subprocesses. See the +<A href="http://www.chiark.greenend.org.uk/~ian/adns/adnshost.txt">adnshost +usage message</A> for a summary of its capabilities. + +</ul> + +<h2>Documentation</h2> + +I'm afraid there is no manual yet. However, competent C programmers +should be able to use the library based on the +<A href="http://www.chiark.greenend.org.uk/~ian/adns/adns.h.txt">commented +adns.h header file</A>, and the usage messages for the programs should +be sufficient. + +<h2>Feedback</h2> + +I'd be pleased if you would let me know if you're using my library in +your project, and what you think of it. + +<p> + +If you are subscribed to <code>adns-discuss</code> please send +feedback, including bug reports, there; otherwise send mail to +<code>adn...@ch...</code>. If you'd prefer +that your message wasn't forwarded to the <code>adns-bugreports</code> +list, send it to <code>adn...@ch...</code>. + +<h2>Mailinglists</h2> + +I have set up mailinglists <code>adns-announce</code> and +<code>adns-discuss</code>. The announcements list is moderated and +will contain only announcements of important bugs, new versions, etc. +The bug reports address mentioned above is also a mailing list; feel +free to subscribe to it. + +<p> + +There are +<A href="http://www.chiark.greenend.org.uk/mailman/listinfo">archives +and subscription web pages</A>, or you can subscribe by sending mail +containing the word `subscribe' to +<code>adn...@ch...</code> or +<code>adn...@ch...</code>. + +<h2>Download</h2> + +Available for download from +<A href="http://www.chiark.greenend.org.uk/~ian/adns/">chiark.greenend.org.uk</A> +are: +<ul> +<li>The <A href="http://www.chiark.greenend.org.uk/~ian/adns/adns.tar.gz">current + release</A> as a gzipped tarfile. +<li><A href="http://www.chiark.greenend.org.uk/~ian/adns/adns.h.txt">adns.h</A> + API header file with comments, and + <A href="http://www.chiark.greenend.org.uk/~ian/adns/adnshost.txt">usage + message for adnshost</A> (currently there is no manual, sorry). +<li>All versions released so far are also available via + <A href="ftp://ftp.chiark.greenend.org.uk/users/ian/adns/">anonymous + FTP</A> and <A href="http://www.chiark.greenend.org.uk/~ian/adns/ftp/">HTTP</A>, +<li>A mirror of my CVS repository is available via rsync from + <code>rsync.chiark.greenend.org.uk::ftp/users/ian/cvs-pub/adns</code> + (use FTP first to find your way around), or via + <A href="http://www.chiark.greenend.org.uk/ucgi/~ijackson/cvsweb/adns/">cvsweb</A>. +</ul> + +adns is also available from the +<A href="http://www.gnu.org/">GNU Project</A> FTP servers and their +<A href="http://www.gnu.org/order/ftp.html">mirrors</A>. + +<h2>Technical note</h2> + +adns requires a real nameserver like +<A href="http://www.isc.org/view.cgi?/products/BIND/index.phtml">BIND</A> +or +<A href="http://www.dents.org/">Dents</A> running on +the same system or a nearby one, which must be willing to provide +`recursive service'. I.e., adns is a `stub resolver'. All properly +configured UN*X and GNU systems will already have such nameserver(s); +they are usually listed in /etc/resolv.conf. + +<h2>Copyright and licensing</h2> + +<kbd>adns</kbd> is Copyright 1997-2000 Ian Jackson, Copyright +1999-2000 Tony Finch, and Copyright (C) 1991 Massachusetts Institute +of Technology. + +<p> + +<kbd>adns</kbd> is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2 of the License, or (at +your option) any later version. + +<p> + +This program and documentation is distributed in the hope that it will +be useful, but <em>without any warranty</em>; without even the implied +warranty of <em>merchantability</em> or <em>fitness for a particular +purpose</em>. See the +<A href="http://www.chiark.greenend.org.uk/~ian/COPYING.txt">GNU +General Public License</A> for more details. + +<p> + +You should have received a copy of the GNU General Public License +along with <kbd>adns</kbd>, or one should be available above; if not, +write to the +<A href="http://www.fsf.org/">Free Software Foundation</A>, +59 Temple Place - Suite 330, Boston, MA 02111-1307, USA, +or email <code>adn...@ch...</code>. + +<p> + +<hr> +<A href="http://www.chiark.greenend.org.uk/">Ian Jackson</A> / +<A href="mailto:adn...@ch..."><tt>adn...@ch...</tt></A>; +more <A href="http://www.chiark.greenend.org.uk/~ian/software/">free +software</A> by me. +<p> + +<A href="http://www.gnu.org/">GNU home page</A>; +<A href="http://www.chiark.greenend.org.uk/">chiark home page</A>; +<A href="/">site or mirror home page</A> +<p> + +This web page is Copyright (C)1996-2000 Ian Jackson. See the +<A href="http://www.chiark.greenend.org.uk/~ian/sw-www-copy.html">Copyright/acknowledgements</A>. +<p> + +Use any browser - +<A href="http://www.anybrowser.org/campaign/">Campaign for a non-browser-specific WWW</A> + +</body> +</html> Index: ircd-ircdev/libs/adns/README.ircu diff -u /dev/null ircd-ircdev/libs/adns/README.ircu:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/README.ircu Sat Nov 1 09:28:12 2003 @@ -0,0 +1,3 @@ +The files in adns/ were borrowed from the ADNS library and slightly +modified to work with ircu's event loop. The original code's copyright +notices are in the README file. Index: ircd-ircdev/libs/adns/aclocal.m4 diff -u /dev/null ircd-ircdev/libs/adns/aclocal.m4:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/aclocal.m4 Sat Nov 1 09:28:12 2003 @@ -0,0 +1,70 @@ +# aclocal.m4 - package-specific macros for autoconf +# +# This file is +# Copyright (C) 1997-1999 Ian Jackson <ia...@da...> +# +# It is part of adns, which is +# Copyright (C) 1997-1999 Ian Jackson <ia...@da...> +# Copyright (C) 1999-2000 Tony Finch <do...@do...> +# +# This file is part of adns, which is Copyright (C) 1997-1999 Ian Jackson +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software Foundation, +# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +dnl DPKG_CACHED_TRY_COMPILE(<description>,<cachevar>,<include>,<program>,<ifyes>,<ifno>) +define(DPKG_CACHED_TRY_COMPILE,[ + AC_MSG_CHECKING($1) + AC_CACHE_VAL($2,[ + AC_TRY_COMPILE([$3],[$4],[$2=yes],[$2=no]) + ]) + if test "x$$2" = xyes; then + true + $5 + else + true + $6 + fi +]) + +define(ADNS_C_GCCATTRIB,[ + DPKG_CACHED_TRY_COMPILE(__attribute__((,,)),adns_cv_c_attribute_supported,, + [extern int testfunction(int x) __attribute__((,,))], + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_GNUC25_ATTRIB) + DPKG_CACHED_TRY_COMPILE(__attribute__((noreturn)),adns_cv_c_attribute_noreturn,, + [extern int testfunction(int x) __attribute__((noreturn))], + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_GNUC25_NORETURN), + AC_MSG_RESULT(no)) + DPKG_CACHED_TRY_COMPILE(__attribute__((const)),adns_cv_c_attribute_const,, + [extern int testfunction(int x) __attribute__((const))], + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_GNUC25_CONST), + AC_MSG_RESULT(no)) + DPKG_CACHED_TRY_COMPILE(__attribute__((format...)),adns_cv_attribute_format,, + [extern int testfunction(char *y, ...) __attribute__((format(printf,1,2)))], + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_GNUC25_PRINTFFORMAT), + AC_MSG_RESULT(no)), + AC_MSG_RESULT(no)) +]) + +define(ADNS_C_GETFUNC,[ + AC_CHECK_FUNC([$1],,[ + AC_CHECK_LIB([$2],[$1],[$3],[ + AC_MSG_ERROR([cannot find library function $1]) + ]) + ]) +]) Index: ircd-ircdev/libs/adns/configure diff -u /dev/null ircd-ircdev/libs/adns/configure:1.1 --- /dev/null Sat Nov 1 09:28:22 2003 +++ ircd-ircdev/libs/adns/configure Sat Nov 1 09:28:12 2003 @@ -0,0 +1,1994 @@ +#! /bin/sh + +# Guess values for system-dependent variables and create Makefiles. +# Generated automatically using autoconf version 2.13 +# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. + +# Defaults: +ac_help= +ac_default_prefix=/usr/local +# Any additions from configure.in: + +# Initialize some variables set by options. +# The variables have the same names as the options, with +# dashes changed to underlines. +build=NONE +cache_file=./config.cache +exec_prefix=NONE +host=NONE +no_create= +nonopt=NONE +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +target=NONE +verbose= +x_includes=NONE +x_libraries=NONE +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datadir='${prefix}/share' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +libdir='${exec_prefix}/lib' +includedir='${prefix}/include' +oldincludedir='/usr/include' +infodir='${prefix}/info' +mandir='${prefix}/man' + +# Initialize some other variables. +subdirs= +MFLAGS= MAKEFLAGS= +SHELL=${CONFIG_SHELL-/bin/sh} +# Maximum number of lines to put in a shell here document. +ac_max_here_lines=12 + +ac_prev= +for ac_option +do + + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval "$ac_prev=\$ac_option" + ac_prev= + continue + fi + + case "$ac_option" in + -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; + *) ac_optarg= ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case "$ac_option" in + + -bindir | --bindir | --bindi | --bind | --bin | --bi) + ac_prev=bindir ;; + -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) + bindir="$ac_optarg" ;; + + -build | --build | --buil | --bui | --bu) + ac_prev=build ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=*) + build="$ac_optarg" ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file="$ac_optarg" ;; + + -datadir | --datadir | --datadi | --datad | --data | --dat | --da) + ac_prev=datadir ;; + -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ + | --da=*) + datadir="$ac_optarg" ;; + + -disable-* | --disable-*) + ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } + fi + ac_feature=`echo $ac_feature| sed 's/-/_/g'` + eval "enable_${ac_feature}=no" ;; + + -enable-* | --enable-*) + ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then + { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } + fi + ac_feature=`echo $ac_feature| sed 's/-/_/g'` + case "$ac_option" in + *=*) ;; + *) ac_optarg=yes ;; + esac + eval "enable_${ac_feature}='$ac_optarg'" ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix="$ac_optarg" ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he) + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat << EOF +Usage: configure [options] [host] +Options: [defaults in brackets after descriptions] +Configuration: + --cache-file=FILE cache test results in FILE + --help print this message + --no-create do not create output files + --quiet, --silent do not print \`checking...' messages + --version print the version of autoconf that created configure +Directory and file names: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [same as prefix] + --bindir=DIR user executables in DIR [EPREFIX/bin] + --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] + --libexecdir=DIR program executables in DIR [EPREFIX/libexec] + --datadir=DIR read-only architecture-independent data in DIR + [PREFIX/share] + --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data in DIR + [PREFIX/com] + --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] + --libdir=DIR object code libraries in DIR [EPREFIX/lib] + --includedir=DIR C header files in DIR [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] + --infodir=DIR info documentation in DIR [PREFIX/info] + --mandir=DIR man documentation in DIR [PREFIX/man] + --srcdir=DIR find the sources in DIR [configure dir or ..] + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM + run sed PROGRAM on installed program names +EOF + cat << EOF +Host type: + --build=BUILD configure for building on BUILD [BUILD=HOST] + --host=HOST configure for HOST [guessed] + --target=TARGET configure for TARGET [TARGET=HOST] +Features and packages: + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --x-includes=DIR X include files are in DIR + --x-libraries=DIR X library files are in DIR +EOF + if test -n "$ac_help"; then + echo "--enable and --with options recognized:$ac_help" + fi + exit 0 ;; + + -host | --host | --hos | --ho) + ac_prev=host ;; + -host=* | --host=* | --hos=* | --ho=*) + host="$ac_optarg" ;; + + -includedir | --includedir | --includedi | --included | --include \ + | --includ | --inclu | --incl | --inc) + ac_prev=includedir ;; + -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ + | --includ=* | --inclu=* | --incl=* | --inc=*) + includedir="$ac_optarg" ;; + + -infodir | --infodir | --infodi | --infod | --info | --inf) + ac_prev=infodir ;; + -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) + infodir="$ac_optarg" ;; + + -libdir | --libdir | --libdi | --libd) + ac_prev=libdir ;; + -libdir=* | --libdir=* | --libdi=* | --libd=*) + libdir="$ac_optarg" ;; + + -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ + | --libexe | --libex | --libe) + ac_prev=libexecdir ;; + -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ + | --libexe=* | --libex=* | --libe=*) + libexecdir="$ac_optarg" ;; + + -localstatedir | --localstatedir | --localstatedi | --localstated \ + | --localstate | --localstat | --localsta | --localst \ + | --locals | --local | --loca | --loc | --lo) + ac_prev=localstatedir ;; + -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ + | --localstate=* | --localstat=* | --localsta=* | --localst=* \ + | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) + localstatedir="$ac_optarg" ;; + + -mandir | --mandir | --mandi | --mand | --man | --ma | --m) + ac_prev=mandir ;; + -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) + mandir="$ac_optarg" ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ + | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ + | --oldin | --oldi | --old | --ol | --o) + ac_prev=oldincludedir ;; + -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ + | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ + | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) + oldincludedir="$ac_optarg" ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix="$ac_optarg" ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix="$ac_optarg" ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix="$ac_optarg" ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name="$ac_optarg" ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) + ac_prev=sbindir ;; + -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ + | --sbi=* | --sb=*) + sbindir="$ac_optarg" ;; + + -sharedstatedir | --sharedstatedir | --sharedstatedi \ + | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ + | --sharedst | --shareds | --shared | --share | --shar \ + | --sha | --sh) + ac_prev=sharedstatedir ;; + -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ + | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ + | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ + | --sha=* | --sh=*) + sharedstatedir="$ac_optarg" ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site="$ac_optarg" ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir="$ac_optarg" ;; + + -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ + | --syscon | --sysco | --sysc | --sys | --sy) + ac_prev=sysconfdir ;; + -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ + | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) + sysconfdir="$ac_optarg" ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target="$ac_optarg" ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers) + echo "configure generated by autoconf version 2.13" + exit 0 ;; + + -with-* | --with-*) + ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } + fi + ac_package=`echo $ac_package| sed 's/-/_/g'` + case "$ac_option" in + *=*) ;; + *) ac_optarg=yes ;; + esac + eval "with_${ac_package}='$ac_optarg'" ;; + + -without-* | --without-*) + ac_package=`echo $ac_option|sed -e 's/-*without-//'` + # Reject names that are not valid shell variable names. + if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then + { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } + fi + ac_package=`echo $ac_package| sed 's/-/_/g'` + eval "with_${ac_package}=no" ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes="$ac_optarg" ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries="$ac_optarg" ;; + + -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } + ;; + + *) + if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then + echo "configure: warning: $ac_option: invalid host type" 1>&2 + fi + if test "x$nonopt" != xNONE; then + { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } + fi + nonopt="$ac_option" + ;; + + esac +done + +if test -n "$ac_prev"; then + { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } +fi + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +# File descriptor usage: +# 0 standard input +# 1 file creation +# 2 errors and warnings +# 3 some systems may open it to /dev/tty +# 4 used on the Kubota Titan +# 6 checking for... messages and results +# 5 compiler messages saved in config.l... [truncated message content] |
From: Toni G. <zo...@us...> - 2003-11-01 17:23:40
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-01 17:23:39 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/adns/src added to the repository |
From: Toni G. <zo...@us...> - 2003-11-01 17:23:40
|
CVSROOT : /cvsroot/irc-dev Module : ircd-ircdev Commit time: 2003-11-01 17:23:39 UTC Log message: Directory /cvsroot/irc-dev/ircd-ircdev/libs/adns added to the repository |