I changed Line 642 to
P_QUERY_STRING => P_QUERY_STRING
After this change I got
<Error><Code>SignatureDoesNotMatch</Code><Message>The request signature we calculated does not match the signature you provided. Check your key and signing method.</Message>
I found that this issue was in the canonical_request function.
On line 395 we were escaping the query string which was different then the url
l_query_string := aws4_escape(P_QUERY_STRING);
So the url we were calling was formatted like this
list-type=2&max-keys=1000&prefix=RRS
but the
query_string passed to
was
list-type=2%26max-keys=1000%26prefix=RRS
so the signature did not match
changed line 395 to
l_query_string := P_QUERY_STRING;
So short summary this works
Line 395 l_query_string := P_QUERY_STRING;
Line 642 P_QUERY_STRING => P_QUERY_STRING
In case anyone else runs into this issue.
I found that there was an issue on line 642 with the call to prep_aws_data. The p_query_string was passed in as null.
I changed Line 642 to P_QUERY_STRING => P_QUERY_STRING
After this change I got
<Error><Code>SignatureDoesNotMatch</Code><Message>The request signature we calculated does not match the signature you provided. Check your key and signing method.</Message>
I found that this issue was in the canonical_request function.
On line 395 we were escaping the query string which was different then the url
l_query_string := aws4_escape(P_QUERY_STRING);
So the url we were calling was formatted like this list-type=2&max-keys=1000&prefix=RRS but the query_string passed to was list-type=2%26max-keys=1000%26prefix=RRS so the signature did not match
changed line 395 to l_query_string := P_QUERY_STRING;
So short summary this works Line 395 l_query_string := P_QUERY_STRING; Line 642 P_QUERY_STRING => P_QUERY_STRING
`