> ## 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.

# XNetworkingSecurityInformation

> XNetworkingSecurityInformation

# XNetworkingSecurityInformation

定義為特定 URL 端點設定 HTTP 堆疊時所使用的安全性資訊。

## 語法

```cpp theme={null}
typedef struct XNetworkingSecurityInformation {
    uint32_t enabledHttpSecurityProtocolFlags;
    size_t thumbprintCount;
    XNetworkingThumbprint* thumbprints;
} XNetworkingSecurityInformation
```

### 成員

*enabledHttpSecurityProtocolFlags*\
類型：uint32\_t

旗標的位元遮罩，指出 HTTP 要求針對此 URL 端點應限制使用哪些傳輸層安全性 (TLS) 通訊協定，並應透過呼叫 `WinHttpSetOption` 傳遞給 `WINHTTP_OPTION_SECURE_PROTOCOLS` WinHTTP 選項。可以是 `WINHTTP_FLAG_SECURE_PROTOCOL_TLS1`、`WINHTTP_FLAG_SECURE_PROTOCOL_TLS1_1`、`WINHTTP_FLAG_SECURE_PROTOCOL_TLS1_2` 和 `WINHTTP_FLAG_SECURE_PROTOCOL_TLS1_3` 的任意組合。

*thumbprintCount*\
類型：size\_t

`thumbprints` 欄位所指向陣列中的指紋數目。

*thumbprints*\
類型：[XNetworkingThumbprint](/zh-TW/reference/networking/xnetworking/structs/xnetworkingthumbprint)\*

預期出現在伺服器針對此 URL 端點所出示之憑證鏈結中的指紋陣列。

## 備註

此結構描述設定 HTTP 堆疊時所使用的安全性資訊。它會決定 HTTP 要求針對特定 URL 端點應限制使用哪些 TLS 通訊協定。不一定會有任何指紋。一般使用 Fiddler 時會有一個根指紋。

## 需求

**標頭：** XNetworking.h

**支援的平台：** Windows、XBOX One 系列主機和 XBOX Series 主機

## 概念文件

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

## 另請參閱

[XNetworkingQuerySecurityInformationForUrlAsync](/zh-TW/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlasync)\
[XNetworkingQuerySecurityInformationForUrlUtf16Async](/zh-TW/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlutf16async)\
[XNetworking](/zh-TW/reference/networking/xnetworking/xnetworking_members)


## Related topics

- [XNetworkingSecurityInformation](/reference/networking/xnetworking/structs/xnetworkingsecurityinformation.md)
- [XNetworkingVerifyServerCertificate](/reference/networking/xnetworking/functions/xnetworkingverifyservercertificate.md)
- [XNetworkingQuerySecurityInformationForUrlAsyncResult](/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlasyncresult.md)
- [XNetworkingQuerySecurityInformationForUrlUtf16AsyncResult](/reference/networking/xnetworking/functions/xnetworkingquerysecurityinformationforurlutf16asyncresult.md)
- [XNetworkingThumbprintType](/reference/networking/xnetworking/enums/xnetworkingthumbprinttype.md)
