The LlmSetUserAgent function changes the user-agent string
used by the client session. The specified string is trimmed to remove
leading and trailing whitespace and will be used the next time the
client establishes a connection to the provider.
If lpszUserAgent is NULL or points to an empty string, the
current user-agent string is cleared and a new default value is
generated for the session.
The default user-agent string uses a format similar to Chromium-based
browsers and includes information about the current Windows platform
and the SocketTools version. If an application name was specified when
the session was created, it may also be included in the default value.
For example, a default user-agent string may look similar to the
following:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) Chrome/134.0.0.0 Safari/537.36 SocketTools/12.0
Applications normally do not need to change the user-agent string.
However, a custom value may be useful when an application needs to
identify itself to a provider, gateway, proxy, or logging system.
Developers should avoid including sensitive information, such as API
keys, account identifiers, or user-specific data, in the user-agent
string.