From d225cfe2cabb01eb6982d26cd6d410b90934d1c2 Mon Sep 17 00:00:00 2001 From: babolivier Date: Tue, 5 Oct 2021 13:13:48 +0000 Subject: deploy: b2c5e79291b9f93cdb39c9a6f7de50e62f45e64e --- latest/dev/saml.html | 294 --------------------------------------------------- 1 file changed, 294 deletions(-) delete mode 100644 latest/dev/saml.html (limited to 'latest/dev/saml.html') diff --git a/latest/dev/saml.html b/latest/dev/saml.html deleted file mode 100644 index 749b12817b..0000000000 --- a/latest/dev/saml.html +++ /dev/null @@ -1,294 +0,0 @@ - - - - - - SAML - Synapse - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
- - - - - - - - - - - -
-
- -
- -
- -

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. -
  3. Copy the XML to your clipboard.
  4. -
  5. On your Synapse server, create a new file samling.xml next to your homeserver.yaml with -the XML from step 2 as the contents.
  6. -
  7. Edit your homeserver.yaml to include: -
    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"]   
    -
    -
  8. -
  9. Ensure that your homeserver.yaml has a setting for public_baseurl: -
    public_baseurl: http://localhost:8080/
    -
    -
  10. -
  11. Run apt-get install xmlsec1 and pip install --upgrade --force 'pysaml2>=4.5.0' to ensure -the dependencies are installed and ready to go.
  12. -
  13. Restart Synapse.
  14. -
-

Then in Riot:

-
    -
  1. Visit the login page with a Riot pointing at your homeserver.
  2. -
  3. Click the Single Sign-On button.
  4. -
  5. On the samling page, enter a Name Identifier and add a SAML Attribute for uid=your_localpart. -The response must also be signed.
  6. -
  7. Click "Next".
  8. -
  9. Click "Post Response" (change nothing).
  10. -
  11. You should be logged in.
  12. -
-

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.

- -
- - -
-
- - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file -- cgit 1.4.1