Перейти к содержимому

Spring Security JWT - Asymmetric Encryption

Ali Bouali

0:00 / 0:00

Spring Security JWT - Asymmetric Encryption

18 378 просмотров · 1 год назад
Ali Bouali
79 тыс. подписчиков
18 378 просмотров · 1 год назад
In this video, we’ll show you how to implement asymmetric encryption in your Spring Boot application using JWT tokens and private/public key pairs. Learn how to generate keys, secure your endpoints, and understand the real difference between symmetric vs. asymmetric encryption — all with practical examples! GitHub Link: https://github.com/ali-bouali/spring-... 📌 What You’ll Learn: Why asymmetric encryption matters How to generate private & public keys Implementing JWT with RSA keys in Spring Boot Symmetric vs. Asymmetric encryption: which to choose? Best practices for securing your backend 🛠️ Commands Used in the Video: Generate private key openssl genrsa -out private-secret.pem 2048 Extract public key openssl rsa -in private-secret.pem -pubout -out public-secret.pem 💬 Got questions? Drop them in the comments — and don’t forget to like & subscribe for more secure coding tutorials! 🔗 Follow for more dev content: #SpringBoot #JWT #Encryption #WebSecurity #DeveloperTools #Java 00:00 Intro 05:20 Create and configure the project 13:45 Add the project properties 21:34 Implement the security config 27:04 Implement the user entity 43:23 Implement the user service 01:10:00 Implement the user controller 01:14:23 Generate the private & public keys 01:18:39 Implement the Key Utils service 01:25:24 Implement the JWT service 01:41:18 Implement the JWT Filter 01:48:43 Add the authentication DTOs 01:53:49 Implement the authentication logic 02:13:00 Implement the authentication controller 02:16:00 Implement the application auditor aware 02:21:12 Add the validation 02:30:22 Implement a custom validation annotation 02:39:37 add the exception handler 02:59:00 Add the OpenAPI (Swagger) Configuration 03:05:22 Test the application 03:23:38 Outro