I want to get createtimestamp, krbLastSuccessfulAuth, and krbLastPwdChange for all active users
The "ipa user-find" or "ipa user-show" commands only give krbLastPwdChange and failed login count/date
The "ipa user-status" command shows "Last successful authentication", but it has to be run for each user
I found this suggestion https://www.redhat.com/archives/freeipa-users/2016-May/msg00213.html Could you use ldapsearch? # ldapsearch -Y GSSAPI -b "cn=users,cn=accounts,dc=rhel72" createtimestamp krbLastSuccessfulAuth
and tried it adding in krbLastPwdChange, and using a service account as described here https://www.freeipa.org/page/HowTo/LDAP#System_Accounts
but it did not return any krbLastSuccessfulAuth values. A bit of tinkering revealed that I have to use the Directory Manager to get back the krbLastSuccessfulAuth.
Is it possible to tweak the service account to allow it to read krbLastSuccessfulAuth ? ______________________________________________________________________________________________
Daniel E. White daniel.e.white@nasa.gov NICS Linux Engineer NASA Goddard Space Flight Center 8800 Greenbelt Road Building 14, Room E175 Greenbelt, MD 20771 Office: (301) 286-6919 Mobile: (240) 513-5290
I use this:
ipa user-show $USER --all --raw | grep krbLastSuccessful | awk '{print $2}'
On Fri, Jul 10, 2020 at 9:52 AM White, Daniel E. (GSFC-770.0)[NICS] via FreeIPA-users freeipa-users@lists.fedorahosted.org wrote:
I want to get createtimestamp, krbLastSuccessfulAuth, and krbLastPwdChange for all active users
The "ipa user-find" or "ipa user-show" commands only give krbLastPwdChange and failed login count/date
The "ipa user-status" command shows "Last successful authentication", but it has to be run for each user
I found this suggestion https://www.redhat.com/archives/freeipa-users/2016-May/msg00213.html Could you use ldapsearch? # ldapsearch -Y GSSAPI -b "cn=users,cn=accounts,dc=rhel72" createtimestamp krbLastSuccessfulAuth
and tried it adding in krbLastPwdChange, and using a service account as described here https://www.freeipa.org/page/HowTo/LDAP#System_Accounts
but it did not return any krbLastSuccessfulAuth values. A bit of tinkering revealed that I have to use the Directory Manager to get back the krbLastSuccessfulAuth.
Is it possible to tweak the service account to allow it to read krbLastSuccessfulAuth ?
Daniel E. White daniel.e.white@nasa.gov NICS Linux Engineer NASA Goddard Space Flight Center 8800 Greenbelt Road Building 14, Room E175 Greenbelt, MD 20771 Office: (301) 286-6919 Mobile: (240) 513-5290
FreeIPA-users mailing list -- freeipa-users@lists.fedorahosted.org To unsubscribe send an email to freeipa-users-leave@lists.fedorahosted.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedorahosted.org/archives/list/freeipa-users@lists.fedorahoste...
Thanks, Russel, I missed that, but you have to do it in a "for each user" loop. The single ldapquery would be easier. ______________________________________________________________________________________________
Daniel E. White mailto:daniel.e.white@nasa.gov NICS Linux Engineer NASA Goddard Space Flight Center 8800 Greenbelt Road Building 14, Room E175 Greenbelt, MD 20771 Office: (301) 286-6919 Mobile: (240) 513-5290
From: Russell Long kd8fre@gmail.com Date: Friday, July 10, 2020 at 09:58 To: FreeIPA-Users freeipa-users@lists.fedorahosted.org Cc: Daniel White daniel.e.white@nasa.gov Subject: [EXTERNAL] Re: [Freeipa-users] It ain't easy to dig a user's last login time info out of IdM/FreeIPA
I use this:
ipa user-show $USER --all --raw | grep krbLastSuccessful | awk '{print $2}'
White, Daniel E. (GSFC-770.0)[NICS] via FreeIPA-users wrote:
Thanks, Russel, I missed that, but you have to do it in a "for each user" loop. The single ldapquery would be easier.
The data is not replicated because doing so was found to be very heavy weight.
rob
Daniel E. White mailto:daniel.e.white@nasa.gov NICS Linux Engineer NASA Goddard Space Flight Center 8800 Greenbelt Road Building 14, Room E175 Greenbelt, MD 20771 Office: (301) 286-6919 Mobile: (240) 513-5290
From: Russell Long kd8fre@gmail.com Date: Friday, July 10, 2020 at 09:58 To: FreeIPA-Users freeipa-users@lists.fedorahosted.org Cc: Daniel White daniel.e.white@nasa.gov Subject: [EXTERNAL] Re: [Freeipa-users] It ain't easy to dig a user's last login time info out of IdM/FreeIPA
I use this:
ipa user-show $USER --all --raw | grep krbLastSuccessful | awk '{print $2}'
FreeIPA-users mailing list -- freeipa-users@lists.fedorahosted.org To unsubscribe send an email to freeipa-users-leave@lists.fedorahosted.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedorahosted.org/archives/list/freeipa-users@lists.fedorahoste...
freeipa-users@lists.fedorahosted.org