简体   繁体   English

使用 SSL 保护 Spring Boot 和 Angular 应用程序的最佳方法

[英]Best way to secure Spring Boot & Angular app with SSL

What is the best way to implement SSL in Spring Boot & Angular application (frontend with backend)?在 Spring Boot 和 Angular 应用程序(前端与后端)中实现 SSL 的最佳方法是什么?

  1. Should I configure SSL in both applications separately?我应该在两个应用程序中分别配置 SSL 吗?
  2. Or should I configure SSL in Nginx web server and not taking care about securing applications?或者我应该在 Nginx Web 服务器中配置 SSL 而不关心保护应用程序?

Should I configure SSL in both applications separately?我应该在两个应用程序中分别配置 SSL 吗?

If you've built out a microservice architecture and both your spring boot application and your Angular application are served off different domains, then yes you should configure SSL on both applications.如果您已经构建了一个微服务架构,并且您的 Spring Boot 应用程序和 Angular 应用程序都由不同的域提供服务,那么是的,您应该在这两个应用程序上配置 SSL。

Or should I configure SSL in Nginx web server and not taking care about securing applications?或者我应该在 Nginx Web 服务器中配置 SSL 而不关心保护应用程序?

If you are using NGINX to serve your Angular application, then yes you should setup SSL on it.如果您使用 NGINX 来为您的 Angular 应用程序提供服务,那么是的,您应该在其上设置 SSL。

I'll add that SSL is not the only step required to secure an application.我要补充一点,SSL 不是保护应用程序所需的唯一步骤。 Many applications will require some user management with role based permissions and control access to screens in your app or REST APIs based on user permissions.许多应用程序需要一些具有基于角色的权限的用户管理,并根据用户权限控制对应用程序或 REST API 中的屏幕的访问。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将 Spring 引导应用程序的 SSL.pem 文件合并到 ECR 中托管的 Docker 容器中的最佳安全方法? - Best secure method to incorporate SSL .pem file for Spring Boot app within Docker container hosted in ECR? Spring 启动和 Angular 身份验证 - 如何保护应用程序? - Spring Boot and Angular authentication - how to secure the app? 设置 Spring Boot + Angular 与 Facebook Marketing API 通信的最佳方式 - Best way to setup Spring Boot + Angular to communicate with Facebook Marketing API 在 Spring Boot 应用程序中处理 json 文件的最佳方法是什么? - What is the best way to process a json file in spring boot app? 使用自定义范围/角色保护 Spring 启动应用程序 - Secure Spring Boot app with custom scopes/roles 具有基本身份验证的Secure Spring Boot REST应用程序 - Secure Spring Boot REST app with basic authentication 使用 Spring 启动应用程序在 Angular 8 中配置 SSL 证书 - Configure SSL certificate in Angular 8 with Spring boot Application 使用 Spring Boot 实现 2 路 SSL - Implementing 2 way SSL using spring boot Spring 使用 SSL 启动 App 连接到 Kafka - Spring Boot App connection to Kafka with SSL 如何使用 keycloak 保护 angular/spring 应用程序? - How to secure angular/spring app with keycloak?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM