[Freeipa-devel] [PATCH] 254 Sort password policies properly with --pkey-only

Martin Kosek mkosek at redhat.com
Thu Apr 26 12:46:39 UTC 2012


On Thu, 2012-04-26 at 11:05 +0200, Petr Viktorin wrote:
> On 04/25/2012 04:41 PM, Martin Kosek wrote:
> > Password policy plugin sorts password policies by its COS priority.
> > However, when the pwpolicy-find command is run with --pkey-only,
> > the resulting entries do not contain COS priority and the sort
> > function crashes.
> >
> > This patch makes sure that cospriority is present in the time
> > of the result sorting process and removes the cospriority again
> > when the sorting is done. This way, the entries are sorted properly
> > both with and without --pkey-only flag.
> >
> > Previous entries_sortfn member attribute of LDAPSearch class
> > containing custom user sorting function was replaced just with
> > a flag indicating if a sorting in LDAPSearch shall be done at all.
> > This change makes it possible to sort entries in a custom
> > post_callback which is much more powerful (and essential for
> > sorting like in pwpolicy plugin) approach than a plain sorting
> > function.
> >
> > https://fedorahosted.org/freeipa/ticket/2676
> >
> 
> ACK
> 

Pushed to master, ipa-2-2.

Martin




More information about the Freeipa-devel mailing list