Bug 768316

Summary: [RFE] ipa-getkeytab should auto-detect the ipa server name
Product: Red Hat Enterprise Linux 7 Reporter: Najmuddin Chirammal <nc>
Component: ipaAssignee: Martin Kosek <mkosek>
Status: CLOSED ERRATA QA Contact: IDM QE LIST <seceng-idm-qe-list>
Severity: medium Docs Contact: Aneta Šteflová Petrová <apetrova>
Priority: medium    
Version: 7.0CC: jgalipea, ksiddiqu, mkosek, pvoborni, sumenon, yjog
Target Milestone: rcKeywords: FutureFeature
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: ipa-4.4.0-0.el7.1.alpha1 Doc Type: Enhancement
Doc Text:
*ipa-getkeytab* can now automatically detect the IdM server When running the *ipa-getkeytab* utility on an Identity Management (IdM) server, you are no longer required to specify the server name using the "-s" option. The *ipa-getkeytab* utility detects the IdM server automatically in this situation.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-04 05:42:57 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Najmuddin Chirammal 2011-12-16 10:45:48 UTC
Description of problem:

Ipa-getkeytab command expect the ipa server name and it fails if no server name is provided.

Currently the ipa server name has to be mentioned even if the command is executed  from ipa server or client.

expectation: ipa-getkeytab detects the ipa server(if configured) 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. execute ipa-getkeytab without -s <ipa_server> option
  
Actual results: ipa-getkeytab fails if server name is not provided.
ipa-getkeytab -p HTTP/vm123.example.com -k /tmp/HTTP_vm123.example.com
Usage: ipa-getkeytab [-qP?] [-q|--quiet] [-s|--server Server Name] [-p|--principal Kerberos Service Principal Name] [-k|--keytab Keytab File Name]

Expected results:

ipa-getkeytab detects the ipa server name if the box is configured as ipa client.

Comment 2 Dmitri Pal 2011-12-16 14:35:20 UTC
Upstream ticket:
https://fedorahosted.org/freeipa/ticket/2203

Comment 5 Petr Vobornik 2016-01-29 08:57:38 UTC
Has been fixed upstream:

master:
    f12f56fe8d607240efd7e8c8a942554bdd3b980f Support sourcing the IPA server name from config

Comment 6 Mike McCune 2016-03-28 23:07:19 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 8 Sudhir Menon 2016-09-16 09:16:19 UTC
Verified on RHEL73 using ipa-server-4.4.0-11.el7.x86_64

===IPA Client====
[root@client ~]# ipa-getkeytab -p ldap/master.test-relm.test -k /tmp/ldap1.keytab 
Keytab successfully retrieved and stored in: /tmp/ldap1.keytab
[root@client ~]# ipa-getkeytab -p HTTP/master.test-relm.test -k /tmp/http.keytab
Keytab successfully retrieved and stored in: /tmp/http.keytab
[root@client ~]# ipa-getkeytab -p cifs/master.test-relm.test -k /tmp/cifs.keytab
Keytab successfully retrieved and stored in: /tmp/cifs.keytab

===IPA Master===
[root@master ~]# ipa-getkeytab -p ldap/master.test-relm.test -k /tmp/ldap1.keytab 
Keytab successfully retrieved and stored in: /tmp/ldap1.keytab
[root@master ~]# ipa-getkeytab -p HTTP/master.test-relm.test -k /tmp/http.keytab
Keytab successfully retrieved and stored in: /tmp/http.keytab
[root@master ~]#  ipa-getkeytab -p cifs/master.test-relm.test -k /tmp/cifs.keytab
Keytab successfully retrieved and stored in: /tmp/cifs.keytab

Comment 10 errata-xmlrpc 2016-11-04 05:42:57 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2404.html