Pinning,Mutual authentication,EV等passthrough功能在windows10测试通过。

This commit is contained in:
zhengchao
2019-05-18 12:39:19 +08:00
parent dda60c674c
commit 3f305a9e88
3 changed files with 12 additions and 6 deletions

View File

@@ -13,12 +13,14 @@ enum ssl_stream_action ssl_policy_enforce(struct ssl_stream *upstream, void* u_p
{
UNUSED struct ssl_policy_enforcer* enforcer=(struct ssl_policy_enforcer*)u_para;
UNUSED int ret=0;
int pinning_staus=0, is_ev=0;
int pinning_staus=0, is_ev=0, is_mauth=0;
ret=ssl_stream_get_integer_opt(upstream, SSL_STREAM_OPT_PINNING_STATUS, &pinning_staus);
assert(ret==1);
ret=ssl_stream_get_integer_opt(upstream, SSL_STREAM_OPT_IS_EV_CERT, &is_ev);
assert(ret==1);
if(pinning_staus>0||is_ev)
ret=ssl_stream_get_integer_opt(upstream, SSL_STREAM_OPT_IS_MUTUAL_AUTH, &is_mauth);
if(pinning_staus>0||is_ev||is_mauth)
{
return SSL_ACTION_PASSTHROUGH;
}