I tried now to get the hostname for output in the Debug Log but the variable is always empty but I don't know if my code is correct. I added a line mslog(s, proc, LOG_DEBUG, "Hostname '%s'", tmsg->hostname); after the if (tmsg->hostname) block but in the log I always get main: IP:Port Hostname '' or main: IP:Port Hostname '(null)' and some lines after that then I will see X-CSTP-Hostname: value. I added the code in the main-worker-cmd.c Can you tell me what I did wrong or I used the wrong file to add the code. Thanks Regards Matthias -----Urspr?ngliche Nachricht----- Von: Nikos Mavrogiannopoulos [mailto:n.mavrogiannopoulos at gmail.com] Gesendet: Samstag, 5. M?rz 2016 13:22 An: Matthias Mandlmeier <matthias.mandlmeier at online.de> Cc: 'openconnect-devel' <openconnect-devel at lists.infradead.org> Betreff: Re: AW: AW: AW: Read Client Hostname On Sat, 2016-03-05 at 13:07 +0100, Matthias Mandlmeier wrote: > Nsupdate will work with my server. I can try to create a patch for > this but then I need to know where the variables are set in the > sources that I can trigger the hostname and send it to Bind. Most likely you need to modify config.c (and ocserv-args.def) to add new config file variables. The update should be triggered at main -worker.c when the CMD_SESSION_INFO message is received by main which contains the hostname. regards, Nikos