You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think this is a bug. The only other reference I could find is here: #263 (comment)
What is the current behavior?
We are using the IAM auth link. The logs are filled with error: Refused to set unsafe header "host". The signature per se works (after all, the "overridden header" is the correct host to begin with, so there's nothing to override), but the mess in the logs causes some troubles with our error tracking.
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
No errors. Maybe we are using this incorrectly and I'm missing something.. I can't quite understand how this could work with Host being a forbidden header.2
Do you want to request a feature or report a bug?
I think this is a bug. The only other reference I could find is here: #263 (comment)
What is the current behavior?
We are using the IAM auth link. The logs are filled with error:
Refused to set unsafe header "host"
. The signature per se works (after all, the "overridden header" is the correct host to begin with, so there's nothing to override), but the mess in the logs causes some troubles with our error tracking.If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
Our Apollo client is configured as follows:
The
url
is our custom domain on AppSync.1What is the expected behavior?
No errors. Maybe we are using this incorrectly and I'm missing something.. I can't quite understand how this could work with
Host
being a forbidden header.2I think the problem is coming from here:
aws-mobile-appsync-sdk-js/packages/aws-appsync-auth-link/src/signer/signer.ts
Line 235 in 8502a78
Since the same
request
object is created to compute the IAM signature, and then replaced into the Apollo operation context:aws-mobile-appsync-sdk-js/packages/aws-appsync-auth-link/src/auth-link.ts
Line 103 in 82cb58e
Which versions and which environment (browser, react-native, nodejs) / OS are affected by this issue? Did this work in previous versions?
We also use the Cognito auth link - that one does not present any issue.
The same error is there on Safari 17.2.1 and Chrome 120, both on macOS 14.2.1
Footnotes
https://docs.aws.amazon.com/appsync/latest/devguide/custom-domain-name.html ↩
https://developer.mozilla.org/en-US/docs/Glossary/Forbidden_header_name ↩
The text was updated successfully, but these errors were encountered: