Include Network information in Prefix/Aggregate view #6550

Closed
opened 2025-12-29 19:42:14 +01:00 by adam · 7 comments
Owner

Originally created by @basti1508 on GitHub (Jun 9, 2022).

Originally assigned to: @renatoalmeidaoliveira on GitHub.

NetBox version

v3.2.4

Feature type

Change to existing functionality

Proposed functionality

Inlcude additinal information in the Prefix/Aggregate view to make it easier for admins to get more knowledge to the network.
The example would be the output of sipcalc. For me the most valueable information is boradcast address, quick view on the usable range and cisco wildcard address.

$ sipcalc 10.14.0.0/19
-[ipv4 : 10.14.0.0/19] - 0

[CIDR]
Host address		- 10.14.0.0
Host address (decimal)	- 168689664
Host address (hex)	- A0E0000
Network address		- 10.14.0.0
Network mask		- 255.255.224.0
Network mask (bits)	- 19
Network mask (hex)	- FFFFE000
Broadcast address	- 10.14.31.255
Cisco wildcard		- 0.0.31.255
Addresses in network	- 8192
Network range		- 10.14.0.0 - 10.14.31.255
Usable range		- 10.14.0.1 - 10.14.31.254

Use case

Get additional network information more quickly.

Database changes

No response

External dependencies

No response

Originally created by @basti1508 on GitHub (Jun 9, 2022). Originally assigned to: @renatoalmeidaoliveira on GitHub. ### NetBox version v3.2.4 ### Feature type Change to existing functionality ### Proposed functionality Inlcude additinal information in the Prefix/Aggregate view to make it easier for admins to get more knowledge to the network. The example would be the output of sipcalc. For me the most valueable information is boradcast address, quick view on the usable range and cisco wildcard address. ``` $ sipcalc 10.14.0.0/19 -[ipv4 : 10.14.0.0/19] - 0 [CIDR] Host address - 10.14.0.0 Host address (decimal) - 168689664 Host address (hex) - A0E0000 Network address - 10.14.0.0 Network mask - 255.255.224.0 Network mask (bits) - 19 Network mask (hex) - FFFFE000 Broadcast address - 10.14.31.255 Cisco wildcard - 0.0.31.255 Addresses in network - 8192 Network range - 10.14.0.0 - 10.14.31.255 Usable range - 10.14.0.1 - 10.14.31.254 ``` ### Use case Get additional network information more quickly. ### Database changes _No response_ ### External dependencies _No response_
adam added the status: acceptedtype: feature labels 2025-12-29 19:42:14 +01:00
adam closed this issue 2025-12-29 19:42:14 +01:00
Author
Owner

@jeremystretch commented on GitHub (Jun 9, 2022):

What specifically are you proposing be added?

@jeremystretch commented on GitHub (Jun 9, 2022): What specifically are you proposing be added?
Author
Owner

@ITJamie commented on GitHub (Jun 9, 2022):

I did some of this (netmask/wildcard) in my gateways plugin as it was highly requested internally during our migration from racktables which had similar data.

https://github.com/ITJamie/netbox_gateways/blob/main/docs/images/prefix_view_gw.png

@ITJamie commented on GitHub (Jun 9, 2022): I did some of this (netmask/wildcard) in my gateways plugin as it was highly requested internally during our migration from racktables which had similar data. https://github.com/ITJamie/netbox_gateways/blob/main/docs/images/prefix_view_gw.png
Author
Owner

@basti1508 commented on GitHub (Jun 14, 2022):

From the example above the most valuable information would be:

Network mask		- 255.255.224.0
Cisco wildcard		- 0.0.31.255
Network range		- 10.14.0.0 - 10.14.31.255
@basti1508 commented on GitHub (Jun 14, 2022): From the example above the most valuable information would be: ``` Network mask - 255.255.224.0 Cisco wildcard - 0.0.31.255 Network range - 10.14.0.0 - 10.14.31.255 ```
Author
Owner

@weidi commented on GitHub (Jun 29, 2022):

Would love to add that showing the netmask in addition to the CIDR notation for each IP would help a lot so this might not only help in the prefix view.

@weidi commented on GitHub (Jun 29, 2022): Would love to add that showing the netmask in addition to the CIDR notation for each IP would help a lot so this might not only help in the prefix view.
Author
Owner

@PieterL75 commented on GitHub (Jun 29, 2022):

I have this plugin : https://github.com/PieterL75/netbox_ipcalculator
It is a client-side javascript based subnet calculator...

Feel free to use/modify it !

@PieterL75 commented on GitHub (Jun 29, 2022): I have this plugin : https://github.com/PieterL75/netbox_ipcalculator It is a client-side javascript based subnet calculator... Feel free to use/modify it !
Author
Owner

@renatoalmeidaoliveira commented on GitHub (Jul 6, 2022):

Which implementation you think is better?
1 - add model methods that calculate netmask, wildcard and etc,
2 - add templatetags in the helpers that do the same thing?

@renatoalmeidaoliveira commented on GitHub (Jul 6, 2022): Which implementation you think is better? 1 - add model methods that calculate netmask, wildcard and etc, 2 - add templatetags in the helpers that do the same thing?
Author
Owner

@jeremystretch commented on GitHub (Jul 6, 2022):

@renatoalmeidaoliveira I'd expect that most such attributes are already available via netaddr as properties of the prefix value. But where needed, model attributes and methods would be preferable: Template tags should only be introduced to fill a general need.

@jeremystretch commented on GitHub (Jul 6, 2022): @renatoalmeidaoliveira I'd expect that most such attributes are already available via `netaddr` as properties of the prefix value. But where needed, model attributes and methods would be preferable: Template tags should only be introduced to fill a general need.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#6550