Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't get peercert subject name in ppv2 #168

Open
HJianBo opened this issue Oct 13, 2022 · 0 comments
Open

Can't get peercert subject name in ppv2 #168

HJianBo opened this issue Oct 13, 2022 · 0 comments
Assignees
Labels

Comments

@HJianBo
Copy link
Member

HJianBo commented Oct 13, 2022

The https://www.haproxy.org/download/1.8/doc/proxy-protocol.txt has not supported the cert Subject Name, but we supported it with Common Name 馃槩

subject(nossl) -> undefined;
subject(undefined) -> undefined;
subject(Cert) when is_binary(Cert) ->
esockd_ssl:peer_cert_subject(Cert);
subject(PP2Info) when is_list(PP2Info) ->
%%Notice: DN is not available in ppv2 additional info
proplists:get_value(pp2_ssl_cn, PP2Info).

This issue was found while investigating emqx/emqx#9147

@HJianBo HJianBo self-assigned this Oct 13, 2022
@HJianBo HJianBo added the bug label Oct 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant