Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

configured authentication methods not showing up in login form #5109

Closed
m4rc3l-h3 opened this issue Aug 29, 2023 · 1 comment
Closed

configured authentication methods not showing up in login form #5109

m4rc3l-h3 opened this issue Aug 29, 2023 · 1 comment

Comments

@m4rc3l-h3
Copy link

m4rc3l-h3 commented Aug 29, 2023

Issue

Server Setup Information

  • Did you test in newest Wekan?: yes, tested versions include 7.09, 7.02, 6.99.9
  • Did you configure root-url correctly so Wekan cards open correctly (see https://github.com/wekan/wekan/wiki/Settings)? yes, see configuration below
  • Operating System: Microk8s is running on Ubuntu 22.04
  • Deployment Method (Snap/Docker/Sandstorm/bundle/source): docker container on Microk8s cluster
  • Http frontend if any (Caddy, Nginx, Apache, see config examples from Wekan GitHub wiki first): Traefik as ingress for the cluster
  • Node.js Version: v14.21.4
  • MongoDB Version: v6.0.7
  • What webbrowser version are you using (Wekan should work on all modern browsers that support Javascript)? Firefox 116.0.3 (64-bit)

Problem description

I am trying to configure the LDAP and OAuth2 authentication methods according to the Wiki here and here, see the environment variables below. I would expect that I have the option to select one of the methods, but the login form does not provide any (see screenshot below) .

I have set the following environment variables in the container:

$ microk8s kubectl describe pod wekan-pod -oyaml

...
spec:
  containers:
  - env:
    - name: LDAP_CA_CERT
      value: |-
        -----BEGIN CERTIFICATE-----
        ...
        -----END CERTIFICATE-----
    - name: DEBUG
      value: "true"
    - name: ROOT_URL
      value: https://wekan.example.com
    - name: PORT
      value: "8080"
    - name: MONGO_URL
      value: mongodb://wekan:redacted@wekan-mongodb.default.svc.cluster.local:27017/wekan
    - name: MAIL_URL
      value: smtp://redacted:redacted@mail.default.svc.cluster.local:587?tls={rejectUnauthorized:false}
    - name: MAIL_FROM
      value: Wekan Notifications <redacted>
    - name: WITH_API
      value: "True"
    - name: BROWSER_POLICY_ENABLED
      value: "true"
    - name: DEFAULT_AUTHENTICATION_METHOD
      value: ldap
    - name: LDAP_ENABLE
      value: "True"
    - name: LDAP_PORT
      value: "389"
    - name: LDAP_HOST
      value: ldap://redacted
    - name: LDAP_BASEDN
      value: ou=users,dc=example,dc=com
    - name: LDAP_LOGIN_FALLBACK
      value: "True"
    - name: LDAP_RECONNECT
      value: "True"
    - name: LDAP_TIMEOUT
      value: "10000"
    - name: LDAP_IDLE_TIMEOUT
      value: "10000"
    - name: LDAP_CONNECT_TIMEOUT
      value: "10000"
    - name: LDAP_AUTHENTIFICATION
      value: "True"
    - name: LDAP_AUTHENTIFICATION_USERDN
      value: uid=wekan,ou=my_group,dc=example,dc=com
    - name: LDAP_AUTHENTIFICATION_PASSWORD
      value: redacted
    - name: LDAP_LOG_ENABLED
      value: "True"
    - name: LDAP_BACKGROUND_SYNC
      value: "False"
    - name: LDAP_BACKGROUND_SYNC_INTERVAL
      value: every 1 hour
    - name: LDAP_BACKGROUND_SYNC_KEEP_EXISTANT_USERS_UPDATED
      value: "false"
    - name: LDAP_BACKGROUND_SYNC_IMPORT_NEW_USERS
      value: "false"
    - name: LDAP_ENCRYPTION
      value: "False"
    - name: LDAP_REJECT_UNAUTHORIZED
      value: "False"
    - name: LDAP_USER_SEARCH_SCOPE
      value: subtree
    - name: LDAP_USER_SEARCH_FIELD
      value: uid
    - name: LDAP_SEARCH_PAGE_SIZE
      value: "0"
    - name: LDAP_SEARCH_SIZE_LIMIT
      value: "0"
    - name: LDAP_GROUP_FILTER_ENABLE
      value: "True"
    - name: LDAP_GROUP_FILTER_OBJECTCLASS
      value: posixGroup
    - name: LDAP_GROUP_FILTER_GROUP_ID_ATTRIBUTE
      value: cn
    - name: LDAP_GROUP_FILTER_GROUP_MEMBER_ATTRIBUTE
      value: memberUid
    - name: LDAP_GROUP_FILTER_GROUP_NAME
      value: admin_group
    - name: LDAP_UNIQUE_IDENTIFIER_FIELD
      value: gid
    - name: LDAP_UTF8_NAMES_SLUGIFY
      value: "true"
    - name: LDAP_USERNAME_FIELD
      value: memberUid
    - name: LDAP_MERGE_EXISTING_USERS
      value: "False"
    - name: LDAP_SYNC_USER_DATA
      value: "False"
    - name: LDAP_DEFAULT_DOMAIN
      value: redacted
    - name: OAUTH2_ENABLED
      value: "True"
    - name: OAUTH2_LOGIN_STYLE
      value: popup
    - name: OAUTH2_CLIENT_ID
      value: wekan
    - name: OAUTH2_SECRET
      value: [redacted]
    - name: OAUTH2_SERVER_URL
      value: https://authelia.example.com
    - name: OAUTH2_AUTH_ENDPOINT
      value: /api/oidc/authorization
    - name: OAUTH2_USERINFO_ENDPOINT
      value: /api/oidc/userinfo
    - name: OAUTH2_TOKEN_ENDPOINT
      value: /api/oidc/token
    - name: OAUTH2_REQUEST_PERMISSIONS
      value: openid profile email
    - name: OAUTH2_USERNAME_MAP
      value: name
    - name: OAUTH2_EMAIL_MAP
      value: name
....

Screenshot of login form

The flag in the admin panel is set, but the drop downbox only shows the password method:
Screenshot admin panel

Reproduction Steps

Deployed with deployment.yaml' using image ghcr.io/wekan/wekan:v7.09` and environment variables shown above.

Logs

Logs of the wekan container read as follows:

$ microk8s kubectl logs wekan-pod

i18next: languageChanged en
i18next: initialized {
  debug: 'true',
  initImmediate: true,
  ns: [ 'translation' ],
  defaultNS: 'translation',
  fallbackLng: [ 'en' ],
  fallbackNS: false,
  supportedLngs: [
    'ar-DZ',  'ar-EG', 'ar',    'ary',   'az-AZ',   'az-LA',
    'az',     'bg',    'br',    'ca',    'ca-ES',   'cnm',
    'cs',     'cs-CZ', 'cy-GB', 'cy',    'da',      'de-AT',
    'de-CH',  'de',    'el-GR', 'el',    'en-BR',   'en-DE',
    'en-GB',  'en-IT', 'en-MY', 'en-YS', 'en',      'eo',
    'ast-ES', 'es-AR', 'es-CL', 'es-CO', 'es-LA',   'es-MX',
    'es-PE',  'es-PY', 'es',    'et-EE', 'eu',      'fa-IR',
    'fa',     'fi',    'fr-BE', 'fr-CA', 'fr-CH',   'fr',
    'fy-NL',  'fy',    'gl-ES', 'gl',    'gu-IN',   'he-IL',
    'he',     'hi-IN', 'hi',    'hr',    'hu',      'hy',
    'id',     'ig',    'it',    'ja',    'ja-Hira', 'ja-JP',
    'ka',     'km',    'ko-KR', 'ko',    'lt',      'lv',
    'mk',     'mn',    'ms',    'ms-MY', 'nb',      'nl-NL',
    'nl',     'oc',    'pa',    'pl-PL', 'pl',      'pt-BR',
    'pt',     'pt-PT', 'ro',    'ro-RO', 'ru-UA',   'ru',
    'sk',     'sl',    'sr',    'sv',    'sw',      'ta',
    'th',     'tlh',   'tr',    'ua-UA',
    ... 32 more items
  ],
  nonExplicitSupportedLngs: false,
  load: 'all',
  preload: false,
  simplifyPluralSuffix: true,
  keySeparator: '.',
  nsSeparator: ':',
  pluralSeparator: '_',
  contextSeparator: '_',
  partialBundledLanguages: false,
  saveMissing: false,
  updateMissing: false,
  saveMissingTo: 'fallback',
  saveMissingPlurals: true,
  missingKeyHandler: false,
  missingInterpolationHandler: false,
  postProcess: [ 'sprintf' ],
  postProcessPassResolved: false,
  returnNull: true,
  returnEmptyString: true,
  returnObjects: false,
  joinArrays: false,
  returnedObjectHandler: false,
  parseMissingKeyHandler: false,
  appendNamespaceToMissingKey: false,
  appendNamespaceToCIMode: false,
  overloadTranslationOptionHandler: [Function: handle],
  interpolation: {
    escapeValue: false,
    format: [Function: bound format],
    prefix: '__',
    suffix: '__',
    formatSeparator: ',',
    unescapePrefix: '-',
    nestingPrefix: '$t(',
    nestingSuffix: ')',
    nestingOptionsSeparator: ',',
    maxReplaces: 1000,
    skipOnVariables: true
  },
  cleanCode: true,
  defaultNs: 'translation',
  resources: {},
  ignoreJSONStructure: true,
  lng: 'en'
}
> Starting board-background-color migration.
> Finishing board-background-color migration.
> Starting add-cardcounterlist-allowed migration.
> Finishing add-cardcounterlist-allowed migration.
> Starting lowercase-board-permission migration.
> Finishing lowercase-board-permission migration.
> Starting use-css-class-for-boards-colors migration.
> Finishing use-css-class-for-boards-colors migration.
> Starting denormalize-star-number-per-board migration.
> Finishing denormalize-star-number-per-board migration.
> Starting add-member-isactive-field migration.
> Finishing add-member-isactive-field migration.
> Starting add-sort-checklists migration.
> Finishing add-sort-checklists migration.
> Starting add-swimlanes migration.
> Finishing add-swimlanes migration.
> Starting add-views migration.
> Finishing add-views migration.
> Starting add-checklist-items migration.
> Finishing add-checklist-items migration.
> Starting add-card-types migration.
> Finishing add-card-types migration.
> Starting add-custom-fields-to-cards migration.
> Finishing add-custom-fields-to-cards migration.
> Starting add-requester-field migration.
> Finishing add-requester-field migration.
> Starting add-assigner-field migration.
> Finishing add-assigner-field migration.
> Starting add-parent-field-to-cards migration.
> Finishing add-parent-field-to-cards migration.
> Starting add-subtasks-boards migration.
> Finishing add-subtasks-boards migration.
> Starting add-subtasks-sort migration.
> Finishing add-subtasks-sort migration.
> Starting add-subtasks-allowed migration.
> Finishing add-subtasks-allowed migration.
> Starting add-authenticationMethod migration.
> Finishing add-authenticationMethod migration.
> Starting remove-tag migration.
> Finishing remove-tag migration.
> Starting remove-customFields-references-broken migration.
> Finishing remove-customFields-references-broken migration.
> Starting add-product-name migration.
> Finishing add-product-name migration.
> Starting add-hide-logo migration.
> Finishing add-hide-logo migration.
> Starting add-hide-card-counter-list migration.
> Finishing add-hide-card-counter-list migration.
> Starting add-hide-board-member-list migration.
> Finishing add-hide-board-member-list migration.
> Starting add-displayAuthenticationMethod migration.
> Finishing add-displayAuthenticationMethod migration.
> Starting add-defaultAuthenticationMethod migration.
> Finishing add-defaultAuthenticationMethod migration.
> Starting add-templates migration.
> Finishing add-templates migration.
> Starting fix-circular-reference_ migration.
> Finishing fix-circular-reference_ migration.
> Starting mutate-boardIds-in-customfields migration.
> Finishing mutate-boardIds-in-customfields migration.
> Starting add-missing-created-and-modified migration.
> Finishing add-missing-created-and-modified migration.
> Starting fix-incorrect-dates migration.
> Finishing fix-incorrect-dates migration.
> Starting add-assignee migration.
> Finishing add-assignee migration.
> Starting add-profile-showDesktopDragHandles migration.
Successfully added createdAt and updatedAt to all tables
> Finishing add-profile-showDesktopDragHandles migration.
> Starting add-profile-hiddenMinicardLabelText migration.
> Finishing add-profile-hiddenMinicardLabelText migration.
> Starting add-receiveddate-allowed migration.
> Finishing add-receiveddate-allowed migration.
> Starting add-startdate-allowed migration.
> Finishing add-startdate-allowed migration.
> Starting add-duedate-allowed migration.
> Finishing add-duedate-allowed migration.
> Starting add-enddate-allowed migration.
> Finishing add-enddate-allowed migration.
> Starting add-members-allowed migration.
> Finishing add-members-allowed migration.
> Starting add-assignee-allowed migration.
> Finishing add-assignee-allowed migration.
> Starting add-labels-allowed migration.
> Finishing add-labels-allowed migration.
> Starting add-checklists-allowed migration.
> Finishing add-checklists-allowed migration.
> Starting add-attachments-allowed migration.
> Finishing add-attachments-allowed migration.
> Starting add-comments-allowed migration.
> Finishing add-comments-allowed migration.
> Starting add-assigned-by-allowed migration.
> Finishing add-assigned-by-allowed migration.
> Starting add-requested-by-allowed migration.
> Finishing add-requested-by-allowed migration.
> Starting add-activities-allowed migration.
> Finishing add-activities-allowed migration.
> Starting add-description-title-allowed migration.
> Finishing add-description-title-allowed migration.
> Starting add-description-text-allowed migration.
> Finishing add-description-text-allowed migration.
> Starting add-description-text-allowed-on-minicard migration.
> Finishing add-description-text-allowed-on-minicard migration.
> Starting add-sort-field-to-boards migration.
> Finishing add-sort-field-to-boards migration.
> Starting add-default-profile-view migration.
> Finishing add-default-profile-view migration.
> Starting add-hide-logo-by-default migration.
> Finishing add-hide-logo-by-default migration.
> Starting add-hide-card-counter-list-by-default migration.
> Finishing add-hide-card-counter-list-by-default migration.
> Starting add-hide-board-member-list-by-default migration.
> Finishing add-hide-board-member-list-by-default migration.
> Starting add-card-number-allowed migration.
> Finishing add-card-number-allowed migration.
> Starting assign-boardwise-card-numbers migration.
> Finishing assign-boardwise-card-numbers migration.
> Starting add-card-details-show-lists migration.
> Finishing add-card-details-show-lists migration.
> Starting migrate-attachments-collectionFS-to-ostrioFiles migration.
> Finishing migrate-attachments-collectionFS-to-ostrioFiles migration.
> Starting migrate-avatars-collectionFS-to-ostrioFiles migration.
> Finishing migrate-avatars-collectionFS-to-ostrioFiles migration.
> Starting migrate-attachment-drop-index-cardId migration.
> Finishing migrate-attachment-drop-index-cardId migration.
> Starting migrate-attachment-migration-fix-source-import migration.
> Finishing migrate-attachment-migration-fix-source-import migration.
{"line":"87","file":"percolate_synced-cron.js","message":"SyncedCron: Scheduled \"notification_cleanup\" next run @Tue Aug 29 2023 17:32:04 GMT+0000 (Coordinated Universal Time)","time":{"$date":1693330324267},"level":"info"}

Please let me know what further information is required to track this issue down.
Thank you for your time and help, it is much appreciated!

@xet7
Copy link
Member

xet7 commented Aug 29, 2023

@m4rc3l-h3

You can select only LDAP or OAUTH2. Not both. Dropdown selection is between one external authentication and password login.

Please do not add any quotes ' or double quotes " to values:
https://github.com/wekan/wekan/blob/master/docker-compose.yml#L3

true is lowercase, without any quotes.

@xet7 xet7 closed this as completed Aug 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants