From 9703cfa87af1489e395c425037ce93c95eb08b9a Mon Sep 17 00:00:00 2001 From: Dino8890 Date: Sat, 26 Jul 2025 14:16:09 +0200 Subject: [PATCH] Clarified attribute mapping docs. --- docs/source/contents/setup.rst | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/docs/source/contents/setup.rst b/docs/source/contents/setup.rst index 384979de..fed507a5 100644 --- a/docs/source/contents/setup.rst +++ b/docs/source/contents/setup.rst @@ -379,12 +379,9 @@ SAML_ATTRIBUTE_MAPPING option in your settings.py:: where the keys of this dictionary are SAML user attributes and the values are Django User attributes. -If you are using Django user profile objects to store extra attributes -about your user you can add those attributes to the SAML_ATTRIBUTE_MAPPING -dictionary. For each (key, value) pair, djangosaml2 will try to store the -attribute in the User model if there is a matching field in that model. -Otherwise it will try to do the same with your profile custom model. For -multi-valued attributes only the first value is assigned to the destination field. +For each (key, value) pair, djangosaml2 will try to store the attribute (key) in your +configured `User` model if the matching fields exists on that model. For multi-valued +attributes only the first value is assigned to the destination field. Alternatively, custom processing of attributes can be achieved by setting the value(s) in the SAML_ATTRIBUTE_MAPPING, to name(s) of method(s) defined on a