Commit 5d8b067
committed
feat(sso): remove SSO surface from open source — Pro only as of 2.58
Strips dojo/sso/ wholesale (the consolidated SSO package merged from origin/dev) and
unwires every call site:
- dojo/settings/settings.dist.py: drops the SSO_ENV_SCHEMA env merge, the
apply_sso_settings(env, globals()) call, the DD_SOCIAL_AUTH_SHOW_LOGIN_FORM /
DD_SOCIAL_LOGIN_AUTO_REDIRECT defaults and their derived SHOW_LOGIN_FORM /
SOCIAL_LOGIN_AUTO_REDIRECT settings, and the saml2 logger entry. The
_DOJO_EXTRA_TEMPLATE_DIRS hook stays — it's still load-bearing for the
notifications and github sub-package template trees.
- dojo/urls.py: drops the dojo.sso.urls inclusion (which mounted social_django.urls
and the conditional ^saml2/ route).
- dojo/user/views.py: removes the get_sso_auto_redirect chain in login_view and
the SHOW_LOGIN_FORM short-circuit in logout_view.
- dojo/context_processors.py: removes SHOW_LOGIN_FORM from the global template
context.
- dojo/templates/dojo/login.html (Tailwind) and dojo/templates_classic/dojo/login.html
(Classic): strip the inline SSO button blocks and the SHOW_LOGIN_FORM gating,
leaving the local username/password form, password-toggle, and forgot-password /
forgot-username links.
- requirements.txt: drops social-auth-app-django, social-auth-core, and djangosaml2;
these now ship in DefectDojo Pro's own dependency manifest.
- unittests/test_remote_user.py and unittests/test_social_auth_failure_handling.py:
removed; the equivalent coverage was ported into Pro's unit_tests/sso/ tree against
pro.sso.remote_user and pro.sso.middleware.
The only authentication surfaces that remain on open source are the local Django
auth login form and the password-reset flow. Pro carries forward — and now owns —
the entire SSO surface (SAML, OIDC, Google, Okta, Azure AD, GitLab, Auth0, Keycloak,
GitHub Enterprise, remote-user) under pro/sso/, configured via the existing tuner.
Upgrade notes in docs/content/releases/os_upgrading/2.58.md describe the cutover at
a high level for OS upgraders; the Pro changelog at docs/content/releases/pro/
changelog.md v2.58.0 calls out that Pro's SSO surface is unchanged and now lives
in pro/sso/ alongside the dependency move.1 parent 16d2b5f commit 5d8b067
23 files changed
Lines changed: 45 additions & 1764 deletions
File tree
- docs/content/releases
- os_upgrading
- pro
- dojo
- settings
- sso
- attribute_maps
- templates/dojo
- templates_classic/dojo
- templates/dojo
- user
- unittests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
33 | 42 | | |
34 | 43 | | |
35 | 44 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | 16 | | |
18 | 17 | | |
19 | 18 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | 33 | | |
42 | | - | |
| 34 | + | |
43 | 35 | | |
44 | 36 | | |
45 | 37 | | |
| |||
140 | 132 | | |
141 | 133 | | |
142 | 134 | | |
143 | | - | |
144 | | - | |
145 | 135 | | |
146 | 136 | | |
147 | 137 | | |
| |||
246 | 236 | | |
247 | 237 | | |
248 | 238 | | |
249 | | - | |
250 | 239 | | |
251 | 240 | | |
252 | 241 | | |
| |||
273 | 262 | | |
274 | 263 | | |
275 | 264 | | |
276 | | - | |
| 265 | + | |
277 | 266 | | |
278 | 267 | | |
279 | 268 | | |
| |||
479 | 468 | | |
480 | 469 | | |
481 | 470 | | |
482 | | - | |
483 | | - | |
484 | | - | |
485 | 471 | | |
486 | 472 | | |
487 | 473 | | |
| |||
708 | 694 | | |
709 | 695 | | |
710 | 696 | | |
711 | | - | |
712 | | - | |
713 | | - | |
714 | | - | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
715 | 701 | | |
716 | 702 | | |
717 | 703 | | |
| |||
725 | 711 | | |
726 | 712 | | |
727 | 713 | | |
728 | | - | |
| 714 | + | |
729 | 715 | | |
730 | 716 | | |
731 | 717 | | |
| |||
839 | 825 | | |
840 | 826 | | |
841 | 827 | | |
842 | | - | |
843 | | - | |
844 | | - | |
845 | | - | |
846 | | - | |
847 | | - | |
848 | | - | |
849 | | - | |
850 | | - | |
851 | 828 | | |
852 | 829 | | |
853 | 830 | | |
| |||
1521 | 1498 | | |
1522 | 1499 | | |
1523 | 1500 | | |
1524 | | - | |
1525 | | - | |
1526 | | - | |
1527 | | - | |
1528 | | - | |
1529 | 1501 | | |
1530 | 1502 | | |
1531 | 1503 | | |
| |||
Whitespace-only changes.
Whitespace-only changes.
This file was deleted.
0 commit comments