All Apps and Add-ons

TA-LDAP search result default to 5 rows

krishnarajapant
Path Finder

Hi Splunkers,

I'm using Add-on for LDAP (version 4.0.0) to fetch the results from my LDAP server. When I use | ldap server="xxxxxx" it is giving the result of only 5 rows. I tried increasing "sizelimit" option in the search, still it is giving 5 rows. Also if I use "attrs" option in the search then it is giving 0 results. Please help to fix the issue.

Regards,
Krishna

0 Karma

krishnarajapant
Path Finder

Hi MuS,
can you please help to download the 3.x version of this add-on to test it in my environment. I feel we have some issue in the latest version's myLDAP2.py script.

With Regards,
Krishna

0 Karma

MuS
Legend

Hi there,

Have you enabled debugging in the script?
What does the log tell you?

Using v3.x will not help, because v4.x was a complete re-work and works differently.

cheers, MuS

0 Karma

krishnarajapant
Path Finder

Thanks MuS for the response.
I have enabled debug, but i have not seen any errors as iäm getting result of 5 rows. Also I have observed that it is not taking the options (Eg L:DAP_filter)) which I have provided in the search or from the inputs.conf.

When I have changed the default filter directly in the myLDAP2.py then it has taken the default value in the script.

Not sure iäm missing something or some issue with the python script.

With Regards,
Krishna

0 Karma

krishnarajapant
Path Finder

Hi MuS,

Still unfortunately im getting same result of 5 rows. I have tested this in other environment. Enabling debug didnot help too.

can you please help in fixing this. I think this is some issue with version 4.0.0 or am i missing something?

With Regards,
Krishna

0 Karma

krishnarajapant
Path Finder

Hi MuS,

I think, found the issue.

in myLDAP2.py, pages_size has been hardcoded to 5, when I have increased to 50 then iäm getting 50 results. So Im checking for the option to change it to unlimited.

searchParameters = { 'search_base': basedn, 'search_scope': scope, 'search_filter': ldap_filter, 'attributes': [''], 'paged_size': 5 }
my_filter = '(&' + ldap_filter + ')'
l.search(search_base=basedn, search_filter=my_filter, attributes=["
"], paged_size=5)

With Regards,
Krishna

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

🍂 Fall into November with a fresh lineup of Community Office Hours, Tech Talks, and Webinars we’ve ...

Transform your security operations with Splunk Enterprise Security

Hi Splunk Community, Splunk Platform has set a great foundation for your security operations. With the ...

Splunk Admins and App Developers | Earn a $35 gift card!

Splunk, in collaboration with ESG (Enterprise Strategy Group) by TechTarget, is excited to announce a ...