def clean_old_password(self):
        old_password = self.cleaned_data["old_password"]
        if not self.user.check_password(old_password):
            raise forms.ValidationError(
                self.error_messages['password_incorrect'])
        return old_password
Validates that the old_password field is correct.
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.4/django/contrib/auth/forms.py/PasswordChangeForm.clean_old_password