The Wayback Machine - https://web.archive.org/web/20220709065758/https://github.com/sitespeedio/sitespeed.io/issues/2979
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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document how to use client certificate in browser #2979

Open
znerd opened this issue May 4, 2020 · 4 comments
Open

Document how to use client certificate in browser #2979

znerd opened this issue May 4, 2020 · 4 comments

Comments

@znerd
Copy link

@znerd znerd commented May 4, 2020

I'd like to use a client certificate with sitespeed.io (with the Chrome backend). I've searched the documentation, but I could not find any explanation on how to do this.

Note that the Chrome browser does support the use the certificates installed in the host operating system (e.g. Windows or macOS).

Request: Please document how to use client certificates (e.g. P12) in the any browser (or at least Chrome) used by sitespeed.io.

@soulgalore
Copy link
Member

@soulgalore soulgalore commented May 5, 2020

Hi @znerd maybe you can help me out if you have some certificates. I think there's a couple of ways to do it:

  • For Firefox you can setup your own profile with --firefox.profileTemplate, I guess the best is to setup Firefox and then copy that dir and use it.
  • For Chrome my guess is to either create your own Docker file where you add the certificates or ignore them with --ignore-certificate-errors-spki-list see https://peter.sh/experiments/chromium-command-line-switches/

I've been lucky that I haven't needed to add extra certificates so far.

@hellosirandy
Copy link

@hellosirandy hellosirandy commented May 9, 2020

I'd like to use a client certificate with sitespeed.io (with the Chrome backend). I've searched the documentation, but I could not find any explanation on how to do this.

Note that the Chrome browser does support the use the certificates installed in the host operating system (e.g. Windows or macOS).

Request: Please document how to use client certificates (e.g. P12) in the any browser (or at least Chrome) used by sitespeed.io.

@znerd Have you found any way to insert client key/cert with sitespeed.io? For me I'm trying to test mtls endpoints with sitespeed.io so I think I'm looking for the same thing as you do.
Thanks!

@hellosirandy
Copy link

@hellosirandy hellosirandy commented May 15, 2020

Hi @soulgalore, in our case we are trying to run tests on internal mTLS url with sitespeed.io, in which ignore-certificate-errors won't work. Do you have any suggestion on inserting the key/cert in the request?
Thanks!

@soulgalore
Copy link
Member

@soulgalore soulgalore commented Jul 6, 2020

There's no magic in Browsertime/sitespeed.io so if you can do it with your browser you can do it with Browsertime/sitespeed.io. If you run Docker you can add your own extra start script: https://www.sitespeed.io/documentation/sitespeed.io/docker/#extra-start-script - I think you could use that to install extra certificates?

In our Docker container we install certificates for WebPageReplay, so I think if you can get the mounting right (mounting your certificate into the container you could use the same functionality): https://github.com/sitespeedio/sitespeed.io/blob/main/Dockerfile#L22 (but do it in your start script if you want to avoid creating your own container).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants