-
Notifications
You must be signed in to change notification settings - Fork 351
Open
Labels
Traffic Opsrelated to Traffic Opsrelated to Traffic Opsbugsomething isn't working as intendedsomething isn't working as intended
Description
This Bug Report affects these Traffic Control components:
- Traffic Ops
What did you do?
When creating servers on the same profile with the same service address in range /32 for IPv4 or /128 for IPv6 (i.e. 1.1.1.1/32) it works fine. However, other ranges fail as servers with the same service address are not allowed
To reproduce:
- Run Traffic Ops
- Create server with service address ending in /32
- Create another with the same address it won't fail
- Try with /24 the same case and it will fail
This is because we are using inet
Postgres type to represent IPs and it omits the mask part if it's a single host: https://www.postgresql.org/docs/current/datatype-net-types.html#DATATYPE-INET
So upon validation the IP stored in DB does not match what's in the request and it gets created with no errors.
What did you expect to happen?
Fail with error indicating that servers on the same profile can't share the same service address for subnet /32.
What actually happened?
Servers were created fine.
Metadata
Metadata
Assignees
Labels
Traffic Opsrelated to Traffic Opsrelated to Traffic Opsbugsomething isn't working as intendedsomething isn't working as intended