Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The DnsAcquireContextHandle function type acquires a context handle to a set of credentials. Like many DNS functions, the DnsAcquireContextHandle function type is implemented in multiple forms to facilitate different character encoding. Based on the character encoding involved, use one of the following functions:
DNS_STATUS DnsAcquireContextHandle_A(
[in] DWORD CredentialFlags,
[in, optional] PVOID Credentials,
[out] PHANDLE pContext
);
[in] CredentialFlags
A flag that indicates the character encoding. Set to TRUE for Unicode, FALSE for ANSI.
[in, optional] Credentials
A pointer to a SEC_WINNT_AUTH_IDENTITY_W structure or a SEC_WINNT_AUTH_IDENTITY_A structure that contains the name, domain, and password of the account to be used in a secure dynamic update. If CredentialFlags is set to TRUE, Credentials points to a SEC_WINNT_AUTH_IDENTITY_W structure; otherwise, Credentials points to a SEC_WINNT_AUTH_IDENTITY_A structure. If not specified, the credentials of the calling service are used. This parameter is optional.
[out] pContext
A pointer to a handle pointing to the returned credentials.
Returns success confirmation upon successful completion. Otherwise, returns the appropriate DNS-specific error code as defined in Winerror.h.
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | windns.h |
Library | Dnsapi.lib |
DLL | Dnsapi.dll |
Events
May 19, 6 PM - May 23, 12 AM
Calling all developers, creators, and AI innovators to join us in Seattle @Microsoft Build May 19-22.
Register today