Opened 3 years ago
Closed 3 years ago
#33877 closed Cleanup/optimization (wontfix)
Add accurate port validation to the URLValidator.
| Reported by: | Igor Izvekov | Owned by: | nobody |
|---|---|---|---|
| Component: | Core (Other) | Version: | dev |
| Severity: | Normal | Keywords: | |
| Cc: | Florian Apolloner | Triage Stage: | Unreviewed |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
A port of internet address (TCP and UDP) is a 16-bit number (0-65535) by RFC 1085 sec. 5.1 (https://datatracker.ietf.org/doc/rfc1085/).
Django's URLValidator accepts addresses with the port more than 65535 (For example, http://example:78000/).
This patch fixed that problem.
Change History (1)
comment:1 by , 3 years ago
| Cc: | added |
|---|---|
| Resolution: | → wontfix |
| Status: | new → closed |
| Summary: | Fixed port's problem in URLValidator → Add accurate port validation to the URLValidator. |
| Type: | Bug → Cleanup/optimization |
Note:
See TracTickets
for help on using tickets.
Thanks for this ticket, however we would prefer to keep the regex simple. It was also briefly discussed in #32930.