Skip to content

Commit 9af0f8b

Browse files
pau1iePaul HoughtonnijelCopilot
authored
SAML Documentation for IdP Certificate Rotation (#351)
* Update SAML documentation for cert rotation. * Fix formatting * Hopefully clearer text. Co-authored-by: Paul Houghton <[email protected]> Co-authored-by: Michal Čihař <[email protected]> Co-authored-by: Copilot <[email protected]>
1 parent 875b7c7 commit 9af0f8b

File tree

1 file changed

+26
-1
lines changed

1 file changed

+26
-1
lines changed

docs/backends/saml.rst

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,6 @@ Advanced Settings
214214
"x509certNew": "MIIEDjCCAvagAwIBAgIBADA ... 8Bbnl+ev0peYzxFyF5sQA==",
215215
}
216216

217-
218217
- ``SOCIAL_AUTH_SAML_SECURITY_CONFIG``: This can be set to a dict, and any
219218
key/value pairs specified here will be passed to the underlying
220219
``python-saml`` library configuration's ``security`` setting. Two useful keys
@@ -233,6 +232,32 @@ Advanced Settings
233232
('department', 'department'),
234233
('manager_full_name', 'manager_full_name')]
235234

235+
- In ``SOCIAL_AUTH_SAML_ENABLED_IDPS``: ``x509certMulti["signing"]`` is a list
236+
that can be used instead of ``x509cert``. For example, when the IdP
237+
certificate is rotated, use::
238+
239+
SOCIAL_AUTH_SAML_ENABLED_IDPS = {
240+
"my_idp": {
241+
"entity_id": "https://...",
242+
"url": "https://...",
243+
"x509certMulti": {
244+
"signing": [
245+
# Old certificate
246+
"""
247+
-----BEGIN CERTIFICATE-----
248+
MIIEDjCCAvagAwIBAgIBADA ...
249+
-----END CERTIFICATE-----
250+
""",
251+
# New certificate
252+
"""
253+
-----BEGIN CERTIFICATE-----
254+
8Bbnl+ev0peYzxFyF5sQA ...
255+
-----END CERTIFICATE-----
256+
"""
257+
]
258+
}
259+
}
260+
}
236261

237262
Advanced Usage
238263
--------------

0 commit comments

Comments
 (0)