Skip to content

Commit

Permalink
removed unused settings and made note to show that
Browse files Browse the repository at this point in the history
  • Loading branch information
lme-nca committed May 21, 2024
1 parent 088b47a commit 6544c6d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 14 deletions.
2 changes: 1 addition & 1 deletion docs/content/en/integrations/social-authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ Follow along below.
5. Restart DefectDojo, and you should now see a **Login with Gitlab**
button on the login page.

## Keycloak
## Keycloak !!Needs to be updated!!
There is also an option to use Keycloak as OAuth2 provider in order to authenticate users to Defect Dojo, also by using
the social-auth plugin.

Expand Down
6 changes: 3 additions & 3 deletions dojo/context_processors.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ def globalize_vars(request):
"AZUREAD_TENANT_OAUTH2_GET_GROUPS": settings.AZUREAD_TENANT_OAUTH2_GET_GROUPS,
"AZUREAD_TENANT_OAUTH2_GROUPS_FILTER": settings.AZUREAD_TENANT_OAUTH2_GROUPS_FILTER,
"AZUREAD_TENANT_OAUTH2_CLEANUP_GROUPS": settings.AZUREAD_TENANT_OAUTH2_CLEANUP_GROUPS,
"KEYCLOAK_TENANT_OAUTH2_GET_GROUPS": settings.AZUREAD_TENANT_OAUTH2_GET_GROUPS,
"KEYCLOAK_TENANT_OAUTH2_GROUPS_FILTER": settings.AZUREAD_TENANT_OAUTH2_GROUPS_FILTER,
"KEYCLOAK_TENANT_OAUTH2_CLEANUP_GROUPS": settings.AZUREAD_TENANT_OAUTH2_CLEANUP_GROUPS,
"KEYCLOAK_TENANT_OAUTH2_GET_GROUPS": settings.KEYCLOAK_TENANT_OAUTH2_GET_GROUPS,
"KEYCLOAK_TENANT_OAUTH2_GROUPS_FILTER": settings.KEYCLOAK_TENANT_OAUTH2_GROUPS_FILTER,
"KEYCLOAK_TENANT_OAUTH2_CLEANUP_GROUPS": settings.KEYCLOAK_TENANT_OAUTH2_CLEANUP_GROUPS,
"KEYCLOAK_ENABLED": settings.KEYCLOAK_OAUTH2_ENABLED,
"SOCIAL_AUTH_KEYCLOAK_LOGIN_BUTTON_TEXT": settings.SOCIAL_AUTH_KEYCLOAK_LOGIN_BUTTON_TEXT,
"GITHUB_ENTERPRISE_ENABLED": settings.GITHUB_ENTERPRISE_OAUTH2_ENABLED,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
class Migration(migrations.Migration):

dependencies = [
('dojo', '0204_jira_project_epic_issue_type_name'),
('dojo', '0209_alter_finding_severity'),
]

operations = [
Expand Down
9 changes: 0 additions & 9 deletions dojo/settings/settings.dist.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,6 @@
DD_SOCIAL_AUTH_OIDC_OIDC_ENDPOINT=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_KEY=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_SECRET=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_PUBLIC_KEY=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_AUTHORIZATION_URL=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_ACCESS_TOKEN_URL=(str, ''),
DD_SOCIAL_AUTH_KEYCLOAK_LOGIN_BUTTON_TEXT=(str, 'Login with Keycloak'),
DD_SOCIAL_AUTH_GITHUB_ENTERPRISE_OAUTH2_ENABLED=(bool, False),
DD_SOCIAL_AUTH_GITHUB_ENTERPRISE_URL=(str, ''),
Expand Down Expand Up @@ -493,7 +490,6 @@ def generate_url(scheme, double_slashes, user, password, host, port, path, param
'dojo.okta.OktaOAuth2',
'social_core.backends.azuread_tenant.AzureADTenantOAuth2',
'social_core.backends.gitlab.GitLabOAuth2',
# 'social_core.backends.keycloak.KeycloakOAuth2',
'social_core.backends.open_id_connect.OpenIdConnectAuth',
'social_core.backends.github_enterprise.GithubEnterpriseOAuth2',
'dojo.remote_user.RemoteUserBackend',
Expand Down Expand Up @@ -598,11 +594,6 @@ def generate_url(scheme, double_slashes, user, password, host, port, path, param
KEYCLOAK_TENANT_OAUTH2_CLEANUP_GROUPS = env('DD_SOCIAL_AUTH_KEYCLOAK_OAUTH2_CLEANUP_GROUPS')
KEYCLOAK_TENANT_OAUTH2_GROUPS_FILTER = env('DD_SOCIAL_AUTH_KEYCLOAK_OAUTH2_GROUPS_FILTER')

# SOCIAL_AUTH_KEYCLOAK_PUBLIC_KEY = env('DD_SOCIAL_AUTH_KEYCLOAK_PUBLIC_KEY')
# SOCIAL_AUTH_KEYCLOAK_AUTHORIZATION_URL = env('DD_SOCIAL_AUTH_KEYCLOAK_AUTHORIZATION_URL')
# SOCIAL_AUTH_KEYCLOAK_ACCESS_TOKEN_URL = env('DD_SOCIAL_AUTH_KEYCLOAK_ACCESS_TOKEN_URL')


GITHUB_ENTERPRISE_OAUTH2_ENABLED = env('DD_SOCIAL_AUTH_GITHUB_ENTERPRISE_OAUTH2_ENABLED')
SOCIAL_AUTH_GITHUB_ENTERPRISE_URL = env('DD_SOCIAL_AUTH_GITHUB_ENTERPRISE_URL')
SOCIAL_AUTH_GITHUB_ENTERPRISE_API_URL = env('DD_SOCIAL_AUTH_GITHUB_ENTERPRISE_API_URL')
Expand Down

0 comments on commit 6544c6d

Please sign in to comment.