Commit Graph

207 Commits

Author SHA1 Message Date
Jan Cholasta
1c5028c17d Configure SSSD to store user password if offline.
ticket 1359
2011-07-14 19:26:25 -04:00
Jan Cholasta
f05141e646 Remove redundant configuration values from krb5.conf.
ticket 1358
2011-06-28 01:10:06 -04:00
Rob Crittenden
d0af8b28d7 On a master configure sssd to only talk to the local master.
Otherwise it is possible for sssd to pick a different master to
communicate with via the DNS SRV records and if the remote master
goes down the local one will have problems as well.

ticket https://fedorahosted.org/freeipa/ticket/1187
2011-06-21 16:07:06 +02:00
Martin Kosek
e773124474 Fix support for nss-pam-ldapd
Client installation with --no-sssd option was broken if the client
was based on a nss-pam-ldap instead of nss_ldap. The main issue is
with authconfig rewriting the nslcd.conf after it has been
configured by ipa-client-install.

This has been fixed by changing an order of installation steps.
Additionally, nslcd daemon needed for nss-pam-ldap function is
correctly started.

https://fedorahosted.org/freeipa/ticket/1235
2011-06-08 10:00:27 +02:00
Rob Crittenden
7a867102c5 Properly configure nsswitch.conf when using the --no-sssd option.
Even with --no-sssd authconfig was setting nsswitch.conf to use sssd
for users, groups, shadow and netgroups. We need to pass in the
--enableforcelegacy option hwen configuring nss_ldap.

Also always back up and restore sssd.conf. It still gets configured for
kerberos.

ticket 1142
2011-05-18 13:19:06 +02:00
Martin Kosek
95b4040f6b KDC autodiscovery may fail when domain is not realm
When ipa-client-install autodiscovers IPA server values it
doesn't fill the fixed KDC address to Kerberos configuration
file. However, when realm != domain or the autodiscovered values
are overridden, installation may fail because it cannot find the
KDC.

This patch adds a failover to use static KDC address in case when
such an issue occurs.

https://fedorahosted.org/freeipa/ticket/1100
2011-05-17 08:56:22 +02:00
Martin Kosek
2cbc6fd6a2 Improve service manipulation in client install
Remove redundant ipa-client-install error message when optional nscd
daemon was not installed. Additionally, use standard IPA functions
for service manipulation and improve logging.

https://fedorahosted.org/freeipa/ticket/1207
2011-05-13 13:24:35 +02:00
Martin Kosek
9de10f3674 Consolidate man pages and IPA tools help
IPA tools options are not consistent with information in man
pages.

https://fedorahosted.org/freeipa/ticket/1163
https://fedorahosted.org/freeipa/ticket/1178
2011-05-12 16:55:27 -04:00
Jan Cholasta
16d1db4996 Fix issues found by Coverity.
tickets 1166, 1167, 1168, 1169
2011-05-09 16:23:40 -04:00
Simo Sorce
d1fd695467 install-scripts: avoid using --list with chkconfig
This option does not behave properly in F15 as chkconfig does not list services
moved to use systemd service files.

Plus there are more direct ways than parsing its output, which are more
reliable.

Also just testing for the availability of the service calling 'chkconfig name'
is enough.

https://fedorahosted.org/freeipa/ticket/1206
2011-05-06 15:46:41 +02:00
Martin Kosek
e90120bdcb Bad return values for ipa-rmkeytab command
ipa-rmkeytab returns success even when the realm passed to the
program is not found in a keytab. This patch adds an explanatory
error message and returns error code 5 - Principal or realm not
found.

https://fedorahosted.org/freeipa/ticket/694
2011-05-03 15:19:07 +02:00
Martin Kosek
c6763d0a58 ipa-client-install uninstall does not work on IPA server
When IPA server is being uninstalled, IPA client on-master
uninstallation which is called by the script fails.

https://fedorahosted.org/freeipa/ticket/1197
2011-04-29 16:32:59 -04:00
Martin Kosek
2e99c60c8b Forbid reinstallation in ipa-client-install
The --force option may be misused to reinstall an existing IPA
client. This is not supported and may lead to unexpected errors.
When required, the cleanest way to re-install IPA client is to
run uninstall and then install again.

This patch also includes few cosmetic changes in messages to user
to provide more consistent user experience with the script.

https://fedorahosted.org/freeipa/ticket/1117
2011-04-29 09:28:37 +02:00
Martin Kosek
d76b9aef39 Prevent uninstalling client on the IPA server
This patch prevents uninstalling IPA client when it is configured
as a part of IPA server. ipa-server-installation script is advised
for this situation.

https://fedorahosted.org/freeipa/ticket/1049
2011-04-29 09:23:59 +02:00
Martin Kosek
8472dc26b7 Log temporary files in ipa-client-install
This patch adds logging of temporary files (Kerberos configuration,
nsupdate commands) that may be very useful for debugging purposes.

https://fedorahosted.org/freeipa/ticket/1093
https://fedorahosted.org/freeipa/ticket/1094
2011-04-28 10:02:18 +02:00
Jan Cholasta
1ac3ed2c27 Fix lint false positives. 2011-04-13 15:58:45 +02:00
Rob Crittenden
811f631c09 Suppress --on-master from ipa-client-install command-line and man page.
This option is only used when configuring an IPA client on an IPA server.
Describing it on the command-line will only confuse people so don't
list it as an option.

Ticket 1050
2011-04-12 09:31:56 +02:00
Rob Crittenden
b3a85890ef Make retrieval of the CA during DNS discovery non-fatal.
ticket 1135
2011-03-30 10:03:56 -04:00
Rob Crittenden
15e213d025 Ensure that the system hostname is lower-case.
ticket 1080
2011-03-18 14:54:01 -04:00
Rob Crittenden
a36bc4ee93 Always consider domain and server when doing DNS discovery in client.
When not on master we weren't passing in the user-supplied domain and
server. Because of changes made that require TLS on the LDAP calls
we always need the server name early in the process to retrieve the IPA
CA certificate.

ticket 1090
2011-03-15 11:01:03 -04:00
Rob Crittenden
3735450ab8 If --hostname is provided for ipa-client-install use it everywhere.
If a hostname was provided it wasn't used to configure either
certmonger or sssd. This resulted in a non-working configuration.

Additionally on un-enrollment the wrong hostname was unenrolled, it
used the value of gethostname() rather than the one that was passed
into the installer.

We have to modify the CA configuration of certmonger to make it
use the right principal when requesting certificates. The filename
is unpredicable but it will be in /var/lib/certmonger/cas.
We need to hunt for ipa_submit and add -k <principal> to it, then
undo that on uninstall. These files are created the first time
the certmonger service starts, so start and stop it before messing
with them.

ticket 1029
2011-03-08 10:23:07 -05:00
Rob Crittenden
61d70657ab Always try to stop tracking the server cert when uninstalling client.
stop_tracking() is robust enough to do the right thing if no certificate
exists so go ahead and always call it. If the certificate failed to
be issued for some reason the request will still in certmonger
after uninstalling. This would cause problems when trying to reinstall
the client. This will go ahead and always tell certmonger to stop
tracking it.

ticket 1028
2011-03-08 10:23:03 -05:00
Simo Sorce
998dd701a7 Fix kinit invocation in ipa-client-install 2011-03-01 17:49:45 -05:00
Rob Crittenden
388c9a1705 Add man page for the IPA configuration file
ticket 969
2011-02-23 11:56:31 -05:00
Rob Crittenden
e7ed4035b5 Set krb5_realm in sssd.conf in the ipa provider.
ticket 925
2011-02-22 09:06:58 -05:00
Jr Aquino
32e4914584 18 Use TLS for ipadiscovery during ipa-client-install https://fedorahosted.org/freeipa/ticket/974 2011-02-21 16:09:37 -05:00
Jakub Hrozek
119b8a4ccf Document --enable-dns-updates in ipa-client-install man page
https://fedorahosted.org/freeipa/ticket/991
2011-02-21 11:55:50 -05:00
Jan Zeleny
7fe78b4e48 Fixes in ipa-join man page
https://fedorahosted.org/freeipa/ticket/784
https://fedorahosted.org/freeipa/ticket/786
https://fedorahosted.org/freeipa/ticket/787
2011-02-18 10:37:46 -05:00
Simo Sorce
eab4e36ee5 Try to register DNS name through a DNS Update on install.
Fixes: https://fedorahosted.org/freeipa/ticket/935
2011-02-17 19:43:52 -05:00
Rob Crittenden
cd2365bf64 Configure SSSD to use DNS to find the IPA server by default.
Add the server we registered with as a fallback.

ticket 980
2011-02-17 17:12:42 -05:00
Simo Sorce
50318b60ee Fix duplicate OIDs
Apparently we forgot to check OID consistency between the schema and the
extensions, and we got duplicates.

Technically the schema was done later but it is easier to change the extensions
OIDs than to change the schema of current beta2/rc1 installations.

The only side effect is that older ipa-getkeytab and ipa-join binaries will
fail. So all the admin/client tools must be upgraded at the same time as well
as all the masters (otherwise some will show/accept the new OID while others
won't).

Fixes: https://fedorahosted.org/freeipa/ticket/976
2011-02-17 08:38:53 -05:00
Jan Zeleny
5f317ab680 Fix a typo in ipa-client-install man page
https://fedorahosted.org/freeipa/ticket/782
2011-02-15 15:41:19 -05:00
Jr Aquino
72e315c936 Bugfix for ipa-client-install echo's password in cleartext to stdout https://fedorahosted.org/freeipa/ticket/959 2011-02-14 15:43:18 -05:00
Martin Kosek
309ed42865 Detection of v1 server during ipa-client-install
When v2 IPA client is trying to join an IPA v1 server
a strange exception is printed out to the user. This patch
detects this by catching an XML-RPC error reported by ipa-join
binary called in the process which fails on unexisting IPA server
'join' method.

https://fedorahosted.org/freeipa/ticket/553
2011-02-14 15:03:32 -05:00
Jakub Hrozek
22c3a681da Fine tuning DNS options
Add pointer to self to /etc/hosts to avoid chicken/egg problems when
restarting DNS.

On servers set both dns_lookup_realm and dns_lookup_kdc to false so we don't
attempt to do any resolving. Leave it to true on clients.

Set rdns to false on both server and client.

https://fedorahosted.org/freeipa/ticket/931
2011-02-14 14:45:22 -05:00
Jakub Hrozek
856d890bb3 Make sure only root can run ipa-client-install
https://fedorahosted.org/freeipa/ticket/957
2011-02-14 10:43:56 -05:00
Rob Crittenden
fd50d9e900 nscd should be disabled before sssd is configured/started.
If not then sssd spits out a warning message:

sssd: nscd socket was detected.  As nscd caching capabilities may conflict
with SSSD, it is recommended to not run nscd in parallel with SSSD

Stop nscd before configuring sssd so we don't confuse our users.

ticket 743
2011-02-10 13:50:47 -05:00
Rob Crittenden
e6d3b7031d Fix prompt for confirmation of fixed values wrapping around terminal.
ticket 940
2011-02-10 13:50:06 -05:00
Jakub Hrozek
a3a154d915 Fix filter_keys in ipa-getkeytab
https://fedorahosted.org/freeipa/ticket/723
2011-01-28 11:44:38 -05:00
Rob Crittenden
80e87e75bd Add an option for overriding the hostname value.
Ticket 834
2011-01-26 15:53:41 -05:00
Rob Crittenden
35f2f1d720 Improve output when options are not found in non-interactive client install
We should still give some feedback when things go wrong when in
non-interactive mode.

ticket 828
2011-01-21 13:47:55 -05:00
Simo Sorce
8a6547943f Do not try to dereference bindpw if it is null
Fixes: https://fedorahosted.org/freeipa/ticket/783
2011-01-18 11:56:03 -05:00
Martin Kosek
bd965c92d8 Mozldap-specific code removed
Mozldap code removed from all sources and configure source script.
Now, IPA will compile even when package mozldap-devel is not
installed on the system.

https://fedorahosted.org/freeipa/ticket/756
2011-01-14 17:33:11 -05:00
Martin Kosek
a6a91e5dbc Unitialized pointer read in ipa-join
This patch fixes a possible situation when krb5_kt_close()
function is called with uninitialized keytab parameter.

https://fedorahosted.org/freeipa/ticket/712
2011-01-14 14:20:57 -05:00
Martin Kosek
7b5601eeb5 Potential memory leaks in ipa-getkeytab
This patch fixes 2 situations where a pointer to allocated error
string could be overwritten - which could have resulted in
a memory leak.

https://fedorahosted.org/freeipa/ticket/714
2011-01-14 14:20:57 -05:00
Martin Kosek
974287895e Unchecked return values in ipa-join
krb5_get_default_realm() and asprintf() return values were ignored.
This could lead to unhandled error issues or memory access
issues.

This patch adds return value checks to all such functions.
As a consequence, one new return value has been added to man page.

https://fedorahosted.org/freeipa/ticket/720
2011-01-12 11:31:26 -05:00
Martin Kosek
b739df4c11 Unchecked return value in ipa-getkeytab
krb5_init_context return value was not checked. This could lead
to unhandled error issues.

This patch moves the Kerberos context initialization to the
branch where it is needed and handles the error value in a way
that allows program exit in a standard way deallocating all
resources.

https://fedorahosted.org/freeipa/ticket/721
2011-01-12 11:29:19 -05:00
Martin Kosek
e2d4e9477e Uninitialized pointer read in ipa-rmkeytab
Fix "--realm" parameter processing in ipa-rmkeytab. Also make sure
that memory allocated in this process is also freed.

https://fedorahosted.org/freeipa/ticket/711
2011-01-12 11:28:25 -05:00
Martin Kosek
6503813608 Use of pointer after free in ipa-join
In some cases recently freed memory was used/freed again. This
patch introduces more consistency between functions
join_ldap/join_krb5 when dealing with affected variables.

https://fedorahosted.org/freeipa/ticket/709
2011-01-12 11:20:42 -05:00
Rob Crittenden
a1188d95e8 Better detection when not working with a real keytab in ipa-rmkeytab.
Resolving the keytab isn't enough, this just creates a name. Try to
create a cursor into the keytab to see if it is a valid keytab.

ticket 654
2011-01-07 05:15:37 -05:00