$SSH_CLIENT has IP address with some port info, and echo $SSH_CLIENT gives me '10.0.40.177 52335 22', and Running
if [ -n "$SSH_CONNECTION" ] ; then for i in $SSH_CLIENT do echo $i done fi
gives me
- 10.0.40.177
- 52335
- 22
And I see the first element is the IP address.
Q : How can I get the first element of $SSH_CLIENT? ${SSH_CLIENT[0]} doesn't work.