#8013 ipa service-find does not list cifs service created by ipa-client-samba
Closed: fixed by rcritten. Opened by rcritten.

Ticket was cloned from Red Hat Bugzilla (product Fedora): Bug 1731433

Description of problem:
ipa-client-samba utility creates cifs service, which is not listed by "ipa
service-find", though it can be viewed using "ipa service-show"
Version-Release number of selected component (if applicable):
freeipa-server-4.8.0-1.fc30.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Setup topology: install ipa server, run ipa-adtrust-install on server, setup
ipa client.
2. run ipa-client-samba on client
3. run ipa service-find
Actual results:
cifs service for client is not listed
Expected results:
record for principal cifs/client1.testrelm.test@TESTRELM.TEST in output
Additional info:
"ipa service-show cifs/client1.testrelm.test@TESTRELM.TEST" shows the desired
service.
Extract from /var/log/dirsrv/slapd-TESTRELM-TEST/access captured during
execution of ipa service-find:
SRCH base="cn=services,cn=accounts,dc=testrelm,dc=test" scope=1 filter="(&(&(ob
jectClass=ipaService)(!(objectClass=posixAccount))(!(|(krbPrincipalName=kadmin/
*)(krbPrincipalName=K/M@*)(krbPrincipalName=krbtgt/*))))(&(objectClass=krbprinc
ipal)(objectClass=krbprincipalaux)(objectClass=krbticketpolicyaux)(objectClass=
ipaobject)(objectClass=ipaservice)(objectClass=pkiuser)))"
attrs="userCertificate krbPrincipalName ipaKrbAuthzData ipaAllowedToPerform
krbPrincipalAuthInd krbCanonicalName"
Thing to note here is "!(objectClass=posixAccount)"
And as the service record contains this objectClass, the record is removed from
search results:
ipa service-show cifs/client1.testrelm.test@TESTRELM.TEST --raw --all
  dn: krbprincipalname=cifs/client1.testrelm.test@TESTRELM.TEST,cn=services,cn=
accounts,dc=testrelm,dc=test
  krbcanonicalname: cifs/client1.testrelm.test@TESTRELM.TEST
...
  objectClass: posixaccount
...
The filter was introduced in commit 789fec4381 in year 2009.

Metadata Update from @rcritten:
- Custom field rhbz adjusted to https://bugzilla.redhat.com/show_bug.cgi?id=1731433

Metadata Update from @rcritten:
- Issue assigned to rcritten

https://github.com/freeipa/freeipa/pull/3418

master:

  • e771fa59ff65545ff1e84f1cd30e06556fabcee3 Remove posixAccount from service_find search filter

ipa-4-8:

  • 2f9cbffb6e57ded2d0107f457241f33b17869a96 Remove posixAccount from service_find search filter

Metadata Update from @rcritten:
- Issue close_status updated to: fixed
- Issue status updated to: Closed (was: Open)

Metadata