Automattic / Automattic/jetpack

Enhancement: support IDNS on URL form input validations

Open
#27,396 0 comments 1 reaction 0 assignees View on GitHub
[Feature] Forms [Plugin] Jetpack Enhancement
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

### Impacted plugin

Jetpack

### What

Add validation support for IDNS, example: https://παράδειγμα.test

### How

perhaps we can abstract URL validation functionality to a shared helper function somewhere as it'd seem quite useful to have around (and tested). I tried looking to see if we already did that somewhere, though the closest I found was using [FILTER_VALIDATE_URL](https://www.php.net/manual/en/filter.filters.validate.php) which isn't perfect as it will not work for internationalized domain names (IDNs).

Quoted from https://github.com/Automattic/jetpack/pull/27138#pullrequestreview-1177703733

Contributor guide

Open the contributing guide

Research direction

Start by reviewing the closed, merged pull request #40490 and the existing URL validation based on FILTER_VALIDATE_URL. Done means the example https://παράδειγμα.test is accepted through the relevant form validation, with coverage for internationalized domain names and any shared helper behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.