r7 - 2018-02-14 - 09:46:59 - HarlanStennYou are here: NTP >  Dev Web > DevelopmentIssues > EmbeddedVersionStringContent
NTP users are strongly urged to take immediate action to ensure that their NTP daemons are not susceptible to being used in distributed denial-of-service (DDoS) attacks. Please also take this opportunity to defeat denial-of-service attacks by implementing Ingress and Egress filtering through BCP38.

ntp-4.2.8p10 was released on 21 March 2017. It addresses 6 medium- and 5 low-severity security issues, 4 informational security topics, 15 bugfixes, and contains other improvements over 4.2.8p9.

Please see the NTP Security Notice for vulnerability and mitigation details.

Are you using Autokey in production? If so, please contact Harlan - he's got some questions for you.

Embedded Version String Content

While fixing bug_small.png Bug #683 it was noted that the version string in the code takes the form:

 Version @ CSet [ build-flags ] date buildnumber

where:

Version
the version string, eg 4.2.3p29
@
the @ sign
CSet
A number indicating the latest changeset in the repository

build-flags:

-o
for OpenSSL support

date
the date and time of program linkage
buildnumber
(n), where n counts the number of times the program has been linked in this directory

The intent of this value is to make it easy to identify the state of the codebase when each program was built.

The CSet value is mostly useful to developers, who may build and run several different versions of the programs during testing, and need a way to easily identify which changes are in each executable. The problem with using CSet is that its value can change as the repository is updated. If we:

  • release 4.2.8 and tag it as NTP_4_2_8 when it is at CSet 1.2900,
  • add more changesets, releasing 4.2.8p1 and 4.2.8p2,
  • take this newer repo and check out NTP_4_2_8 and build it,
this built version of 4.2.8 may not be at CSet 1.2900.

This is even more confusing to people.

We need a better understanding of what we're trying to accomplish with the data in the version string content, including the "use cases".

Anyway...

Note that previous versions of NTP used different values for build-flags and the file scripts/mkver describes them.

  • As of 4.2.7p272, 12 April 2012, the mkver script uses VER_SUFFIX, and the value -o means we have OpenSSL.
  • As of 6 Aug 2004, 4.2.1, a suffix of -o means we have -lcrypto and -? means some other crypto library is available.
  • As of 4 May 2000, the suffix -a meant Autokey was supported, in additon to -r for RSA.
  • As of 25 Feb 2000, the suffix was changed to -r.
  • As of 24 Feb 2000, the suffix was changed to -RSAREF.
  • 4.0.99: In July of 1999, the suffix RSAREF meant that the RSA libraries were available.

It has been suggested that some users are confused by the information after the @. While the remaining information is important and useful, it is not part of the software version.

The following suggestions have been made in this regard:

  • Leave it alone
  • Get rid of the information after the @
    • Harlan says not without finding somewhere else for the info
  • Change the @ to something else:
    • 4.2.3p29; 1.123-o
    • 4.2.3p29, build 1.123-o

Changeset Number

The changeset number we have been using comes from bk changes -v -r+ and while the number is short, it can change. It's better to use a changeset key, as that value does not change.

As mentioned above, we build a version string that looks like:

ntpd 4.2.8p10@1.3732-o Sun Feb 11 07:53:58 UTC 2018 (32)

We get the changeset number from:

bk -R prs -hr+ -nd:I: ChangeSet

and this is what a changeset key looks like:

harlan@mb6> bk changes -kr+ | cat
harlan@mb6.tal1.ntfo.org|ChangeSet|20180211102002|15587
harlan@mb6> bk changes -kr+ | wc -c
56
harlan@mb6>

We could store the full changeset key, and only use the final two pieces, resulting in something like:

ntpd 4.2.8p10@20180211102002|15587-o Sun Feb 11 07:53:58 UTC 2018 (32)

which is 71 characters long.

Looking at the discussion above, how about:

ntpd 4.2.8p10-o, build 20180211102002|15587 Sun Feb 11 07:53:58 UTC 2018 (32)

which is 78 characters long. It would be easy enough to change 'Sun Feb 11 07:53:58 UTC 2018' to '20180211.07:53:58' and save 11 characters:

ntpd 4.2.8p10-o, build 20180211102002|15587 20180211.07:53:58 (32)
Edit | WYSIWYG | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r7 < r6 < r5 < r4 < r3 | More topic actions
 
SSL security by CAcert
Get the CAcert Root Certificate
This site is powered by the TWiki collaboration platform
IPv6 Ready
Copyright & 1999-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors. Ideas, requests, problems regarding the site? Send feedback