|
From: | shishi-commit |
Subject: | Cleanup. |
Date: | Thu, 18 Dec 2003 11:36:14 +0100 |
Commit from jas | 2003-12-18 11:36 CET |
Cleanup.
Module | File name | Revision | |||
---|---|---|---|---|---|
shishi | src/shishid.c | 1.81 | >>> | 1.82 |
shishi/src/shishid.c 1.81 >>> 1.82 |
---|
Line 28 |
/* Get error. */ #include "error.h" |
- #define FAMILY_IPV4 "IPv4" - #define FAMILY_IPV6 "IPv6" - - #ifdef WITH_IPV6 - # define LISTEN_DEFAULT FAMILY_IPV4 ":*:kerberos/udp, " \ - FAMILY_IPV4 ":*:kerberos/tcp, " \ - FAMILY_IPV6 ":*:kerberos/udp, " \ - FAMILY_IPV6 ":*:kerberos/tcp" - #else - # define LISTEN_DEFAULT "*:kerberos/udp, *:kerberos/tcp" - #endif - |
+ /* Global variables. */ |
Shishi * handle; Shisa * dbh; struct gengetopt_args_info arg; struct listenspec *listenspec; char *fatal_krberror; size_t fatal_krberror_len; |
- |
#ifdef USE_STARTTLS |
- #define DH_BITS 1024 |
gnutls_dh_params dh_params; gnutls_anon_server_credentials anoncred; #endif |
+ /* Listen to all listenspec's, removing entries that fail. */ |
static void kdc_listen () { |
Line 118 |
printf ("Listening on %d ports...\n", maxfd); } |
+ /* Close open sockets, reporting any errors. */ |
static void kdc_unlisten (void) { |
Line 145 |
} } |
+ /* If requested, abandon user privileges. */ |
static void kdc_setuid (void) { |
Line 172 |
passwd->pw_name, passwd->pw_uid); } |
+ /* Create a hard coded error message that can be used in case kdc.c + fail to produce */ |
static int setup_fatal_krberror (Shishi * handle) { |
Line 195 |
return SHISHI_OK; } |
+ /* Core daemon part. Initialize and set up various things, and then + hand over control to kdc.c via kdc_loop, and cleaning up + afterwards. Note that kdc_loop only return when the process has + received SIGINT or SIGTERM. */ |
static void doit (void) { |
Line 287 |
shishi_done (handle); } |
+ #define FAMILY_IPV4 "IPv4" + #define FAMILY_IPV6 "IPv6" + + #ifdef WITH_IPV6 + # define LISTEN_DEFAULT FAMILY_IPV4 ":*:kerberos/udp, " \ + FAMILY_IPV4 ":*:kerberos/tcp, " \ + FAMILY_IPV6 ":*:kerberos/udp, " \ + FAMILY_IPV6 ":*:kerberos/tcp" + #else + # define LISTEN_DEFAULT "*:kerberos/udp, *:kerberos/tcp" + #endif + + /* Parse the --listen parameter, creating listenspec elements. */ |
static void parse_listen (char *listen) { |
[Prev in Thread] | Current Thread | [Next in Thread] |