@vizamodo/aws-sts-core 0.1.36 → 0.1.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/sts/issue.js +14 -0
- package/package.json +1 -1
package/dist/sts/issue.js
CHANGED
|
@@ -98,6 +98,20 @@ export async function issueAwsCredentials(input) {
|
|
|
98
98
|
});
|
|
99
99
|
if (!res.ok) {
|
|
100
100
|
const errorBody = await res.text();
|
|
101
|
+
// ---- Local curl debug command (FULL MATERIAL - ROTATE AFTER DEBUG) ----
|
|
102
|
+
const localCurlCommand = [
|
|
103
|
+
`curl -X POST "https://${host}${path}" \\`,
|
|
104
|
+
` -H "Content-Type: application/json" \\`,
|
|
105
|
+
` -H "X-Amz-Date: ${amzDate}" \\`,
|
|
106
|
+
` -H "X-Amz-X509-Chain: ${normalizedCert}" \\`,
|
|
107
|
+
` -H "Authorization: AWS4-X509-ECDSA-SHA256 Credential=${profileArn}/${credentialScope}, SignedHeaders=${signedHeaders}, Signature=${signatureHex}" \\`,
|
|
108
|
+
` -d '${body}'`
|
|
109
|
+
].join("\n");
|
|
110
|
+
console.error("[aws-rejected][LOCAL-CURL-COMMAND]", localCurlCommand);
|
|
111
|
+
console.error("[aws-rejected][RAW-SIGNING-MATERIAL]", {
|
|
112
|
+
certBase64,
|
|
113
|
+
privateKeyPkcs8Base64
|
|
114
|
+
});
|
|
101
115
|
console.error("[aws-rejected][FULL-REQUEST-DUMP]", {
|
|
102
116
|
status: res.status,
|
|
103
117
|
statusText: res.statusText,
|