Skip to content

Commit

Permalink
http: use the IDN decoded name in HSTS checks
Browse files Browse the repository at this point in the history
Otherwise it stores the info HSTS into the persistent cache for the IDN
name which will not match when the HSTS status is later checked for
using the decoded name.

Reported-by: Hiroki Kurosawa

Closes #10111
  • Loading branch information
bagder committed Dec 19, 2022
1 parent 4644195 commit 9e71901
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/http.c
Expand Up @@ -3646,7 +3646,7 @@ CURLcode Curl_http_header(struct Curl_easy *data, struct connectdata *conn,
#endif
)) {
CURLcode check =
Curl_hsts_parse(data->hsts, data->state.up.hostname,
Curl_hsts_parse(data->hsts, conn->host.name,
headp + strlen("Strict-Transport-Security:"));
if(check)
infof(data, "Illegal STS header skipped");
Expand Down

0 comments on commit 9e71901

Please sign in to comment.