Laravel SAML Authentication | SSO | OneLogin | SAML-Laravel Integration

  Рет қаралды 26,539

KS Tech Laravel

KS Tech Laravel

Күн бұрын

KS Tech | Learn your favourite Language No matter you know English or not | Integration of SAML in Laravel.
Here are some useful links which I used during the session:-
Laravel SAML Library: github.com/aac...
SAML Configuration: developers.one...
#SAML #SSO #LARAVEL-SAML2 #OneLogin

Пікірлер: 76
@adrintoul
@adrintoul 3 жыл бұрын
New to Laravel (not so new to SAML), and was struggling with the Event Listener. This was super helpful, thank you!
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
@Andrew I am very glad to hear.
@nyplace1
@nyplace1 5 ай бұрын
The creator of the library said it was the simplest way to configure it, i disagree i don't think i would be able to get it working without this video explanation and i have been working with SAML for years now.
@BhagatSinghChandrawat
@BhagatSinghChandrawat Ай бұрын
Can someone help me- can we use same Laravel package for Microsoft ADFS authentication
@adam192021
@adam192021 3 жыл бұрын
Incredible, you helped me a lot!!
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
Glad I could help!
@tanzimislam2395
@tanzimislam2395 Жыл бұрын
Hi Thank you ver much for this video. I followed al the steps, everything works, but just one problem. When the asc url is called by the IDP, it does not stay on the acs url and dump data like you showed in the video. Instead it instantly gets redirect to it's root route (localhost:8000/) . any ideas why this is happening?
@alanjose7049
@alanjose7049 Жыл бұрын
Same issue happening for me.Login listner not triggering
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
Hi Alan can you please let me know that after authenticate with Service Provider where exactly your request got redirected ?
@Joeron79
@Joeron79 2 жыл бұрын
I have a question how to implement FortiAuthenticator SP/Idp with Laravel?
@yashvishwakarma6434
@yashvishwakarma6434 2 жыл бұрын
how can i Integrate my website with Google SAML SSO ?
@VichitraSaini-v6w
@VichitraSaini-v6w Жыл бұрын
hiii i am getting error when i am installed saml package Your requirements could not be resolved to an installable set of packages. Installation failed, reverting ./composer.json and ./composer.lock to their original content.
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
It could be your version issue so better to check with package forum
@inbainba8542
@inbainba8542 3 жыл бұрын
I got Assertion token how to use that for my application user login
@dipeshchangawala9910
@dipeshchangawala9910 2 жыл бұрын
Hello, I am using Laravel as Rest API, In the event listener I want to redirect user to the Frontend URL with the authorization token generated into event listener. But `redirect(URL?token=mytoken)` not working. How could Frontend store that authorization token?
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
So once you got the success login from service provider then you can create a token and send it with your url
@dipeshchangawala9910
@dipeshchangawala9910 2 жыл бұрын
@@kstechlaravel5426 Sorry I Didn't get, My Frontend and Backend URL are different. I used SPA. I use laravel as a backend API. But from the Event listener, I can't use redirection. Could you please send me the Code, How can I redirect after getting the authorization token. Thank you.
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
Hello sir Finally got the response in Event Listener, now just 1 small issue I get "attributes" element null in the response, as per the video you get your email and name in the "attributes", so what i am needed to do to get that attributes.
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
Hi Ankit, You need to set these params in service provider. Sorry for late response
@jesusaranda8595
@jesusaranda8595 2 жыл бұрын
Thanks for your content, I have to implement a saml in django, and I was wondering if this tool could help me to test my sp and later change the idp data to the correct server. or else it only works for onelogin
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
Hi Jesus sorry for being late reply Actually it’s only for onelogin but may be it give you the little hints in your path
@maile-cf4wz
@maile-cf4wz 2 жыл бұрын
Thanks for explaining detail. How can I join multi lines in one line in VS code?
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
What do you mean multilines in one line?
@maile-cf4wz
@maile-cf4wz 2 жыл бұрын
@@kstechlaravel5426 Sorry to asked not clear question. I pasted the IDP_x509 key to VS code and it not in one line
@niralshakya3083
@niralshakya3083 3 жыл бұрын
How do you check login for each page without using user Auth in our app.?
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
But Why you don't want to use Auth? and yes you can store something in the session variable and check in your controller actions.
@immancoc6020
@immancoc6020 3 жыл бұрын
Bro I tried. But I got error msg while saml login 'We've been notified about this issue and we'll take a look at it shortly.'. Any solution??
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
I think it’s from SAML provider
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
Hello sir, Your video is very helpfull, I get stuck in the last bit in which we get the Response data in "ACS" Url I got a route error and if I change that to my login page it does not go there to the event service provider. help If possible.
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
I think you have to check the starting steps of video where I am setting the landing back URL
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
​@@kstechlaravel5426 sir did i needed to change the URL in "saml2_settings.php" or in "test_idp_settings.php" because I have added in "assertionConsumerService" in "test_idp_settings.php " file with my SP login URL.
@lioncat731
@lioncat731 3 жыл бұрын
Hi, do you have auth scaffolding installed ? Not sure what's the issue when I tried to do the login step it redirected me automatically to the welcome page (I followed everything is fine until @39:12). I am using laravel 8 as well. Do you have email that I can contact you or discord etc ?
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
You can contact me on kushalsuthar555@gmail.com
@gdtrombetti
@gdtrombetti 3 жыл бұрын
I am back, and got far with the Okta integration. I keep getting a "Signature validation failed. Reference validation failed". I use the IDP SSO metadata x.509 just like you do in the .env. Then I use the SAMLResponse that the IDP sent me to test. Any settings that might be effecting this?
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
Okay let me check the configuration for okta I will get back to you soon
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
developer.okta.com/blog/2019/09/05/laravel-authentication can you please check that
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
Hello sir , a litle progress in my case I got pass threw the "Event::listen('Aacotroneo\Saml2\Events\Saml2LoginEvent', function (Saml2LoginEvent $event) {" and request did not going in this. where should i check for the error sir?
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
Are you getting any response in listener?
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
@@kstechlaravel5426 no sir but if i do dd($request->all()); i get response but that did not has any Id or attribute in that response.
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
@@ankitsuthar526 have you set the response parameters in Service provider ?
@ankitsuthar526
@ankitsuthar526 2 жыл бұрын
@@kstechlaravel5426 i did not know sir where should I set response parameters? is that in any file in saml config or on the One login app configuration ?
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
In oneLogin you need to set the params so can you plz watch the video in starting
@DipeshPatel-d6y
@DipeshPatel-d6y Жыл бұрын
I am getting response in encrypted. how can I decrypt it?
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
You have to find some encryption is that and then you can easily decrypt
@dipeshpatel2166
@dipeshpatel2166 Жыл бұрын
@@kstechlaravel5426 i tried to find out the encryption but not found from where this encryption is applying
@gopikrishna8671
@gopikrishna8671 6 ай бұрын
Kindly share your code .
@imtiazahamed1632
@imtiazahamed1632 3 жыл бұрын
Hello, your tutorial was amazing. I had an issue, when I use dd($userdata) in event listener, it does not show dd in login url but redirect to home directory. can you please tell me what i am doing mistake
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
First of all thanks for your support. For issue may be your listener not getting call.
@lioncat731
@lioncat731 3 жыл бұрын
Hi, have you solved the issue yet ? I have encountered exactly same problem when I try to dd($userdata) when sending login request. So far I can only see 302 found in my header and the request url is mypath/laravel/public/saml2/test/acs. Hope hear from you soon. Thanks
@lioncat731
@lioncat731 3 жыл бұрын
@imitiaz ahamed
@imtiazahamed1632
@imtiazahamed1632 3 жыл бұрын
@@lioncat731 sorry for late reply..I was sick..I made a mistake.. my issue was resolved after adding base url to my env file. U can check if your callback url is properly set or not.
@yoh9104
@yoh9104 2 жыл бұрын
@imitiaz ahamed - I am facing the same issue. What you mean by you gave the base url in the .env file. Can you please elaborate the fix you did. Thanks.
@matthausnawan2817
@matthausnawan2817 2 жыл бұрын
Its works with Azure users?
@kstechlaravel5426
@kstechlaravel5426 2 жыл бұрын
Not sure but may it will work as same way
@heykiiw1371
@heykiiw1371 3 жыл бұрын
how to create account onelogin sure?
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
You need to create account from your company email account app.onelogin.com/login
@animeshkumar2011
@animeshkumar2011 3 жыл бұрын
Request URL: localhost:8000/saml2/test/acs Request Method: POST Status Code: 302 Found Remote Address: 127.0.0.1:8000 Referrer Policy: strict-origin-when-cross-origin when i enter url - localhost:8000/saml2/test/login then in networks i am getting not found error as shown above. What I am doing wrong? Can you please help me in this? Thank you!
@karlosrodas6518
@karlosrodas6518 Жыл бұрын
i got this answer: Saml2 error_detail {"error":"The response was received at localhost/saml2/test/acs instead of localhost:8085/saml2/test/acs"} what could be the error?
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
That means you are getting the response on localhost but without port
@karlosrodas6518
@karlosrodas6518 Жыл бұрын
@@kstechlaravel5426 How could I correct it? When adding the port localhost:8085/saml2/test/acs, the result returned is invalid operation
@kstechlaravel5426
@kstechlaravel5426 Жыл бұрын
But why you need port
@GkNarayan-dr8rw
@GkNarayan-dr8rw 6 ай бұрын
I need help please drop your email I'm getting Saml signature failed ?
@kstechlaravel5426
@kstechlaravel5426 6 ай бұрын
kushalsuthar555@gmail.com
@gdtrombetti
@gdtrombetti 3 жыл бұрын
would this also work with Okta?
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
I never tried with other service provider, but I think it will work because in the end we just need to change the configuration that’s it
@gdtrombetti
@gdtrombetti 3 жыл бұрын
@@kstechlaravel5426 thank you very much
@kstechlaravel5426
@kstechlaravel5426 3 жыл бұрын
@@gdtrombetti Thanks for watching. Really it will very helpful for me if you just subscribe to the channel.
@gdtrombetti
@gdtrombetti 3 жыл бұрын
@@kstechlaravel5426 Subbed !
@AFZALK-em5lj
@AFZALK-em5lj 7 ай бұрын
did u integrate okta sso via saml2 in laravel?
What Is Single Sign-on (SSO)? How It Works
4:54
ByteByteGo
Рет қаралды 602 М.
SAML 2.0: Technical Overview
15:35
VMware End-User Computing
Рет қаралды 550 М.
Apple peeling hack @scottsreality
00:37
_vector_
Рет қаралды 127 МЛН
Modus males sekolah
00:14
fitrop
Рет қаралды 26 МЛН
Or is Harriet Quinn good? #cosplay#joker #Harriet Quinn
00:20
佐助与鸣人
Рет қаралды 58 МЛН
Single Sign-On (SSO) Part-1 | Why do we need SSO? | What is SSO?
13:36
Gourab Banerjee
Рет қаралды 45 М.
A Developer's Guide to SAML
27:47
OktaDev
Рет қаралды 182 М.
Intro to SAML: What, How and Why
4:25
Ping Identity TV
Рет қаралды 444 М.
Introduction to SAML - Chalktalk on what is it, how it is used
32:03
Single Sign-On (SAML IdP and SP)
15:07
Automated Testing
Рет қаралды 91 М.
The secret behind FrankenPHP: Will it revolutionize PHP?
12:40
Chris Fidao
Рет қаралды 41 М.
OAuth 2.0: An Overview
6:34
InterSystems Learning Services
Рет қаралды 1,2 МЛН
Single Sign-On (SSO)- Part -2 | SSO Authentication Flow | SAML
18:41
Gourab Banerjee
Рет қаралды 45 М.
How to Set-Up SAML 2.0 Single Sign-On (SSO) with Azure AD
6:46