From 01f95e902255873a9ef22bf5ea6612c81a11d334 Mon Sep 17 00:00:00 2001 From: Daniel Bankhead Date: Mon, 5 Feb 2024 14:14:21 -0800 Subject: [PATCH] refactor: use `hostname` for signing --- src/signer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/signer.ts b/src/signer.ts index 6811c5754..65e2f4462 100644 --- a/src/signer.ts +++ b/src/signer.ts @@ -287,7 +287,7 @@ export class URLSigner { const fqdn = new url.URL( config.host?.toString() || config.cname || this.storage.apiEndpoint ); - extensionHeaders.host = fqdn.host; + extensionHeaders.host = fqdn.hostname; if (config.contentMd5) { extensionHeaders['content-md5'] = config.contentMd5; }