502 Bad Gateway Error in CloudFront AWS

0 votes

Hello This is my Website. www.giftdays.jp Which is insecured as its older SSL certificate has expired and is the reason I switched to AWS . Here is what I did step by step.

1) Issued a certificate aws cert manager method. It has been issued and status are OK and all green

2)Create a bucket inside s3 and set permission to public access + set properties(Static website hosting) to redirect requests to my domain which is www.giftdays.jp

3) Create a cloudfront distribution linking my issued aws certificate and s3 bucket.

Here is the result:

1)S3 bucket links shows XML error.

2)which leads to cloudfront error same as xml

3) Site is not secured.

Few keypoints:

I also did route to redirect dns to s3 link which results in same xml error page, thats why I have removed it from route 53 settings. Can anyone help me where am i going wrong. I just want to make my site secured.

Redirect Rules

Error:

This XML file does not appear to have any style information associated with it. The document tree is shown below.

 <ListBucketResult xmlns="s3.amazonaws.com/doc/2006-03-01/">; <Name>giftdays</Name> <Prefix/> <Marker/> <MaxKeys>1000</MaxKeys> <IsTruncated>false</IsTruncated> </ListBucketResult>

Sep 6, 2018 in AWS by bug_seeker
• 15,350 points
687 views

1 answer to this question.

0 votes

To resolve this you have 2 option. 
 

  • Enable HTTP back to your origin which would allow CloudFront to make HTTP connections to your Origin, however you could continue to serve HTTPS content to your viewers.

  • If you had a certificate that allowed a wildcard like *.salesfront.com, you could CNAME cdn.salesfront.com = d2trhlwwrhewo8.cloudfront.net and then allow cdn.salesfront.com on your Origins certificate so that it passes the right domain name when trying to establish the SSL session.
answered Sep 6, 2018 by Priyaj
• 56,920 points

Related Questions In AWS

0 votes
1 answer

Nginx error "502 Bad Gateway nginx/1.16.0"

This typically indicates that a back-end service ...READ MORE

answered Jul 3 in AWS by Isha
794 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

AWS S3 uploading hidden files by default

versioning is enabled in your bucket. docs.aws.amazon.com/AmazonS3/latest/user-guide/….... the ...READ MORE

answered Oct 4, 2018 in AWS by Priyaj
• 56,920 points
296 views
0 votes
1 answer

How to decrypt the encrypted S3 file using aws-encryption-cli --decrypt

Use command : aws s3 presign s3://mybucket/abc_count.png you get ...READ MORE

answered Oct 22, 2018 in AWS by Priyaj
• 56,920 points
669 views
0 votes
1 answer

Import my AWS credentials using python script

Using AWS Cli  Configure your IAM user then ...READ MORE

answered Nov 16, 2018 in AWS by Jino
• 5,560 points
467 views
0 votes
2 answers
0 votes
2 answers
0 votes
1 answer