Skip to content

Instantly share code, notes, and snippets.

@Snawoot
Created August 29, 2023 11:29
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Snawoot/eb77709bc34c8afeeaad6d6a6c0c0226 to your computer and use it in GitHub Desktop.
Save Snawoot/eb77709bc34c8afeeaad6d6a6c0c0226 to your computer and use it in GitHub Desktop.
exclude IP address from wireguard routes
{ ipcalc -j -d 0.0.0.0-167.235.232.135 ; ipcalc -j -d 167.235.232.137-223.255.255.255 ; } | jq -r -s 'map(.DEAGGREGATEDNETWORK) | flatten | join(",")'
0.0.0.0/1,128.0.0.0/3,160.0.0.0/6,164.0.0.0/7,166.0.0.0/8,167.0.0.0/9,167.128.0.0/10,167.192.0.0/11,167.224.0.0/13,167.232.0.0/15,167.234.0.0/16,167.235.0.0/17,167.235.128.0/18,167.235.192.0/19,167.235.224.0/21,167.235.232.0/25,167.235.232.128/29,167.235.232.137/32,167.235.232.138/31,167.235.232.140/30,167.235.232.144/28,167.235.232.160/27,167.235.232.192/26,167.235.233.0/24,167.235.234.0/23,167.235.236.0/22,167.235.240.0/20,167.236.0.0/14,167.240.0.0/12,168.0.0.0/5,176.0.0.0/4,192.0.0.0/3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment