Project

General

Profile

Actions

Enhancement #1200

closed

Search for IP addresses included in a subnet

Added by Jonathan CLARKE over 13 years ago. Updated about 1 month ago.

Status:
Resolved
Priority:
N/A
Assignee:
-
Category:
Web - Nodes & inventories
Target version:
UX impact:
Suggestion strength:
User visibility:
Effort required:
Name check:
Fix check:
Regression:
No

Description

We must be able to clearly match nodes that have an IP in a given subnet, eg 192.168.0.0/24


Related issues 2 (0 open2 closed)

Has duplicate Rudder - User story #4417: Allow node search on IP rangeRejectedActions
Is duplicate of Rudder - User story #3615: IP search field with slash notation (subnet, mask, ip range)ReleasedClark ANDRIANASOLOActions
Actions #1

Updated by Jonathan CLARKE over 13 years ago

  • Target version changed from 9 to 10
Actions #2

Updated by Nicolas CHARLES over 13 years ago

First version : an IP with /8, /16, /24 or /32

Actions #3

Updated by François ARMAND about 13 years ago

  • Target version changed from 10 to 18

Set in 2.4, perhaps it will be needed soon.

Actions #4

Updated by François ARMAND about 13 years ago

  • Target version changed from 18 to 24
Actions #5

Updated by Jonathan CLARKE almost 13 years ago

  • Category set to Web - Nodes & inventories
Actions #6

Updated by Jonathan CLARKE over 12 years ago

  • Target version changed from 24 to 18
Actions #7

Updated by Jonathan CLARKE about 12 years ago

  • Target version changed from 18 to Ideas (not version specific)
Actions #8

Updated by Florian Heigl over 9 years ago

Hi,

I just ran into this.
Currently you need to make heavy abuse of regex matches to implement subnet calculations.

It is feasible for dealing with small numbers of networks but i.e. when considering doing this for 1000 or 10000 subnets it gets really awkward and it's very hard to automatically generate.

Now, to make it worse:
We've just established it's possible to add them using regex. But honestly: It's pretty impossible to maintain and thus it should really be a builtin comparism.

Please keep in mind ipv6 on this one since it'll be even more needed. I don't think we want to assign a million+ ip range for any single dmz network...

Actions #9

Updated by Florian Heigl over 9 years ago

[duplicated with other comments]

Actions #10

Updated by Florian Heigl over 9 years ago

[duplicated]

Actions #11

Updated by Florian Heigl over 9 years ago

Regex trick

Example for Regex usage

Mapping a subnet to regex


Subnet: 192.168.10.0/25  
Regex: 192.168.10.([0-9]{3} | 1[01][0-9] | 12[0-6])

Make sure you don't forget the mask when naming your group, i.e.
NET-192_168_10_P25

(P for Prefix)

Actions #12

Updated by François ARMAND over 9 years ago

The correct regex is:

192\.168\.10\.([0-9]{1,2}|1[01][0-9]|12[0-6])

It will matches IPs 192.168.10.{0-126}

You can build any integer matching with the above decomposition trick ( [0-9] or [0-9][0-9] or 11[0-9] etc). It's "just" über fastidious.

You can check the regex with http://www.regexplanet.com/advanced/java/index.html for example.

Actions #13

Updated by Benoît PECCATTE over 7 years ago

Actions #14

Updated by François ARMAND almost 3 years ago

  • Tracker changed from User story to Enhancement
Actions #15

Updated by François ARMAND about 1 month ago

  • Related to User story #3615: IP search field with slash notation (subnet, mask, ip range) added
Actions #16

Updated by François ARMAND about 1 month ago

  • Related to deleted (User story #3615: IP search field with slash notation (subnet, mask, ip range))
Actions #17

Updated by François ARMAND about 1 month ago

  • Is duplicate of User story #3615: IP search field with slash notation (subnet, mask, ip range) added
Actions #18

Updated by François ARMAND about 1 month ago

  • Status changed from New to Resolved
  • Target version changed from Ideas (not version specific) to 8.2.0~rc1
  • Regression set to No

Rsolved in #3615

Actions

Also available in: Atom PDF