NTP Orphan Mode stratum setting is not displayed in input field
The "Orphan Mode" setting in the NTP config is not displayed in the input form field.
It is used, though. I checked the config file (
/var/etc/ntpd.conf), the correct value is used there. When submitting the form with the empty field,
12, the default value is used in the config file.
I could reproduce it in the current stable release (
2.3.2-RELEASE-p1 (amd64)), on a firewall used in production and the current nightly snapshot (
2.4.0-BETA (amd64), built on Thu Dec 22 16:08:06 CST 2016), freshly installed in a VM. I don't know if non-amd64 architectures are also affected.
#4 Updated by Thomas Rieschl about 1 year ago
I just tested it with the current nightly (
2.4.0-BETA (amd64) built on Wed Jan 04 13:38:53 CST 2017; FreeBSD 11.0-RELEASE-p5). In general it works as expected, although, due to a typo, I noticed that the input is not being validated or filtered.
I could enter a non-numeric value which was accepted, but after restarting the ntpd the following error was logged:
syntax error in /var/etc/ntpd.conf line 7, column 7
line 7 column 7 syntax error, unexpected T_String, expecting T_Integer
Also, whitespace before and after the number is not removed, but that is just cosmetic and doesn't trigger an error.
#7 Updated by Thomas Rieschl about 1 year ago
Just tested again with
2.4.0-BETA (amd64) built on Fri Jan 06 01:41:07 CST 2017, FreeBSD 11.0-RELEASE-p5 and it's working now as expected. Also, the weird behavior when entering "12" is gone :)
trim in line 98 (https://github.com/pfsense/pfsense/commit/531c348639adb8b7e7d190e8fdab709fea61f61a#diff-e65382559f6744c6c0a4ab8ac8be6a3fR98) is moot, because "
13" won't validate as numeric anyway.