Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Matrix
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Container Registry
Model registry
Operate
Environments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TeDomum
Matrix
Commits
c755955f
Commit
c755955f
authored
5 years ago
by
Travis Ralston
Committed by
Richard van der Hoff
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Add developer docs for using SAML without a server (#6032)
parent
b617864c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
changelog.d/6032.misc
+1
-0
1 addition, 0 deletions
changelog.d/6032.misc
docs/dev/saml.md
+37
-0
37 additions, 0 deletions
docs/dev/saml.md
with
38 additions
and
0 deletions
changelog.d/6032.misc
0 → 100644
+
1
−
0
View file @
c755955f
Add developer documentation for using SAML2.
This diff is collapsed.
Click to expand it.
docs/dev/saml.md
0 → 100644
+
37
−
0
View file @
c755955f
# How to test SAML as a developer without a server
https://capriza.github.io/samling/samling.html (https://github.com/capriza/samling) is a great
resource for being able to tinker with the SAML options within Synapse without needing to
deploy and configure a complicated software stack.
To make Synapse (and therefore Riot) use it:
1.
Use the samling.html URL above or deploy your own and visit the IdP Metadata tab.
2.
Copy the XML to your clipboard.
3.
On your Synapse server, create a new file
`samling.xml`
next to your
`homeserver.yaml`
with
the XML from step 2 as the contents.
4.
Edit your
`homeserver.yaml`
to include:
```
yaml
saml2_config
:
sp_config
:
allow_unknown_attributes
:
true
# Works around a bug with AVA Hashes: https://github.com/IdentityPython/pysaml2/issues/388
metadata
:
local
:
[
"
samling.xml"
]
```
5.
Run
`apt-get install xmlsec1`
and
`pip install --upgrade --force 'pysaml2>=4.5.0'`
to ensure
the dependencies are installed and ready to go.
6.
Restart Synapse.
Then in Riot:
1.
Visit the login page with a Riot pointing at your homeserver.
2.
Click the Single Sign-On button.
3.
On the samling page, enter a Name Identifier and add a SAML Attribute for
`uid=your_localpart`
.
The response must also be signed.
4.
Click "Next".
5.
Click "Post Response" (change nothing).
6.
You should be logged in.
If you try and repeat this process, you may be automatically logged in using the information you
gave previously. To fix this, open your developer console (
`F12`
or
`Ctrl+Shift+I`
) while on the
samling page and clear the site data. In Chrome, this will be a button on the Application tab.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment