Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

LDAP filter to restrict some of the AD groups

Vasanthakumar V
Contributor
November 24, 2023

Hi All,

 

I am trying to block/allow set of AD groups flow in the Jira database using LDAP query, facing issues in it. Suggestion will be appriciated, thanks in advance :)

 

Below filter worked for me, but when I tried add multiple names its not working.

(&(name=*-XYZ-*)(!(|(name=*-21-00)(name=*-21-01)(name=*-21-03))))

 

1 answer

1 accepted

1 vote
Answer accepted
Laurie Sciutti
Community Champion
November 24, 2023

Hi @Vasanthakumar V ~ if I understand correctly, you would want to use the OR clause (use the pipe | instead of the ampersand &) for the ALLOW inclusion, unless the requirement is to include those members that are in BOTH groups. 

 

Allow portion(|(name=*-XYZ-*)(name=*-AZU-*))

Block portion:  (!(|(name=*-21-00)(name=*-21-01)(name=*-21-03)))

 

(&(objectClass=group)(|(name=*-XYZ-*)(name=*-AZU-*))(!(|(name=*-21-00)(name=*-21-01)(name=*-21-03))))

 

Reference:  https://confluence.atlassian.com/kb/how-to-write-ldap-search-filters-792496933.html 

Vasanthakumar V
Contributor
November 27, 2023

@Laurie Sciutti Thanks for the suggestion, it works.

Like Laurie Sciutti likes this

Suggest an answer

Log in or Sign up to answer