Skip to content

Instantly share code, notes, and snippets.

View Loveforkeeps's full-sized avatar
🐶
Meow~

EMoDevil Loveforkeeps

🐶
Meow~
View GitHub Profile
@syzdek
syzdek / ipv6-regex-test.sh
Last active July 18, 2024 05:44
Simple script to test my IPv6 regular expression.
#!/bin/sh
#
# Use posixregex CLI tool from: https://github.com/syzdek/dmstools/blob/master/src/posixregex.c
RE_IPV4="((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])"
posixregex -r "^(${RE_IPV4})$" \
127.0.0.1 \
10.0.0.1 \
192.168.1.1 \