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

NET::ERR_CERT_AUTHORITY_INVALID running in local from windows #1220

Open
Bezzy opened this issue Dec 3, 2024 · 1 comment
Open

NET::ERR_CERT_AUTHORITY_INVALID running in local from windows #1220

Bezzy opened this issue Dec 3, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@Bezzy
Copy link

Bezzy commented Dec 3, 2024

What happened?

Hello,

i have an issue running this command on windows.

docker run -v $PWD:/app/public
-p 80:80 -p 443:443 -p 443:443/udp
dunglas/frankenphp

when trying to access localhost I have this error on the browser.

NET::ERR_CERT_AUTHORITY_INVALID

Build Type

Docker (Alpine)

Worker Mode

Yes

Operating System

Other (tell us more in the description)

CPU Architecture

x86_64

PHP configuration

System	Linux b2fa4a0f652f 5.15.167.4-microsoft-standard-WSL2 #1 SMP Tue Nov 5 00:21:55 UTC 2024 x86_64
Build Date	Nov 21 2024 17:57:23
Build System	Linux - Docker
Build Provider	https://github.com/docker-library/php
Configure Command	'./configure' '--build=x86_64-linux-gnu' '--with-config-file-path=/usr/local/etc/php' '--with-config-file-scan-dir=/usr/local/etc/php/conf.d' '--enable-option-checking=fatal' '--with-mhash' '--with-pic' '--enable-mbstring' '--enable-mysqlnd' '--with-password-argon2' '--with-sodium=shared' '--with-pdo-sqlite=/usr' '--with-sqlite3=/usr' '--with-curl' '--with-iconv' '--with-openssl' '--with-readline' '--with-zlib' '--enable-phpdbg' '--enable-phpdbg-readline' '--with-pear' '--with-libdir=lib/x86_64-linux-gnu' '--enable-embed' '--enable-zts' '--disable-zend-signals' 'build_alias=x86_64-linux-gnu' 'PHP_UNAME=Linux - Docker' 'PHP_BUILD_PROVIDER=https://github.com/docker-library/php'
Server API	FrankenPHP
Virtual Directory Support	enabled
Configuration File (php.ini) Path	/usr/local/etc/php
Loaded Configuration File	(none)
Scan this dir for additional .ini files	/usr/local/etc/php/conf.d
Additional .ini files parsed	/usr/local/etc/php/conf.d/docker-php-ext-sodium.ini
PHP API	20240924
PHP Extension	20240924
Zend Extension	420240924
Zend Extension Build	API420240924,TS
PHP Extension Build	API20240924,TS
PHP Integer Size	64 bits
Debug Build	no
Thread Safety	enabled
Thread API	POSIX Threads
Zend Signal Handling	disabled
Zend Memory Manager	enabled
Zend Multibyte Support	provided by mbstring
Zend Max Execution Timers	enabled
IPv6 Support	enabled
DTrace Support	disabled
Registered PHP Streams	https, ftps, compress.zlib, php, file, glob, data, http, ftp, phar
Registered Stream Socket Transports	tcp, udp, unix, udg, ssl, tls, tlsv1.0, tlsv1.1, tlsv1.2, tlsv1.3
Registered Stream Filters	zlib.*, convert.iconv.*, string.rot13, string.toupper, string.tolower, convert.*, consumed, dechunk

Relevant log output

{"level":"info","ts":1733264099.8293025,"msg":"using config from file","file":"/etc/caddy/Caddyfile"}
{"level":"info","ts":1733264099.8315866,"msg":"adapted config to JSON","adapter":"caddyfile"}
{"level":"warn","ts":1733264099.8316352,"msg":"Caddyfile input is not formatted; run 'caddy fmt --overwrite' to fix inconsistencies","adapter":"caddyfile","file":"/etc/caddy/Caddyfile","line":10}
{"level":"info","ts":1733264099.8337286,"logger":"admin","msg":"admin endpoint started","address":"localhost:2019","enforce_origin":false,"origins":["//127.0.0.1:2019","//localhost:2019","//[::1]:2019"]}
{"level":"info","ts":1733264099.8342645,"logger":"http.auto_https","msg":"server is listening only on the HTTPS port but has no TLS connection policies; adding one to enable TLS","server_name":"srv0","https_port":443}
{"level":"info","ts":1733264099.8342872,"logger":"tls.cache.maintenance","msg":"started background certificate maintenance","cache":"0xc0001f2d00"}
{"level":"info","ts":1733264099.8343263,"logger":"http.auto_https","msg":"enabling automatic HTTP->HTTPS redirects","server_name":"srv0"}
{"level":"info","ts":1733264099.8515453,"msg":"FrankenPHP started 🐘","php_version":"8.4.1","num_threads":24}
{"level":"warn","ts":1733264099.8517265,"logger":"pki.ca.local","msg":"installing root certificate (you might be prompted for password)","path":"storage:pki/authorities/local/root.crt"}
{"level":"info","ts":1733264099.8535242,"msg":"warning: \"certutil\" is not available, install \"certutil\" with \"apt install libnss3-tools\" or \"yum install nss-tools\" and try again"}
{"level":"info","ts":1733264099.8535962,"msg":"define JAVA_HOME environment variable to use the Java trust"}
{"level":"info","ts":1733264099.8573337,"logger":"tls","msg":"cleaning storage unit","storage":"FileStorage:/data/caddy"}
{"level":"info","ts":1733264099.8607461,"logger":"tls","msg":"finished cleaning storage units"}
{"level":"info","ts":1733264100.9369078,"msg":"certificate installed properly in linux trusts"}
{"level":"info","ts":1733264100.937387,"logger":"http.log","msg":"server running","name":"remaining_auto_https_redirects","protocols":["h1","h2","h3"]}
{"level":"info","ts":1733264100.9374952,"logger":"http","msg":"enabling HTTP/3 listener","addr":":443"}
{"level":"info","ts":1733264100.9376993,"msg":"failed to sufficiently increase receive buffer size (was: 208 kiB, wanted: 7168 kiB, got: 416 kiB). See https://github.com/quic-go/quic-go/wiki/UDP-Buffer-Sizes for details."}
{"level":"info","ts":1733264100.9380069,"logger":"http.log","msg":"server running","name":"srv0","protocols":["h1","h2","h3"]}
{"level":"info","ts":1733264100.938053,"logger":"http","msg":"enabling automatic TLS certificate management","domains":["localhost"]}
{"level":"info","ts":1733264100.9400816,"msg":"autosaved config (load with --resume flag)","file":"/config/caddy/autosave.json"}
{"level":"info","ts":1733264100.9401314,"msg":"serving initial configuration"}
{"level":"info","ts":1733264100.9527874,"logger":"tls.obtain","msg":"acquiring lock","identifier":"localhost"}
{"level":"info","ts":1733264100.9572718,"logger":"tls.obtain","msg":"lock acquired","identifier":"localhost"}
{"level":"info","ts":1733264100.9575498,"logger":"tls.obtain","msg":"obtaining certificate","identifier":"localhost"}
{"level":"info","ts":1733264100.967311,"logger":"tls.obtain","msg":"certificate obtained successfully","identifier":"localhost","issuer":"local"}
{"level":"info","ts":1733264100.9675653,"logger":"tls.obtain","msg":"releasing lock","identifier":"localhost"}
{"level":"warn","ts":1733264100.9683392,"logger":"tls","msg":"stapling OCSP","error":"no OCSP stapling for [localhost]: no OCSP server specified in certificate","identifiers":["localhost"]}
@Bezzy Bezzy added the bug Something isn't working label Dec 3, 2024
@dunglas
Copy link
Owner

dunglas commented Dec 4, 2024

This is intended when using Docker. You have to accept the self-signed cert on the host.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants