2

I want to programmatically install certificate into Windows for localhost MITM SSL sniffing.

>certutil -addstore "TrustedPublisher" mitmproxy-ca-cert.p12
TrustedPublisher
CertUtil: -addstore команда НЕ ВЫПОЛНЕНА: 0x80093102 (ASN: 258)
CertUtil: В ASN1 встречен неожиданный конец данных.

means in English the Unexpected end of data While this command:

>certutil -asn \Users\Nakilon\.mitmproxy\mitmproxy-ca-cert.p12
CertUtil: -asn - команда успешно выполнена.

doesn't see any issue.

Nakilon
  • 34,866
  • 14
  • 107
  • 142

2 Answers2

2

You can just convert .p12 cert to .pem and then you will be able to import it through your command.

0

From http://docs.mitmproxy.org/en/latest/certinstall.html:

 certutil.exe -importpfx Root mitmproxy-ca-cert.p12
Maximilian Hils
  • 6,309
  • 3
  • 27
  • 46