67c8164 Ticket #48228 - wrong password check if passwordInHistory is decreased.

Authored and Committed by nhosoi 8 years ago
    Ticket #48228 - wrong password check if passwordInHistory is decreased.
    
    Bug Description: When N passwords to be remembered (passwordInHistroy)
    and N passwords are remembered, decreasing the passwordInHistory value
    to M (< N) does not allow to use the oldest password which should have
    been discarded from the history and should be allowed.
    
    Fix Description: Before checking if the password is in the history or
    not, adding a check the passwordInHistory value (M) is less than the
    count of passwords remembered (N).  If M < N, discard the (N-M) oldest
    passwords.
    
    https://fedorahosted.org/389/ticket/48228
    
    Reviewed by mreynolds@redhat.com (Thank you, Mark!!)
    
    (cherry picked from commit 1a119125856006543aae0520b5800a8b52c3b049)
    (cherry picked from commit dd85ee9c9ac24f1b141dd806943de236d2e44c90)
    
        
file modified
+114 -79