AW: Read Client Hostname

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 3, 2016 at 7:00 PM, Matthias Mandlmeier
<matthias.mandlmeier at online.de> wrote:
> I tested it with the the ocserv-script and added the value $Hostname in it get the Hostname.
> The Line in the ocserv-script now looks like echo "User '$USERNAME' from '$IP_REAL' connected. Local IP is '$IP_REMOTE' Hostname is '$Hostname'" >> /etc/ocserv/test2.txt and output it to a file that I can see the variables. When a client connects I get the following Output "User 'test' from 'X.X.X.X' connected. Local IP is 'X.X.X.X' Hostname is ''" and the Value of the Hostname variable is empty all other variables in the script has the correct value in it. In the debug log I see the correct hostname in this entry HTTP: X-CSTP-Hostname.

You're right, that's indeed an issue. It seems that the hostname
information is only known to ocserv after the user successfully
connects so it cannot forward it to the up-down scripts. Due to a bug
it wasn't even available on occtl (fixed now in master branch). Not
sure what we can do there except document the fact that this variable
is not provided to the up script.

regards,
Nikos



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux