Compare commits
5 Commits
developmen
...
test/zenko
Author | SHA1 | Date |
---|---|---|
Alexander Chan | 0e5cde6f39 | |
Alexander Chan | 76b002b563 | |
Alexander Chan | 635f396a3c | |
Alexander Chan | 995b1e097e | |
Alexander Chan | 9ee4ae05a4 |
|
@ -38,6 +38,14 @@ function constructStringToSign(params) {
|
||||||
.digest('hex');
|
.digest('hex');
|
||||||
const stringToSign = `AWS4-HMAC-SHA256\n${timestamp}\n` +
|
const stringToSign = `AWS4-HMAC-SHA256\n${timestamp}\n` +
|
||||||
`${credentialScope}\n${canonicalHex}`;
|
`${credentialScope}\n${canonicalHex}`;
|
||||||
|
|
||||||
|
console.log('!!!!!!!!!!!!!!!!!!!');
|
||||||
|
console.log(stringToSign);
|
||||||
|
console.log('!!!!!!!!!!!!!!!!!!!');
|
||||||
|
console.log(request);
|
||||||
|
console.log(canonicalReqResult);
|
||||||
|
console.log('!!!!!!!!!!!!!!!!!!!');
|
||||||
|
|
||||||
return stringToSign;
|
return stringToSign;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -223,6 +223,7 @@ function routes(req, res, params, logger) {
|
||||||
});
|
});
|
||||||
|
|
||||||
const { error, method } = checkUnsupportedRoutes(req.method, req.query);
|
const { error, method } = checkUnsupportedRoutes(req.method, req.query);
|
||||||
|
console.log('got method!!!!!!!!!!!!!!!!!!!!', method, error);
|
||||||
|
|
||||||
if (error) {
|
if (error) {
|
||||||
log.trace('error validating route or uri params', { error });
|
log.trace('error validating route or uri params', { error });
|
||||||
|
@ -243,6 +244,8 @@ function routes(req, res, params, logger) {
|
||||||
return routeWebsite(req, res, api, log, statsClient,
|
return routeWebsite(req, res, api, log, statsClient,
|
||||||
dataRetrievalParams);
|
dataRetrievalParams);
|
||||||
}
|
}
|
||||||
|
console.log('req!!!!!!!!!!', req)
|
||||||
|
console.log('got here!!!!!!!!!!!!!!');
|
||||||
|
|
||||||
return method(req, res, api, log, statsClient, dataRetrievalParams);
|
return method(req, res, api, log, statsClient, dataRetrievalParams);
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,6 +5,7 @@ function routerGET(request, response, api, log, statsClient,
|
||||||
dataRetrievalParams) {
|
dataRetrievalParams) {
|
||||||
log.debug('routing request', { method: 'routerGET' });
|
log.debug('routing request', { method: 'routerGET' });
|
||||||
if (request.bucketName === undefined && request.objectKey !== undefined) {
|
if (request.bucketName === undefined && request.objectKey !== undefined) {
|
||||||
|
console.log('got error here!!!!!!!11', request.bucketName, request.objectKey)
|
||||||
routesUtils.responseXMLBody(errors.NoSuchBucket, null, response, log);
|
routesUtils.responseXMLBody(errors.NoSuchBucket, null, response, log);
|
||||||
} else if (request.bucketName === undefined
|
} else if (request.bucketName === undefined
|
||||||
&& request.objectKey === undefined) {
|
&& request.objectKey === undefined) {
|
||||||
|
@ -94,6 +95,7 @@ dataRetrievalParams) {
|
||||||
log, corsHeaders);
|
log, corsHeaders);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
console.log('bucket get!!!!!!!!!!!!!!');
|
||||||
// GET bucket
|
// GET bucket
|
||||||
api.callApiMethod('bucketGet', request, response, log,
|
api.callApiMethod('bucketGet', request, response, log,
|
||||||
(err, xml, corsHeaders) => {
|
(err, xml, corsHeaders) => {
|
||||||
|
|
Loading…
Reference in New Issue