[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#62721: 30.0.50; EUDC: stop adding a wildcard to LDAP searches
From: |
Filipp Gunbin |
Subject: |
bug#62721: 30.0.50; EUDC: stop adding a wildcard to LDAP searches |
Date: |
Mon, 10 Apr 2023 17:29:35 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
On 08/04/2023 09:20 +0200, Fabrice Bauzac-Stehly wrote:
> Hello,
>
> I use EUDC to search entries from LDAP. I routinely search for a
> username to retrieve the email address. The LDAP server contains lots
> of entries, and a username is often a prefix of lots of other usernames.
> For example, when I search for the "js" username, I don't want to have
> dozens of results of usernames that just start with "js" like "jsmith"
> or "jscott".
>
> However, that's what eudcb-ldap does: for reasons I don't understand,
> the eudc-ldap-format-query-as-rfc1558 defun automatically appends the
> wildcard character "*" to the last field. This is annoying as I get
> dozens of results. I want to have the choice of adding a wildcard or
> not to my searches, I don't want that imposed on me.
>
> I propose the attached patch to fix this behaviour. The result is a
> simplification of the existing code. Could you please review it?
>
Hi,
The wildcard is there so you can use partial values with M-x
eudc-expand-inline (and also in M-x eudc-query-form and others).
You can customize eudc-ldap-no-wildcard-attributes, or just let-bind it
around your code.
Thanks.