I'm trying to secure full e2e connection between clients and my backend servers. This is how my current infrastructure looks like:
- Fargate cluster with my backend apps placed inside private subnets.
- They are fronted by internal network load balancer which is also not exposed to the outside world.
- REST API Gateway with VPC link integration to my internal NLB.
Currently my NLB is using TLS listener on port 443 and have certificate attached but is terminating the TLS and communicating with its target group limply by TCP on port 80. My plan is to configure TLS and certs also on my Fargate nodes. Currently I lack the understanding of how the following setup would work. Is it going to send encrypted traffic from my clients to backend apps or rather perform decryption at the NLB and encrypt the traffic one more time before sending it to the Fargate nodes ?
I have learn reading many blogs that it is possible to achieve a passthrough behavior using NLB without decrypting/encrypting the traffic on NLB but didn't find any examples, also AWS documentation is not clear about this topic.
It is possible to have certificates applied only to my backend apps and have decryption happening only there ? My understanding is that I could look similar to below:
- Certs and TLS configured at my Fargate apps side
- NLB with TCP listener on port 443, no certs applied on NLB level. So the NLB would only pass the encrypted traffic from my clients to the backend.
Does anyone tried setting up similar infrastructure and have some knowledge on how this should be configured ?
Regards.