Closed DaveCurr closed 2 years ago
You must be referring to the parameter validation. Technically, I know an address can include 255. But are there really any registered addresses in the ARIN database that use 255?
This isn't the one that drew my attention today, but it will suffice:
NetRange: 167.255.0.0 - 167.255.255.255
CIDR: 167.255.0.0/16
NetName: VIEWPORT
NetHandle: NET-167-255-0-0-1
Parent: NET167 (NET-167-0-0-0-0)
NetType: Direct Allocation
OriginAS:
Organization: Vuteq Engineering Corporation (VEC-1)
RegDate: 1993-11-30
Updated: 2021-12-14
Ref: https://rdap.arin.net/registry/ip/167.255.0.0
Got it. This gives me something to test with. This is a simple enough fix to roll into the next release.
I fixed this in v2.40.0 of the module if you want to update and verify.
Works great - many thanks
From: Jeff Hicks @.> Sent: 10 January 2022 19:54 To: jdhitsolutions/PSScriptTools @.> Cc: DaveCurr @.>; Author @.> Subject: Re: [jdhitsolutions/PSScriptTools] get-whois fails on valid IP address (Issue #117)
I fixed this in v2.40.0 of the module if you want to update and verify.
— Reply to this email directly, view it on GitHubhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjdhitsolutions%2FPSScriptTools%2Fissues%2F117%23issuecomment-1009289149&data=04%7C01%7C%7C0307105525264a3010b508d9d4730894%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637774412805612763%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=yfnWgE2WbyWcyDQp1rissmbE1pXssWFAfDRwhek9pgc%3D&reserved=0, or unsubscribehttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAXG75ZORPG4TTKR6SBA3LFTUVM2P3ANCNFSM5LR6CYNQ&data=04%7C01%7C%7C0307105525264a3010b508d9d4730894%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637774412805612763%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=may7UeZHg2VNdIZkX%2BfE7fB40NxHfM49pWia%2FlEM%2FJ0%3D&reserved=0. Triage notifications on the go with GitHub Mobile for iOShttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fapps.apple.com%2Fapp%2Fapple-store%2Fid1477376905%3Fct%3Dnotification-email%26mt%3D8%26pt%3D524675&data=04%7C01%7C%7C0307105525264a3010b508d9d4730894%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637774412805612763%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=6Po9MtcpdibPyXAQrB%2B%2BCPOC%2FD%2FeW5ZFQVlnXpKEzJU%3D&reserved=0 or Androidhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fplay.google.com%2Fstore%2Fapps%2Fdetails%3Fid%3Dcom.github.android%26referrer%3Dutm_campaign%253Dnotification-email%2526utm_medium%253Demail%2526utm_source%253Dgithub&data=04%7C01%7C%7C0307105525264a3010b508d9d4730894%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637774412805612763%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=WR2cTBCpIq5i%2FsL7xyVwliQoBKFH8tEnvkBqd4MpMYQ%3D&reserved=0. You are receiving this because you authored the thread.Message ID: @.***>
The octet verifiction checks to see if each one is >254, and fails if they are. 255 is valid as part of an IP address (even if used as the broadcast address). Suggest (for simplicity's sake) just changing the check to 255, rather than worry about CIDR subnetting..