]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
almost editorial stuff
authorFrancis Dupont <fdupont@isc.org>
Fri, 30 Nov 2007 21:51:43 +0000 (21:51 +0000)
committerFrancis Dupont <fdupont@isc.org>
Fri, 30 Nov 2007 21:51:43 +0000 (21:51 +0000)
25 files changed:
client/dhc6.c
client/dhclient.c
common/options.c
common/packet.c
common/parse.c
common/resolv.c
common/socket.c
common/tables.c
dst/dst_api.c
dst/dst_internal.h
dst/dst_support.c
dst/hmac_link.c
dst/md5.h
dst/md5_dgst.c
dst/md5_locl.h
dst/prandom.c
includes/dhcpd.h
omapip/dispatch.c
relay/dhcrelay.c
server/confpars.c
server/dhcpd.c
server/dhcpleasequery.c
server/dhcpv6.c
server/failover.c
server/mdb.c

index 4001c0eb72a9c37ef73188fd776f2a2bd00fb174..ad9c3c62d9936655c788cfbf92df0285cd1f0f05 100644 (file)
@@ -969,7 +969,7 @@ do_init6(void *input)
        else
                client->elapsed = elapsed * 100;
 
-       log_debug("XMT: Forming Solicit, %u ms elapsed.",
+       log_debug("XMT: Forming Solicit, %u0 ms elapsed.",
                  (unsigned)client->elapsed);
 
        client->elapsed = htons(client->elapsed);
@@ -1144,7 +1144,7 @@ do_confirm6(void *input)
        else
                client->elapsed = elapsed * 100;
 
-       log_debug("XMT: Forming Confirm, %u ms elapsed.",
+       log_debug("XMT: Forming Confirm, %u0 ms elapsed.",
                  (unsigned)client->elapsed);
 
        client->elapsed = htons(client->elapsed);
@@ -2069,7 +2069,7 @@ do_select6(void *input)
        else
                client->elapsed = elapsed * 100;
 
-       log_debug("XMT: Forming Request, %u ms elapsed.",
+       log_debug("XMT: Forming Request, %u0 ms elapsed.",
                  (unsigned)client->elapsed);
 
        client->elapsed = htons(client->elapsed);
@@ -2951,7 +2951,7 @@ do_refresh6(void *input)
        else
                client->elapsed = elapsed * 100;
 
-       log_debug("XMT: Forming %s, %u ms elapsed.",
+       log_debug("XMT: Forming %s, %u0 ms elapsed.",
                  dhcpv6_type_names[client->refresh_type],
                  (unsigned)client->elapsed);
 
index 9798119f2be1eba5d7e9e203aa440e175c574aef..6b0bd0a4830e2d6903c03e8eab8c010ab2a6808d 100644 (file)
@@ -106,7 +106,7 @@ main(int argc, char **argv) {
 
         /* Make sure that file descriptors 0 (stdin), 1, (stdout), and
            2 (stderr) are open. To do this, we assume that when we
-           open a file the lowest available file decriptor is used. */
+           open a file the lowest available file descriptor is used. */
         fd = open("/dev/null", O_RDWR);
         if (fd == 0)
                 fd = open("/dev/null", O_RDWR);
@@ -1201,7 +1201,7 @@ dhcpv6(struct packet *packet) {
                }
        }
 
-       /* XXX: temporary log for debuggin */
+       /* XXX: temporary log for debugging */
        log_info("Packet received, but nothing done with it.");
 }
 #endif /* DHCPv6 */
@@ -3346,7 +3346,7 @@ isc_result_t dhcp_set_control_state (control_object_state_t oldstate,
        return ISC_R_SUCCESS;
 }
 
-/* Schedule updates to retry occaisionally until it no longer times out.
+/* Schedule updates to retry occasionally until it no longer times out.
  */
 void
 dhclient_schedule_updates(struct client_state *client, struct iaddr *addr,
index d8b7026c2b68c18f19aa90db7f5bc720295ddb16..101bfb504d636f4e63167f26902e730eb72fdfe9 100644 (file)
@@ -163,7 +163,7 @@ int parse_option_buffer (options, buffer, length, universe)
                 * have a length field, unless it's a DHCPv6 zero-length
                 * options space (eg any of the enterprise-id'd options).
                 *
-                * Zero-length-size option spaces basicaly consume the
+                * Zero-length-size option spaces basically consume the
                 * entire options buffer, so have at it.
                 */
                if (universe->get_length != NULL)
@@ -597,7 +597,7 @@ cons_options(struct packet *inpacket, struct dhcp_packet *outpacket,
         * If answering a client message, see whether any relay agent
         * options were included with the message.  If so, save them
         * to copy back in later, and make space in the main buffer
-        * to accomodate them
+        * to accommodate them
         */
        if (client_state == NULL) {
                priority_list[0] = DHO_DHCP_AGENT_OPTIONS;
@@ -811,7 +811,7 @@ cons_options(struct packet *inpacket, struct dhcp_packet *outpacket,
                        memcpy(&buffer[index], agentopts, agent_size);
                        index += agent_size;
                } else
-                       log_error("Unable to store relay agent information"
+                       log_error("Unable to store relay agent information "
                                  "in reply packet.");
        }
 
@@ -1326,7 +1326,7 @@ store_options(int *ocount,
                    length += encapsulation.len;
 
                    /* od.len can be nonzero if we got here without an
-                    * oc (cache lookup failed), but did have an enapculated
+                    * oc (cache lookup failed), but did have an encapsulated
                     * simple encapsulation space.
                     */
                    if (!od.len) {
@@ -2229,7 +2229,7 @@ prepare_option_buffer(struct universe *universe, struct buffer *bp,
                break;
 
              default:
-               log_fatal("Inconstent universe tag size at %s:%d.", MDL);
+               log_fatal("Inconsistent universe tag size at %s:%d.", MDL);
        }
 
        option_code_hash_lookup(&option, universe->code_hash, &code, 0, MDL);
@@ -3313,7 +3313,7 @@ fqdn6_universe_decode(struct option_state *options,
 
        /* Save the contents of the option in a buffer.  There are 3
         * one-byte values we record from the packet, so we go ahead
-        * and allocate a bigger buffer to accomodate them.  But the
+        * and allocate a bigger buffer to accommodate them.  But the
         * 'length' we got (because it is a DNS encoded string) is
         * one longer than we need...so we only add two extra octets.
         */
index 3b2c1be9900ecdcd4d7d8e7232efb46f6424b255..3e1c91b44c0626fef05a433420564441f00f9b48 100644 (file)
@@ -250,7 +250,7 @@ decode_udp_ip_header(struct interface_info *interface,
   if ((upp + sizeof(udp)) > endbuf)
          return -1;
 
-  /* Copy the UDP header into a stack alined structure for inspection. */
+  /* Copy the UDP header into a stack aligned structure for inspection. */
   memcpy(&udp, upp, sizeof(udp));
 
 #ifdef USERLAND_FILTER
index 6171cd3802488092458c4fb17fb6bb8f8abd7b13..befebd75108570966c83849dd7a6c3426b9ac825 100644 (file)
@@ -338,7 +338,7 @@ int parse_ip_addr (cfile, addr)
 }      
 
 /*
- * Return true if every character in the string is hexidecimal.
+ * Return true if every character in the string is hexadecimal.
  */
 static int
 is_hex_string(const char *s) {
index 572ca026d7bbb23270c7e8a8b181445e86957d4f..940435e1a48cbe7ea563b13d4fab99bb04cc8335 100644 (file)
@@ -147,7 +147,7 @@ void read_resolv_conf (parse_time)
                        /* We can't actually free the name server structure,
                           because somebody might be hanging on to it.    If
                           your /etc/resolv.conf file changes a lot, this
-                          could be a noticable memory leak. */
+                          could be a noticeable memory leak. */
                } else
                        sl = sp;
        }
index b3d4ef3e7205547727a1a2b91107c155585fa825..8058c286ab22f1df69826b3a2e25b20921ea97e3 100644 (file)
@@ -413,7 +413,7 @@ ssize_t send_packet (interface, packet, raw, len, from, to, hto)
 #ifdef DHCPv6
 /* 
  * For both send_packet6() and receive_packet6() we need to use the 
- * sendmsg()/recvmsg() functions rather than the simplier send()/recv()
+ * sendmsg()/recvmsg() functions rather than the simpler send()/recv()
  * functions.
  *
  * In the case of send_packet6(), we need to do this in order to insure
index a11f3c6244bcfa18a9bacf3f86fca7fdf7195005..b4e95939db21ca9f4d584dc8a2a309ee6f633993 100644 (file)
@@ -403,7 +403,7 @@ static struct option dhcpv6_options[] = {
         * intents and purposes we only need to treat the entire field
         * like a globally unique identifier (and if we create such an
         * option, ensure the first 4 bytes are our enterprise-id followed
-        * by a globlaly unique ID so long as you're within that enterprise
+        * by a globally unique ID so long as you're within that enterprise
         * id).  So we'll use "X" for now unless someone grumbles.
         */
        { "remote-id", "X",                     &dhcpv6_universe, 37, 1 },
@@ -469,7 +469,7 @@ struct enumeration_value dhcpv6_message_values[] = {
        { "RECONFIGURE", 10 },
        { "INFORMATION-REQUEST", 11 },
        { "RELAY-FORW", 12 },
-       { "RELY-REPL", 13 },
+       { "RELAY-REPL", 13 },
        { NULL, 0 }
 };
 
@@ -866,7 +866,7 @@ void initialize_common_option_spaces()
         * universe as they're configured - except during startup.
         * Since we know how many we put down in .c files, we can
         * allocate a more-than-right-sized buffer now, leaving some
-        * space for user-configged option spaces.
+        * space for user-configured option spaces.
         *
         * 1: dhcp_universe (dhcpv4 options)
         * 2: nwip_universe (dhcpv4 NWIP option)
@@ -1341,7 +1341,7 @@ void initialize_common_option_spaces()
                          &vsio_universe, MDL);
        universe_hash_add(universe_hash, isc6_universe.name, 0,
                          &isc6_universe, MDL);
-/* This should not be neccessary.  Listing here just for consistency.
+/* This should not be necessary.  Listing here just for consistency.
  *     universe_hash_add(universe_hash, fqdn6_universe.name, 0,
  *                       &fqdn6_universe, MDL);
  */
index d9b7c395e91fc24b56eadd9829d26a359bbb74ec..fff072573c54c9ed34e2888e54d2e601e7e9686c 100644 (file)
@@ -1,5 +1,5 @@
 #ifndef LINT
-static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_api.c,v 1.5 2007/09/05 17:32:10 dhankins Exp $";
+static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_api.c,v 1.6 2007/11/30 21:51:43 fdupont Exp $";
 #endif
 
 /*
@@ -24,7 +24,7 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_api.c,v 1.5 2007
  * This is the only file that needs to be changed if the crypto system is
  * changed.  Exported functions are:
  * void dst_init()      Initialize the toolkit
- * int  dst_check_algorithm()   Function to determines if alg is suppored.
+ * int  dst_check_algorithm()   Function to determines if alg is supported.
  * int  dst_compare_keys()      Function to compare two keys for equality.
  * int  dst_sign_data()         Incremental signing routine.
  * int  dst_verify_data()       Incremental verify routine.
@@ -35,8 +35,8 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_api.c,v 1.5 2007
  *                             KEY structure.
  * int dst_key_to_dnskey()     Function to return a public key in DNS 
  *                             format binary
- * DST_KEY *dst_buffer_to_key() Converst a data in buffer to KEY
- * int *dst_key_to_buffer()    Writes out DST_KEY key matterial in buffer
+ * DST_KEY *dst_buffer_to_key() Convert a data in buffer to KEY
+ * int *dst_key_to_buffer()    Writes out DST_KEY key material in buffer
  * void dst_free_key()         Releases all memory referenced by key structure
  */
 
@@ -241,7 +241,7 @@ dst_compare_keys(const DST_KEY *key1, const DST_KEY *key2)
  *           The location to which the signature will be written.
  *     sig_len Length of the signature field in bytes.
  * Return
- *      0      Successfull INIT or Update operation
+ *      0      Successful INIT or Update operation
  *     >0      success FINAL (sign) operation
  *     <0      failure
  */
@@ -320,8 +320,8 @@ dst_verify_data(const int mode, DST_KEY *in_key, void **context,
  *     in_id       The id of the private key.
  *     options     DST_FORCE_READ  Read from disk - don't use a previously
  *                                   read key.
- *               DST_CAN_SIGN    The key must be useable for signing.
- *               DST_NO_AUTHEN   The key must be useable for authentication.
+ *               DST_CAN_SIGN    The key must be usable for signing.
+ *               DST_NO_AUTHEN   The key must be usable for authentication.
  *               DST_STANDARD    Return any key 
  *  Returns
  *     NULL    If there is no key found in the current directory or
@@ -337,7 +337,7 @@ dst_read_key(const char *in_keyname, const unsigned in_id,
        DST_KEY *dg_key = NULL, *pubkey = NULL;
 
        if (!dst_check_algorithm(in_alg)) { /* make sure alg is available */
-               EREPORT(("dst_read_private_key(): Algorithm %d not suppored\n",
+               EREPORT(("dst_read_private_key(): Algorithm %d not supported\n",
                         in_alg));
                return (NULL);
        }
@@ -377,7 +377,7 @@ dst_write_key(const DST_KEY *key, const int type)
        if (key == NULL) 
                return (0);
        if (!dst_check_algorithm(key->dk_alg)) { /* make sure alg is available */
-               EREPORT(("dst_write_key(): Algorithm %d not suppored\n", 
+               EREPORT(("dst_write_key(): Algorithm %d not supported\n", 
                         key->dk_alg));
                return (UNSUPPORTED_KEYALG);
        }
@@ -462,7 +462,7 @@ dst_s_write_private_key(const DST_KEY *key)
  *                   filename of the key file to be read.
  *  Returns
  *     NULL        If the key does not exist or no name is supplied.
- *     NON-NULL        Initalized key structure if the key exists.
+ *     NON-NULL        Initialized key structure if the key exists.
  */
 
 static DST_KEY *
@@ -536,7 +536,7 @@ dst_s_read_public_key(const char *in_name, const unsigned in_id, int in_alg)
        while ((c = getc(fp)) != EOF)
                if (!isspace(c))
                        break;
-       ungetc(c, fp);          /* return the charcter to the input field */
+       ungetc(c, fp);          /* return the character to the input field */
        /* Handle hex!! FIXME.  */
 
        if (fscanf(fp, "%d %d %d", &flags, &proto, &alg) != 3) {
@@ -639,7 +639,7 @@ dst_s_write_public_key(const DST_KEY *key)
  *  dst_dnskey_to_public_key
  *     This function converts the contents of a DNS KEY RR into a DST
  *     key structure.
- *  Paramters
+ *  Parameters
  *     len      Length of the RDATA of the KEY RR RDATA
  *     rdata    A pointer to the the KEY RR RDATA.
  *     in_name     Key name to be stored in key structure.
@@ -661,7 +661,7 @@ dst_dnskey_to_key(const char *in_name,
                return (NULL);
        alg = (u_int8_t) rdata[DST_KEY_ALG];
        if (!dst_check_algorithm(alg)) { /* make sure alg is available */
-               EREPORT(("dst_dnskey_to_key(): Algorithm %d not suppored\n",
+               EREPORT(("dst_dnskey_to_key(): Algorithm %d not supported\n",
                         alg));
                return (NULL);
        }
@@ -679,7 +679,7 @@ dst_dnskey_to_key(const char *in_name,
                start += 2;
        }
        /*
-        * now point to the begining of the data representing the encoding
+        * now point to the beginning of the data representing the encoding
         * of the key
         */
        if (key_st->dk_func && key_st->dk_func->from_dns_key) {
@@ -687,7 +687,7 @@ dst_dnskey_to_key(const char *in_name,
                                                  len - start) > 0)
                        return (key_st);
        } else
-               EREPORT(("dst_dnskey_to_public_key(): unsuppored alg %d\n",
+               EREPORT(("dst_dnskey_to_public_key(): unsupported alg %d\n",
                         alg));
 
        SAFE_FREE(key_st);
@@ -718,7 +718,7 @@ dst_key_to_dnskey(const DST_KEY *key, u_char *out_storage,
                return (-1);
 
        if (!dst_check_algorithm(key->dk_alg)) { /* make sure alg is available */
-               EREPORT(("dst_key_to_dnskey(): Algorithm %d not suppored\n",
+               EREPORT(("dst_key_to_dnskey(): Algorithm %d not supported\n",
                         key->dk_alg));
                return (UNSUPPORTED_KEYALG);
        }
@@ -777,7 +777,7 @@ dst_buffer_to_key(const char *key_name,             /* name of the key */
        DST_KEY *dkey = NULL; 
 
        if (!dst_check_algorithm(alg)) { /* make sure alg is available */
-               EREPORT(("dst_buffer_to_key(): Algorithm %d not suppored\n", alg));
+               EREPORT(("dst_buffer_to_key(): Algorithm %d not supported\n", alg));
                return (NULL);
        }
 
@@ -800,7 +800,7 @@ int
 dst_key_to_buffer(DST_KEY *key, u_char *out_buff, unsigned buf_len)
 {
        int len;
-  /* this function will extrac the secret of HMAC into a buffer */
+  /* this function will extract the secret of HMAC into a buffer */
        if(key == NULL) 
                return (0);
        if(key->dk_func != NULL && key->dk_func != NULL) {
@@ -822,7 +822,7 @@ dst_key_to_buffer(DST_KEY *key, u_char *out_buff, unsigned buf_len)
  *     pk_key  Structure that the key is returned in.
  *     in_id   Key identifier (tag)
  * Return
- *     1 if everthing works
+ *     1 if everything works
  *     0 if there is any problem
  */
 
@@ -963,7 +963,7 @@ dst_generate_key(const char *name, const int bits, const int exp,
                return (NULL);
 
        if (!dst_check_algorithm(alg)) { /* make sure alg is available */
-               EREPORT(("dst_generate_key(): Algorithm %d not suppored\n", alg));
+               EREPORT(("dst_generate_key(): Algorithm %d not supported\n", alg));
                return (NULL);
        }
 
@@ -1020,7 +1020,7 @@ dst_free_key(DST_KEY *f_key)
 
 /*
  * dst_sig_size
- *     Return the maximim size of signature from the key specified in bytes
+ *     Return the maximum size of signature from the key specified in bytes
  * Parameters
  *      key 
  * Returns
index 0890d803a897757e1214b678247886f75030fe7f..cd6676d4a0fd76c8035dea68ce5a3d727a172c60 100644 (file)
@@ -36,14 +36,14 @@ typedef struct dst_key {
        unsigned dk_flags;     /* and the flags of the public key */
        unsigned dk_id;        /* identifier of the key */
        void    *dk_KEY_struct; /* pointer to key in crypto pkg fmt */
-       struct dst_func *dk_func; /* point to cryptto pgk specific function table */
+       struct dst_func *dk_func; /* point to crypto pgk specific function table */
 } DST_KEY;
 #define HAS_DST_KEY 
 
 #include <isc-dhcp/dst.h>
 /* 
  * define what crypto systems are supported for RSA, 
- * BSAFE is prefered over RSAREF; only one can be set at any time
+ * BSAFE is preferred over RSAREF; only one can be set at any time
  */
 #if defined(BSAFE) && defined(RSAREF)
 # error "Cannot have both BSAFE and RSAREF defined"
index 2b1008d9efc9517cc56f08ed6d936d6fe5c8a24c..f9db6fce6b7c7ef5bc732a4a8e9958c2434bf59d 100644 (file)
@@ -1,4 +1,4 @@
-static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_support.c,v 1.2 2007/10/27 19:15:32 each Exp $";
+static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/dst_support.c,v 1.3 2007/11/30 21:51:43 fdupont Exp $";
 
 
 /*
@@ -133,7 +133,7 @@ dst_s_verify_str(const char **buf, const char *str)
  *     byte order conversion.
  * Parameters
  *     buf     Pointer to encoded input string. Pointer is updated if
- *        function is successfull.
+ *        function is successful.
  *     loc     Output area.
  *     loclen  Size in bytes of output area.
  * Return
@@ -225,13 +225,13 @@ dst_s_id_calc(const u_char *key, const unsigned keysize)
 }
 
 /* 
- * dst_s_dns_key_id() Function to calculated DNSSEC footprint from KEY reocrd
+ * dst_s_dns_key_id() Function to calculated DNSSEC footprint from KEY record
  *   rdata (all of  record)
  * Input:
  *     dns_key_rdata: the raw data in wire format 
  *      rdata_len: the size of the input data 
  * Output:
- *      the key footprint/id calcuated from the key data 
+ *      the key footprint/id calculated from the key data 
  */ 
 u_int16_t
 dst_s_dns_key_id(const u_char *dns_key_rdata, const unsigned rdata_len)
index 4c2a757206abd53e542a96f99e6bad603e8dcc65..bc5dbe5e1644fb30074628581f2b2b3f484c4427 100644 (file)
@@ -1,6 +1,6 @@
 #ifdef HMAC_MD5
 #ifndef LINT
-static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/hmac_link.c,v 1.1 2001/02/22 07:22:08 mellon Exp $";
+static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/hmac_link.c,v 1.2 2007/11/30 21:51:43 fdupont Exp $";
 #endif
 /*
  * Portions Copyright (c) 1995-1998 by Trusted Information Systems, Inc.
@@ -362,7 +362,7 @@ dst_hmac_md5_key_from_file_format(DST_KEY *dkey, const char *buff,
 /*
  * dst_hmac_md5_to_dns_key() 
  *         function to extract hmac key from DST_KEY structure 
- * intput: 
+ * input: 
  *      in_key:  HMAC-MD5 key 
  * output: 
  *     out_str: buffer to write ot
index c886d17bb009f759bae616f1bfe7e46725c0973e..d73d66213c7fdc9cd4c9ca2a42971f7197ed109a 100644 (file)
--- a/dst/md5.h
+++ b/dst/md5.h
@@ -90,7 +90,7 @@ void MD5_Final();
 unsigned char *MD5();
 #endif
 
-/* to provide backward compatabilty to RSAREF calls ogud@tis.com 1997/11/14 */
+/* to provide backward compatibleness to RSAREF calls ogud@tis.com 1997/11/14 */
 #define MD5Init(c)             MD5_Init(c)
 #define MD5Update(c,data, len) MD5_Update(c,data,len)
 #define MD5Final(md, c)        MD5_Final(md, c) 
index 25dd51b759f9eadf4dd761fe4cfb0cdd743603a1..db70574fb9af7d9caa10a20e40c75698031298b7 100644 (file)
@@ -308,7 +308,7 @@ MD5_CTX *c;
        static unsigned char end[4]={0x80,0x00,0x00,0x00};
        unsigned char *cp=end;
 
-       /* c->num should definitly have room for at least one more byte. */
+       /* c->num should definitely have room for at least one more byte. */
        p=c->data;
        j=c->num;
        i=j>>2;
index c52d73377def220befef2f3da8145a362e684e79..b0337e13e33bae1124ef1a30d0076450932c099a 100644 (file)
 */
 
 /* As pointed out by Wei Dai <weidai@eskimo.com>, the above can be
- * simplified to the code below.  Wei attributes these optimisations
+ * simplified to the code below.  Wei attributes these optimizations
  * to Peter Gutmann's SHS code, and he attributes it to Rich Schroeppel.
  */
 #define        F(x,y,z)        ((((y) ^ (z)) & (x)) ^ (z))
index 26c94703190a2de46c42a10e8bc8f48e374e6f03..2eae5f7b0308f4b926bc52bac3c5aa7fda6a7189 100644 (file)
@@ -1,5 +1,5 @@
 #ifndef LINT
-static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/prandom.c,v 1.5 2007/09/05 17:32:10 dhankins Exp $";
+static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/prandom.c,v 1.6 2007/11/30 21:51:43 fdupont Exp $";
 #endif
 /*
  * Portions Copyright (c) 1995-1998 by Trusted Information Systems, Inc.
@@ -47,8 +47,8 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/prandom.c,v 1.5 2007
 #endif
 
 /* 
- * the constant below is a prime number to make fixed data structues like 
- * stat and time wrap over blocks. This adds certain uncertanty to what is 
+ * the constant below is a prime number to make fixed data structures like 
+ * stat and time wrap over blocks. This adds certain randomness to what is
  * in each digested block. 
  * The prime number 2879 has the special property that when 
  * divided by 2,4 and 6 the result is also a prime numbers
@@ -59,14 +59,14 @@ static const char rcsid[] = "$Header: /tmp/cvstest/DHCP/dst/prandom.c,v 1.5 2007
 #endif
 
 /* 
- * This constant dictatates how many bits we shift to the right before using a 
+ * This constant dictates how many bits we shift to the right before using a 
  */
 #ifndef DST_SHIFT
 #define DST_SHIFT 9
 #endif
 
 /*
- * An initalizer that is as bad as any other with half the bits set 
+ * An initializer that is as bad as any other with half the bits set 
  */
 #ifndef DST_RANDOM_PATTERN
 #define DST_RANDOM_PATTERN 0x8765CA93
@@ -172,7 +172,7 @@ static const char *files[] = {
 /*  
  *  these two data structure are used to process input data into digests, 
  *
- *  The first structure is containts a pointer to a DST HMAC key 
+ *  The first structure contains a pointer to a DST HMAC key 
  *  the variables accompanying are used for 
  *     step : select every step byte from input data for the hash
  *     block: number of data elements going into each hash
@@ -186,7 +186,7 @@ typedef struct hash {
 } prand_hash;
 
 /*
- *  This data structure controlls number of hashes and keeps track of 
+ *  This data structure controls number of hashes and keeps track of 
  *  overall progress in generating correct number of bytes of output.
  *     output  : array to store the output data in
  *     needed  : how many bytes of output are needed
@@ -228,7 +228,7 @@ static u_int32_t ran_cnt = (DST_RANDOM_PATTERN >> 10);
 
 /* 
  * setting the quick_random generator to particular values or if both 
- * input parameters are 0 then set it to initial vlaues
+ * input parameters are 0 then set it to initial values
  */
 
 void
@@ -312,7 +312,7 @@ do_time(dst_work *work)
  *
  * do_ls() does not visit subdirectories
  * if attacker has access to machine it can guess most of the values seen
- * thus it is important to only visit directories that are freqently updated
+ * thus it is important to only visit directories that are frequently updated
  * Attacker that has access to the network can see network traffic 
  * when NFS mounted directories are accessed and know exactly the data used
  * but may not know exactly in what order data is used. 
@@ -375,7 +375,7 @@ do_ls(dst_work *work)
                file_name[dir_len + len] = 0x0;
                /* for all entries in dir get the stats */
                if (stat(file_name, &buf) == 0) {
-                       n++;    /* count successfull stat calls */
+                       n++;    /* count successful stat calls */
                        /* copy non static fields */
                        dir_info.uid   += buf.st_uid;
                        dir_info.gid   += buf.st_gid;
@@ -509,7 +509,7 @@ force_hash(dst_work *work, prand_hash *hash)
 
        /* 
         * if more than half a block then add data to output 
-        * otherwise adde the digest to the next hash 
+        * otherwise add the digest to the next hash 
         */
        if ((hash->digested * 2) > hash->block) {
                i = dst_sign_data(SIG_MODE_FINAL, hash->key, &hash->ctx,
@@ -528,7 +528,7 @@ force_hash(dst_work *work, prand_hash *hash)
 /* 
  * This function takes the input data does the selection of data specified
  * by the hash control block.
- * The step varialbe in the work sturcture determines which 1/step bytes
+ * The step variable in the work structure determines which 1/step bytes
  * are used, 
  *
  */
@@ -550,7 +550,7 @@ do_hash(dst_work *work, prand_hash *hash, const u_char *input, unsigned size)
                tmp = tp;
                for (cnt = 0, i = hash->curr; i < size; i += hash->step, cnt++)
                        *(tp++) = input[i];
-               /* calcutate the starting point in the next input set */
+               /* calculate the starting point in the next input set */
                hash->curr = (hash->step - (i - size)) % hash->step;
        }
        /* digest the data in block sizes */
@@ -604,7 +604,7 @@ my_digest(dst_work *work, const u_char *input, unsigned size)
 
 /*
  * this function gets some semi random data and sets that as an HMAC key
- * If we get a valid key this function returns that key initalized
+ * If we get a valid key this function returns that key initialized
  * otherwise it returns NULL;
  */
 static prand_hash *
@@ -622,7 +622,7 @@ get_hmac_key(int step, int block)
        if (buff == NULL)
                return (NULL);
        /* do not memset the allocated memory to get random bytes there */
-       /* time of day is somewhat random  expecialy in the last bytes */
+       /* time of day is somewhat random  especially in the last bytes */
        gettimeofday((struct timeval *) &buff[n], NULL);
        n += sizeof(struct timeval);
 
@@ -684,7 +684,7 @@ get_hmac_key(int step, int block)
  * This function goes out and from various sources tries to generate enough
  * semi random data that a hash function can generate a random data. 
  * This function will iterate between the two main random source sources, 
- *  information from programs and directores in random order. 
+ *  information from programs and directories in random order. 
  * This function return the number of bytes added to the random output buffer. 
  */
 static unsigned
@@ -761,8 +761,8 @@ own_random(dst_work *work)
  * of randomness to the caller it will use the best available sources of 
  * randomness.
  * The current order is to use /dev/random, precalculated randomness, and 
- * finaly use some system calls and programs to generate semi random data that 
- * is then digested to generate randomness. 
+ * finally use some system calls and programs to generate semi random data
+ * that is then digested to generate randomness. 
  * This function is thread safe as each thread uses its own context, but
  * concurrent treads will affect each other as they update shared state 
  * information.
@@ -770,7 +770,7 @@ own_random(dst_work *work)
  * that is not a multiple of the output of the hash function used. 
  * 
  * If /dev/random is not available this function is not suitable to generate 
- * large ammounts of data, rather it is suitable to seed a pseudo-random 
+ * large amounts of data, rather it is suitable to seed a pseudo-random 
  * generator 
  * Returns the number of bytes put in the output buffer 
  */
@@ -872,8 +872,8 @@ dst_s_random(u_char *output, unsigned size)
  * counters that is incremented between digest operations
  * each increment operation amortizes to 2 bits changed in that value
  * for 5 counters thus the input will amortize to have 10 bits changed 
- * The counters are initaly set using the strong random function above
- * the HMAC key is selected by the same methold as the HMAC keys for the 
+ * The counters are initially set using the strong random function above
+ * the HMAC key is selected by the same method as the HMAC keys for the 
  * strong random function. 
  * Each set of counters is used for 2^25 operations 
  * 
@@ -928,13 +928,13 @@ dst_s_semi_random(u_char *output, unsigned size)
                        semi_loc += out;
                }
        }
-/* generate more randome stuff */
+/* generate more random stuff */
        while (out < size) {
                /* 
                 * modify at least one bit by incrementing at least one counter
                 * based on the last bit of the last counter updated update
                 * the next one.
-                * minimaly this  operation will modify at least 1 bit, 
+                * minimally this  operation will modify at least 1 bit, 
                 * amortized 2 bits
                 */
                for (n = 0; n < DST_NUMBER_OF_COUNTERS; n++)
index 1b86b337062cb2fcd24050c657ef0f05a1060d87..a3058fbef6d9f0a3a0afe1927763626866639e65 100644 (file)
@@ -102,10 +102,10 @@ typedef time_t TIME;
 #include <omapip/omapip_p.h>
 
 #if !defined (BYTE_NAME_HASH_SIZE)
-# define BYTE_NAME_HASH_SIZE   401     /* Default would be rediculous. */
+# define BYTE_NAME_HASH_SIZE   401     /* Default would be ridiculous. */
 #endif
 #if !defined (BYTE_CODE_HASH_SIZE)
-# define BYTE_CODE_HASH_SIZE   254     /* Default would be rediculous. */
+# define BYTE_CODE_HASH_SIZE   254     /* Default would be ridiculous. */
 #endif
 
 /* Although it is highly improbable that a 16-bit option space might
@@ -121,7 +121,7 @@ typedef time_t TIME;
 #endif
 
 /* Not only is it improbable that the 32-bit spaces might actually use 2^32
- * defined options, it is infeasable.  It would be best for this kind of
+ * defined options, it is infeasible.  It would be best for this kind of
  * space to be dynamically sized.  Instead we size it at the word hash's
  * level.
  */
@@ -146,7 +146,7 @@ typedef time_t TIME;
 #endif
 
 #if !defined (FQDN_HASH_SIZE)
-# define FQDN_HASH_SIZE                13      /* A rediculously small table. */
+# define FQDN_HASH_SIZE                13      /* A ridiculously small table. */
 #endif
 
 /* I really doubt a given installation is going to have more than a few
index 9d1a62e07acb61d3169b57b7109479e3bdbd9499..8ca68d4c9bef11126ee32dab73ae109a2e57919e 100644 (file)
@@ -496,7 +496,7 @@ isc_result_t omapi_io_get_value (omapi_object_t *h,
 
 /* omapi_io_destroy (object, MDL);
  *
- *     Find the requsted IO [object] and remove it from the list of io
+ *     Find the requested IO [object] and remove it from the list of io
  * states, causing the cleanup functions to destroy it.  Note that we must
  * hold a reference on the object while moving its ->next reference and
  * removing the reference in the chain to the target object...otherwise it
index 941fe8ef6119634224724c6021a048594853ca9f..8563ae04fc478894ec3157edbde244a5f06e70f9 100644 (file)
@@ -111,7 +111,7 @@ main(int argc, char **argv) {
 
         /* Make sure that file descriptors 0 (stdin), 1, (stdout), and
            2 (stderr) are open. To do this, we assume that when we
-           open a file the lowest available file decriptor is used. */
+           open a file the lowest available file descriptor is used. */
         fd = open("/dev/null", O_RDWR);
         if (fd == 0)
                 fd = open("/dev/null", O_RDWR);
index f6101b3b1756b82f181ff47d0293212cbd5512a8..715e654241736c9f6669ce84b78461ddc0abb2d4 100644 (file)
@@ -242,7 +242,7 @@ isc_result_t conf_file_subparse (struct parse *cfile, struct group *group,
 }
 
 /* lease-file :== lease-declarations END_OF_FILE
-   lease-statments :== <nil>
+   lease-statements :== <nil>
                     | lease-declaration
                     | lease-declarations lease-declaration */
 
@@ -1850,7 +1850,7 @@ void parse_host_declaration (cfile, group)
                        token = next_token(&val, NULL, cfile);
                        if (token != OPTION) {
                                parse_warn(cfile, 
-                                          "host-identifer must be an option");
+                                          "host-identifier must be an option");
                                skip_to_rbrace(cfile, 1);
                                break;
                        }
@@ -3022,7 +3022,7 @@ int parse_lease_declaration (struct lease **lp, struct parse *cfile)
                                break;
 
                                /* RESERVED and BOOTP states preserved for
-                                * compatiblity with older versions.
+                                * compatibleness with older versions.
                                 */
                              case TOKEN_RESERVED:
                                new_state = FTS_ACTIVE;
@@ -4133,7 +4133,7 @@ parse_server_duid(struct parse *cfile) {
  * server-duid llt ethernet|ieee802|fddi 213982198 00:16:6F:49:7D:9B;
  * server-duid ll;
  * server-duid ll ethernet|ieee802|fddi 00:16:6F:49:7D:9B;
- * server-duid en 2495 "enterprise-specific-identifer-1234";
+ * server-duid en 2495 "enterprise-specific-identifier-1234";
  */
 void 
 parse_server_duid_conf(struct parse *cfile) {
index 93dc2c76edec79cac840dadf26e561a0e7b3f466..904d50d6e72ae8d664c047449357b878a5bcad77 100644 (file)
@@ -224,7 +224,7 @@ main(int argc, char **argv) {
 
         /* Make sure that file descriptors 0 (stdin), 1, (stdout), and
            2 (stderr) are open. To do this, we assume that when we
-           open a file the lowest available file decriptor is used. */
+           open a file the lowest available file descriptor is used. */
         fd = open("/dev/null", O_RDWR);
         if (fd == 0)
                 fd = open("/dev/null", O_RDWR);
index c3c0fa77b9ebb414cdbaf244e559bca80c577762..c46e4acb1169f33d0799a339daf0251ca2329b59 100644 (file)
@@ -139,7 +139,7 @@ dhcpleasequery(struct packet *packet, int ms_nulltp) {
        struct lease *lease;
        int want_associated_ip;
        int assoc_ip_cnt;
-       u_int32_t assoc_ips[40];  /* XXXSK: arbritrary maximum number of IPs */
+       u_int32_t assoc_ips[40];  /* XXXSK: arbitrary maximum number of IPs */
        const int nassoc_ips = sizeof(assoc_ips) / sizeof(assoc_ips[0]);
 
        unsigned char dhcpMsgType;
@@ -231,7 +231,7 @@ dhcpleasequery(struct packet *packet, int ms_nulltp) {
        allow_leasequery = 0;
 
        /*
-        * See if we are authorised to do LEASEQUERY.
+        * See if we are authorized to do LEASEQUERY.
         */
        oc = lookup_option(&server_universe, options, SV_LEASEQUERY);
        if (oc != NULL) {
index 80c2bd11994c5635da9cee000db1aa9ad6f93bb8..53df84a5cd4868648838cfbc2b1295e8358a72f4 100644 (file)
@@ -65,13 +65,13 @@ struct reply_state {
         */
        u_int32_t renew, rebind, prefer, valid;
 
-       /* Client-rqeuested valid and preferred lifetimes. */
+       /* Client-requested valid and preferred lifetimes. */
        u_int32_t client_valid, client_prefer;
 
        /* Chosen values to transmit for valid and preferred lifetimes. */
        u_int32_t send_valid, send_prefer;
 
-       /* Index into the data field that has been sonsumed. */
+       /* Index into the data field that has been consumed. */
        unsigned cursor;
 
        union reply_buffer {
@@ -1005,7 +1005,7 @@ pick_v6_address(struct iaaddr **addr, struct shared_network *shared_network,
  * reply that contains all that we know about the client's correct lease
  * (or projected lease).
  *
- * Solicit - "Soft" binding, ignore uknown addresses or bindings, just
+ * Solicit - "Soft" binding, ignore unknown addresses or bindings, just
  *          send what we "may" give them on a request.
  *
  * Request - "Hard" binding, but ignore supplied addresses (just provide what
@@ -1940,7 +1940,7 @@ reply_process_is_addressed(struct reply_state *reply,
                                           reply->opt_state,
                                           scope, oc, MDL) ||
                    (data.len != 4)) {
-                       log_error("reply_process_ia: uanble to "
+                       log_error("reply_process_ia: unable to "
                                  "evaluate default lease time");
                        status = ISC_R_FAILURE;
                        goto cleanup;
@@ -1991,7 +1991,7 @@ reply_process_is_addressed(struct reply_state *reply,
         * XXX: case where a client first identifies itself using vendor
         * XXX: options in a solicit, or request, but later neglects to include
         * XXX: these options in a Renew or Rebind.  It is not clear that this
-        * XXX: is required, and has some startling ramnifications (such as
+        * XXX: is required, and has some startling ramifications (such as
         * XXX: how to recover this dynamic host {} state across restarts).
         */
        if (reply->host != NULL)
@@ -2047,7 +2047,7 @@ reply_process_send_addr(struct reply_state *reply, struct iaddr *addr) {
        /* Now append the lease. */
        data.len = IAADDR_OFFSET;
        if (!buffer_allocate(&data.buffer, data.len, MDL)) {
-               log_error("reply_process_ia: out of memory alloating "
+               log_error("reply_process_ia: out of memory allocating "
                          "new IAADDR buffer.");
                status = ISC_R_NOMEMORY;
                goto cleanup;
@@ -2920,7 +2920,7 @@ exit:
  * address we gave it.
  *
  * Since we're only dealing with fixed leases for now, there's not
- * much we can do, other that log the occurrance.
+ * much we can do, other that log the occurrence.
  * 
  * When we start issuing addresses from pools, then we will have to
  * record our declined addresses and issue another. In general with
@@ -3134,7 +3134,7 @@ dhcpv6_relay_forw(struct data_string *reply_ret, struct packet *packet) {
        struct data_string interface_id;
 
        /* 
-        * Intialize variables for early exit.
+        * Initialize variables for early exit.
         */
        memset(&enc_opt_data, 0, sizeof(enc_opt_data));
        enc_packet = NULL;
index 36451fb03b689dccaf096f195132c2e0d3255e56..0621077da8f841a4630cd63d4d4bc5d567e366c1 100644 (file)
@@ -168,7 +168,7 @@ isc_result_t find_failover_peer (peer, name, file, line)
    specified for each failover object, there could be as many as one
    listener object for each secondary failover_state object. */
 
-/* This, then, is the implemention of the failover link object. */
+/* This, then, is the implementation of the failover link object. */
 
 isc_result_t dhcp_failover_link_initiate (omapi_object_t *h)
 {
@@ -2121,7 +2121,7 @@ isc_result_t dhcp_failover_peer_state_changed (dhcp_failover_state_t *state,
                        break;
 
                        /* If we're in communications-interrupted and an
-                          amnesiac peer connects, go to the partner_down
+                          amnesic peer connects, go to the partner_down
                           state immediately. */
                      case recover:
                        dhcp_failover_set_state (state, partner_down);
@@ -2564,7 +2564,7 @@ isc_result_t dhcp_failover_send_updates (dhcp_failover_state_t *state)
        if (!state -> link_to_peer)
                return ISC_R_SUCCESS;
 
-       /* If there are acks pending, transmit them prior to potentialy
+       /* If there are acks pending, transmit them prior to potentially
         * sending new updates for the same lease.
         */
        if (state->toack_queue_head != NULL)
@@ -5153,7 +5153,7 @@ isc_result_t dhcp_failover_process_bind_ack (dhcp_failover_state_t *state,
                write_lease(lease);
                /* Commit the lease only after a two-second timeout,
                   so that if we get a bunch of acks in quick
-                  successtion (e.g., when stealing leases from the
+                  succession (e.g., when stealing leases from the
                   secondary), we do not do an immediate commit for
                   each one. */
                add_timeout(cur_time + 2,
index 2c3b1053c5d92a80f74aa27347ae47b2d34e71d5..2604117d263d95950444f3be8165b86c9938d887 100644 (file)
@@ -382,7 +382,7 @@ isc_result_t enter_host (hd, dynamicp, commit)
                                         hd->host_id_option, MDL);
                        if (!host_new_hash(&h_id_info->values_hash, 
                                           HOST_HASH_SIZE, MDL)) {
-                               log_fatal("No memory for host-identifer "
+                               log_fatal("No memory for host-identifier "
                                          "option hash.");
                        }
                        h_id_info->next = host_id_info;
@@ -1224,7 +1224,7 @@ int supersede_lease (comp, lease, commit, propogate, pimmediate)
       just_move_it:
 #if defined (FAILOVER_PROTOCOL)
        /* Atsfp should be cleared upon any state change that implies
-        * propogation whether supersede_lease was given a copy lease
+        * propagation whether supersede_lease was given a copy lease
         * structure or not (often from the pool_timer()).
         */
        if (propogate)
@@ -2373,7 +2373,7 @@ int lease_enqueue (struct lease *comp)
        }
 
        /* This only works during server startup: during runtime, the last
-        * lease may be dequeued inbetween calls.  If the queue is the same
+        * lease may be dequeued in between calls.  If the queue is the same
         * as was used previously, and the lease structure isn't (this is not
         * a re-queue), use that as a starting point for the insertion-sort.
         */