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

Certificate is generated with a wrong DateTime #524

Open
Antonytm opened this issue May 11, 2023 · 1 comment
Open

Certificate is generated with a wrong DateTime #524

Antonytm opened this issue May 11, 2023 · 1 comment

Comments

@Antonytm
Copy link

Environment

  • Operating system (including version): Windows 11 Pro 22H2
  • mkcert version (from mkcert -version): 1.4.1
  • Server (where the certificate is loaded): local
  • Client (e.g. browser, CLI tool, or script): browser/cli
  • Date, time and timezone are configured to set automatically

What you did

  1. .\mkcert.exe -install
  2. .\mkcert.exe "*.headless.localhost"
  3. .\mkcert.exe -install
  4. Open browser, try to open cm.headless.localhost
    image
  5. Open certmgr.msc
    image
    image
    image
  6. Check current time: 12 of May 2023, 1:26 AM GMT+2

What went wrong

For some reason, the certificate generates for future + 8 hours.
And it is a reason, why it is invalid for browser or CLI calls.
(Or there is some other reason, I will confirm Date/time hypothesis after 10 hours)

@Antonytm
Copy link
Author

I can confirm that error was related to the timezone.
It started to work in the morning after 8+ hours.

The issue was not reproducible on another machine.
So, I don't know what exactly specific is about that machine.

Why don't generate certificates valid from -1 day to avoid this kind of issue?

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

No branches or pull requests

1 participant