Multiple Authentication Providers Spring Security

  Рет қаралды 6,251

Java Development Journal

Java Development Journal

Күн бұрын

Пікірлер: 17
@pt_trainer9244
@pt_trainer9244 3 жыл бұрын
Hi bro, do you think you can do some tutorials explaining how to work with Spring boot and react, specifically authentication and authorisation, the routing in react etc. It makes me all confused because both front and back end are served on different ports so how do you do that
@javadevjournal
@javadevjournal 3 жыл бұрын
That is in the pipeline :)
@pt_trainer9244
@pt_trainer9244 3 жыл бұрын
@@javadevjournal Thanks, I'm trying to build my first Web app with this stack but there's very little tutorials that cover what I need
@bluex217
@bluex217 2 жыл бұрын
​@@pt_trainer9244 Did you ever get it? From a high level if you're using basic authentication you will need to send from node/JS -> Spring Boot an HTTP request with "Basic username:password" For example, in NODE/JS frontend, if using AXIOS library for HTTP calls, do: const resp = await axios.post("authenticated/endpoint", { auth: { username: 'username_here', password: 'password_here' }}); From here, Spring boot app will be able to authenticate identically to how it authenticates when sending a postman request. For JWT would be similar
@pt_trainer9244
@pt_trainer9244 2 жыл бұрын
@@bluex217 Hey, yes i managed to get it working with JWT, thanks btw.
@chrispure7461
@chrispure7461 2 жыл бұрын
How to secure with multiple Oauth2 auth servers/ providers? example keycloak and some other Oauth2 provider , any example app or refrence?
@javadevjournal
@javadevjournal 2 жыл бұрын
Still not very clear about your question but if you are looking for using multiple OAuth provider based on the URL, I think all you need is "separate authentication filter"
@ah_ay_
@ah_ay_ Жыл бұрын
@@javadevjournal What do you mean by based on the URL ? From my side, I need to use Google, Facebook and JWT authentication for example
@vudumshiva4162
@vudumshiva4162 2 жыл бұрын
i have two userdetailservices employees and students, i configured two userdetails with DaoAuthenticationProvider. when i try to login with /employee/signIn or /student/singin it is checking in both userdetailservices. But i need to use respective userdetails. How to configure that bro?
@vudumshiva4162
@vudumshiva4162 2 жыл бұрын
In this case should maintain customerAuthenticationproviders like EmployyeAuthPrvder,StudentAuthPvd and apply provider on authrequest path
@javadevjournal
@javadevjournal 2 жыл бұрын
I think what you are looking for is the multiple user details services for different endpoints. You can configure different user details services using this option.
@vudumshiva4162
@vudumshiva4162 2 жыл бұрын
this is how i did , two providers supports UsernamePasswordAuthenticationToken, catalogprovider has configured with cataloguserdetails and storeprovider has configured with storeuserdetails, how to choose authprovider based on endpoint?
@unmeshkadam4876
@unmeshkadam4876 2 жыл бұрын
Sir can you please share your code, I am implementing same in my college project, but not able to go ahead? If not code can you please share some useful resources for same
@sush2142
@sush2142 2 жыл бұрын
What if I have only username? My password (OTP) is getting verified by third party.
@javadevjournal
@javadevjournal 2 жыл бұрын
In this case, you need authorization and not authentication. Are you referring to something as SAML or something similar?
@harisurendhra3317
@harisurendhra3317 3 жыл бұрын
First person to like and comment
@javadevjournal
@javadevjournal 3 жыл бұрын
Thanks Hari :)
Spring Security Custom Authentication Provider
13:49
Java Development Journal
Рет қаралды 8 М.
How Spring Security Authentication works - Java Brains
19:36
Java Brains
Рет қаралды 301 М.
إخفاء الطعام سرًا تحت الطاولة للتناول لاحقًا 😏🍽️
00:28
حرف إبداعية للمنزل في 5 دقائق
Рет қаралды 83 МЛН
ROSÉ & Bruno Mars - APT. (Official Music Video)
02:54
ROSÉ
Рет қаралды 94 МЛН
Seja Gentil com os Pequenos Animais 😿
00:20
Los Wagners
Рет қаралды 43 МЛН
Spring Method Security
12:44
Java Development Journal
Рет қаралды 2,1 М.
Spring Boot 3.0.0 Security (part 11) Create Multiple Authentication Providers.
6:30
Spring Boot Security - SecurityFilterChain
7:48
Teddy Smith
Рет қаралды 57 М.
Spring Security Architecture Explained
14:41
Amigoscode
Рет қаралды 110 М.
Spring security forgot password
22:24
Java Development Journal
Рет қаралды 19 М.
Spring Security : Custom Authentication
40:41
Himanshu Sharma
Рет қаралды 6 М.
إخفاء الطعام سرًا تحت الطاولة للتناول لاحقًا 😏🍽️
00:28
حرف إبداعية للمنزل في 5 دقائق
Рет қаралды 83 МЛН