Details
-
Type: Improvement
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 4.8.0-b1
-
Component/s: None
-
Labels:None
Description
It would be useful to have a validation service that checks whether a hostname is valid. Currently, there are multiple places in modules, and in the core, that perform similar/identical hostname validation checks. See https://www.blesta.com/forums/index.php?/topic/11833-validatehostname-should-accept-uppercase-characters/
I'm thinking a new utility under /core/Util/Validate/Server that provides a method to validate a server's hostname. Perhaps another to validate an IP address.
The Zend framework supports a Hostname validator that appears to handle domain/IDN/IP validation but it's apart of a larger library that requires php 5.6+ and adds up to almost 2MB of files. It may be best in the interim to use php's filter_var with FILTER_VALIDATE_DOMAIN and FILTER_VALIDATE_IP.
Issue Links
- blocks
-
CORE-3294 Update hostname validation for extensions
- Closed
Activity
Field | Original Value | New Value |
---|---|---|
Rank | Ranked higher |
Story Points | 3 |
Description |
It would be useful to have a validation service that checks whether a hostname is valid. Currently, there are multiple places in modules, and in the core, that perform similar/identical hostname validation checks. See https://www.blesta.com/forums/index.php?/topic/11833-validatehostname-should-accept-uppercase-characters/
I'm thinking a new utility under _/core/Util/Validate/Server_ that provides a method to validate a server's hostname. Perhaps another to validate an IP address. |
It would be useful to have a validation service that checks whether a hostname is valid. Currently, there are multiple places in modules, and in the core, that perform similar/identical hostname validation checks. See https://www.blesta.com/forums/index.php?/topic/11833-validatehostname-should-accept-uppercase-characters/
I'm thinking a new utility under _/core/Util/Validate/Server_ that provides a method to validate a server's hostname. Perhaps another to validate an IP address. The Zend framework supports a Hostname [validator|https://github.com/zendframework/zend-validator] that appears to handle domain/IDN/IP validation but it's apart of a larger library that requires php 5.6+ and adds up to almost 2MB of files. It may be best in the interim to use php's _filter_var_ with _FILTER_VALIDATE_DOMAIN_ and _FILTER_VALIDATE_IP_. |
Rank | Ranked higher |
Rank | Ranked higher |
Epic Link |
|
Sprint | 4.7.0 Sprint 2 [ 87 ] |
Rank | Ranked higher |
Fix Version/s | 4.7.0-b1 [ 11123 ] |
Sprint | 4.7.0 Sprint 2 [ 87 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3 [ 87, 88 ] |
Rank | Ranked higher |
Sprint | 4.7.0 Sprint 2, 4.7.0 Sprint 3 [ 87, 88 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4 [ 87, 88, 89 ] |
Rank | Ranked higher |
Sprint | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4 [ 87, 88, 89 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5 [ 87, 88, 89, 90 ] |
Rank | Ranked higher |
Sprint | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5 [ 87, 88, 89, 90 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5, 4.7.0 Sprint 6 [ 87, 88, 89, 90, 91 ] |
Rank | Ranked higher |
Fix Version/s | 4.7.0-b2 [ 11125 ] | |
Fix Version/s | 4.7.0-b1 [ 11123 ] |
Fix Version/s | 4.8.0-b1 [ 11127 ] | |
Fix Version/s | 4.7.0 [ 11125 ] |
Sprint | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5, 4.7.0 Sprint 6 [ 87, 88, 89, 90, 91 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5, 4.7.0 Sprint 6, 4.8.0 Sprint 1 [ 87, 88, 89, 90, 91, 92 ] |
Rank | Ranked higher |
Status | Open [ 1 ] | In Progress [ 3 ] |
Remaining Estimate | 0 minutes [ 0 ] | |
Time Spent | 54 minutes [ 3240 ] | |
Worklog Id | 12641 [ 12641 ] |
Time Spent | 54 minutes [ 3240 ] | 2 hours, 24 minutes [ 8640 ] |
Worklog Id | 12643 [ 12643 ] |
Status | In Progress [ 3 ] | In Review [ 5 ] |
Resolution | Fixed [ 1 ] |
Sprint | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5, 4.7.0 Sprint 6, 4.8.0 Sprint 1 [ 87, 88, 89, 90, 91, 92 ] | 4.7.0 Sprint 2, 4.7.0 Sprint 3, 4.7.0 Sprint 4, 4.7.0 Sprint 5, 4.7.0 Sprint 6, 4.8.0 Sprint 1, 4.8.0 Sprint 2 [ 87, 88, 89, 90, 91, 92, 93 ] |
Time Spent | 2 hours, 24 minutes [ 8640 ] | 4 hours, 17 minutes [ 15420 ] |
Worklog Id | 12656 [ 12656 ] |
Time Spent | 4 hours, 17 minutes [ 15420 ] | 4 hours, 32 minutes [ 16320 ] |
Worklog Id | 12673 [ 12673 ] |
Status | In Review [ 5 ] | Closed [ 6 ] |
Depending on complexity, an initial fix for uppercase characters could be made per https://dev.blesta.com/browse/CORE-2832 While it would be good to have a consistent way of validating hostnames which modules can utilize, this shouldn't slow down a fix for resolving uppercase character validation in individually affected modules.