# SAML with layout = embedded not working

**URL:** <https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897>\
**Category:** Community Support\
**Tags:** projectideas\
**Created:** [July 29, 2020, 3:56pm UTC](https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897 "2020-07-29T15:56:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![fischel](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/fischel/32/2013_2.png) [@fischel](https://forums.rocket.chat/u/fischel)\
**Post date:** [July 29, 2020, 3:56pm UTC](https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897/1 "2020-07-29T15:56:29Z")

</div>

### Description

I setup SAML for authenticating user to rocketchat. I like to use the layout=embedded for a simple chat on my website - only one channel. So if the user first time come to my site ([http://mysite/channel/general?layout=embedded](http://mysite/channel/general?layout=embedded)) he will be redirected to the IdP (simplesaml) and after successfull authentication he will be redirect to: [http://mysite/home?saml\_idp\_credentialToken=xxx](http://mysite/home?saml_idp_credentialToken=xxx). This is not the site with embedded layout ☹

Did I do something wrong? Are there more params necessary than layout=embedded?

Thanks for help 🙂  
Stephan

### Server Setup Information

- Version of Rocket.Chat Server: 3.3.3
- Operating System: linux
- Deployment Method: docker
- NodeJS Version: 12.16
- MongoDB Version: 4.0.19

---

<div class="post-metadata">

**Author:** ![jsantana](https://avatars.discourse-cdn.com/v4/letter/j/f05b48/32.png) [@jsantana](https://forums.rocket.chat/u/jsantana)\
**Post date:** [July 29, 2020, 4:33pm UTC](https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897/2 "2020-07-29T16:33:49Z")

</div>

![image](https://us1.discourse-cdn.com/flex021/uploads/rocketchat/original/2X/8/88fe6f3a30a78551ef5f9aa6eeafa9cab2c5f329.png)

I had to ON this two options to allow the iFrame using, by default that options are OFF

ADMIN --\> GENERAL --\> iFrame Integration

---

<div class="post-metadata">

**Author:** ![fischel](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/fischel/32/2013_2.png) [@fischel](https://forums.rocket.chat/u/fischel)\
**Post date:** [July 30, 2020, 3:07pm UTC](https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897/3 "2020-07-30T15:07:48Z")

</div>

Sorry, but that doesn’t help. I’ll still get the /home after login with saml. Did you really use SAML for login?  
If you use a normal login with username and password, it works. You start with embedded layout and after login your are still in embedded layout - but not with SAML.

Thanks,  
Stephan

---

<div class="post-metadata">

**Author:** ![mihail.prosyanik](https://sea1.discourse-cdn.com/flex021/user_avatar/forums.rocket.chat/mihail.prosyanik/32/3703_2.png) [@mihail.prosyanik](https://forums.rocket.chat/u/mihail.prosyanik)\
**Post date:** [April 22, 2022, 9:54am UTC](https://forums.rocket.chat/t/saml-with-layout-embedded-not-working/7897/4 "2022-04-22T09:54:43Z")

</div>

We are too affecting this isssue, redirect url always is /home after login with saml, so this means that it is impossible to use chat inside applications with external authentication.
