Note that while upper and lower case letters are allowed in domain
names, no significance is attached to the case. That is, two names with
the same spelling but different case are to be treated as if identical.
The labels must follow the rules for ARPANET host names. They must
start with a letter, end with a letter or digit, and have as interior
characters only letters, digits, and hyphen. There are also some
restrictions on the length. Labels must be 63 characters or less.
Requirements
[x] Add validators where required
[ ] write tests for validators
Tasks
[x] app/api/models/tokens.py ensure token or partial token can't be set within the notes field
[x] app/config_management/models/groups.py ensure self cant be set as parent
[x] app/itam/models/device.pyDevice validate name as a valid hostname
[x] app/itam/models/device.pyDevice validate UUID as correctly formatted
audit all models to ensure any value that should be validated is validated as it should be.
Check
Links
ref: https://datatracker.ietf.org/doc/html/rfc1035#autoid-6
Note that while upper and lower case letters are allowed in domain names, no significance is attached to the case. That is, two names with the same spelling but different case are to be treated as if identical.
The labels must follow the rules for ARPANET host names. They must start with a letter, end with a letter or digit, and have as interior characters only letters, digits, and hyphen. There are also some restrictions on the length. Labels must be 63 characters or less.
Requirements
Tasks
app/api/models/tokens.py
ensure token or partial token can't be set within the notes fieldapp/config_management/models/groups.py
ensure self cant be set as parentapp/itam/models/device.py
Device
validate name as a valid hostnameapp/itam/models/device.py
Device
validate UUID as correctly formatted