Xamarin.forms Xamarin表单android证书固定网络\u安全\u配置如何测试它?

Xamarin.forms Xamarin表单android证书固定网络\u安全\u配置如何测试它?,xamarin.forms,xamarin.android,Xamarin.forms,Xamarin.android,我正在通过网络\安全\配置实现证书固定,我有 <?xml version="1.0" encoding="utf-8"?> <network-security-config> <domain-config> <domain includeSubdomains="true">example.com</domain> <pin-set expiration=&

我正在通过网络\安全\配置实现证书固定,我有

<?xml version="1.0" encoding="utf-8"?>
<network-security-config>
<domain-config>
    <domain includeSubdomains="true">example.com</domain>
    <pin-set expiration="2018-01-01">
        <pin digest="SHA-256">7HIpactkIAq2Y49orFOOQKurWxmmSFZhBCoQYcRhJ3Y=</pin>
        <!-- backup pin -->
        <pin digest="SHA-256">fwza0LRMXouZHRC8Ei+4PyuldPDcf3UKgO/04cDM1oE=</pin>
    </pin-set>
</domain-config>

example.com
7HIpactkIAq2Y49orFOOQKurWxmmSFZhBCoQYcRhJ3Y=
fwza0LRMXouZHRC8Ei+4YULDPDCF3UKGO/04cDM1oE=
现在我该如何测试它的工作原理呢

我找不到任何关于你如何证明它有效的东西,例如“无效证书错误”,我可以关闭应用程序或做其他事情


感谢您的建议,任何使用表单的示例

请查看下面的Microsoft博客,这将非常有用@WendyZang MSFT感谢您的回复我已经阅读了该博客,但没有提供关于如何测试实现的建议检查下面链接中的代码使用
IX509TrustManager
检查:请检查下面的Microsoft博客,这会很有帮助@WendyZang MSFT感谢您的回复我已经阅读了该博客,但没有提供如何测试实现的建议检查下面链接中的代码以使用
IX509TrustManager
检查: