opensearch-project / opensearch-project/security

add include_users as an alternative to skip_users for authorization

Open
#488 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted triaged
Dominant language
Java
Stars
252
Forks
395
Avg merge
1d 11h
Merged PRs (30d)
76

Description

We're using authentication against several ldap DB and we're using the UPN as the username attribute. So it will be easier to configure the role search to include only the users which have a upn corresponding to the domain rather than adding exceptions with skip_users which can become hard to maintain.

Something like:

authz:
  roles_from_adm_corp:
    description: "Authorize on domain1.corp"
    http_enabled: true
    transport_enabled: false
    authorization_backend:
      type: "ldap"
      config:
        hosts:
        - "ldap.domain1.corp:389"
        bind_dn: "CN=elk,OU=Users,DC=domain1,DC=corp"
        password: "xxxxxx"
        rolebase: "dc=domain1,dc=corp"
        rolesearch: "(member={0})"
        rolename: "cn"
        resolve_nested_roles: true
        include_users:
        - "*@domain1.corp" 

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the LDAP authorization backend configuration and the existing skip_users handling. Confirm how user patterns are matched against the UPN, then implement include_users as the alternative described in the example and add coverage showing that matching users are included while others are excluded.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
authorization
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.