Permissions-Policy: chỉ thị identity-credentials-get
Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.
Chỉ thị identity-credentials-get của header HTTP Permissions-Policy kiểm soát việc tài liệu hiện tại có được phép sử dụng Federated Credential Management API (FedCM), và cụ thể hơn là việc sử dụng các phương thức sau:
navigator.credentials.get()(khi sử dụng với tùy chọnidentity)IdentityCredential.disconnect()IdentityProvider.getUserInfo()
Khi chính sách này cấm việc sử dụng API, các Promise được trả về bởi các phương thức này sẽ bị từ chối với NotAllowedError DOMException.
Cú pháp
http
Permissions-Policy: identity-credentials-get=<allowlist>;
<allowlist>-
Danh sách các nguồn gốc được cấp quyền sử dụng tính năng. Xem
Permissions-Policy> Cú pháp để biết thêm chi tiết.
Chính sách mặc định
Danh sách cho phép mặc định cho identity-credentials-get là self.
Thông số kỹ thuật
| Specification |
|---|
| Federated Credential Management API> # permissions-policy-integration> |