Spring Boot Security With Azure Active Directory | OICD | Oauth2 | JavaTechie

Поділитися
Вставка
  • Опубліковано 29 лип 2024
  • In This tutorial I will walkthrough on how to secure a Java Spring Boot Application using Microsoft Azure AD, which is a great and widely adopted example of a reliable Identity Provider
    👉 Create Azure Active Directory instance & new Tenant
    👉 Add an application registration for your Spring Boot app
    👉 Add a user account to your directory, and add that account to an appRole
    👉 Configure and compile your app
    #JavaTechie #SpringBoot #Security #AzureAD
    Spring boot microservice Premium course lunched with 70% off 🚀 🚀
    Hurry-up & Register today itself!
    COURSE LINK : javatechie5246.ongraphy.com/
    PROMO CODE : JAVATECHIE50
    GitHub:
    github.com/Java-Techie-jt/spr...
    Blogs:
    / javatechie
    Facebook:
    / javatechie
    Join this channel to get access to perks:
    ua-cam.com/users/javatechiejoin
    guys if you like this video please do subscribe now and press the bell icon to not miss any update from Java Techie
    Disclaimer/Policy:
    --------------------------------
    Note : All uploaded content in this channel is mine and its not copied from any community ,
    you are free to use source code from above mentioned GitHub account
  • Наука та технологія

КОМЕНТАРІ • 70

  • @dhirajnavale3861
    @dhirajnavale3861 Рік тому +1

    Bro last week I was just thinking what is Azure active directory and here is a video by you thank you so much

  • @gopisambasivarao5282
    @gopisambasivarao5282 Рік тому +1

    Appreciate your efforts, Basant...

  • @zawedakhtar379
    @zawedakhtar379 Рік тому +1

    Thank you for this video:)

  • @omaradrian80
    @omaradrian80 11 місяців тому +1

    Thanks for the effort!!

  • @arnabneogi4237
    @arnabneogi4237 10 місяців тому +2

    Hey Basanth, this is very helpful.
    But how can you integrate this with spring security and apply filter?
    Example, if I want to implement this with api-gateway and want to implement authentication to only a few APIs, I would need to implement spring security.
    How can I do that using azure authentication?

  • @user-yc2ho5oh7b
    @user-yc2ho5oh7b 10 місяців тому +2

    with Azure AD if user logged in once then we don't need to ask again username password how to do this with spring boot and azure thanks in advance

  • @lakshminathanrd5174
    @lakshminathanrd5174 10 днів тому +1

    How to get and print accessToken that is provided by Azure AD after authentication?

  • @user-lw2jn8gp3e
    @user-lw2jn8gp3e 10 місяців тому +1

    do me a favor sir i need to access Azure AD directory with personal mcrosoft accounts only, Need to access my tenant from personal microsoft accounts . reply ...please

  • @kamalk4917
    @kamalk4917 10 днів тому

    Hi sir. I have a application where my FE is react and is deployed to a app service in azure and it is authenticated using Msal. It calls my BE spring boot app deployed to another Web app in azure . How to I need to configure security in this scenario as my FE does authentication and it receives token. Do I need to validate that token or Altogether create a new app registration for my BE app or make use of existing client to validate the token send from FE

  • @hashimp5262
    @hashimp5262 Рік тому +1

    Very helpful content 👍🏻

  • @devchouhan2436
    @devchouhan2436 2 місяці тому

    I have a two api's they are preserved with azure ad how can I communicate with them using resttemplate

  • @user-sr8hd4by8m
    @user-sr8hd4by8m 10 місяців тому

    how to get the azure token , and the token can be used to query the graph api ?

  • @BalarajuKanike
    @BalarajuKanike 10 місяців тому +1

    Hi basant, is it possible to get access_token attribute here?

  • @surajpandey7533
    @surajpandey7533 Рік тому

    Sir, I have a large pdf (50 pages) in that pdf I want to put data in some fields of that pdf and after that send it to user..
    Could you please make a video on that to write content to html pages and after that convert to pdf.

  • @indibizz1724
    @indibizz1724 7 місяців тому

    Hello admin. Can I make one package for authentication in spring for user verification and configure with my existing Java and .jsp project? Using azure ad ..is it possible?

  • @rajkumarwinc9372
    @rajkumarwinc9372 3 місяці тому

    Hi Basant, currently I'm working on Azure ad SSO, could you please help me on , How to implement logout of Azure ad logged in user?

  • @bboyfool215
    @bboyfool215 9 місяців тому

    Nice tutorial, thank you
    How about the logout feature, or how can we force logout from springboot application. Hope you have another demo

  • @niharr7
    @niharr7 4 місяці тому

    Instead of client secret i would like to implement private key jwt based client authentication. How to do that?

  • @anilreddy9654
    @anilreddy9654 10 місяців тому

    How to call the api in postman what parameters need to send

  • @prabhatmahanty3799
    @prabhatmahanty3799 7 місяців тому

    Hello Basant bhai, this video is very helpful. I have a doubt. My requirement is to fetch the microsoft form data by using graph api. So, here how and where I register the microsoft form url so that I will get the data as response.

  • @zenitneziri4677
    @zenitneziri4677 Рік тому +1

    @JavaTechie I am trying to create a tenant within Azure AD, in order to put some users there and connect to a backend project. But I can't create a tenant at all, when I go to the manage tenants, the create tenant button is not clickable at all.
    p.s Also when entering Azure AD I have no primary domain (I tried to enter a custom domain the button is not clickable too) if this is a relevant factor to above issue.

    • @Javatechie
      @Javatechie  Рік тому

      In the first login attempt this issue appears but try in the new browser it will not give any error

  • @KoppoluBalayogeeswar
    @KoppoluBalayogeeswar 11 місяців тому +1

    Based on your video the server maintains the cookie for the subsequent requests to validate, how do we achieve passing bearer token to validate ont he authentication is done on azure, basically i want to achieve stateless after you authenticate in azure for next 1hr e.g. based on your oAuth token expiry

    • @Javatechie
      @Javatechie  11 місяців тому

      That token expiry limit you can set 📐

  • @user-lw2jn8gp3e
    @user-lw2jn8gp3e 10 місяців тому

    hi sir, i need global access microsoft azure active directory,can you post as soon as possible

  • @VVeNqbMx0
    @VVeNqbMx0 11 місяців тому +2

    Why do we need to use
    server:
    forward-headers-strategy: native ?

  • @zawedakhtar379
    @zawedakhtar379 Рік тому

    Basant sir is great

  • @udiptadas4936
    @udiptadas4936 9 місяців тому

    captcha now working? anyone have same issue /

  • @jaswanthg3876
    @jaswanthg3876 Рік тому +1

    You are one of the most underrated youtuber
    But eventually you will reach out to 1M
    Thanks for the videos
    Also if possible try to do the videos on Multi threading it would be helpful

    • @Javatechie
      @Javatechie  Рік тому

      Thanks buddy for appreciating my work. Hope for the best 🤞🥰

    • @sajid.farooqi8074
      @sajid.farooqi8074 Рік тому +1

      I think sir is working for the requested topic, hopefully we will soon see Multireading course

    • @Javatechie
      @Javatechie  Рік тому +1

      Yes i will cover multi threading soon . It will be helpful if you guys could specify the usecase which you are looking for.

    • @sajid.farooqi8074
      @sajid.farooqi8074 Рік тому +1

      @@Javatechie we are supposed to start from initial to advance level.

    • @jaswanthg3876
      @jaswanthg3876 Рік тому +1

      @@Javatechie how multithreading used in the springboot

  • @VVeNqbMx0
    @VVeNqbMx0 11 місяців тому +1

    I want to store the users that authenticate via Azure AD inside a db. How can I get the user information after it logged in via Azure AD?

    • @Javatechie
      @Javatechie  11 місяців тому

      No you can't do that. That's completely violence the contract of auth delegation

    • @VVeNqbMx0
      @VVeNqbMx0 11 місяців тому +1

      I need his first name,last name and email. What is wrong with wanting to store it?

    • @Javatechie
      @Javatechie  11 місяців тому

      Yes these principal details you can get no problem with that

  • @rushikeshkarkhanis7915
    @rushikeshkarkhanis7915 Рік тому +2

    Thanks for the video. Can you built frontend (Full Stack Application) React/Angular and Spring Boot ??

  • @balrajkanike1685
    @balrajkanike1685 11 місяців тому +1

    Hello i just recreated this but finally it is redirecting to default login page from spring server, not redirecting to Azure AD login page. Why?

    • @Javatechie
      @Javatechie  11 місяців тому

      Please correct your configuration in yml

    • @balrajkanike1685
      @balrajkanike1685 11 місяців тому

      @@Javatechie that is almost same, and that credentials are successfully authenticating user without spring boot, I think here this request it self not going to azure ad login page because if any error in configuration azure ad login page display it there :)

  • @user-yc2ho5oh7b
    @user-yc2ho5oh7b 10 місяців тому

    how to logout once I logged in

  • @rajkumarwinc9372
    @rajkumarwinc9372 3 місяці тому

    Hi Basant, if we search for any videoos we will get your videos on top first. Thanks for your efforts.
    How to get access_token, refresh_token, id_token, client_info, expires_in, token_type, scope etc... details when user logged in.

  • @balrajkanike1685
    @balrajkanike1685 11 місяців тому +1

    Is it possible to authenticate user and get user group details like this? Please reply

    • @Javatechie
      @Javatechie  11 місяців тому +1

      User details means you can get name and email i don't think we can extract other fields

  • @niharr7
    @niharr7 5 місяців тому

    Thanks Basant. How to retrive the id token and userinfo in spring App

    • @Javatechie
      @Javatechie  5 місяців тому

      No i don't think we can do that because it's an oauth security

  • @anilreddy9654
    @anilreddy9654 9 місяців тому

    angular and spring boot rest apis azure ad project

  • @manee427
    @manee427 Рік тому +1

    Amazing video. How can we access user details inside the controller?

    • @Javatechie
      @Javatechie  Рік тому +1

      Pass the principal object and get user details.

    • @manee427
      @manee427 Рік тому

      @@Javatechie thanks a lot

  • @vignesh3184
    @vignesh3184 Рік тому +1

    Can we generate token using azure ad?

  • @roshanraj8727
    @roshanraj8727 3 місяці тому +1

    Nice explanation , i was thinking of a poc on this and i got all information through your channel ❤. If possible can let me know how can i encrypt the tentanid , client id in application.yml ,
    Thanks in advance

    • @Javatechie
      @Javatechie  3 місяці тому

      Good to hear this roshna , if you want to encrypt in yml file then can use jasypt

    • @roshanraj8727
      @roshanraj8727 3 місяці тому

      @@Javatechie Is there any way to directly access the codes from azure active directory from spring boot app instead of having them in .yml file

    • @rajkumarwinc9372
      @rajkumarwinc9372 3 місяці тому

      ​@@roshanraj8727no way

  • @rakibahmed1011
    @rakibahmed1011 Рік тому +1

    Please..... Make video on the new Spring Authorization Server.!!!