-
Notifications
You must be signed in to change notification settings - Fork 619
V4 Signer #36
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
V4 Signer #36
Conversation
…considered always unsignable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had 2 main comments.
-
We talked about this yesterday but just reiterating here. It might be nice to allow customers to specify a list of unsignable headers that can be merged into our known list of unsignable headers. Ruby currently allows this, and it could be nice if they need to not sign a header that gets modified by a proxy, or we need to work-around an issue like we did with XRay.
-
Are you still expecting to have separate node and browser packages? It might be a lot to ask customers to also provide a SHA256 implementation if we can easily hook that up for them.
}); | ||
|
||
it( | ||
'should return true for ArrayBuffers created with a different instance of the ArrayBuffer constructor', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice test! Take that, frames!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Turns out to be surprisingly relevant to running Jest, too.
|
* Add a VM- and WebWorker-safe way to check if an object is an ArrayBuffer * Document expectations on headers and querystring params * WIP commit * WIP commit * Add a node stream collector * Add a hex encoding package * Add tests for getCanonicalQuery * Add tests for getPayloadHash * Remove dependency on and use of stream collectors. Streams should be considered always unsignable * Add tests to fully cover SignatureV4::signRequest * Remove unused packages * Update RequestSigner interface to take keywords args instead of positional arguments * Add presigner and functional and unit tests * Cover the last uncovered line of code * Allow the set of unsignable headers to be customized
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread. |
The signatures in the functional tests in
__tests__/SignatureV4.ts
were calculated using the PHP SDK's signers. Tests use node crypto packages, with the expectation that browser SDK modules will inject the browser Sha256 implementation via theSignatureV4
constructor.Jest reports the following in Node 4, 5, 6, 7, and 8: