Re: sockaddr_storage

2017-01-27 Thread Hal Murray
e...@thyrsus.com said: >> Are there any places left in the code that are storing addresses in >> packed-4-octets or ints? > These are areas I will have to investigate. I think the storage is all sockaddr_u I think all the printout goes through socktoa in libntp/socktoa.c The input side is 2 t

Hash function support, MD5 / SHA256, strawman proposal

2017-01-27 Thread Hal Murray
fallenpega...@gmail.com said: > How hard would the following be? > Just go ahead and add SHA256 to NTPsec then Write an I-D modifying the NTP4 > protocol documenting it. then Write a patch to NTP classic for it. > (yes, I know, icky code) I think you are overlooking how long it takes to update t

Re: Crypto tangle

2017-01-27 Thread Hal Murray
dfoxfra...@gmail.com said: > Setting aside any countervailing considerations concerning dependencies and > binary footprint, yes. MAC computation lives in the real-time critical > section where speed means precision so any optimization we can get here is a > win. Just to make sure we are all on

More on crypto

2017-01-28 Thread Hal Murray
e...@thyrsus.com said: > BTW, I've successfully turfed out the ISC MD5 code. This dropped about > 300LOC. Still need to get rid of the local SHA-1 and remove the libsodium > dependency. Just to make sure I/we understand... The plan is to require OpenSSL and drop sodium and the local copies of

Timings for random

2017-01-28 Thread Hal Murray
Intel(R) Core(TM) i3-2120 CPU @ 3.30GHz Stdlib: 100 calls to rand() took 0.021 microseconds each Sodium: 100 calls to randombytes_buf() took 0.367 microseconds each OpenSSL: 100 calls to RAND_pseudo_bytes() took 0.630 microseconds each Raspberry Pi 2 model name : ARMv7 Processor

Copyright dates

2017-01-28 Thread Hal Murray
Do they need to be updated? I just noticed one that was 2015. Should that go on the release checklist? -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.org/mailman/listinfo/devel

Re: Timings for random

2017-01-28 Thread Hal Murray
g...@rellim.com said: > rand() and RAND_pseudo_rand() are not random, just psuedo random, thus not > for NTP. Do you think fuzzing needs cryptographically strong randomness? I timed RAND_pseudo_bytes() rather than RAND_bytes() because I didn't want to get mixed up with not enough randomness and

Crypto timings

2017-01-29 Thread Hal Murray
This is computing the digest for a password and a 48 byte packet, then dropping it on the floor. The "old" version uses EVP_DigestInit, like the current code in ntpd. The new version uses EVP_DigestInit_ex and a static context. Intel(R) Core(TM) i3-2120 CPU @ 3.30GHz 100 MD5 encrypts took

Re: Crypto timings

2017-01-29 Thread Hal Murray
e...@thyrsus.com said: > I'm not sure we care a lot about this performance gain, given that SHA-1 use > seems to be uncommon. But the change seems simple enough and would only need > to be done in two places. Would it change the floor version of OpenSSL we > can use? The speedup applies to any t

Re: Timings for random

2017-01-29 Thread Hal Murray
g...@rellim.com said: > You can't run out of randomness with RAND_bytes(). Would you please say more. The man page says: RAND_bytes() puts num cryptographically strong pseudo-random bytes into buf. An error occurs if the PRNG has not been seeded with enough randomness to en

Re: Recent trends in the codebase size

2017-01-29 Thread Hal Murray
fallenpega...@gmail.com said: > Is there a reason to keep dumbclock? Maybe it exists as a starting > framework for when someone wants to write a new clockdriver? It's not good for much more. It's not clear that there is any good way to have a starting point reference. If you give examples o

Profiling tools?

2017-01-29 Thread Hal Murray
What tools are available for figuring out where the cycles are going? I'd like to understand how fast ntpd does and/or can go. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.org/mailman/listinfo/

Clocks broken on Mac mini

2017-01-29 Thread Hal Murray
Both Linux (Debian) and FreeBSD have the same problem. The symptom is that the drift goes to 500 PPM and that isn't enough so every few minutes it steps the clock. 29 Jan 18:12:01 ntpd[568]: 0.0.0.0 c61c 0c clock_step +0.623666 s 29 Jan 18:17:13 ntpd[568]: 0.0.0.0 c61c 0c clock_step +0.636564 s

Re: Crypto timings

2017-01-29 Thread Hal Murray
e...@thyrsus.com said: > Please commit it, then. There are two issues tangled up in this area. Build fails on Debian sid (#237) https://gitlab.com/NTPsec/ntpsec/issues/237 Debian sid has openssl 1.1.0c OpenSSL v1.1 compatibility (!306) https://gitlab.com/NTPsec/ntpsec/merge_requests/306 I

Re: Clocks broken on Mac mini

2017-01-29 Thread Hal Murray
e...@thyrsus.com said: > Well, that's disturbing. But hard to act on until we get a better idea > what's busted Sorry if I wasn't clear. It's the kernel, not our code. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.o

Re: Crypto timings

2017-01-29 Thread Hal Murray
e...@thyrsus.com said: [context is cleaning up crypto code] > Oh dear Goddess you are right. I think I noticed that before but spaced it. > I'll fix that up once I've had some sleep. My straw man is that the table that holds keys has password password length digest length the magic that

Re: Policy question - drop low-precision clocks?

2017-01-30 Thread Hal Murray
e...@thyrsus.com said: > In the wake of the dumbclock removal, I'm now wondering if it makes any > sense at all to retain refclocks that report only in-band time to a > precision of a second. That is, without 1PPS. I think you are on a wild goose chase. You can get very accurate timing from a

Re: Policy question - drop low-precision clocks?

2017-01-30 Thread Hal Murray
e...@thyrsus.com said: > So, the only way to get accurate time out of this box is to pass its 1PPS > output through an outboard conter chip. That doesn't make sense. If you have PPS, why not feed it into the serial port. -- These are my opinions. I hate spam.

Rough edge to clean up

2017-01-30 Thread Hal Murray
EVP_MD_CTX_FLAG_NON_FIPS_ALLOW is only used in libntp/macencrypt.c EVP_MD_CTX_init(&ctx); #ifdef EVP_MD_CTX_FLAG_NON_FIPS_ALLOW /* MD5 is not used as a crypto hash here. */ EVP_MD_CTX_set_flags(&ctx, EVP_MD_CTX_FLAG_NON_FIPS_ALLOW); #endif if (!EVP_DigestInit_ex(&c

Re: Copyright dates

2017-01-30 Thread Hal Murray
fallenpega...@gmail.com said: > Right now our standard copyright text is "Copyright $YEAR_YOU_ARE_WRITING_THI > S by the NTP Project contributors" Should the documentation files have a copyright notice? -- These are my opinions. I hate spam. ___

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
h...@blemings.org said: > If it would be of help I've a couple of friends who still do Linux/PowerPC > kernel work, might be able to prod them about a fix at least for upstream > if we have a simple to demonstrate test case and are confident it's in the > kernel. Thanks. I think that would be

Re: Recent trends in the codebase size

2017-01-30 Thread Hal Murray
fallenpega...@gmail.com said: > My inclination is that when more clock types show up, they get a driver > running in it's own process space, and exporting a SHM buffer. We should clean up the SHM interface first. The ntpd side should be read only. > The problem with covering existing drivers t

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
h...@blemings.org said: > That sounds right for getting into OpenFirware - but for what we're digging > into you shouldn't need to putz with it. I got into open firmware. It doesn't like my KVM switching setup. A real keyboard worked. I did a printenv and didn't see anything clock related.

Re: Rough edge to clean up

2017-01-30 Thread Hal Murray
e...@thyrsus.com said: > Maybe not. I went looking for other places the refid computation is done > and that seems to be it. What other other places did you have in mind? I was thinking of other places that called EVP_DigestInit If we need that flag for addr2refid, do we need it for other use

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
> That Mac Mini (Late 2005) was sold with either 1.3GHz or 1.5GHz, per > Mactracker. > Looks like you do have the 1.5GHz version. That doesn't agree with my samples in hand. There is a row of text on the underside along the connector edge. I have 3 samples: One gives serial number and Ethern

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
> $ cat /proc/cmdline root=UUID=48d99649-90b2-4dc6-be05-5ca3858579a1 ro h...@blemings.org said: > That sounds right for getting into OpenFirware - but for what we're digging > into you shouldn't need to putz with it. It looks like the kernel code is getting the clock frequency from Open Firm

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
> $ uname -a Linux deb-ppc.example.com 3.16.0-4-powerpc #1 Debian 3.16.39-1 (2016-12-30) ppc GNU/Linux > $ cat /etc/issue Debian GNU/Linux 8 \n \l > One other query if I may - I think you've already confirmed this behaviour > across a couple of physical machines ? Just want to rule out a sing

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
>From a second system: 30 Jan 19:46:40 ntpd[3773]: frequency error 2712 PPM exceeds tolerance 500 PPM 30 Jan 19:46:43 ntpd[3773]: ntpd exiting on signal 15 (Terminated) $ more /proc/cpuinfo processor : 0 cpu : 7447A, altivec supported clock : 1416.61MHz revision

Re: Clocks broken on Mac mini

2017-01-30 Thread Hal Murray
> 30 Jan 19:46:40 ntpd[3773]: frequency error 2712 PPM exceeds tolerance 500 PPM > clock : 1416.61MHz If the clock really is 1.42 GHz but the system thinks it is 1.416... My calculations say it's off by 2400 ppm That's the sort of glitch I've been looking for. The next question is

Re: Rough edge to clean up

2017-01-30 Thread Hal Murray
e...@thyrsus.com said: > There are three uses in libntp/macencrypt.c. Two of them are MAC > computations that do require crypto security. You found the third, which > doesn't. The flag seems to be intended to tag hashes that don't require > crypto security, so we seem to be OK so far. If we ne

Re: Policy question - drop low-precision clocks?

2017-01-30 Thread Hal Murray
> The driver is polled, so it's not going to be shipping time at a fixed > offset from top of second. Reading the code, do you see any way we get > precision of less than a second out of it? It also gets normal serial info via true_receive The polling is necessary to handle the case where the d

Re: Clocks broken on Mac mini

2017-01-31 Thread Hal Murray
I poked around enough in Open Firmware to "fix" the clock parameters. But it made things worse rather than better. I assume some step in my thinking is backwards. > When I get some time later today/tonight I'll summarise what we have so far > into a single email and send that off to the linu

Re: Clocks broken on Mac mini

2017-01-31 Thread Hal Murray
h...@blemings.org said: > Oh ok, did it make any sort of sensible change ? Did tweaking the clock > parameter the "wrong" way make it better I wonder ? I didn't try that. The change I tried seemed reasonable. I might have fatfingered something. It takes just long enough to try something tha

Re: Clocks broken on Mac mini

2017-01-31 Thread Hal Murray
h...@blemings.org said: > Embarrassingly it only just occurred to me to apply some google fu to "Mac > Mini G4 clock problem" and it yielded some interesting hits. > "Clock Drift on Mac Mini (G4-based), ajdtimex, ntp" - undated http://i1.dk/ > misc/mac_mini_clock_drift_adjtimex_ntp.html > "Syst

Re: Clocks broken on Mac mini

2017-01-31 Thread Hal Murray
g...@rellim.com said: > I think we are heading the wrong way on this. It is not an Open Firmware > problem and it is not a Mac problem. I have seen this before with NTP > Classic. I have verified before that Chronyd does not have the same issue. > There was a time I used to buy and provision

Re: Clocks broken on Mac mini

2017-01-31 Thread Hal Murray
>> Looks like ntpd is happy now. > And what was the magic incantation? Can you reset and make ntpd fail again? Installing adjtimex. Aside from the command line, it's got a mode where tries to adjust the drift like ntpd does. I think saves stuff on the disk so when you run it again it can see

Re: Timekeeping oddities on MacMini G4s

2017-01-31 Thread Hal Murray
Thanks. b...@kernel.crashing.org said: > Right, we just use the value provided by Open Firmware. Any chance you can > try with MacOS X ? Not easily. I'm using boxes from eBay. They didn't come with CDs and I've already installed other software. > From the value in the properties you showed

Re: Timekeeping oddities on MacMini G4s

2017-01-31 Thread Hal Murray
b...@kernel.crashing.org said: > Ok, I do have one though somewhere with OS X on it. If you give me > instructions on how to test (I know near to nothing about ntpsec), I should > be able to compile and run it. I'm assuming you are already running the normal ntpd from ntp classic, or Apple's ver

Re: Reconstructing our issue list

2017-02-01 Thread Hal Murray
* waf needs some tlc #212 · opened a month ago by Hal Murray updated 3 weeks ago waf check generates: ``` magic.pyc control.pyc version.pyc magic.pyo control.pyo version.pyo ``` waf build should have done all of that. ctx.add_group() is called after the ctx() calls to build

Re: Reconstructing our issue list

2017-02-01 Thread Hal Murray
It's reasonably easy to setup a cron job to make a copy of the data in git. How many of us should do it? Is there any way to grab a copy of the issues data? What do we have in the way of backup for our other stuff? How much is there that's not on gitlab? --- A while ago, I signed up fo

ntpq peers formatting needs floating point for time slots.

2017-02-01 Thread Hal Murray
[I tried to submit an issue, but it was reject as spam.] Somebody recently changed things to print out a 4th digit. That made things worse. It was already broken if you had a negative number bigger than 1000 which isn't all that uncommon. ntpq -p remote refid st t when pol

Re: ntpq peers formatting needs floating point for time slots

2017-02-01 Thread Hal Murray
g...@rellim.com said: > Eric did that. Also notice the LSB is always zero, which is clearly also > wrong. I just pushed a fix. That stuff goes from ntpd to ntpq as text. It was 3 digits of fraction. Now 6. -- The printout in ntpq still needs floating point for big numbers. -- These

Re: ntpq peers formatting needs floating point for time slots

2017-02-01 Thread Hal Murray
>> The printout in ntpq still needs floating point for big numbers. > Not sure how that would look. Ugly, but less ugly than the current setup. In case I wasn't clear, instead of printing "-1234.5678", it should print "-1234.56". It's probably simplest to turn it into a string with 4 digits to

Re: ntpq peers formatting needs floating point for time slots

2017-02-01 Thread Hal Murray
> Since it is a string, maybe send something nicer? The formatting should be done in ntpq. Your version of "nice" conflicts with mine. As far as I'm concerned, you can fix ntpq so it has an option to do anything you want as long as the default doesn't change. -- PS: My suggesti

Re: ntpq peers formatting needs floating point for time slots.

2017-02-02 Thread Hal Murray
e...@thyrsus.com said: > Sigh. I'll revert that commit. I don't think there's any horizontal slack > left in the display, then. Don't revert. I'll fix it. The current display is 78 characters wide. Is there a good reason not to use the last 2? g...@rellim.com said: > Hal already updated y

Testing unusual build options

2017-02-02 Thread Hal Murray
At Gary's suggestion a while ago, I just pushed a script that will test various configuration combinations. Partly, I was trying to make sure all of the options were tested. It's tests/option-tester.sh It writes stuff into ./test-xxx where xxx is the tag for an individual test. If you have an

Re: ntpq peers formatting needs floating point for time slots.

2017-02-02 Thread Hal Murray
e...@thyrsus.com said: >> The current display is 78 characters wide. Is there a good reason >> not to use the last 2? > Nope. That's what my previous commit did. There may be quirks with somebody putting in a line break at exactly 80 rather than waiting to see if the next character is a retu

Re: ntpq peers formatting needs floating point for time slots.

2017-02-02 Thread Hal Murray
e...@thyrsus.com said: >> Looks like lines from ntpmon are one character shorter than ntpq. > They use the same display code - pylib/uril.py::PeerSummary. I get the same width when run directly on a system, but see the difference when ssh-ing into that system. The refid column and everything t

Re: Testing unusual build options

2017-02-02 Thread Hal Murray
>> --enable-doc-only doesn't build any documentation. :) > I think that is a silly option, and a perfect example of how the recipe got > overcomplicated. I'm going to remove it. How do I update the installed documentation without updating the code? -- These are my opinions. I hate spam.

Re: Testing unusual build options

2017-02-02 Thread Hal Murray
> I would want my installedcode to match my installed doc. I agree. But use your imagination. The default is no doc. You have to turn on --enable-doc to get it. Suppose I have done extensive testing with the installed code but forgot to turn on --enable-doc. Why should I re-install the same

Re: Testing unusual build options

2017-02-02 Thread Hal Murray
e...@thyrsus.com said: > That soumds like a request for two two different *install* productions. > Noted. I could easily imagine a rats-nest. Why just two? How about a no-ntpviz option? How about a no-clients option? The latter gets "interesting". I think there are two types of clients. T

Re: ntpq peers formatting needs floating point for time slots.

2017-02-03 Thread Hal Murray
I just pushed a fix. Please test. I bumped the width from 78 to 79. If that screws up, we should document a test case. I'm assuming the output supports an 80 character line. There was a space-space before the delay column. I grabbed one of them. Those 2 extra spaces let me change the widt

FWD: Go API for monotonitc elapsed time measurements

2017-02-03 Thread Hal Murray
[From the leapseconds list - good background on timekeeping in go] This is an interesting proposal for fixing the Cloudflare leap second bug, so that time interval calculations do sensible things even when the clock is reset, without making an incompatible change to the existing APIs. https://git

Re: ntpq peers formatting needs floating point for time slots.

2017-02-04 Thread Hal Murray
matthew.sel...@twosigma.com said: > We need some backwards compatibility for ntp classic servers. Eg, the > server has only microsecond precision. We need to avoid adding trailing > zeros that are not actually significant. Good catch. Thanks. I just pushed a fix. It's the sort of kludge tha

Re: ntpq peers formatting needs floating point for time slots.

2017-02-04 Thread Hal Murray
> Is the jitter column header/data supposed to have moved 1 character to the > right? Yes. The printout is now 79 characters wide rather than 78. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.

Re: ntpq peers formatting needs floating point for time slots.

2017-02-04 Thread Hal Murray
strom...@nexgo.de said: > I don't know how compatible you are trying to stay with the "classic" > output, but to me it seems you'd be better off with such changes made > conditional on the use of an option, either a new one or maybe the existing > '-W' one (which means that the extra space first g

Re: Timekeeping oddities on MacMini G4s

2017-02-04 Thread Hal Murray
g...@rellim.com said: > Then you have to take aging into account. A 10 year old Mac may have difted > a lot. Or maybe the crystal got bumped. > Also a lot of crystals are now surface mount. The soldering process may > have bend to crystal a lot. Do you have references to any published data?

Re: Timekeeping oddities on MacMini G4s

2017-02-04 Thread Hal Murray
Thanks. f...@fwright.net said: > That seems inconsistent with the following comment in arch/powerpc/kernel/ > time.c: > * TODO (not necessarily in this file): > * - improve precision and reproducibility of timebase frequency > * measurement at boot time. I didn't see any calibration code, bu

duplicate documentation

2017-02-04 Thread Hal Murray
We have two copies of the documentation for the statistics files. One in docs/includes/mon-commands.txt and another in docs/statfiles.txt -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.org/mailm

Re: *****SPAM***** Re: ntpq peers formatting needs floating point for time slots.

2017-02-05 Thread Hal Murray
strom...@nexgo.de said: > Well, If I know that I'm going to display ten characters wider than usual, I > can add teo digits of extra precision before I widen the space for the > hostname by four digits. That sort of intelligence. All the recent changes have been for the case of no extra command

Re: Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Hal Murray
strom...@nexgo.de said: >> # ntpq -c 'rv 0 frequency' >> frequency=-0.928558 > Make that number go into the loopstats file as well? I don't suppose I > should log the output of ntpq to benefit from that extra precision. Is anybody actually running gear where more than 3 fractional digit

Re: Timekeeping oddities on MacMini G4s

2017-02-05 Thread Hal Murray
> Tell me what to look for, and I’ll take as many hi-res pictures as you want. I'm looking for the frequency printed on the oscillator/crystal. Here is a picture with several examples: https://en.wikipedia.org/wiki/File:Crystal_Packages.jpg The row of Oscillators is most likely. They also c

Re: Timekeeping oddities on MacMini G4s

2017-02-07 Thread Hal Murray
> What do I do if I don't have an existing ntp.conf ? Assuming ntpsec builds... There are sample config files in config/ contrib/ntp.conf.log.sample has logging which you probably want. it has lots of comments. It is setup to use us.pool.ntp.org If you aren't in the us, you should probably cha

Re: ntpq peers formatting needs floating point for time slots.

2017-02-07 Thread Hal Murray
g...@rellim.com said: > OTOH, prolly best to set it to -30, just for grins. Someday it might > matter, or I might have missed something, or just to seem to do the right > thing. Looks like we are getting into the old precision vs accuracy tangle. Do we have a glossary with useful descriptions?

current HEAD is broken on old gcc (and warnings on current clang)

2017-02-13 Thread Hal Murray
Debian wheezy gcc (Debian 4.7.2-5) 4.7.2 [96/97] Linking deb/main/ntpd/ntpd /usr/bin/ld: libntp/pymodule.c.2.o: relocation R_X86_64_PC32 against symbol `progname' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: final link failed: Bad value collect2: error: ld retur

Re: clockvar reporting from generic (DCF77)

2017-02-20 Thread Hal Murray
>> I suspect the problem is back in ntpd, which is sending bad mode 6. > Fortunately, that kind of thing is easy to fix once characterized. And I > know that code *really* well. Post an issue one you've figured out what's > going wring, I'll be on it instantly. The ntpd side of ntpq -c "cv &" (

Re: ntpclient names

2017-02-21 Thread Hal Murray
>> gps-log -> ntpgpslog >> temp-log -> ntptemplog >> makeheat -> ntpmakeheat > That works for me. I'd make 'em shorter if I could, but don't see any > obvious way to do that that wouldn't reduce them to garble. Those names aren't going to be typed by hand very often so I do

Re: ntpclient names

2017-02-21 Thread Hal Murray
e...@thyrsus.com said: > I've forgotten. What's the actual problem with including ntpviz in the > standard install? 1) General clutter for the 99% who won't use it. 2) It drags in a big pile of stuff, starting with gnuplot. -- These are my opinions. I hate spam.

Re: ntpsec | Extra precision for avgint field in ntpmon (#247)

2017-02-22 Thread Hal Murray
issue tracker. Subject: Re: ntpsec | Extra precision for avgint field in ntpmon (#247) From: Hal Murray Date: Tue, 14 Feb 2017 23:41:33 -0800 To: NTPsec / ntpsec Cc: hmur...@megapathdsl.net > avgint should be an integer, not a float. That change is a feature, not a bug. Otherwise you can'

Information lost when switching to buildprep

2017-02-22 Thread Hal Murray
Gary said: >> 2) It drags in a big pile of stuff, starting with gnuplot. > No. At least one of us is confused. buildprep installs gnuplot unconditionally. Perhaps you mean that it doesn't need to do that. But currently it does. What does ntpviz do without gnuplot and/or why would I want to d

Re: Generic doesn't log into clockstat

2017-02-22 Thread Hal Murray
strom...@nexgo.de said: > Like the NMEA clock: day, time of day, clock ID, timecode (optionally maybe > the decoded time and flags from the timecode). There are two approaches to logging clockstats info. As background, the assumption is that you don't want to log everything. You can log stuff

Re: ntpclient names

2017-02-22 Thread Hal Murray
g...@rellim.com said: > I'm unaware of anything in NTPsec that does things behind anyone's back. >> Does it start a server? Does it run a cron job? Does it install >> hooks that some code I do need might call? > Now I'm really lost. I'm unaware of anything in NTPsec does any of that > without

INSTALL and buildprep

2017-02-23 Thread Hal Murray
There is a tangle in this area, and I think you are the right one to sort it all out. buildprep is is the tip of an interesting iceberf. It's good since it contains some info in a form that is very easy to use. But it's also evil since all the associated comments that used to be in INSTALL h

Re: ntpclient names

2017-02-23 Thread Hal Murray
> Our scripts are just for developers and for packagers to get a start. I think we can do a better job of providing the information that a packager needs. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists

Re: INSTALL and buildprep

2017-02-23 Thread Hal Murray
e...@thyrsus.com said: > Right now we have one action (pull all dependencies from the platform's > package manager) and no switches. What switches and actions need to be > added? show about to be installed files without tools, tools only run only print stuff in a human friendly format neede

Re: INSTALL and buildprep

2017-02-23 Thread Hal Murray
> tag required packages with the feature that requires them Or maybe only tell me about the packages needed for a specific configuration. There is a chicken/egg problem with waf. It won't configure unless the header files and libraries are available. There is also the cross build area. Tell m

Google+CWI announce SHA1 attack, publishe a collision

2017-02-23 Thread Hal Murray
https://security.googleblog.com/2017/02/announcing-first-sha1-collision.html Today, 10 years after of SHA-1 was first introduced, we are announcing the first practical technique for generating a collision. This represents the culmination of two years of research that sprung from a collaboration

Re: Generic doesn't log into clockstat

2017-02-24 Thread Hal Murray
> The DCF77 only produces one timestamp each minute, so there really isn't a > big push for data reduction compared to NMEA's timestamp each second. I'd > really like to record the timestamp as received since it'll be useful in > case there's a problem with reception you can easily determine if it

Re: DCF77 driver seems to be broken

2017-02-25 Thread Hal Murray
> I've opted to fix the comments. > * compare previously-normalised a and b > - * return 1 / 0 / -1 if a < / == / > b > + * return -1 / 0 / 1 if a < / == / > b Thanks for making it match what other cmp type routines do. -- These are my opinions. I hate spam. ___

Re: PPS documentation

2017-02-26 Thread Hal Murray
g...@rellim.com said: > I thought we had killed it. If not it needs to be killed. It should never > be used. No. If nothing else, we need a way to test it to show that it is/isn't as good as other approaches. -- These are my opinions. I hate spam. _

Re: Bounding the target platforms

2017-02-27 Thread Hal Murray
e...@thyrsus.com said: > So let's drop back to two questions: > 1. What platforms do we care about supporting in client mode (doesn't need > PPS)? I don't see how you jumped from client mode to not needing PPS. I'm not even sure what "client mode" means. Does it mean no clients? aka it is a c

Re: Feature Removals, NMEA GPS

2017-02-27 Thread Hal Murray
g...@rellim.com said: > What hassle? Just install and run, gpsd auto configures. Autoconfigure can be a bug or a feature. It can be great if it does what you want. I often have more than one serial device plugged into a system. It's a bug if gpsd messes with the ones I don't want it to touc

Re: Bounding the target platforms

2017-03-01 Thread Hal Murray
e...@thyrsus.com said: > The immediate issue is whether we can drop RFC1589 support in favor of > RFC2783. RFC1589 describes an in-kernel PLL that synchronizes the system clock to an external PPS signal. RFC2783 describes the API for user code to read the time stamps for a PPS signal that the

Re: Scheduling a repository outage

2017-03-05 Thread Hal Murray
e...@thyrsus.com said: > 3. Reply to this message telling me you're ready - especially if you >are Gary, Matt, or Hal. Go for it. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.org/mailman/

Re: Repository downtime scheduled from 1500 to 1600 today

2017-03-06 Thread Hal Murray
e...@thyrsus.com said: > Please keep track of any problems or remediation actions you need to take as > a result of the surgery. 75% of the point of this procedure is to clarify > what we need to do when making more serious changes. > The NTPsec repo is scheduled to be out of service for surge

Re: Repository downtime scheduled from 1500 to 1600 today

2017-03-06 Thread Hal Murray
> I caught 140 typos in this round. Thanks. -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http://lists.ntpsec.org/mailman/listinfo/devel

Re: Repository surgery is complete

2017-03-06 Thread Hal Murray
> If you have any difficulties with the alterered repo, please report them. I did a git pull and all seemed happy. Actually, I did two, one for my local unaltered copy of gitlab and a second from there to my working copy which had some changes. Both seemed happy. Is that what you expect? Wil

Re: lfpinit() signed or unsigned?

2017-03-08 Thread Hal Murray
g...@rellim.com said: > Does lfpinit() need to return a signed? Or should the parameters to > lfpinit() annd be unsigned? I'm guessing the later, but I'm new to that > part of the code... Good catch. I think both parameters should be unsigned. If you want a negative answer, you need to think

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
e...@thyrsus.com said: > It doesn't matter. All those calculations are casted to within an inch of > their lives. :-) Would it help to have another signed type? -- These are my opinions. I hate spam. ___ devel mailing list devel@ntpsec.org http

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
e...@thyrsus.com said: > The macros that are the API for the abstract data type are constructed to be > indifferent to whether the underlying concrete 64-bit type is signed or > unsigned. If I were willing to commit either way I could throw away several > of them in favor of bare arithmetic opera

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
g...@rellim.com said: > So we are now doing modulo arithmetic. I believe that ntpd expects to be using modular arithmetic for time. I don't have a handy pointer to any documentation to back that up. Most of the internal calculations are done with time represented as the offset from the system

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
g...@rellim.com said: > Yeah, I see that now. But as you pointed out, NTP time is already modulo, > so it only fails immediately after the rollover. > But that rollover is gonna be rough... I think it should be clean if/after we get the code right. Assume we have 64 bit Unix/POSIX time_t. Th

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
e...@thyrsus.com said: >> Do any of the casts actually change any bits? > I believe not. Then all the casts are just noise to keep the compiler happy and/or hints to tell the reader what the intent is. > I believe the RFC intention is that they should be unsigned offsets from an > epoch date,

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
e...@thyrsus.com said: >> How about something like l_fp_time (unsigned) and >> l_fp_delta or _fp_offset (signed)? > More detail, please? Replace typedef uint64_t l_fp; with typedef uint64_t l_fp_time; typedef int64_t l_fp_offset; Then replace all the places that used to use l_fp with the

Re: lfpinit() signed or unsigned?

2017-03-09 Thread Hal Murray
e...@thyrsus.com said: >> Does the current code have the right variable? Have you found it? >> Is there more than one place that does NTP to Unix conversion? > What you're looking for is called the "pivot point", snd it's implemented in > libntp/systime.c. Thanks. > There used to be sporadic N

Re: lfpinit() signed or unsigned?

2017-03-10 Thread Hal Murray
g...@rellim.com said: >> How about something like l_fp_time (unsigned) and >> l_fp_delta or l_fp_offset (signed)? > I'm now leaning that way too. And two ways to make an l_fp, one starting > with int's and the other uint's. Be careful with making negative values. The case I'm worried about is

Re: lfpinit() signed or unsigned?

2017-03-10 Thread Hal Murray
g...@rellim.com said: >> Be careful with making negative values. The case I'm worried about >> is dropping the carry out of the low half. > The code has a normalize_tspec() ir prolly needs a normalize_lp(). There is nothing to normalize in a l_fp All bit patterns are valid. > Because a RasPi

Do we need a few new types?

2017-03-10 Thread Hal Murray
POSIX has time_t ntp_types.h has time64_t There are various places that are working with seconds since NTP epoch. They are using uint32_t and uint64_t. I think we want something like ntp_time32_t and ntp_time64_t. I'm looking for something that will tell the reader that it's a seconds since

Re: lfpinit() signed or unsigned?

2017-03-10 Thread Hal Murray
g...@rellim.com said: >> There is nothing to normalize in a l_fp All bit patterns are valid. > Sort of. The header notes imply the integral and fractional part may be > signed or unsigned. Separately. I have not confirmed if the code use that. The whole point of l_fp is so you can do 64 bit a

Re: lfpinit() signed or unsigned?

2017-03-10 Thread Hal Murray
> Yes, but the overhead of timespec arithmetic is small, and pretty soon I > don';t think we will do any arithmetic in l_fp. That seems strange. l_fp seems like an obvious choice to me. Please be very careful before undoing the current stuff. You can find all the places that do arithmetic by

<    1   2   3   4   5   6   7   8   9   10   >