Skip to main content


Last updated March 2020


ec_httpsrv_request_username_get — Gets the authenticated user name


#include "modules/listeners/httpsrv.h"

| const char * **ec_httpsrv_request_username_get** ( | sess); |   |

ec_httpsrv_session * <var class="pdparam">sess</var>;



This reference page was automatically generated from functions found in the header files in the development branch. The function described here may not exist in generally available versions of Momentum, and may change in behavior when it is generally available. Consult your vendor for definitive advice on the use of this function.

Gets the authenticated user name.



the session to interrogate

Return Values

the user name, which will be NULL for a session that is not authenticated.

The nature of the string depends on the underlying authentication mechanism; it may be a simple user identifier like "john.smith", or an email address like "", a string representation of an SSL certificate common name, or a Windows style "domain\username".

The returned string is valid for the lifetime of the request.

Was this page helpful?