[SSSD] [PATCH] DB: Add user/group lookup by SID

Ondrej Kos okos at redhat.com
Wed Sep 4 07:30:37 UTC 2013


On 09/03/2013 12:08 AM, Jakub Hrozek wrote:
> On Tue, Aug 27, 2013 at 12:19:39PM +0200, Ondrej Kos wrote:
>> On 08/26/2013 03:53 PM, Jakub Hrozek wrote:
>>> On Mon, Aug 26, 2013 at 02:58:18PM +0200, Ondrej Kos wrote:
>>>> Hi,
>>>>
>>>> Attached patch adds sysdb routine to search users/groups by their
>>>> SID, which will be needed for ticket 1568.
>>>>
>>>> I'm sending it now, because one of the patches I have in this
>>>> working branch (store group SID) was already written and posted on
>>>> the list by Sumit, so not to waste time again :)
>>>>
>>>
>>> There is quite some code duplication between the two functions. Can we
>>> have a single one that would also take a search base and either
>>> objectlass or filter as arguments? The objectclass or filter would then
>>> be and-end with SYSDB_SID_STR=%s. User and group functions could then be
>>> just thin wrappers.
>>>
>>> Also I would prefer a unit test for any new sysdb API.
>>> _______________________________________________
>>> sssd-devel mailing list
>>> sssd-devel at lists.fedorahosted.org
>>> https://lists.fedorahosted.org/mailman/listinfo/sssd-devel
>>>
>>
>> New patch attached.
>
> This is better, but do you need the generic function and the enum
> exposed in the header? Can you make the generic function static and move
> the enum inside the module?
>
> Also, instead of the enum, maybe the function can accept the format
> strings directly and then we wouldn't need the adhoc enum at all.
> _______________________________________________
> sssd-devel mailing list
> sssd-devel at lists.fedorahosted.org
> https://lists.fedorahosted.org/mailman/listinfo/sssd-devel
>
New patch attached

Ondra

-- 
Ondrej Kos
Associate Software Engineer
Identity Management - SSSD
Red Hat Czech
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-DB-Add-user-group-lookup-by-SID.patch
Type: text/x-patch
Size: 10630 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20130904/22465f88/attachment.bin>


More information about the sssd-devel mailing list