Project

General

Profile

Bug #10386

A NTP Time Server name may only contain the characters a-z, 0-9, '-' and '.'.

Added by Manuel Piovan 7 months ago. Updated 7 months ago.

Status:
Resolved
Priority:
Normal
Category:
Web Interface
Target version:
Start date:
03/28/2020
Due date:
% Done:

100%

Estimated time:
Affected Version:
2.5.x
Affected Architecture:

Description

System / General Setup
localization > time server
if it is populated with an ipv6 server you can't save anymore
A NTP Time Server name may only contain the characters a-z, 0-9, '
' and '.'.

Associated revisions

Revision cb92c086 (diff)
Added by Viktor Gurov 7 months ago

NTP Time Server input validation. Issue #10386

History

#1 Updated by Manuel Piovan 7 months ago

Manuel Piovan wrote:

System / General Setup
localization -> time server
if it is populated with an ipv6 server you can't save anymore
A NTP Time Server name may only contain the characters a-z, 0-9 ....

PR : https://github.com/pfsense/pfsense/pull/4254

#2 Updated by Jim Pingle 7 months ago

  • Status changed from New to Pull Request Review
  • Target version set to 2.5.0

#3 Updated by Renato Botelho 7 months ago

  • Status changed from Pull Request Review to Feedback
  • Assignee set to Renato Botelho
  • % Done changed from 0 to 100

PR has been merged. Thanks!

#4 Updated by Viktor Gurov 7 months ago

  • Status changed from Feedback to Resolved

works OK on 2.5.0.a.20200409.0657,

I see an updated and more correct validation code:

if (!is_domain($ts) && (!is_ipaddr($ts))) {
                        $input_errors[] = gettext("NTP Time Server names must be valid domain names, IPv4 addresses, or IPv6 addresses");
}

#5 Updated by Viktor Gurov 7 months ago

  • Status changed from Resolved to New

same fix for services_ntpd.php:
https://github.com/pfsense/pfsense/pull/4269

#6 Updated by Jim Pingle 7 months ago

  • Status changed from New to Pull Request Review

#7 Updated by Renato Botelho 7 months ago

  • Status changed from Pull Request Review to Feedback

PR has been merged. Thanks!

#8 Updated by Viktor Gurov 7 months ago

  • Status changed from Feedback to Resolved

input validation on 2.5.0.a.20200415.0942 is correct

Also available in: Atom PDF