1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-09 03:36:48 +00:00
webvirtcloud/networks
catborise 0a1219c659 fix(networks): a subnet that is not one is refused by the create form
The create-network form only checked the characters of its subnets, so
192.0.2.0/33 or 999.0.2.0/24 passed and network_size raised a
ValueError: the user got a server error instead of a message. So did a
subnet too small for the gateway, DHCP range and broadcast address that
network_size derives (0.0.0.0/32, 255.255.255.255/32), and 192.0.2.0/31
or a bare address gave an inverted DHCP range.

Each subnet field now parses its value as a network of its IP version
and refuses it with a field error otherwise. An IPv4 prefix must be /30
or shorter; the IPv6 prefix must be /64, which the view checked after
the form and now the form does.
2026-10-20 22:37:44 +03:00
..
api fix(api): typed URLs and accurate response schemas 2026-10-04 01:08:11 +03:00
migrations add missing migrations for new models 2022-08-24 09:34:16 +03:00
templates fix(templates): the dialogs only a real host shows have accessible names 2026-10-19 21:17:48 +03:00
tests fix(networks): a subnet that is not one is refused by the create form 2026-10-20 22:37:44 +03:00
__init__.py Initial commit 2015-02-27 10:53:51 +02:00
forms.py fix(networks): a subnet that is not one is refused by the create form 2026-10-20 22:37:44 +03:00
models.py format python code with black 2022-11-02 08:54:35 +03:00
views.py fix(networks): a subnet that is not one is refused by the create form 2026-10-20 22:37:44 +03:00