> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XNetworkingQuerySecurityInformationForUrlUtf16Async

> XNetworkingQuerySecurityInformationForUrlUtf16Async

# XNetworkingQuerySecurityInformationForUrlUtf16Async

检索与在通用开发人员门户中为启用 XBOX Live 的游戏所配置的 URL 相关联的安全信息。

## 语法

```cpp theme={null}
HRESULT XNetworkingQuerySecurityInformationForUrlUtf16Async(
         const wchar_t* url,
         XAsyncBlock* asyncBlock
)
```

### 参数

*url*   \_In\_z\_\
类型：wchar\_t\*

用于检索证书指纹列表的 URL 端点。

*asyncBlock*   \_Inout\_\
类型：[XAsyncBlock](/reference/system/xasync/structs/xasyncblock)\*

指向要传递给 [XAsyncRun](/reference/system/xasync/functions/xasyncrun) 函数的 [XAsyncBlock](/reference/system/xasync/structs/xasyncblock) 结构体的指针。

### 返回值

类型：HRESULT

异步调用的 HRESULT 成功或错误代码。

## 备注

此函数发起异步请求，以获取通过通用开发人员门户为游戏配置的 URL 关联的证书。这允许启用 XBOX Live 的 Microsoft 游戏开发工具包 (GDK) 游戏在与 [Windows HTTP 服务 (WinHTTP)](https://learn.microsoft.com/windows/desktop/winhttp/winhttp-start-page) API 配合使用时，对特定于游戏的自定义服务端点执行证书固定。

<Note>当向 XBOX Live 服务端点发起自定义 Web 请求时，应允许 XBOX 服务 API (XSAPI) 库自动执行证书固定。</Note>

此方法查询调用进程中的本地状态并快速返回，因此可以从时间敏感的上下文中安全调用。

## 要求

**头文件：** XNetworking.h

**库：** xgameruntime.lib

**支持的平台：** Windows、XBOX One 系列主机和 XBOX Series 主机

## 概念文档

* [WinHTTP 概述](/build/console-features/networking/web-requests/intro-winhttp)

## 另请参阅

[检索网络信息](/build/console-features/networking/initialization-connectivity-networking)\
[XNetworkingQuerySecurityInformationForUrlUtf16AsyncResult](/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlutf16asyncresult)\
[XNetworking](/reference/networking/xnetworking/xnetworking_members)


## Related topics

- [XNetworkingQuerySecurityInformationForUrlUtf16AsyncResult](/zh-CN/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlutf16asyncresult.md)
- [XNetworkingQuerySecurityInformationForUrlUtf16AsyncResultSize](/zh-CN/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlutf16asyncresultsize.md)
- [XNetworkingSecurityInformation](/zh-CN/reference/networking/xnetworking/structs/xnetworkingsecurityinformation.md)
- [XNetworking](/zh-CN/reference/networking/xnetworking/xnetworking_members.md)
- [WinHTTP 概述](/zh-CN/build/console-features/networking/web-requests/intro-winhttp.md)
