Created
August 28, 2023 00:44
-
-
Save LGM-AdrianHum/9f7295038f0099793c96bc09f69e170d to your computer and use it in GitHub Desktop.
IP Tools : A regex static function to extract IP addresses from strings (good for DNS services that return extra data with IP addresses.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static string ExtractIpAddress(this string input) => string.Join("", Regex.Matches(input, @"[\d\.]+")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment