Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert a range of IPs into CIDR #23

Open
Sf298 opened this issue Aug 10, 2024 · 0 comments
Open

Convert a range of IPs into CIDR #23

Sf298 opened this issue Aug 10, 2024 · 0 comments

Comments

@Sf298
Copy link

Sf298 commented Aug 10, 2024

Hello I needed a function that can convert a range of IPs (192.168.0.1-192.168.0.33) into a list of CIDR formats (192.168.0.1/32, 192.168.0.2/31, 192.168.0.4/30, 192.168.0.8/29, 192.168.0.16/28, 192.168.0.32/31).
I couldn't find a JS library to do it anywhere (I may have been bad at looking) so I made one myself.
If you like, I can try make a PR and add it into this library or I could post my code here and let you handle it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant