Hello AdriR,
Perhaps you want to take a look at the following document:
Enable your Java Spring Boot web app to sign in users on your Azure Active Directory tenant with the Microsoft identity platform
You can use AAD to sign in users to your Spring Boot app to seamlessly login.
If this is helpful please accept answer.