0001-auth_saml-clarify-some-parameters-67875.patch
src/authentic2_auth_saml/migrations/0001_initial.py | ||
---|---|---|
81 | 81 |
'realm', |
82 | 82 |
models.CharField( |
83 | 83 |
default='saml', |
84 |
help_text='The default realm to associate to user, used when setting username.',
|
|
84 |
help_text='The default realm to associate to user, can be used in username template.',
|
|
85 | 85 |
max_length=32, |
86 |
verbose_name='Realm', |
|
86 |
verbose_name='Realm (realm)',
|
|
87 | 87 |
), |
88 | 88 |
), |
89 | 89 |
( |
src/authentic2_auth_saml/models.py | ||
---|---|---|
57 | 57 |
blank=True, |
58 | 58 |
) |
59 | 59 |
realm = models.CharField( |
60 |
_('Realm'), |
|
60 |
_('Realm (realm)'),
|
|
61 | 61 |
max_length=32, |
62 |
help_text=_('The default realm to associate to user, used when setting username.'),
|
|
62 |
help_text=_('The default realm to associate to user, can be used in username template.'),
|
|
63 | 63 |
default='saml', |
64 | 64 |
) |
65 | 65 |
username_template = models.CharField( |
... | ... | |
144 | 144 |
type = 'saml' |
145 | 145 |
how = ['saml'] |
146 | 146 |
manager_view_template_name = 'authentic2_auth_saml/authenticator_detail.html' |
147 |
description_fields = [ |
|
148 |
'show_condition', |
|
149 |
'metadata_url', |
|
150 |
'metadata_path', |
|
151 |
'metadata', |
|
152 |
'provision', |
|
153 |
'username_template', |
|
154 |
] |
|
147 |
description_fields = ['show_condition', 'metadata_url', 'metadata_path', 'metadata', 'provision'] |
|
155 | 148 | |
156 | 149 |
class Meta: |
157 | 150 |
verbose_name = _('SAML') |
tests/test_manager_authenticators.py | ||
---|---|---|
254 | 254 | |
255 | 255 |
authenticator = SAMLAuthenticator.objects.filter(slug='test').get() |
256 | 256 |
resp = app.get(authenticator.get_absolute_url()) |
257 |
assert 'Username template: {attributes[name_id_content]}@{realm}' in resp.text |
|
258 | 257 |
assert 'Provision: True' in resp.text |
259 | 258 |
assert 'Metadata file path' not in resp.text |
260 | 259 | |
261 |
- |