home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / unix / volume26 / xinetd21 / part01 < prev    next >
Encoding:
Text File  |  1993-06-26  |  34.9 KB  |  1,285 lines

  1. Newsgroups: comp.sources.unix
  2. From: panos@cs.colorado.edu (Panos Tsirigotis)
  3. Subject: v26i245: xinetd-2.1.1 - inetd replacement with access control and logging, Part01/31
  4. Sender: unix-sources-moderator@gw.home.vix.com
  5. Approved: vixie@gw.home.vix.com
  6.  
  7. Submitted-By: panos@cs.colorado.edu (Panos Tsirigotis)
  8. Posting-Number: Volume 26, Issue 245
  9. Archive-Name: xinetd-2.1.1/part01
  10.  
  11. #! /bin/sh
  12. # This is a shell archive.  Remove anything before this line, then unpack
  13. # it by saving it into a file and typing "sh file".  To overwrite existing
  14. # files, type "sh file -c".  You can also feed this as standard input via
  15. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  16. # will see the following message at the end:
  17. #        "End of archive 1 (of 31)."
  18. # Contents:  README libs libs/include libs/lib libs/man libs/src
  19. #   libs/src/misc libs/src/misc/README libs/src/misc/ftwx.h
  20. #   libs/src/misc/misc.h libs/src/pq libs/src/pq/hpqimpl.h
  21. #   libs/src/pq/pq.c libs/src/pq/pq.h libs/src/pset
  22. #   libs/src/pset/ops.c libs/src/sio libs/src/sio/suite
  23. #   libs/src/sio/suite/buftest.c libs/src/sio/suite/example.c
  24. #   libs/src/sio/suite/testlib libs/src/sio/suite/tietest.c
  25. #   libs/src/str libs/src/str/CHANGELOG libs/src/str/ss_bmh.h
  26. #   libs/src/str/ss_kmp.h libs/src/str/ss_rk.h libs/src/str/ss_sbm.h
  27. #   libs/src/str/ss_so.h libs/src/timer libs/src/xlog
  28. #   libs/src/xlog/CHANGELOG libs/src/xlog/slog.h xinetd
  29. #   xinetd/BUG-REPORTS xinetd/addr.h xinetd/builtin.h xinetd/conf.h
  30. #   xinetd/flags.h xinetd/mask.h xinetd/parse.h xinetd/sconst.h
  31. # Wrapped by panos@mystique on Mon Jun 21 14:51:19 1993
  32. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  33. if test -f 'README' -a "${1}" != "-c" ; then 
  34.   echo shar: Will not clobber existing file \"'README'\"
  35. else
  36. echo shar: Extracting \"'README'\" \(2895 characters\)
  37. sed "s/^X//" >'README' <<'END_OF_FILE'
  38. X
  39. X======================================================================
  40. XATTENTION: vi users set your tabstop to 3 to make this file (and all
  41. X           other files) look nice on your screen
  42. X======================================================================
  43. X
  44. XQ. What is xinetd ?
  45. XA. xinetd is a replacement for inetd, the internet services daemon.
  46. X
  47. X
  48. XQ: I am not a system administrator; what do I care about an inetd replacement ?
  49. XA: xinetd is not just an inetd replacement. Anybody can use it to start servers
  50. X    that don't require privileged ports because xinetd does not require that the 
  51. X    services in its configuration file be listed in /etc/services.
  52. X
  53. X
  54. XQ. Is it compatible with inetd ?
  55. XA. No, its configuration file has a different format than inetd's one
  56. X   and it understands different signals. However the signal-to-action 
  57. X    assignment can be changed and a program has been included to convert 
  58. X    inetd.conf to xinetd.conf.
  59. X
  60. X
  61. XQ. Why should I use it ?
  62. XA. Because it is a lot better (IMHO) than inetd. Here are the reasons:
  63. X
  64. X      1) It can do access control on all services based on:
  65. X            a. address of remote host
  66. X            b. time of access
  67. X
  68. X      2) Access control works on all services, whether multi-threaded or
  69. X         single-threaded and for both the TCP and UDP protocols.
  70. X         All UDP packets can be checked as well as all TCP connections.
  71. X
  72. X      3) It provides hard reconfiguration:
  73. X            a. kills servers for services that are no longer in the
  74. X               configuration file
  75. X            b. kills servers that no longer meet the access control criteria
  76. X
  77. X      4) It can prevent denial-of-access attacks by
  78. X            a. placing limits on the number of servers for each service
  79. X               (avoids process table overflows)
  80. X            b. placing an upper bound on the number of processes it will fork
  81. X            c. placing limits on the size of log files it creates
  82. X
  83. X      5) Extensive logging abilities:
  84. X            a. for every server started it can log:
  85. X                    i) the time when the server was started
  86. X                   ii) the remote host address
  87. X                  iii) who was the remote user (if the other end runs a
  88. X                       RFC-931/RFC-1413 server)
  89. X                   iv) how long the server was running
  90. X               (i, ii and iii can be logged for failed attempts too).
  91. X            b. for some services, if the access control fails, it can
  92. X               log information about the attempted access (for example,
  93. X               it can log the user name and command for the rsh service)
  94. X
  95. X      6) No limit on number of server arguments
  96. X
  97. XQ. Where can I find the latest-and-greatest version ?
  98. XA. It should be available via anonymous FTP from mystique.cs.colorado.edu
  99. X    in the directory "pub/xinetd".
  100. X
  101. XQ. Whom should I thank/blame for this program ?
  102. XA. Any comments about xinetd should be sent to panos@cs.colorado.edu
  103. X
  104. END_OF_FILE
  105. if test 2895 -ne `wc -c <'README'`; then
  106.     echo shar: \"'README'\" unpacked with wrong size!
  107. fi
  108. # end of 'README'
  109. fi
  110. if test ! -d 'libs' ; then
  111.     echo shar: Creating directory \"'libs'\"
  112.     mkdir 'libs'
  113. fi
  114. if test ! -d 'libs/include' ; then
  115.     echo shar: Creating directory \"'libs/include'\"
  116.     mkdir 'libs/include'
  117. fi
  118. if test ! -d 'libs/lib' ; then
  119.     echo shar: Creating directory \"'libs/lib'\"
  120.     mkdir 'libs/lib'
  121. fi
  122. if test ! -d 'libs/man' ; then
  123.     echo shar: Creating directory \"'libs/man'\"
  124.     mkdir 'libs/man'
  125. fi
  126. if test ! -d 'libs/src' ; then
  127.     echo shar: Creating directory \"'libs/src'\"
  128.     mkdir 'libs/src'
  129. fi
  130. if test ! -d 'libs/src/misc' ; then
  131.     echo shar: Creating directory \"'libs/src/misc'\"
  132.     mkdir 'libs/src/misc'
  133. fi
  134. if test -f 'libs/src/misc/README' -a "${1}" != "-c" ; then 
  135.   echo shar: Will not clobber existing file \"'libs/src/misc/README'\"
  136. else
  137. echo shar: Extracting \"'libs/src/misc/README'\" \(439 characters\)
  138. sed "s/^X//" >'libs/src/misc/README' <<'END_OF_FILE'
  139. X
  140. X
  141. XThis library is made of 3 parts:
  142. X    ftwx, misc, env
  143. X
  144. Xenv is a collection of environment processing functions.
  145. Xmisc is a collection of miscellaneous functions.
  146. Xftwx is a replacement for the standard ftw(3) function.
  147. X
  148. XWhen installing this library you may need to define the following
  149. Xflags in the Makefile:
  150. X    OLD_DIR if your system does not have the file /usr/include/dirent.h
  151. X    __FTWX_NO_FTW if your system does not have the ftw(3) function
  152. X
  153. END_OF_FILE
  154. if test 439 -ne `wc -c <'libs/src/misc/README'`; then
  155.     echo shar: \"'libs/src/misc/README'\" unpacked with wrong size!
  156. fi
  157. # end of 'libs/src/misc/README'
  158. fi
  159. if test -f 'libs/src/misc/ftwx.h' -a "${1}" != "-c" ; then 
  160.   echo shar: Will not clobber existing file \"'libs/src/misc/ftwx.h'\"
  161. else
  162. echo shar: Extracting \"'libs/src/misc/ftwx.h'\" \(702 characters\)
  163. sed "s/^X//" >'libs/src/misc/ftwx.h' <<'END_OF_FILE'
  164. X/*
  165. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  166. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  167. X * and conditions for redistribution.
  168. X */
  169. X
  170. X
  171. X#ifndef __FTWX_H
  172. X#define __FTWX_H
  173. X
  174. X/*
  175. X * $Id: ftwx.h,v 2.1 1992/10/01 00:41:02 panos Exp $
  176. X */
  177. X
  178. X#ifndef __FTWX_NO_FTW
  179. X#include <ftw.h>
  180. X#else
  181. X#define FTW_F   0
  182. X#define FTW_D   1
  183. X#define FTW_DNR 2
  184. X#define FTW_NS  3
  185. X#endif
  186. X
  187. X
  188. X/*
  189. X * Flags
  190. X */
  191. X#define FTWX_ALL        -1
  192. X#define FTWX_FOLLOW     0x1
  193. X
  194. X
  195. X#ifdef __ARGS
  196. X#undef _ARGS
  197. X#endif
  198. X
  199. X#ifdef PROTOTYPES
  200. X#  define __ARGS( s )               s
  201. X#else
  202. X#  define __ARGS( s )               ()
  203. X#endif
  204. X
  205. Xint ftwx __ARGS( ( char *path, int (*func)(), int depth, int flags ) ) ;
  206. X
  207. X#endif     /* __FTWX_H */
  208. X
  209. END_OF_FILE
  210. if test 702 -ne `wc -c <'libs/src/misc/ftwx.h'`; then
  211.     echo shar: \"'libs/src/misc/ftwx.h'\" unpacked with wrong size!
  212. fi
  213. # end of 'libs/src/misc/ftwx.h'
  214. fi
  215. if test -f 'libs/src/misc/misc.h' -a "${1}" != "-c" ; then 
  216.   echo shar: Will not clobber existing file \"'libs/src/misc/misc.h'\"
  217. else
  218. echo shar: Extracting \"'libs/src/misc/misc.h'\" \(806 characters\)
  219. sed "s/^X//" >'libs/src/misc/misc.h' <<'END_OF_FILE'
  220. X/*
  221. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  222. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  223. X * and conditions for redistribution.
  224. X */
  225. X
  226. X
  227. X#ifndef __MISC_H
  228. X#define __MISC_H
  229. X
  230. X
  231. X/*
  232. X * $Id: misc.h,v 2.1 1992/10/01 00:41:34 panos Exp $
  233. X */
  234. X
  235. X/*
  236. X * Align to a power of 2
  237. X */
  238. X#define align2( num, al )                    (((num)+(al)-1) & ~((al)-1))
  239. X
  240. X#ifdef __ARGS
  241. X#undef __ARGS
  242. X#endif
  243. X
  244. X#ifdef PROTOTYPES
  245. X#   define __ARGS( s )               s
  246. X#else
  247. X#   define __ARGS( s )               ()
  248. X#endif
  249. X
  250. X
  251. Xchar *make_string __ARGS( ( unsigned count, ... ) ) ;
  252. Xchar *make_pathname __ARGS( ( unsigned count, ... ) ) ;
  253. X
  254. Xchar **argv_copy_and_clear __ARGS( ( char **argv, int start, int count ) ) ;
  255. Xchar *dirname __ARGS( ( char *pathname ) ) ;
  256. Xchar *basename __ARGS( ( char *pathname ) ) ;
  257. X
  258. X#endif     /* __MISC_H */
  259. X
  260. END_OF_FILE
  261. if test 806 -ne `wc -c <'libs/src/misc/misc.h'`; then
  262.     echo shar: \"'libs/src/misc/misc.h'\" unpacked with wrong size!
  263. fi
  264. # end of 'libs/src/misc/misc.h'
  265. fi
  266. if test ! -d 'libs/src/pq' ; then
  267.     echo shar: Creating directory \"'libs/src/pq'\"
  268.     mkdir 'libs/src/pq'
  269. fi
  270. if test -f 'libs/src/pq/hpqimpl.h' -a "${1}" != "-c" ; then 
  271.   echo shar: Will not clobber existing file \"'libs/src/pq/hpqimpl.h'\"
  272. else
  273. echo shar: Extracting \"'libs/src/pq/hpqimpl.h'\" \(785 characters\)
  274. sed "s/^X//" >'libs/src/pq/hpqimpl.h' <<'END_OF_FILE'
  275. X/*
  276. X * (c) Copyright 1993 by Panagiotis Tsirigotis
  277. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  278. X * and conditions for redistribution.
  279. X */
  280. X
  281. X/*
  282. X * $Id: hpqimpl.h,v 1.1 1992/11/23 16:25:25 panos Exp $
  283. X */
  284. X
  285. X#include "hpq.h"
  286. X
  287. Xtypedef struct __hpq_header header_s ;
  288. X
  289. X#define HHP( p )            ((header_s *)p)
  290. X
  291. X#define HANDLE_ERROR( flags, retval, errp, errval, msg )        \
  292. X                if ( flags & PQ_RETURN_ERROR )                        \
  293. X                {                                                                \
  294. X                    *errp = errval ;                                        \
  295. X                    return( retval ) ;                                    \
  296. X                }                                                                \
  297. X                else                                                            \
  298. X                {                                                                \
  299. X                    char *s = msg ;                                        \
  300. X                                                                                \
  301. X                    (void) write( 2, s, strlen( s ) ) ;                \
  302. X                    abort() ;                                                \
  303. X                    _exit( 1 ) ;                                             \
  304. X                    /* NOTREACHED */                                        \
  305. X                }
  306. X
  307. X
  308. END_OF_FILE
  309. if test 785 -ne `wc -c <'libs/src/pq/hpqimpl.h'`; then
  310.     echo shar: \"'libs/src/pq/hpqimpl.h'\" unpacked with wrong size!
  311. fi
  312. # end of 'libs/src/pq/hpqimpl.h'
  313. fi
  314. if test -f 'libs/src/pq/pq.c' -a "${1}" != "-c" ; then 
  315.   echo shar: Will not clobber existing file \"'libs/src/pq/pq.c'\"
  316. else
  317. echo shar: Extracting \"'libs/src/pq/pq.c'\" \(289 characters\)
  318. sed "s/^X//" >'libs/src/pq/pq.c' <<'END_OF_FILE'
  319. X/*
  320. X * (c) Copyright 1993 by Panagiotis Tsirigotis
  321. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  322. X * and conditions for redistribution.
  323. X */
  324. X
  325. Xstatic char RCSid[] = "$Id: pq.c,v 1.1 1992/11/23 16:25:25 panos Exp $" ;
  326. Xstatic char version[] = VERSION ;
  327. X
  328. Xint pq_errno ;
  329. X
  330. END_OF_FILE
  331. if test 289 -ne `wc -c <'libs/src/pq/pq.c'`; then
  332.     echo shar: \"'libs/src/pq/pq.c'\" unpacked with wrong size!
  333. fi
  334. # end of 'libs/src/pq/pq.c'
  335. fi
  336. if test -f 'libs/src/pq/pq.h' -a "${1}" != "-c" ; then 
  337.   echo shar: Will not clobber existing file \"'libs/src/pq/pq.h'\"
  338. else
  339. echo shar: Extracting \"'libs/src/pq/pq.h'\" \(686 characters\)
  340. sed "s/^X//" >'libs/src/pq/pq.h' <<'END_OF_FILE'
  341. X/*
  342. X * (c) Copyright 1993 by Panagiotis Tsirigotis
  343. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  344. X * and conditions for redistribution.
  345. X */
  346. X
  347. X#ifndef __PQ_H
  348. X#define __PQ_H
  349. X
  350. X/*
  351. X * $Id: pq.h,v 1.4 1993/04/01 02:14:52 panos Exp $
  352. X */
  353. X
  354. X/*
  355. X * Return values
  356. X */
  357. X#define PQ_OK            0
  358. X#define PQ_ERR            (-1)
  359. X
  360. Xextern int pq_errno ;
  361. X
  362. X/*
  363. X * pq_errno values
  364. X */
  365. X#define PQ_ENOERROR                0
  366. X#define PQ_ENOFUNC                1
  367. X#define PQ_ENOMEM                    2
  368. X#define PQ_ENULLOBJECT            3
  369. X#define PQ_ENOTFOUND                4
  370. X#define PQ_ENOTSUPPORTED        5
  371. X
  372. X/*
  373. X * flag values
  374. X */
  375. X#define PQ_NOFLAGS                0x0
  376. X#define PQ_RETURN_ERROR            0x1
  377. X
  378. Xtypedef void *pq_h ;
  379. Xtypedef void *pq_obj ;
  380. X
  381. X#include "hpq.h"
  382. X
  383. X#endif    /* __PQ_H */
  384. X
  385. END_OF_FILE
  386. if test 686 -ne `wc -c <'libs/src/pq/pq.h'`; then
  387.     echo shar: \"'libs/src/pq/pq.h'\" unpacked with wrong size!
  388. fi
  389. # end of 'libs/src/pq/pq.h'
  390. fi
  391. if test ! -d 'libs/src/pset' ; then
  392.     echo shar: Creating directory \"'libs/src/pset'\"
  393.     mkdir 'libs/src/pset'
  394. fi
  395. if test -f 'libs/src/pset/ops.c' -a "${1}" != "-c" ; then 
  396.   echo shar: Will not clobber existing file \"'libs/src/pset/ops.c'\"
  397. else
  398. echo shar: Extracting \"'libs/src/pset/ops.c'\" \(968 characters\)
  399. sed "s/^X//" >'libs/src/pset/ops.c' <<'END_OF_FILE'
  400. X/*
  401. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  402. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  403. X * and conditions for redistribution.
  404. X */
  405. X
  406. Xstatic char RCSid[] = "$Id: ops.c,v 3.1 1993/03/13 23:21:53 panos Exp $" ;
  407. X
  408. X#include "pset.h"
  409. X
  410. X#define PRIVATE                static
  411. X#define POINTER                __pset_pointer
  412. X
  413. X#ifndef NULL
  414. X#define NULL                    0
  415. X#endif
  416. X
  417. X
  418. X/*
  419. X * Remove all NULL pointers from a pset
  420. X */
  421. Xvoid pset_compact( pset )
  422. X    register pset_h pset ;
  423. X{
  424. X    register unsigned u ;
  425. X
  426. X    for ( u = 0 ; u < pset_count( pset ) ; )
  427. X        if ( pset_pointer( pset, u ) != NULL )
  428. X            u++ ;
  429. X        else
  430. X            pset_remove_index( pset, u ) ;
  431. X}
  432. X
  433. X
  434. X/*
  435. X * Apply a function to all pointers of a pset
  436. X */
  437. Xvoid pset_apply( pset, func, arg )
  438. X    register pset_h pset ;
  439. X    register void (*func)() ;
  440. X    register void *arg ;
  441. X{
  442. X    register unsigned u ;
  443. X
  444. X    for ( u = 0 ; u < pset_count( pset ) ; u++ )
  445. X        if ( arg )
  446. X            (*func)( arg, pset_pointer( pset, u ) ) ;
  447. X        else
  448. X            (*func)( pset_pointer( pset, u ) ) ;
  449. X}
  450. X
  451. END_OF_FILE
  452. if test 968 -ne `wc -c <'libs/src/pset/ops.c'`; then
  453.     echo shar: \"'libs/src/pset/ops.c'\" unpacked with wrong size!
  454. fi
  455. # end of 'libs/src/pset/ops.c'
  456. fi
  457. if test ! -d 'libs/src/sio' ; then
  458.     echo shar: Creating directory \"'libs/src/sio'\"
  459.     mkdir 'libs/src/sio'
  460. fi
  461. if test ! -d 'libs/src/sio/suite' ; then
  462.     echo shar: Creating directory \"'libs/src/sio/suite'\"
  463.     mkdir 'libs/src/sio/suite'
  464. fi
  465. if test -f 'libs/src/sio/suite/buftest.c' -a "${1}" != "-c" ; then 
  466.   echo shar: Will not clobber existing file \"'libs/src/sio/suite/buftest.c'\"
  467. else
  468. echo shar: Extracting \"'libs/src/sio/suite/buftest.c'\" \(748 characters\)
  469. sed "s/^X//" >'libs/src/sio/suite/buftest.c' <<'END_OF_FILE'
  470. X/*
  471. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  472. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  473. X * and conditions for redistribution.
  474. X */
  475. X
  476. Xstatic char RCSid[] = "$Id: buftest.c,v 8.1 1993/03/13 01:23:09 panos Exp $" ;
  477. X
  478. X#include "sio.h"
  479. X
  480. Xmain()
  481. X{
  482. X    int i ;
  483. X    int sleep_interval = 3 ;
  484. X
  485. X    if ( Sbuftype( 1, SIO_LINEBUF ) == SIO_ERR )
  486. X    {
  487. X        Sprint( 2, "Sbuftype failed\n" ) ;
  488. X        exit( 1 ) ;
  489. X    }
  490. X
  491. X    for ( i = 0 ; i < 10 ; i++ )
  492. X    {
  493. X        Sprint( 1, "Line %d\n", i ) ;
  494. X        if ( i == 5 )
  495. X        {
  496. X            Sprint( 1, "Now switching to full buffering\n" ) ;
  497. X            sleep_interval = 2 ;
  498. X            if ( Sbuftype( 1, SIO_FULLBUF ) == SIO_ERR )
  499. X            {
  500. X                Sprint( 2, "2nd Sbuftype failed\n" ) ;
  501. X                exit( 1 ) ;
  502. X            }
  503. X        }
  504. X        sleep( sleep_interval ) ;
  505. X    }
  506. X    exit( 0 ) ;
  507. X}
  508. X
  509. END_OF_FILE
  510. if test 748 -ne `wc -c <'libs/src/sio/suite/buftest.c'`; then
  511.     echo shar: \"'libs/src/sio/suite/buftest.c'\" unpacked with wrong size!
  512. fi
  513. # end of 'libs/src/sio/suite/buftest.c'
  514. fi
  515. if test -f 'libs/src/sio/suite/example.c' -a "${1}" != "-c" ; then 
  516.   echo shar: Will not clobber existing file \"'libs/src/sio/suite/example.c'\"
  517. else
  518. echo shar: Extracting \"'libs/src/sio/suite/example.c'\" \(569 characters\)
  519. sed "s/^X//" >'libs/src/sio/suite/example.c' <<'END_OF_FILE'
  520. X/*
  521. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  522. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  523. X * and conditions for redistribution.
  524. X */
  525. X
  526. Xstatic char RCSid[] = "$Id: example.c,v 8.1 1993/03/13 01:21:48 panos Exp $" ;
  527. X
  528. X#include "sio.h"
  529. X
  530. Xmain( argc, argv )
  531. X   int argc ;
  532. X   char *argv[] ;
  533. X{
  534. X   char *file = (argc > 1) ? argv[ 1 ] : "tee.file" ;
  535. X   int fd = creat( file, 0644 ) ;
  536. X   long length ;
  537. X   char *s ;
  538. X
  539. X   while ( s = Sfetch( 0, &length ) )
  540. X   {
  541. X      Swrite( 1, s, length ) ;
  542. X      Swrite( fd, s, length ) ;
  543. X   }
  544. X   exit( 0 ) ;
  545. X}
  546. X
  547. END_OF_FILE
  548. if test 569 -ne `wc -c <'libs/src/sio/suite/example.c'`; then
  549.     echo shar: \"'libs/src/sio/suite/example.c'\" unpacked with wrong size!
  550. fi
  551. # end of 'libs/src/sio/suite/example.c'
  552. fi
  553. if test -f 'libs/src/sio/suite/testlib' -a "${1}" != "-c" ; then 
  554.   echo shar: Will not clobber existing file \"'libs/src/sio/suite/testlib'\"
  555. else
  556. echo shar: Extracting \"'libs/src/sio/suite/testlib'\" \(877 characters\)
  557. sed "s/^X//" >'libs/src/sio/suite/testlib' <<'END_OF_FILE'
  558. X#!/bin/sh
  559. X
  560. X# (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  561. X# All rights reserved.  The file named COPYRIGHT specifies the terms 
  562. X# and conditions for redistribution.
  563. X
  564. X
  565. X#
  566. X# $Id: testlib,v 8.1 1993/03/13 01:23:48 panos Exp $
  567. X#
  568. X
  569. X#
  570. X# Purpose:
  571. X#        Invoke the tester script. This is necessary because the tester
  572. X#        script requires functions and /bin/sh does not support functions
  573. X#        on all OS's. This script decides what shell to use to execute
  574. X#        tester. On Suns, it uses /bin/sh. On DECstations, it uses
  575. X#        /usr/bin/ksh
  576. X#        The decision is made by checking $ARCH
  577. X#        
  578. X
  579. Xcase "$ARCH" in
  580. X    "")
  581. X        echo "ARCH not defined. Please define it."
  582. X        exit 1
  583. X        ;;
  584. X    
  585. X    sun4|sun3)
  586. X        TESTSHELL=/bin/sh
  587. X        LDFLAGS="-Bstatic -lm"
  588. X        ;;
  589. X
  590. X    dec-mips)
  591. X        TESTSHELL=/usr/bin/ksh
  592. X        LDFLAGS=
  593. X        ;;
  594. X
  595. X    *) echo "Unknown architecture: $ARCH"
  596. X        exit 2
  597. X        ;;
  598. Xesac
  599. X
  600. Xexport LDFLAGS
  601. Xexport TESTSHELL
  602. X$TESTSHELL tester $*
  603. X
  604. END_OF_FILE
  605. if test 877 -ne `wc -c <'libs/src/sio/suite/testlib'`; then
  606.     echo shar: \"'libs/src/sio/suite/testlib'\" unpacked with wrong size!
  607. fi
  608. # end of 'libs/src/sio/suite/testlib'
  609. fi
  610. if test -f 'libs/src/sio/suite/tietest.c' -a "${1}" != "-c" ; then 
  611.   echo shar: Will not clobber existing file \"'libs/src/sio/suite/tietest.c'\"
  612. else
  613. echo shar: Extracting \"'libs/src/sio/suite/tietest.c'\" \(669 characters\)
  614. sed "s/^X//" >'libs/src/sio/suite/tietest.c' <<'END_OF_FILE'
  615. X/*
  616. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  617. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  618. X * and conditions for redistribution.
  619. X */
  620. X
  621. Xstatic char RCSid[] = "$Id: tietest.c,v 8.1 1993/03/13 01:24:07 panos Exp $" ;
  622. X
  623. X#include "sio.h"
  624. X#include <stdio.h>
  625. X
  626. Xmain()
  627. X{
  628. X    char *s ;
  629. X
  630. X    Stie( 0, 1 ) ;
  631. X    Sprint( 1, "Enter 1st command --> " ) ;
  632. X    s = Srdline( 0 ) ;
  633. X    Sprint( 1, "Received command: %s\n", s ) ;
  634. X    Sprint( 1, "Enter 2nd command --> " ) ;
  635. X    s = Srdline( 0 ) ;
  636. X    Sprint( 1, "Received command: %s\n", s ) ;
  637. X    Suntie( 0 ) ;
  638. X    Sprint( 1, "Enter 3rd command --> " ) ;
  639. X    s = Srdline( 0 ) ;
  640. X    Sprint( 1, "Received command: %s\n", s ) ;
  641. X    exit( 0 ) ;
  642. X}
  643. END_OF_FILE
  644. if test 669 -ne `wc -c <'libs/src/sio/suite/tietest.c'`; then
  645.     echo shar: \"'libs/src/sio/suite/tietest.c'\" unpacked with wrong size!
  646. fi
  647. # end of 'libs/src/sio/suite/tietest.c'
  648. fi
  649. if test ! -d 'libs/src/str' ; then
  650.     echo shar: Creating directory \"'libs/src/str'\"
  651.     mkdir 'libs/src/str'
  652. fi
  653. if test -f 'libs/src/str/CHANGELOG' -a "${1}" != "-c" ; then 
  654.   echo shar: Will not clobber existing file \"'libs/src/str/CHANGELOG'\"
  655. else
  656. echo shar: Extracting \"'libs/src/str/CHANGELOG'\" \(437 characters\)
  657. sed "s/^X//" >'libs/src/str/CHANGELOG' <<'END_OF_FILE'
  658. X
  659. X1.2.0: 
  660. X    First release (as part of xinetd 1.3)
  661. X
  662. X1.3.2:
  663. X    Added the string matching functions
  664. X
  665. X1.3.3: (posted to alt.sources)
  666. X    Changed the way the library is configured
  667. X
  668. X1.4.0:
  669. X    Added the shift-or string matching algorithm
  670. X    Implemented the automatic switching to the proper search algorithm
  671. X    Added the STRS_NOSWITCH flag to disallow switching
  672. X    Added the STRS_PATLEN flag
  673. X
  674. X1.4.1:
  675. X    Moved definition of u_wide_int from ss_rk.h to ss_impl.h
  676. X
  677. END_OF_FILE
  678. if test 437 -ne `wc -c <'libs/src/str/CHANGELOG'`; then
  679.     echo shar: \"'libs/src/str/CHANGELOG'\" unpacked with wrong size!
  680. fi
  681. # end of 'libs/src/str/CHANGELOG'
  682. fi
  683. if test -f 'libs/src/str/ss_bmh.h' -a "${1}" != "-c" ; then 
  684.   echo shar: Will not clobber existing file \"'libs/src/str/ss_bmh.h'\"
  685. else
  686. echo shar: Extracting \"'libs/src/str/ss_bmh.h'\" \(366 characters\)
  687. sed "s/^X//" >'libs/src/str/ss_bmh.h' <<'END_OF_FILE'
  688. X/*
  689. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  690. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  691. X * and conditions for redistribution.
  692. X */
  693. X
  694. X#ifndef SS_BMH_H
  695. X#define SS_BMH_H
  696. X
  697. X/*
  698. X * $Id: ss_bmh.h,v 3.1 1993/06/13 02:42:53 panos Exp $
  699. X */
  700. X
  701. Xtypedef unsigned shift_int ;
  702. X
  703. Xstruct bmh_header
  704. X{
  705. X    shift_int *shift ;
  706. X} ;
  707. X
  708. X#endif    /* SS_BMH_H */
  709. X
  710. END_OF_FILE
  711. if test 366 -ne `wc -c <'libs/src/str/ss_bmh.h'`; then
  712.     echo shar: \"'libs/src/str/ss_bmh.h'\" unpacked with wrong size!
  713. fi
  714. # end of 'libs/src/str/ss_bmh.h'
  715. fi
  716. if test -f 'libs/src/str/ss_kmp.h' -a "${1}" != "-c" ; then 
  717.   echo shar: Will not clobber existing file \"'libs/src/str/ss_kmp.h'\"
  718. else
  719. echo shar: Extracting \"'libs/src/str/ss_kmp.h'\" \(381 characters\)
  720. sed "s/^X//" >'libs/src/str/ss_kmp.h' <<'END_OF_FILE'
  721. X/*
  722. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  723. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  724. X * and conditions for redistribution.
  725. X */
  726. X
  727. X#ifndef SS_KMP_H
  728. X#define SS_KMP_H
  729. X
  730. X/*
  731. X * $Id: ss_kmp.h,v 3.1 1993/06/13 02:44:52 panos Exp $
  732. X */
  733. X
  734. Xtypedef int next_int ;            /* must be signed */
  735. X
  736. Xstruct kmp_header
  737. X{
  738. X    next_int *next ;
  739. X} ;
  740. X
  741. X#endif    /* SS_KMP_H */
  742. X
  743. END_OF_FILE
  744. if test 381 -ne `wc -c <'libs/src/str/ss_kmp.h'`; then
  745.     echo shar: \"'libs/src/str/ss_kmp.h'\" unpacked with wrong size!
  746. fi
  747. # end of 'libs/src/str/ss_kmp.h'
  748. fi
  749. if test -f 'libs/src/str/ss_rk.h' -a "${1}" != "-c" ; then 
  750.   echo shar: Will not clobber existing file \"'libs/src/str/ss_rk.h'\"
  751. else
  752. echo shar: Extracting \"'libs/src/str/ss_rk.h'\" \(579 characters\)
  753. sed "s/^X//" >'libs/src/str/ss_rk.h' <<'END_OF_FILE'
  754. X/*
  755. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  756. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  757. X * and conditions for redistribution.
  758. X */
  759. X
  760. X#ifndef SS_RK_H
  761. X#define SS_RK_H
  762. X
  763. X/*
  764. X * $Id: ss_rk.h,v 3.2 1993/06/16 00:06:34 panos Exp $
  765. X */
  766. X
  767. Xstruct rk_header
  768. X{
  769. X    u_wide_int rk_digit1 ;                /* in the appropriate radix */
  770. X    u_wide_int rk_patval ;
  771. X} ;
  772. X
  773. X#if WIDE_INT_SIZE == 32
  774. X#    define PRIME                        16777213
  775. X#else
  776. X#    if WIDE_INT_SIZE == 16
  777. X#        define PRIME                    251
  778. X#    else
  779. X        int WIDE_INT_SIZE_has_bad_value = or_is_undefined ;
  780. X#    endif 
  781. X#endif
  782. X
  783. X#endif    /* SS_RK_H */
  784. X
  785. END_OF_FILE
  786. if test 579 -ne `wc -c <'libs/src/str/ss_rk.h'`; then
  787.     echo shar: \"'libs/src/str/ss_rk.h'\" unpacked with wrong size!
  788. fi
  789. # end of 'libs/src/str/ss_rk.h'
  790. fi
  791. if test -f 'libs/src/str/ss_sbm.h' -a "${1}" != "-c" ; then 
  792.   echo shar: Will not clobber existing file \"'libs/src/str/ss_sbm.h'\"
  793. else
  794. echo shar: Extracting \"'libs/src/str/ss_sbm.h'\" \(393 characters\)
  795. sed "s/^X//" >'libs/src/str/ss_sbm.h' <<'END_OF_FILE'
  796. X/*
  797. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  798. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  799. X * and conditions for redistribution.
  800. X */
  801. X
  802. X
  803. X#ifndef SS_SBM_H
  804. X#define SS_SBM_H
  805. X
  806. X/*
  807. X * $Id: ss_sbm.h,v 3.1 1993/06/13 02:46:00 panos Exp $
  808. X */
  809. X
  810. Xtypedef int last_int ;            /* must be signed */
  811. X
  812. Xstruct sbm_header
  813. X{
  814. X    last_int *last_occurrence ;
  815. X} ;
  816. X
  817. X#endif    /* SS_SBM_H */
  818. X
  819. END_OF_FILE
  820. if test 393 -ne `wc -c <'libs/src/str/ss_sbm.h'`; then
  821.     echo shar: \"'libs/src/str/ss_sbm.h'\" unpacked with wrong size!
  822. fi
  823. # end of 'libs/src/str/ss_sbm.h'
  824. fi
  825. if test -f 'libs/src/str/ss_so.h' -a "${1}" != "-c" ; then 
  826.   echo shar: Will not clobber existing file \"'libs/src/str/ss_so.h'\"
  827. else
  828. echo shar: Extracting \"'libs/src/str/ss_so.h'\" \(353 characters\)
  829. sed "s/^X//" >'libs/src/str/ss_so.h' <<'END_OF_FILE'
  830. X/*
  831. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  832. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  833. X * and conditions for redistribution.
  834. X */
  835. X
  836. X#ifndef SS_SO_H
  837. X#define SS_SO_H
  838. X
  839. X/*
  840. X * $Id: ss_so.h,v 3.1 1993/06/13 02:46:47 panos Exp $
  841. X */
  842. X
  843. Xstruct so_header
  844. X{
  845. X    wide_int *mask ;
  846. X    wide_int offset_mask ;
  847. X} ;
  848. X
  849. X#endif     /* SS_SO_H */
  850. END_OF_FILE
  851. if test 353 -ne `wc -c <'libs/src/str/ss_so.h'`; then
  852.     echo shar: \"'libs/src/str/ss_so.h'\" unpacked with wrong size!
  853. fi
  854. # end of 'libs/src/str/ss_so.h'
  855. fi
  856. if test ! -d 'libs/src/timer' ; then
  857.     echo shar: Creating directory \"'libs/src/timer'\"
  858.     mkdir 'libs/src/timer'
  859. fi
  860. if test ! -d 'libs/src/xlog' ; then
  861.     echo shar: Creating directory \"'libs/src/xlog'\"
  862.     mkdir 'libs/src/xlog'
  863. fi
  864. if test -f 'libs/src/xlog/CHANGELOG' -a "${1}" != "-c" ; then 
  865.   echo shar: Will not clobber existing file \"'libs/src/xlog/CHANGELOG'\"
  866. else
  867. echo shar: Extracting \"'libs/src/xlog/CHANGELOG'\" \(229 characters\)
  868. sed "s/^X//" >'libs/src/xlog/CHANGELOG' <<'END_OF_FILE'
  869. X
  870. X1.0.8:
  871. X    First release
  872. X
  873. X1.0.9:
  874. X    Fixed bug in the syslog xlogs.
  875. X
  876. X1.1.2:
  877. X    * Timestamps are now always included
  878. X    * If NO_SYSLOG is defined, syslog xlogs become unavailable (this was
  879. X      available in 1.0.9 but it didn't work right).
  880. X
  881. END_OF_FILE
  882. if test 229 -ne `wc -c <'libs/src/xlog/CHANGELOG'`; then
  883.     echo shar: \"'libs/src/xlog/CHANGELOG'\" unpacked with wrong size!
  884. fi
  885. # end of 'libs/src/xlog/CHANGELOG'
  886. fi
  887. if test -f 'libs/src/xlog/slog.h' -a "${1}" != "-c" ; then 
  888.   echo shar: Will not clobber existing file \"'libs/src/xlog/slog.h'\"
  889. else
  890. echo shar: Extracting \"'libs/src/xlog/slog.h'\" \(616 characters\)
  891. sed "s/^X//" >'libs/src/xlog/slog.h' <<'END_OF_FILE'
  892. X/*
  893. X * (c) Copyright 1992, 1993 by Panagiotis Tsirigotis
  894. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  895. X * and conditions for redistribution.
  896. X */
  897. X
  898. X
  899. X/*
  900. X * $Id: slog.h,v 2.1 1993/05/06 07:39:39 panos Exp $
  901. X */
  902. X
  903. X
  904. Xstruct syslog
  905. X{
  906. X    int sl_facility ;
  907. X    int sl_default_level ;
  908. X} ;
  909. X
  910. X
  911. Xstruct syslog_parms
  912. X{
  913. X   int         slp_n_xlogs ;              /* # of xlogs using syslog */
  914. X   int         slp_logopts ;              /* used at openlog */
  915. X   int         slp_facility ;
  916. X   char        *slp_ident ;                    /* used at openlog */
  917. X    bool_int slp_ident_is_malloced ;
  918. X} ;
  919. X
  920. X#define SYSLOG( xp )         ((struct syslog *)xp->xl_data)
  921. X
  922. END_OF_FILE
  923. if test 616 -ne `wc -c <'libs/src/xlog/slog.h'`; then
  924.     echo shar: \"'libs/src/xlog/slog.h'\" unpacked with wrong size!
  925. fi
  926. # end of 'libs/src/xlog/slog.h'
  927. fi
  928. if test ! -d 'xinetd' ; then
  929.     echo shar: Creating directory \"'xinetd'\"
  930.     mkdir 'xinetd'
  931. fi
  932. if test -f 'xinetd/BUG-REPORTS' -a "${1}" != "-c" ; then 
  933.   echo shar: Will not clobber existing file \"'xinetd/BUG-REPORTS'\"
  934. else
  935. echo shar: Extracting \"'xinetd/BUG-REPORTS'\" \(312 characters\)
  936. sed "s/^X//" >'xinetd/BUG-REPORTS' <<'END_OF_FILE'
  937. X
  938. XYou can report bugs in xinetd by sending mail to: panos@cs.colorado.edu
  939. X
  940. XIn your message please include:
  941. X    1. A description of the bug
  942. X    2. Any relevant log portions
  943. X    3. The version of xinetd and accompanying libraries. You can use the 
  944. X        following command to obtain this info:
  945. X                strings xinetd | grep Version
  946. X
  947. END_OF_FILE
  948. if test 312 -ne `wc -c <'xinetd/BUG-REPORTS'`; then
  949.     echo shar: \"'xinetd/BUG-REPORTS'\" unpacked with wrong size!
  950. fi
  951. # end of 'xinetd/BUG-REPORTS'
  952. fi
  953. if test -f 'xinetd/addr.h' -a "${1}" != "-c" ; then 
  954.   echo shar: Will not clobber existing file \"'xinetd/addr.h'\"
  955. else
  956. echo shar: Extracting \"'xinetd/addr.h'\" \(460 characters\)
  957. sed "s/^X//" >'xinetd/addr.h' <<'END_OF_FILE'
  958. X/*
  959. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  960. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  961. X * and conditions for redistribution.
  962. X */
  963. X
  964. X#ifndef ADDR_H
  965. X#define ADDR_H
  966. X
  967. X/*
  968. X * $Id: addr.h,v 6.2 1993/06/06 00:06:02 panos Exp $
  969. X */
  970. X
  971. X#include "defs.h"
  972. X
  973. Xbool_int        addrlist_match() ;
  974. Xvoid            addrlist_dump() ;
  975. Xvoid            addrlist_free() ;
  976. Xstatus_e        addrlist_add() ;
  977. Xstatus_e        addrlist_remove() ;
  978. Xstatus_e        addrlist_copy() ;
  979. X
  980. X#endif    /* ADDR_H */
  981. END_OF_FILE
  982. if test 460 -ne `wc -c <'xinetd/addr.h'`; then
  983.     echo shar: \"'xinetd/addr.h'\" unpacked with wrong size!
  984. fi
  985. # end of 'xinetd/addr.h'
  986. fi
  987. if test -f 'xinetd/builtin.h' -a "${1}" != "-c" ; then 
  988.   echo shar: Will not clobber existing file \"'xinetd/builtin.h'\"
  989. else
  990. echo shar: Extracting \"'xinetd/builtin.h'\" \(966 characters\)
  991. sed "s/^X//" >'xinetd/builtin.h' <<'END_OF_FILE'
  992. X/*
  993. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  994. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  995. X * and conditions for redistribution.
  996. X */
  997. X
  998. X#ifndef BUILTIN_H
  999. X#define BUILTIN_H
  1000. X
  1001. X/*
  1002. X * $Id: builtin.h,v 6.1 1993/04/04 19:42:53 panos Exp $
  1003. X */
  1004. X
  1005. X#include "defs.h"
  1006. X
  1007. X#define FORK                YES
  1008. X#define NO_FORK            NO
  1009. X
  1010. Xstruct builtin
  1011. X{
  1012. X   voidfunc        b_handler ;                    /* builtin service handler             */
  1013. X   boolean_e    b_fork_server ;            /* whether a server must be forked    */
  1014. X} ;
  1015. X
  1016. Xtypedef struct builtin builtin_s ;
  1017. X
  1018. X/*
  1019. X * All builtins are invoked with a struct server argument
  1020. X */
  1021. X#define builtin_invoke( bp, serp )        (*(bp)->b_handler)( serp )
  1022. X#define builtin_forks( bp )                ( (bp)->b_fork_server == YES )
  1023. X
  1024. X
  1025. Xstruct builtin_service
  1026. X{
  1027. X   char            *bs_name ;                    /* for identification purposes        */
  1028. X   int            bs_socket_type ;            /* for identification purposes        */
  1029. X    builtin_s    bs_handle ;
  1030. X} ;
  1031. X
  1032. Xbuiltin_s *builtin_find() ;
  1033. Xbuiltin_s *builtin_lookup() ;
  1034. X
  1035. X#endif    /* BUILTIN_H */
  1036. X
  1037. END_OF_FILE
  1038. if test 966 -ne `wc -c <'xinetd/builtin.h'`; then
  1039.     echo shar: \"'xinetd/builtin.h'\" unpacked with wrong size!
  1040. fi
  1041. # end of 'xinetd/builtin.h'
  1042. fi
  1043. if test -f 'xinetd/conf.h' -a "${1}" != "-c" ; then 
  1044.   echo shar: Will not clobber existing file \"'xinetd/conf.h'\"
  1045. else
  1046. echo shar: Extracting \"'xinetd/conf.h'\" \(708 characters\)
  1047. sed "s/^X//" >'xinetd/conf.h' <<'END_OF_FILE'
  1048. X/*
  1049. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  1050. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  1051. X * and conditions for redistribution.
  1052. X */
  1053. X
  1054. X#ifndef CONF_H
  1055. X#define CONF_H
  1056. X
  1057. X/*
  1058. X * $Id: conf.h,v 6.2 1993/05/19 00:46:05 panos Exp $
  1059. X */
  1060. X
  1061. X#include "pset.h"
  1062. X
  1063. X#include "sconf.h"
  1064. X
  1065. Xstruct configuration
  1066. X{
  1067. X    pset_h cnf_service_confs ;
  1068. X    struct service_config *cnf_defaults ;
  1069. X} ;
  1070. X
  1071. X#define CNF_DEFAULTS( confp )            (confp)->cnf_defaults
  1072. X#define CNF_SERVICE_CONFS( confp )    (confp)->cnf_service_confs
  1073. X
  1074. Xstatus_e                     cnf_get() ;
  1075. Xstatus_e                        cnf_init() ;
  1076. Xvoid                             cnf_free() ;
  1077. Xvoid                            cnf_dump() ;
  1078. Xstruct service_config    *cnf_extract() ;
  1079. Xunsigned                        cnf_start_services() ;
  1080. X
  1081. X#endif     /* CONF_H */
  1082. X
  1083. END_OF_FILE
  1084. if test 708 -ne `wc -c <'xinetd/conf.h'`; then
  1085.     echo shar: \"'xinetd/conf.h'\" unpacked with wrong size!
  1086. fi
  1087. # end of 'xinetd/conf.h'
  1088. fi
  1089. if test -f 'xinetd/flags.h' -a "${1}" != "-c" ; then 
  1090.   echo shar: Will not clobber existing file \"'xinetd/flags.h'\"
  1091. else
  1092. echo shar: Extracting \"'xinetd/flags.h'\" \(547 characters\)
  1093. sed "s/^X//" >'xinetd/flags.h' <<'END_OF_FILE'
  1094. X/*
  1095. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  1096. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  1097. X * and conditions for redistribution.
  1098. X */
  1099. X
  1100. X#ifndef FLAGS_H
  1101. X#define FLAGS_H
  1102. X
  1103. X/*
  1104. X * $Id: flags.h,v 6.2 1993/04/22 23:37:35 panos Exp $
  1105. X */
  1106. X
  1107. X/*
  1108. X * Flags
  1109. X */
  1110. X#define SOFT_RECONFIG_FLAG            1
  1111. X#define HARD_RECONFIG_FLAG            2
  1112. X#define TERMINATE_FLAG                3
  1113. X#define DUMP_FLAG                        4
  1114. X#define RETRY_FLAG                    5
  1115. X#define CONSISTENCY_FLAG            6
  1116. X#define CHILD_FLAG                    7
  1117. X#define QUIT_FLAG                        8
  1118. X#define PERIODIC_CHECK_FLAG        9
  1119. X
  1120. X#endif    /* FLAGS_H */
  1121. END_OF_FILE
  1122. if test 547 -ne `wc -c <'xinetd/flags.h'`; then
  1123.     echo shar: \"'xinetd/flags.h'\" unpacked with wrong size!
  1124. fi
  1125. # end of 'xinetd/flags.h'
  1126. fi
  1127. if test -f 'xinetd/mask.h' -a "${1}" != "-c" ; then 
  1128.   echo shar: Will not clobber existing file \"'xinetd/mask.h'\"
  1129. else
  1130. echo shar: Extracting \"'xinetd/mask.h'\" \(986 characters\)
  1131. sed "s/^X//" >'xinetd/mask.h' <<'END_OF_FILE'
  1132. X/*
  1133. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  1134. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  1135. X * and conditions for redistribution.
  1136. X */
  1137. X
  1138. X#ifndef MASK_H
  1139. X#define MASK_H
  1140. X
  1141. X/*
  1142. X * $Id: mask.h,v 6.1 1993/04/04 19:46:50 panos Exp $
  1143. X */
  1144. X
  1145. X/*
  1146. X * Macros about masks
  1147. X */
  1148. X
  1149. Xtypedef unsigned mask_t ;
  1150. X
  1151. X#define MASK_EMPTY                                0
  1152. X#define MASK_NULL                                    ((mask_t *)0)
  1153. X
  1154. X#define MASK( v )                                    ( 1 << ( (v)-1 ) )
  1155. X
  1156. X#define M_CLEAR_ALL( mask )                    (mask) = 0
  1157. X#define M_ASSIGN( mask1, mask2 )                (mask1) = (mask2)
  1158. X#define M_ARE_ALL_CLEAR( mask )                ( (mask) == 0 )
  1159. X#define M_SET( mask, v )                        (mask) |= MASK(v)
  1160. X#define M_CLEAR( mask, v )                        (mask) &= ~MASK(v)
  1161. X#define M_IS_SET( mask, v )                    ( (mask) & MASK(v) )
  1162. X#define M_IS_CLEAR( mask, v )                    ( ! M_IS_SET( mask, v ) )
  1163. X
  1164. X#define M_AND( mres, m1, m2 )                    ( (mres) = (m1) & (m2) )
  1165. X#define M_OR( mres, m1, m2 )                    ( (mres) = (m1) | (m2) )
  1166. X#define M_XOR( mres, m1, m2 )                    ( (mres) = (m1) ^ (m2) )
  1167. X
  1168. X#endif    /* MASK_H */
  1169. END_OF_FILE
  1170. if test 986 -ne `wc -c <'xinetd/mask.h'`; then
  1171.     echo shar: \"'xinetd/mask.h'\" unpacked with wrong size!
  1172. fi
  1173. # end of 'xinetd/mask.h'
  1174. fi
  1175. if test -f 'xinetd/parse.h' -a "${1}" != "-c" ; then 
  1176.   echo shar: Will not clobber existing file \"'xinetd/parse.h'\"
  1177. else
  1178. echo shar: Extracting \"'xinetd/parse.h'\" \(898 characters\)
  1179. sed "s/^X//" >'xinetd/parse.h' <<'END_OF_FILE'
  1180. X/*
  1181. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  1182. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  1183. X * and conditions for redistribution.
  1184. X */
  1185. X
  1186. X#ifndef PARSE_H
  1187. X#define PARSE_H
  1188. X
  1189. X#include "defs.h"
  1190. X
  1191. X/*
  1192. X * $Id: parse.h,v 6.2 1993/06/01 22:54:25 panos Exp $
  1193. X */
  1194. X
  1195. Xtypedef enum { NO_ENTRY, BAD_ENTRY, SERVICE_ENTRY, DEFAULTS_ENTRY } entry_e ;
  1196. X
  1197. Xenum assign_op { SET_EQ, PLUS_EQ, MINUS_EQ } ;
  1198. X
  1199. Xstruct attribute
  1200. X{
  1201. X   char        *a_name ;            /* name of attribute                            */
  1202. X   unsigned a_id ;               /* attribute id                                */
  1203. X   int        a_nvalues ;                /* number of values                            */
  1204. X   status_e (*a_parser)() ;        /* function that parses the attribute    */
  1205. X} ;
  1206. X
  1207. X
  1208. X#define ENTRY_BEGIN              '{'
  1209. X#define ENTRY_END                '}'
  1210. X#define COMMENT_BEGIN            '#'
  1211. X#define KW_SERVICE                    "service"
  1212. X#define KW_DEFAULTS                    "defaults"
  1213. X
  1214. Xextern int line_count ;
  1215. X
  1216. X#endif    /* PARSE_H */
  1217. X
  1218. END_OF_FILE
  1219. if test 898 -ne `wc -c <'xinetd/parse.h'`; then
  1220.     echo shar: \"'xinetd/parse.h'\" unpacked with wrong size!
  1221. fi
  1222. # end of 'xinetd/parse.h'
  1223. fi
  1224. if test -f 'xinetd/sconst.h' -a "${1}" != "-c" ; then 
  1225.   echo shar: Will not clobber existing file \"'xinetd/sconst.h'\"
  1226. else
  1227. echo shar: Extracting \"'xinetd/sconst.h'\" \(688 characters\)
  1228. sed "s/^X//" >'xinetd/sconst.h' <<'END_OF_FILE'
  1229. X/*
  1230. X * (c) Copyright 1992 by Panagiotis Tsirigotis
  1231. X * All rights reserved.  The file named COPYRIGHT specifies the terms 
  1232. X * and conditions for redistribution.
  1233. X */
  1234. X
  1235. X#ifndef SCONST_H
  1236. X#define SCONST_H
  1237. X
  1238. X/*
  1239. X * $Id: sconst.h,v 6.3 1993/04/22 23:42:22 panos Exp $
  1240. X */
  1241. X
  1242. X/*
  1243. X * Names of internal non-visible services
  1244. X */
  1245. X#define INTERCEPT_SERVICE_NAME            "intercept"
  1246. X#define LOG_SERVICE_NAME                    "logging"
  1247. X#define SHUTDOWN_SERVICE_NAME                "shutdown"
  1248. X
  1249. X
  1250. X/*
  1251. X * Log entry ids
  1252. X */
  1253. X#define START_ENTRY                            "START"
  1254. X#define FAIL_ENTRY                            "FAIL"
  1255. X#define EXIT_ENTRY                            "EXIT"
  1256. X#define DATA_ENTRY                            "DATA"
  1257. X#define USERID_ENTRY                            "USERID"
  1258. X#define NOID_ENTRY                            "NOID"
  1259. X
  1260. X#endif     /* SCONST_H */
  1261. X
  1262. END_OF_FILE
  1263. if test 688 -ne `wc -c <'xinetd/sconst.h'`; then
  1264.     echo shar: \"'xinetd/sconst.h'\" unpacked with wrong size!
  1265. fi
  1266. # end of 'xinetd/sconst.h'
  1267. fi
  1268. echo shar: End of archive 1 \(of 31\).
  1269. cp /dev/null ark1isdone
  1270. MISSING=""
  1271. for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 ; do
  1272.     if test ! -f ark${I}isdone ; then
  1273.     MISSING="${MISSING} ${I}"
  1274.     fi
  1275. done
  1276. if test "${MISSING}" = "" ; then
  1277.     echo You have unpacked all 31 archives.
  1278.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  1279. else
  1280.     echo You still need to unpack the following archives:
  1281.     echo "        " ${MISSING}
  1282. fi
  1283. ##  End of shell archive.
  1284. exit 0
  1285.