I'm having the same issue here. Can anyone please post an example?
Here's what I have:
client: openvpn-2.3.12
server: openvpn-2.3.11
I have push-peer-info set in conf files (both client and server, although the 2.3 man page seems to suggest to set it only on the server).
In the server config file I also added:
client-connect "/etc/openvpn/client-up.sh ivpn"
and my client-up.sh script is:
# cat client-up.sh
#!/bin/bash
xvpn=$1
[ ${#xvpn} -eq 0 ] && exit 1
logfile=/var/log/openvpn/${xvpn}-audit-up.csv
echo "$( date +%m/%d/%Y-%H:%M:%S ),${common_name},${username},${untrusted_ip},${ifconfig_local},${ifconfig_pool_remote_ip},${IV_VER},${IV_PLAT}" >> ${logfile}
exit 0
In my case, ${IV_VER} and ${IV_PLAT} are empty.
Furthermore, the 2.3 man page seems to suggest that these variables are always set even when push-peer-info is NOT used.
According to this other post (
http://stackoverflow.com/questions/34887112/openvpn-push-peer-info-option-does-not-work), 2.3 does NOT support these env variables through "client-connect". So I guess I'll have to wait for 2.4 to stabilize.