Project

General

Profile

Actions

Cleanup #37941

closed

mgr/dashboard: Replace IP address validation with Python standard library functions

Added by Patrick Seidensal over 5 years ago. Updated about 3 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
General
Target version:
% Done:

0%

Tags:
low-hanging-fruit
Backport:
Reviewed:
Affected Versions:
Pull request ID:

Description

Currently, we use self-written validation methods to validate IPv4 and IPv6 addresses. By replacing those with Pythons standard library functions, namely `ipaddress`, we can save around 40 lines of code (including tests) and reduce the complexity of the code.

https://docs.python.org/3/library/ipaddress.html

Actions

Also available in: Atom PDF