Skip to content

Commit

Permalink
Now 'ucsf vpn routing' also reports on nameserver settings (fix #66)
Browse files Browse the repository at this point in the history
  • Loading branch information
HenrikBengtsson committed Jun 13, 2024
1 parent b146dc6 commit a8aaf8b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 2 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ ucsf-vpn
can be used to override environment variable `UCSF_VPN_FLAVOR`,
which may be preset in for instance `~/.config/ucsf-vpn/envs`.

* Now `ucsf vpn routing` also reports on nameserver settings.


## Version 6.0.0 (2024-05-20)

Expand Down
9 changes: 7 additions & 2 deletions bin/ucsf-vpn
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
### * UCSF Managing Your Passwords:
### - https://it.ucsf.edu/services/managing-your-passwords
###
### Version: 6.0.0-9002
### Version: 6.0.0-9003
### Copyright: Henrik Bengtsson (2016-2024)
### License: GPL (>= 2.1) [https://www.gnu.org/licenses/gpl.html]
### Source: https://github.com/HenrikBengtsson/ucsf-vpn
Expand Down Expand Up @@ -342,8 +342,13 @@ function routing_details() {
echo "Tunnel interfaces: none"
fi

echo
echo "Nameserve configuration (/etc/resolv.conf):"
grep -v -E "^[[:space:]]*(#|$)" /etc/resolv.conf

mapfile -t ip_route < <(ip route show)
echo "IP routing table (${#ip_route[@]} entries):"
echo
echo "IP routing table (ip route show) [${#ip_route[@]} entries]:"
for kk in "${!ip_route[@]}"; do
row="${ip_route[${kk}]}"
if $use_dig || $use_whois; then
Expand Down

0 comments on commit a8aaf8b

Please sign in to comment.