Questions tagged [amazon-cloudfront]

Amazon CloudFront is a content delivery network (CDN) offered by Amazon Web Services.

94 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
6
votes
1answer
1k views

Strict-Transport-Security on CloudFront with S3 origin?

My company's site has a static homepage for speed and cost reasons. We use S3 as the origin for CloudFront. Now, we would like to declare Strict-Transport-Security for the entire domain, but S3 seems ...
4
votes
0answers
829 views

S3/Cloudfront CORS working on some files only

I'm really struggling to get Cloudfront and S3 to add Access-Control-Allow-Origin: * to the headers of video files stored on S3 (for inline video on iPhones - seems to be working everywhere else ...
3
votes
0answers
855 views

AWS SSL Certificate without Load-Balancer?

I have a standard Elastic Beanstalk app set up and running great over HTTP. Following the AWS Documentation I requested an SSL Certificate and configured it with CloudFront. Instead of a load-...
3
votes
1answer
366 views

Blue/green deployment - AWS Cloudfront with ELB as custom origin

I have following configuration: Cloudfront - ELB - AutoScalingGroup - EC2s Cloudfront serves file-[hash].js files (with chunkhash in their names) from custom origin (ELB). EC2s serve the file-[hash]...
3
votes
1answer
1k views

Does CloudFront support S3 signature version 4 for KMS encrypted objects?

I'm using Cloudfront with an S3 origin that is using KMS to encrypt objects. I'm getting the following error when sending a GET request for an object in the S3 bucket. Requests specifying Server ...
3
votes
1answer
828 views

CloudFront CDN breaks due to DirectorySlash behavior of Apache

My CDN domain is set to www.mysite.com, and it reads from origin.mysite.com. mod_dir is enabled on apache, and so any request without a trailing slash is redirected with a 301 to the equivalent URL ...
3
votes
0answers
1k views

CloudFront + S3 Access Denied Using Signed Cookies

I'm trying to integrate signed cookies for a CloudFront distribution that's fed off of an S3 bucket but getting access denied error messages: <Error> <Code>AccessDenied</Code> ...
2
votes
0answers
91 views

CloudFront usually misses from browser, hits from cURL

When I load my HTML page in my browser, all requests for assets have x-cache: Miss from cloudfront. If I reload my browser very quickly, I can sometimes get a Hit. If I open my developer tools and "...
2
votes
0answers
17 views

Proper way to handle file serving

We have a website where we our daily bandwidth use is roughly 10GB of user generated contents. The software layer is simply Heroku + some addons for DB and monitoring, and we are handling the uploads ...
2
votes
0answers
1k views

AWS CloudFront with API Gateway's Base Path Mapping for IPv6 support

We currently have some APIs set up in API Gateway, with a Custom Domain Name defined with a Regional Endpoint and Base Path Mappings that map incoming requests to the appropriate API and deployment ...
2
votes
0answers
1k views

Buffering when serving videos through AWS CloudFront

We are hosting videos in AWS S3 in HLS format (lots of .ts files, + playlists .m3u8). We have configured AWS CloudFront with all Edge locations to serve those files. We have 2 apps, iOS and Android, ...
2
votes
1answer
4k views

Setting up CloudFront [Custom Origin] for EC2 instance

I have been checking things up & down on Google & AWS Documentation but can't seem to nail this one. I have an EC2 instance setup with a domain being served via a virtual host and I need to ...
2
votes
0answers
681 views

How to get clean URLs in CloudFront

I'm hosting my static website on AWS S3, with Cloudfront as a CDN, and I'm wondering how I can get clean URLs working. I currently have to go to example.com/about.html to get the about page. I'd ...
2
votes
0answers
541 views

Reverse Proxy on cloudfront

I have an angular site / web application (Lets call this www.mysite.com) hosted on Amazon S3 as a static website. This s3 bucket serves as the origin for a cloudfront distribution and it works ...
2
votes
1answer
528 views

Route 53 configuration for Cloudfront distribution linked to S3 bucket for naked domain

I am using route 53 for a domain (example.com) linked to my app on Heroku. To handle naked domain redirection, I am using a S3 bucket as explained here: https://aws.amazon.com/blogs/aws/root-domain-...
2
votes
0answers
777 views

Caching Docker (Cloudfront) images with Squid

I have a Squid server setup with ssl-bump caching SSL resources used by Docker but I'm having issues trying to get it to cache requests to Cloudfront, for example: 1415056176.733 190419 172.17.0.40 ...
2
votes
0answers
309 views

Cherokee force gzip compression for HTTP/1.0

I am using CloudFront with a Cherokee origin server for static files. Cherokee serves gzipped content for direct browser requests without any problem. But when CloudFront requests content, Cherokee ...
1
vote
0answers
62 views

Client connects to Cloudfront via HTTP2, then connects to an Apache Server via HTTP1, can HTTP2 vulnerabilities be exploited in the HTTP1 connection?

We have an environment where customers connect to a Cloudfront distribution via HTTP2 and then from the Cloudfront distribution to an Apache web server via a HTTP1 connection. [ client ] ---(https, ...
1
vote
0answers
133 views

Multi-tenant (multi-domain / multi-certificate) on AWS Cloudfront

I have AWS CloudFront serving content (from EC2/etc), this works fine. The content I have is 'multi-tenant' in that it adjusts its branding/theme based on the domain being used. In theory I would just ...
1
vote
0answers
265 views

Nginx Redirect to EC2 Instance

ORIGINAL I had angular (version: 7) site which was deployed on S3 bucket, but for SEO purposes, recently I integrated Angular Universal. Now I moved site/frontend from S3 bucket to EC2 instance. I ...
1
vote
1answer
348 views

Cloudfront (w/ S3) Static Website Doesn't utilize index.html from sub directories

I have my website hosted on S3 with CloudFront as a CDN, and I need these two URLs to behave the same and to serve the index.html file within the directory: example.com/directory example.com/...
1
vote
0answers
289 views

The way AWS Lambda@Edge accesses to S3 restricted by Object Access Identity (OAI)

I have a question. Is the Lambda function (written in node.js) associated with CloudFront accessible to S3 objects restricted by Object Access Identity (OAI)? If yes, could you tell me how to access? (...
1
vote
0answers
1k views

Cloudfront Access Denied, but only on certain files

I've read through several similar issues, but they differ in that This isn't a website, just CDN for images I have no subdirectories I was notified by our marketing dept that some of our photos ...
1
vote
1answer
1k views

Why CloudFront does not return Access-Control-Allow-Origin?

I'm trying to figure out why cloudfront distribution does not cache / send through access-control-allow-origin. When I curl my website: HTTP/1.1 200 OK Date: Sat, 03 Mar 2018 07:42:01 GMT Content-...
1
vote
0answers
361 views

Cloudfront not compressing Transfer-encoding chunked

My setup looks like this: User->Cloudfront->Nginx->gunicorn Apparently nginx, doesn't compress (gzip) when there is a CDN inbetween (Via header present) so my nginx sends: Transfer-encoding: chunked ...
1
vote
0answers
880 views

Disable Detailed Response Headers from CloudFront to Satisfy Veracode?

If this is the wrong StackExchange sub-exchange, please redirect me, I'm happy to move this question. I was just moved onto a project managing a CloudFront instance. I've never used any Amazon cloud ...
1
vote
0answers
736 views

Chrome stalled requests for some HTTP2 resources

Issue Some resources from the CDN take minutes to load because, according to Chrome devtools, are "stalled". This happens only on Chrome and only the first time I open the page in an incognito ...
1
vote
0answers
649 views

Heroku SSL redirect to www.example.com with AWS Route 53 and Cloudfront

Current Situation example.com == examplecom and so on because of spam I've a Domain examplecom on GoDaddy and a SSL cert for it. The real application is hosted on Heroku at exampleherokuappcom. I ...
1
vote
1answer
565 views

Amazon Cloudfront with S3 bucket - 2 origins

I am bit confused with setting up Amazon Cloudfront and S3 bucket. I've got my bucket setup and using the wordpress WP Offload S3 plugin to store any images in this bucket. When checking the image ...
1
vote
0answers
43 views

How to sign Url on behalf of a certain origin access identity (cloud front)

I want two origin access identities for cloud front (and s3). One that can just view content , and another , that can just put content (and maybe another that can just delete ) I know I can create an ...
1
vote
0answers
769 views

AWS cloudfront with SNI + ELB with 443 to 80 redirection to EC2 issue

I have configured web server front ending with AWS ELB and CloudFront. I have deployed SSL certificate on load balancer (ELB) for HTTPS connection. We have set up 2 listener protocols: Source -> 80 -...
1
vote
0answers
131 views

Cloudfront Distribution Wont Accept New SSL Certificate

I uploaded a reissued new multi-domain certificate via IAM, but when I access the CDN and check the cert, it still has the old cert with the old domains. Tried so far: I tried clearing the browser ...
1
vote
0answers
1k views

CORS Fails on CloudFront Distribution with Nginx Origin

I have a CloudFront distribution set up with an Nginx server as the origin (a Media Temple DV server, to be specific). I enabled the Access-Control-Allow-Origin: * header so fonts will work in Firefox....
1
vote
1answer
263 views

Amazon CloudFront Synchronization

I want to leverage Amazon CloudFront to "cache" my webserver such that my website stays up even if my webserver goes down. I understand CloudFront has many edge servers that facilitate the request/...
1
vote
0answers
153 views

Randomly broken files from CloudFront

I host my software installers on S3 and distribute them through CloudFront. Had couple complaints of broken files from customers. Problems appeared the same night. My files are DMG disc images. ...
0
votes
1answer
44 views

How to route to Cloudfront+s3 and rest to ALB in Route53?

The project has a domain name foobar.com pointing to a legacy system, hosting and serving mainly static files. The project got more complex over time and in AWS ALB certain /routes are pointed to ...
0
votes
0answers
31 views

Same-Origin Policy : configuring CloudFront static content to communicate with dynamic backend?

I am currently hosting a static single-page web application with AWS CloudFront. I would like to add a backend service for my web ui/client to communicate with so that I can serve dynamic content. ...
0
votes
1answer
28 views

Amazon CloudFront default SSL certificate for multiple domain names

A few years ago I setup an S3 bucket and enabled hosting. It's got an index.html file, which I use as a simple landing page. I then setup AWS CloudFront to use this S3 bucket as an origin server and ...
0
votes
0answers
32 views

How to make Cloudfront pick up html files from S3 when request does not end in html

Our static website is stored on S3 and distributed via Cloudfront. The S3 file <S3-bucket>/foo/bar.html can be accessed at www.example.com/foo/bar.html but not at www.example.com/foo/bar (...
0
votes
0answers
26 views

AWS s3 image access is showing access denied while requesting the image through cloudfront

{ "Version": "2012-10-17", "Id": "Policy1548751526201", "Statement": [ { "Sid": "Stmt1548751524478", "Effect": "Allow", "Principal": { "AWS": "arn:aws:iam::...
0
votes
0answers
22 views

AWS CloudFront OAI with S3 Origin not logging GetObject in CloudTrail

As the subject line mentions. I have an S3 Website bucket which has only 1 policy allowing the CloudFront distribution's OAI that it is tethered, to have the "GetObject" action on all objects within ...
0
votes
0answers
50 views

AWS Cognito Hosted UI Bypasses WAF

I have an S3 hosted site behind a Cloudfront and WAF. I set up a Cognito hosted UI with a custom domain (auth.example.com where example.com is my site). Cognito generates a Cloudfront distribution ...
0
votes
1answer
11 views

Base64 images not showing in drupal website after integration with cloudfront

I am receiving some issues on Drupal. I have integrated Amazon cloudfront with Drupal. The Cloudfront origin for my domain is drupal.example.com and Cnames are www.example.com and example.com. The ...
0
votes
1answer
83 views

Connect AWS SSL certificate to Intercom Articles

We have our support articles in Intercom Articles and need to attach a SSL certificate to the subdomain support.packaly.com. Intercom does not offer its own certificate so we need to do it through AWS....
0
votes
1answer
42 views

How proxy all request that comes to some path like “/app*” to an EC2 instance using Cloudfront?

Right now I have a site hosted in S3 and delivery through Cloudfront and I have an application running on an EC2 instance. the problem is I need to serve the application using a folder in the domain ...
0
votes
0answers
44 views

How to configure Cloudfront for API Gateway with API key enabled?

I configured two API Gateways one with API-key enabled and the other with API-key disabled. For both the API gateways I configured and enabled CloudFront. For the API-gateway which has API-key ...
0
votes
0answers
59 views

How do I solve a CNAMEAlreadyExists error?

I'm trying to deploy a next.js app to AWS using serverless. However, when I try to deploy, I get this error: Serverless Error --------------------------------------- An error occurred: ...
0
votes
0answers
17 views

How to fix below-cloudfront distribution update error

I was trying to update cloudfront distribution(disable/remove OriginSSLprotocol:SSLv3) using below commands aws cloudfront get-distribution-config --id E29BDBENPXM1VE | jq 'del(.DistributionConfig....
0
votes
0answers
52 views

CloudFront Reverse Proxy - The specified CGI application encountered an error and the server terminated the process

I have a Wordpress website sat at something.example.com that all works fine, no problems whatsoever. We need this website to be accessible via example.com/something which is a reverse proxy from AWS ...
0
votes
1answer
39 views

Auto redirect Amazon CloudFront content from www to non-www

I'm really new to Amazon CloudFront. I have set up an S3 with Cloudfront, then I'm using a custom domain that I setup in CloudFlare. I can access my photo normally with this kind of link : https://...