paul
05/23/2022, 11:12 AMMark Takata (Adobe)
05/23/2022, 2:53 PMiknowkungfoo
06/16/2022, 11:24 PMiknowkungfoo
06/16/2022, 11:26 PMpaul
06/17/2022, 12:49 AMpaul
06/17/2022, 12:49 AMphilcruz
08/16/2022, 9:15 PMMark Berning
08/23/2022, 2:06 PMbrianklaas
08/24/2022, 7:20 PMbdw429s
11/09/2022, 4:17 PMgeneratesecretkey( 'AES', '256' )
• The base64-coded MD5 hash of the key I tried two different ways--
◦ by hashing the base64-encoded key toBase64( hash( key ) )
◦ or hashing the original binary key toBase64( hash( toBinary( key ) ) )
However, no matter what I do, I get this error back from the AWS REST API
The calculated MD5 hash of the key did not match the hash that was provided.
I'm having a hard time finding a specific reference online that shows examples of what an AES256 key and it's hash would look like, but I can see that my values are not matching examples I see in tickets online. Is anyone, perhaps more familiar with how AWS does stuff, able to see what I'm doing wrong here?bdw429s
11/09/2022, 8:00 PMbdw429s
11/09/2022, 8:00 PMCameron Childress
12/01/2022, 4:28 PMMark Berning
12/12/2022, 8:32 PMharryk
04/13/2023, 12:58 PMharryk
05/01/2023, 3:43 PM/**
* This operation sets the configuration of the website that is specified in the website subresource.
* <https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketWebsite.html>
* @Bucket the name of the bucket
* @Content-MD5 The base64-encoded 128-bit MD5 digest of the data. You must use this header as a message integrity check to verify that the
* request body was not corrupted in transit.
* @x-amz-expected-bucket-owner The account ID of the expected bucket owner. If the bucket is owned by a different account, the request fails
* with the HTTP status code 403 Forbidden (access denied).
* @x-amz-sdk-checksum-algorithm Indicates the algorithm used to create the checksum for the object when using the SDK. This header will not
* provide any additional functionality if not using the SDK.
* @WebsiteConfiguration Root level tag for the WebsiteConfiguration parameters. Required: Yes
* @ErrorDocument The name of the error document for the website.
* @IndexDocument The name of the index document for the website.
* @RedirectAllRequestsTo The redirect behavior for every request to this bucket's website endpoint. If you specify this property, you can't
* specify any other property.
* @RoutingRules Rules that define when a redirect is applied and the redirect behavior. Type: Array of RoutingRule data types
*/
public any function putBucketWebsite(
required string Bucket,
) {
var requestSettings = api.resolveRequestSettings( argumentCollection = arguments );
var queryParams = { 'website': '' };
var apiResponse = apiCall(
requestSettings,
'PUT',
'/',
queryParams,
{ },
arguments.WebsiteConfiguration
);
return apiResponse;
}
My problem here is the WebsiteConfiguration xml data type. I guess that I would have to read the existing settings and then merge my rewriteRule xml Node into the existing xml?
Or is there an easier way? aws-cfml has some xml methods, but not xmlMerge - so I could add it?
Example:
settings = aws.s3.getBucketWebsite(
Bucket="pwa-app"
);
// settings.rawData = '<WebsiteConfiguration xmlns="<http://s3.amazonaws.com/doc/2006-03-01/>"><IndexDocument><Suffix>index.html</Suffix></IndexDocument><ErrorDocument><Key>index.html</Key></ErrorDocument></WebsiteConfiguration>';
WebsiteConfiguration = xmlMerge(settings.rawData, '<RoutingRules><RoutingRule><Condition><KeyPrefixEquals>webcam</KeyPrefixEquals><HttpErrorCodeReturnedEquals>403</HttpErrorCodeReturnedEquals></Condition><Redirect><Protocol>https</Protocol><HostName><http://testhost.de|testhost.de></HostName><ReplaceKeyWith>podcasts/webcam.html</ReplaceKeyWith></Redirect></RoutingRule></RoutingRules>');
setdata = aws.s3.putBucketWebsite(
Bucket="pwa-app",
WebsiteConfiguration = WebsiteConfiguration
);
Alex
05/22/2023, 8:13 AMtony
08/09/2023, 2:10 PMMark Berning
09/29/2023, 11:48 AMdan.byron
12/29/2023, 9:03 PMdan.byron
02/08/2024, 7:22 PM/opt/lucee/tomcat/conf/server.xml
but that setting is set for 20000, so not sure that’s applicable?
<Connector port="8888" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" />
paul
05/20/2024, 2:04 AMSteve Bryant
06/28/2024, 5:47 PMjakobward
08/06/2024, 3:10 AMnyahgfx
08/19/2024, 8:10 AMalholden
04/01/2025, 10:20 PM<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Connector resourceType="Images">
<Error number="0"/>
<CurrentFolder acl="255" path="/" url="<https://BUCKET.s3.amazonaws.com/aam/assets/Image/>"/>
<Files/>
</Connector>
I'm too dumb to understand why S3 would be happy to return other "folder" lists from the same bucket, except just this "/aam/" one, to a Lucee 6.1.0.243 server running Mura.
I'll try updating the S3 Resource Extension - 2.0.2.21 ( 2.0.1.25 ) tonight, although I'm not sure how only one location in a bucket would need it.
Thanks for reading...