Skip to content

Caddy client_auth works for punycode but not IDN hostnames #7729

@hackysphere

Description

@hackysphere

Issue Details

Version: Caddy v2.11.2 on Arch Linux, and base Caddy v2.11.3 from the download page on Arch Linux

If using an internationalized hostname instead of its punycode version, Caddy will ignore tls client_auth rules when accessing the domain and allow requests without a mTLS certificate.

Example config:

つ.localhost

tls {
	client_auth {
		mode require
	}
}

respond {time.now}

If the hostname is instead set to xn--k9j.localhost, Caddy will correctly deny requests without mTLS.
I could not find any important differences in the logs.

Assistance Disclosure

AI not used

If AI was used, describe the extent to which it was used.

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug 🐞Something isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions