Remarque
L’accès à cette page nécessite une autorisation. Vous pouvez essayer de vous connecter ou de modifier des répertoires.
L’accès à cette page nécessite une autorisation. Vous pouvez essayer de modifier des répertoires.
如果您应用以...身份运行策略,且服务清单声明 HTTP 终结点资源,则必须指定 SecurityAccessPolicy。 SecurityAccessPolicy 会确保分配给这些终结点的端口已正确限制为运行该服务所用的用户帐户。 否则, http.sys 无法访问该服务,并且客户端调用失败。 以下示例将 Customer1 帐户应用于名为“EndpointName”的终结点,并向它授予完全访问权限。
<Policies>
<RunAsPolicy CodePackageRef="Code" UserRef="Customer1" />
<!--SecurityAccessPolicy is needed if RunAsPolicy is defined and the Endpoint is http -->
<SecurityAccessPolicy ResourceRef="EndpointName" PrincipalRef="Customer1" />
</Policies>
针对 HTTPS 终结点,还要指出要返回给客户端的证书名称。 使用 EndpointBindingPolicy 引用证书。 应用程序清单的“证书”部分中定义了证书。
<Policies>
<RunAsPolicy CodePackageRef="Code" UserRef="Customer1" />
<!--SecurityAccessPolicy is needed if RunAsPolicy is defined and the Endpoint is http -->
<SecurityAccessPolicy ResourceRef="EndpointName" PrincipalRef="Customer1" />
<!--EndpointBindingPolicy is needed if the EndpointName is secured with https -->
<EndpointBindingPolicy EndpointRef="EndpointName" CertificateRef="Cert1" />
</Policies>
警告
使用 HTTPS 时,请勿将同一端口和证书用于已部署到同一节点的不同服务实例(独立于应用程序)。 在不同的应用程序实例中使用相同的端口升级两个不同的服务将导致升级失败。 有关详细信息,请参阅 使用 HTTPS 终结点升级多个应用程序。
有关后续步骤,请阅读以下文章: