Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/bsd/ntp merge conflicts



details:   https://anonhg.NetBSD.org/src/rev/33af96905777
branches:  trunk
changeset: 321816:33af96905777
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Apr 07 00:19:52 2018 +0000

description:
merge conflicts

diffstat:

 external/bsd/ntp/dist/include/ntp.h                     |    70 +-
 external/bsd/ntp/dist/include/ntp_calendar.h            |    25 +-
 external/bsd/ntp/dist/include/ntp_config.h              |    23 +-
 external/bsd/ntp/dist/include/ntp_fp.h                  |     3 +-
 external/bsd/ntp/dist/include/ntp_keyacc.h              |     2 +-
 external/bsd/ntp/dist/include/ntp_request.h             |    11 +-
 external/bsd/ntp/dist/include/ntp_stdlib.h              |     6 +-
 external/bsd/ntp/dist/include/ntpd.h                    |    44 +-
 external/bsd/ntp/dist/include/recvbuff.h                |     7 +-
 external/bsd/ntp/dist/include/ssl_applink.c             |    24 +-
 external/bsd/ntp/dist/libntp/a_md5encrypt.c             |   250 +-
 external/bsd/ntp/dist/libntp/adjtime.c                  |     6 +-
 external/bsd/ntp/dist/libntp/authkeys.c                 |   128 +-
 external/bsd/ntp/dist/libntp/authreadkeys.c             |    54 +-
 external/bsd/ntp/dist/libntp/libssl_compat.c            |     2 +-
 external/bsd/ntp/dist/libntp/ntp_calendar.c             |   111 +-
 external/bsd/ntp/dist/libntp/ssl_init.c                 |   116 +-
 external/bsd/ntp/dist/libntp/statestr.c                 |   286 +-
 external/bsd/ntp/dist/libntp/systime.c                  |   340 +-
 external/bsd/ntp/dist/libntp/work_thread.c              |     4 +-
 external/bsd/ntp/dist/ntpd/keyword-gen.c                |     6 +-
 external/bsd/ntp/dist/ntpd/ntp_config.c                 |   497 ++-
 external/bsd/ntp/dist/ntpd/ntp_control.c                |   495 +-
 external/bsd/ntp/dist/ntpd/ntp_crypto.c                 |    14 +-
 external/bsd/ntp/dist/ntpd/ntp_io.c                     |    72 +-
 external/bsd/ntp/dist/ntpd/ntp_keyword.h                |  2167 +++++++-------
 external/bsd/ntp/dist/ntpd/ntp_leapsec.c                |    24 +-
 external/bsd/ntp/dist/ntpd/ntp_parser.y                 |    81 +-
 external/bsd/ntp/dist/ntpd/ntp_peer.c                   |    63 +-
 external/bsd/ntp/dist/ntpd/ntp_proto.c                  |   427 ++-
 external/bsd/ntp/dist/ntpd/ntp_refclock.c               |    24 +-
 external/bsd/ntp/dist/ntpd/ntp_request.c                |    53 +-
 external/bsd/ntp/dist/ntpd/ntp_restrict.c               |   197 +-
 external/bsd/ntp/dist/ntpd/ntp_scanner.c                |     3 +-
 external/bsd/ntp/dist/ntpd/ntp_util.c                   |    22 +-
 external/bsd/ntp/dist/ntpd/ntpd-opts.c                  |    16 +-
 external/bsd/ntp/dist/ntpd/ntpd-opts.h                  |     8 +-
 external/bsd/ntp/dist/ntpd/ntpd.c                       |    17 +-
 external/bsd/ntp/dist/ntpd/ntpsim.c                     |     3 +-
 external/bsd/ntp/dist/ntpd/refclock_gpsdjson.c          |     6 +-
 external/bsd/ntp/dist/ntpd/refclock_jjy.c               |    30 +-
 external/bsd/ntp/dist/ntpd/refclock_palisade.c          |   126 +-
 external/bsd/ntp/dist/ntpd/refclock_parse.c             |    15 +-
 external/bsd/ntp/dist/ntpdc/ntpdc-opts.c                |    16 +-
 external/bsd/ntp/dist/ntpdc/ntpdc-opts.h                |     8 +-
 external/bsd/ntp/dist/ntpdc/ntpdc.c                     |     6 +-
 external/bsd/ntp/dist/ntpdc/ntpdc_ops.c                 |     8 +-
 external/bsd/ntp/dist/ntpq/ntpq-opts.c                  |   228 +-
 external/bsd/ntp/dist/ntpq/ntpq-opts.h                  |     8 +-
 external/bsd/ntp/dist/ntpq/ntpq-subs.c                  |    66 +-
 external/bsd/ntp/dist/ntpq/ntpq.c                       |   343 +-
 external/bsd/ntp/dist/ntpsnmpd/netsnmp_daemonize.c      |     4 +-
 external/bsd/ntp/dist/ntpsnmpd/ntpsnmpd-opts.c          |    16 +-
 external/bsd/ntp/dist/ntpsnmpd/ntpsnmpd-opts.h          |     8 +-
 external/bsd/ntp/dist/sntp/crypto.c                     |   244 +-
 external/bsd/ntp/dist/sntp/crypto.h                     |     5 +-
 external/bsd/ntp/dist/sntp/main.c                       |    34 +-
 external/bsd/ntp/dist/sntp/networking.c                 |    10 +-
 external/bsd/ntp/dist/sntp/sntp-opts.c                  |   197 +-
 external/bsd/ntp/dist/sntp/sntp-opts.h                  |     8 +-
 external/bsd/ntp/dist/sntp/tests/crypto.c               |     2 +-
 external/bsd/ntp/dist/sntp/tests/keyFile.c              |     2 +-
 external/bsd/ntp/dist/sntp/tests/packetHandling.c       |     2 +-
 external/bsd/ntp/dist/sntp/tests/packetProcessing.c     |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-crypto.c           |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-keyFile.c          |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-kodDatabase.c      |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-kodFile.c          |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-networking.c       |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-packetHandling.c   |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-packetProcessing.c |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-t-log.c            |     2 +-
 external/bsd/ntp/dist/sntp/tests/run-utilities.c        |     2 +-
 external/bsd/ntp/dist/sntp/utilities.c                  |     4 +-
 external/bsd/ntp/dist/sntp/version.c                    |     2 +-
 external/bsd/ntp/dist/tests/bug-2803/run-bug-2803.c     |     2 +-
 external/bsd/ntp/dist/tests/libntp/a_md5encrypt.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/authkeys.c           |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-a_md5encrypt.c   |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-atoint.c         |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-atouint.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-authkeys.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-buftvtots.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-calendar.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-caljulian.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-caltontp.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-calyearstart.c   |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-clocktime.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-decodenetnum.c   |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-hextoint.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-hextolfp.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-humandate.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-lfpfunc.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-lfptostr.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-modetoa.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-msyslog.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-netof.c          |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-numtoa.c         |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-numtohost.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-octtoint.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-prettydate.c     |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-recvbuff.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-refidsmear.c     |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-refnumtoa.c      |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-sfptostr.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-socktoa.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-ssl_init.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-statestr.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-strtolfp.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-timespecops.c    |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-timevalops.c     |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-tsafememcmp.c    |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-tstotv.c         |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-tvtots.c         |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-uglydate.c       |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-vi64ops.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/run-ymd2yd.c         |     2 +-
 external/bsd/ntp/dist/tests/libntp/ssl_init.c           |     2 +-
 external/bsd/ntp/dist/tests/libntp/timespecops.c        |     2 +-
 external/bsd/ntp/dist/tests/libntp/timevalops.c         |     2 +-
 external/bsd/ntp/dist/tests/ntpd/leapsec.c              |     2 +-
 external/bsd/ntp/dist/tests/ntpd/ntp_prio_q.c           |     2 +-
 external/bsd/ntp/dist/tests/ntpd/ntp_restrict.c         |     2 +-
 external/bsd/ntp/dist/tests/ntpd/rc_cmdlength.c         |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-leapsec.c          |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-ntp_prio_q.c       |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-ntp_restrict.c     |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-rc_cmdlength.c     |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-t-ntp_scanner.c    |     2 +-
 external/bsd/ntp/dist/tests/ntpd/run-t-ntp_signd.c      |     2 +-
 external/bsd/ntp/dist/tests/ntpd/t-ntp_scanner.c        |     2 +-
 external/bsd/ntp/dist/tests/ntpq/run-t-ntpq.c           |     2 +-
 external/bsd/ntp/dist/tests/sandbox/run-modetoa.c       |     2 +-
 external/bsd/ntp/dist/tests/sandbox/run-uglydate.c      |     2 +-
 external/bsd/ntp/dist/tests/sandbox/run-ut-2803.c       |     2 +-
 external/bsd/ntp/dist/tests/sec-2853/run-sec-2853.c     |     2 +-
 external/bsd/ntp/dist/util/ntp-keygen-opts.c            |   331 +-
 external/bsd/ntp/dist/util/ntp-keygen-opts.h            |    40 +-
 external/bsd/ntp/importdate                             |     2 +-
 external/bsd/ntp/include/config.h                       |    37 +-
 external/bsd/ntp/ntp2netbsd                             |     4 +-
 141 files changed, 4821 insertions(+), 2834 deletions(-)

diffs (truncated from 13055 to 300 lines):

diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp.h
--- a/external/bsd/ntp/dist/include/ntp.h       Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp.h       Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp.h,v 1.8 2016/11/22 03:09:30 christos Exp $ */
+/*     $NetBSD: ntp.h,v 1.9 2018/04/07 00:19:52 christos Exp $ */
 
 /*
  * ntp.h - NTP definitions for the masses
@@ -555,11 +555,13 @@
        l_fp    rec;            /* receive time stamp */
        l_fp    xmt;            /* transmit time stamp */
 
-#define        MIN_V4_PKT_LEN  (12 * sizeof(u_int32)) /* min header length */
-#define        LEN_PKT_NOMAC   (12 * sizeof(u_int32)) /* min header length */
-#define MIN_MAC_LEN    (1 * sizeof(u_int32))   /* crypto_NAK */
-#define MAX_MD5_LEN    (5 * sizeof(u_int32))   /* MD5 */
+#define        MIN_V4_PKT_LEN  (12 * sizeof(u_int32))  /* min header length */
+#define        LEN_PKT_NOMAC   (12 * sizeof(u_int32))  /* min header length */
+#define        MIN_MAC_LEN     (1 * sizeof(u_int32))   /* crypto_NAK */
+#define        MAX_MD5_LEN     (5 * sizeof(u_int32))   /* MD5 */
 #define        MAX_MAC_LEN     (6 * sizeof(u_int32))   /* SHA */
+#define        KEY_MAC_LEN     sizeof(u_int32)         /* key ID in MAC */
+#define        MAX_MDG_LEN     (MAX_MAC_LEN-KEY_MAC_LEN) /* max. digest len */
 
        /*
         * The length of the packet less MAC must be a multiple of 64
@@ -824,11 +826,12 @@
 
 typedef struct restrict_u_tag  restrict_u;
 struct restrict_u_tag {
-       restrict_u *            link;   /* link to next entry */
-       u_int32                 count;  /* number of packets matched */
-       u_short                 flags;  /* accesslist flags */
-       u_short                 mflags; /* match flags */
-       u_long                  expire; /* valid until time */
+       restrict_u *    link;           /* link to next entry */
+       u_int32         count;          /* number of packets matched */
+       u_short         rflags;         /* restrict (accesslist) flags */
+       u_short         mflags;         /* match flags */
+       short           ippeerlimit;    /* IP peer limit */
+       u_long          expire;         /* valid until time */
        union {                         /* variant starting here */
                res_addr4 v4;
                res_addr6 v6;
@@ -839,28 +842,40 @@
 #define        V6_SIZEOF_RESTRICT_U    (offsetof(restrict_u, u)        \
                                 + sizeof(res_addr6))
 
+typedef struct r4addr_tag      r4addr;
+struct r4addr_tag {
+       u_short         rflags;         /* match flags */
+       short           ippeerlimit;    /* IP peer limit */
+};
+
+char *build_iflags(u_int32 flags);
+char *build_mflags(u_short mflags);
+char *build_rflags(u_short rflags);
+
 /*
- * Access flags
+ * Restrict (Access) flags (rflags)
  */
 #define        RES_IGNORE              0x0001  /* ignore packet */
 #define        RES_DONTSERVE           0x0002  /* access denied */
 #define        RES_DONTTRUST           0x0004  /* authentication required */
 #define        RES_VERSION             0x0008  /* version mismatch */
 #define        RES_NOPEER              0x0010  /* new association denied */
-#define RES_LIMITED            0x0020  /* packet rate exceeded */
+#define        RES_NOEPEER             0x0020  /* new ephemeral association denied */
+#define RES_LIMITED            0x0040  /* packet rate exceeded */
 #define RES_FLAGS              (RES_IGNORE | RES_DONTSERVE |\
                                    RES_DONTTRUST | RES_VERSION |\
-                                   RES_NOPEER | RES_LIMITED)
+                                   RES_NOPEER | RES_NOEPEER | RES_LIMITED)
 
-#define        RES_NOQUERY             0x0040  /* mode 6/7 packet denied */
-#define        RES_NOMODIFY            0x0080  /* mode 6/7 modify denied */
-#define        RES_NOTRAP              0x0100  /* mode 6/7 set trap denied */
-#define        RES_LPTRAP              0x0200  /* mode 6/7 low priority trap */
+#define        RES_NOQUERY             0x0080  /* mode 6/7 packet denied */
+#define        RES_NOMODIFY            0x0100  /* mode 6/7 modify denied */
+#define        RES_NOTRAP              0x0200  /* mode 6/7 set trap denied */
+#define        RES_LPTRAP              0x0400  /* mode 6/7 low priority trap */
 
-#define        RES_KOD                 0x0400  /* send kiss of death packet */
-#define        RES_MSSNTP              0x0800  /* enable MS-SNTP authentication */
-#define        RES_FLAKE               0x1000  /* flakeway - drop 10% */
-#define        RES_NOMRULIST           0x2000  /* mode 6 mrulist denied */
+#define        RES_KOD                 0x0800  /* send kiss of death packet */
+#define        RES_MSSNTP              0x1000  /* enable MS-SNTP authentication */
+#define        RES_FLAKE               0x2000  /* flakeway - drop 10% */
+#define        RES_NOMRULIST           0x4000  /* mode 6 mrulist denied */
+#define RES_UNUSED             0x8000  /* Unused flag bits */
 
 #define        RES_ALLFLAGS            (RES_FLAGS | RES_NOQUERY |      \
                                 RES_NOMODIFY | RES_NOTRAP |    \
@@ -869,7 +884,7 @@
                                 RES_NOMRULIST)
 
 /*
- * Match flags
+ * Match flags (mflags)
  */
 #define        RESM_INTERFACE          0x1000  /* this is an interface */
 #define        RESM_NTPONLY            0x2000  /* match source port 123 */
@@ -878,10 +893,13 @@
 /*
  * Restriction configuration ops
  */
-#define        RESTRICT_FLAGS          1       /* add flags to restrict entry */
-#define        RESTRICT_UNFLAG         2       /* remove flags from restrict entry */
-#define        RESTRICT_REMOVE         3       /* remove a restrict entry */
-#define        RESTRICT_REMOVEIF       4       /* remove an interface restrict entry */
+typedef enum
+restrict_ops {
+       RESTRICT_FLAGS = 1,     /* add rflags to restrict entry */
+       RESTRICT_UNFLAG,        /* remove rflags from restrict entry */
+       RESTRICT_REMOVE,        /* remove a restrict entry */
+       RESTRICT_REMOVEIF,      /* remove an interface restrict entry */
+} restrict_op;
 
 /*
  * Endpoint structure for the select algorithm
diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp_calendar.h
--- a/external/bsd/ntp/dist/include/ntp_calendar.h      Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp_calendar.h      Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp_calendar.h,v 1.6 2016/01/08 21:35:35 christos Exp $        */
+/*     $NetBSD: ntp_calendar.h,v 1.7 2018/04/07 00:19:52 christos Exp $        */
 
 /*
  * ntp_calendar.h - definitions for the calendar time-of-day routine
@@ -384,6 +384,29 @@
 extern int32_t
 ntpcal_weekday_lt(int32_t /* rdn */, int32_t /* dow */);
 
+
+/*
+ * handling of base date spec
+ */
+extern int32_t
+basedate_eval_buildstamp(void);
+
+extern int32_t
+basedate_eval_string(const char *str);
+
+extern int32_t
+basedate_set_day(int32_t dayno);
+
+extern uint32_t
+basedate_get_day(void);
+
+extern time_t
+basedate_get_eracenter(void);
+
+extern time_t
+basedate_get_erabase(void);
+
+
 /*
  * Additional support stuff for Ed Rheingold's calendrical calculations
  */
diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp_config.h
--- a/external/bsd/ntp/dist/include/ntp_config.h        Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp_config.h        Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp_config.h,v 1.10 2016/01/08 21:35:35 christos Exp $ */
+/*     $NetBSD: ntp_config.h,v 1.11 2018/04/07 00:19:52 christos Exp $ */
 
 #ifndef NTP_CONFIG_H
 #define NTP_CONFIG_H
@@ -56,7 +56,15 @@
        int     last;
 } int_range;
 
-/* Structure for storing an attribute-value pair  */
+/* generic list node */
+typedef struct any_node_tag any_node;
+struct any_node_tag {
+       any_node *      link;
+};
+
+typedef DECL_FIFO_ANCHOR(any_node) any_node_fifo;
+
+/* Structure for storing an attribute-value pair */
 typedef struct attr_val_tag attr_val;
 struct attr_val_tag {
        attr_val *      link;
@@ -104,8 +112,9 @@
        restrict_node * link;
        address_node *  addr;
        address_node *  mask;
-       int_fifo *      flags;
+       int_fifo *      flag_tok_fifo;
        int             line_no;
+       short           ippeerlimit;
 };
 
 typedef DECL_FIFO_ANCHOR(restrict_node) restrict_fifo;
@@ -269,8 +278,12 @@
 const char * token_name(int token);
 
 /* generic fifo routines for structs linked by 1st member */
-void*  append_gen_fifo(void *fifo, void *entry);
+typedef void (*fifo_deleter)(void*);
+void * destroy_gen_fifo(void *fifo, fifo_deleter func);
+void * append_gen_fifo(void *fifo, void *entry);
 void * concat_gen_fifos(void *first, void *second);
+#define DESTROY_G_FIFO(pf, func)       \
+       ((pf) = destroy_gen_fifo((pf), (fifo_deleter)(func)))
 #define APPEND_G_FIFO(pf, pe)          \
        ((pf) = append_gen_fifo((pf), (pe)))
 #define CONCAT_G_FIFOS(first, second)  \
@@ -290,11 +303,13 @@
 attr_val *create_attr_uval(int attr, u_int value);
 attr_val *create_attr_rangeval(int attr, int first, int last);
 attr_val *create_attr_sval(int attr, const char *s);
+void     destroy_attr_val(attr_val *node);
 filegen_node *create_filegen_node(int filegen_token,
                                  attr_val_fifo *options);
 string_node *create_string_node(char *str);
 restrict_node *create_restrict_node(address_node *addr,
                                    address_node *mask,
+                                   short ippeerlimit,
                                    int_fifo *flags, int line_no);
 int_node *create_int_node(int val);
 addr_opts_node *create_addr_opts_node(address_node *addr,
diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp_fp.h
--- a/external/bsd/ntp/dist/include/ntp_fp.h    Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp_fp.h    Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp_fp.h,v 1.9 2017/04/13 20:17:41 christos Exp $      */
+/*     $NetBSD: ntp_fp.h,v 1.10 2018/04/07 00:19:52 christos Exp $     */
 
 /*
  * ntp_fp.h - definitions for NTP fixed/floating-point arithmetic
@@ -366,6 +366,7 @@
 extern void    get_systime     (l_fp *);
 extern int     step_systime    (double);
 extern int     adj_systime     (double);
+extern int     clamp_systime   (void);
 
 extern struct tm * ntp2unix_tm (u_int32 ntp, int local);
 
diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp_keyacc.h
--- a/external/bsd/ntp/dist/include/ntp_keyacc.h        Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp_keyacc.h        Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp_keyacc.h,v 1.1.1.2 2018/04/07 00:15:47 christos Exp $      */
+/*     $NetBSD: ntp_keyacc.h,v 1.2 2018/04/07 00:19:52 christos Exp $  */
 
 /*
  *  ntp_keyacc.h - key access stuff
diff -r 27154a0a4445 -r 33af96905777 external/bsd/ntp/dist/include/ntp_request.h
--- a/external/bsd/ntp/dist/include/ntp_request.h       Sat Apr 07 00:15:40 2018 +0000
+++ b/external/bsd/ntp/dist/include/ntp_request.h       Sat Apr 07 00:19:52 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntp_request.h,v 1.7 2016/01/08 21:35:35 christos Exp $ */
+/*     $NetBSD: ntp_request.h,v 1.8 2018/04/07 00:19:52 christos Exp $ */
 
 /*
  * ntp_request.h - definitions for the ntpd remote query facility
@@ -162,7 +162,7 @@
        req_data_u u;                   /* data area */
        l_fp tstamp;                    /* time stamp, for authentication */
        keyid_t keyid;                  /* (optional) encryption key */
-       char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */
+       char mac[MAX_MDG_LEN];          /* (optional) auth code */
 };
 
 /*
@@ -172,7 +172,7 @@
 struct req_pkt_tail {
        l_fp tstamp;                    /* time stamp, for authentication */
        keyid_t keyid;                  /* (optional) encryption key */
-       char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */
+       char mac[MAX_MDG_LEN];          /* (optional) auth code */
 };
 
 /* MODE_PRIVATE request packet header length before optional items. */
@@ -534,6 +534,8 @@
        u_int32 badauth;        /* bad authentication */
        u_int32 received;       /* packets received */
        u_int32 limitrejected;  /* rate exceeded */
+       u_int32 lamport;        /* Lamport violations */
+       u_int32 tsrounding;     /* Timestamp rounding errors */
 };
 
 
@@ -654,7 +656,7 @@
        u_int32 addr;           /* match address */
        u_int32 mask;           /* match mask */
        u_int32 count;          /* number of packets matched */
-       u_short flags;          /* restrict flags */
+       u_short rflags;         /* restrict flags */
        u_short mflags;         /* match flags */
        u_int v6_flag;          /* is this v6 or not */
        u_int unused1;          /* unused, padding for addr6 */
@@ -669,6 +671,7 @@



Home | Main Index | Thread Index | Old Index