Commit Graph

4341 Commits

Author SHA1 Message Date
Krzysztof Klimonda
c30394fd8e dpkg-query only on bind9 package 2012-04-17 01:07:27 +02:00
Krzysztof Klimonda
bbb86e36aa move check_inst out of bindinstance.py
create a new platform utils module which imports a proper implementation
from platform.PLATFORM.instances.utils. Move the current check_inst to the
fedora16 package and create debian implementation which uses dpkg-query
to check for bind9 and bind-dyndb-ldap packages.
2012-04-17 00:26:03 +02:00
Krzysztof Klimonda
2a40a5f782 rewrite HTTPInstance to be platform agnostic
Moved HTTPInstance class to the base.instances.http module and started
rewriting it to not use hardcoded paths and names, but instead use variables
defined in the implementations provided by the platform modules.
2012-03-09 12:13:18 +01:00
Krzysztof Klimonda
3d3547aae8 Rewrite the base NTPInstance so it's platform-independent
Make NTPInstance use config paths and variables that are set up in the
platform subclass.
2012-03-09 12:13:16 +01:00
Krzysztof Klimonda
ed1d277bf1 use regexp to get current ntpd arguments
Fedora/RHEL uses double quote, but Debian/Ubuntu uses single quote to quote
argument list passed to the daemon. By the replacing current logic with
a simple regexp we remove this difference. It doesn't matter which one is used
so we always save the file with a double quotes.
2012-03-09 12:12:26 +01:00
Krzysztof Klimonda
066849f437 initial import of debian platform modules 2012-03-09 12:12:26 +01:00
Krzysztof Klimonda
2a9868251f convert the base platform module into package
This package will provide base classes for both services and instances
that have to be implemented for each platform to provide needed interface
between FreeIPA and the system it's being run on.
2012-03-09 01:15:32 +01:00
Rob Crittenden
fc37d98b5d Become IPA 2.1.4 2011-12-05 16:45:02 -05:00
Rob Crittenden
1f6c69d411 Remove extraneous trailing single quote in nis.uldif 2011-12-05 16:43:01 -05:00
Rob Crittenden
9f10fb20e9 Require an HTTP Referer header in the server. Send one in ipa tools.
This is to prevent a Cross-Site Request Forgery (CSRF) attack where
a rogue server tricks a user who was logged into the FreeIPA
management interface into visiting a specially-crafted URL where
the attacker could perform FreeIPA oonfiguration changes with the
privileges of the logged-in user.

https://bugzilla.redhat.com/show_bug.cgi?id=747710
2011-12-05 16:02:24 -05:00
Evgeny Sinelnikov
89d9ad428c ipa_kpasswd: Update selinux policies for ldap and urandom
Fixes: https://fedorahosted.org/freeipa/ticket/2160
2011-12-04 17:25:50 -05:00
Martin Kosek
455ce3c67e Make ipa-server-install clean after itself
ipa-server-install may create some files in the first phase of
installation before the actual installation and configuring of
services starts. If the installation is interrupted, these files
may prevent installing the server again until IPA server is
uninstalled. This may be confusing and annoying for the user.

This patch safely recovers all known files that could be created
in the first phase of the installation. No clean up is done if
the actual installation has not started yet or the installation
returned success.

https://fedorahosted.org/freeipa/ticket/1980
2011-11-29 09:24:06 +01:00
Martin Kosek
990553221f Enable automember for upgraded servers
automember functionality is depends on predefined data is in LDAP.
Since we add it for fresh installs only, automember cannot be used
for upgraded servers. Make sure that automember LDAP data is added
during upgrade too.

https://fedorahosted.org/freeipa/ticket/1992
2011-11-29 09:02:16 +01:00
Ondrej Hamada
9eb703f408 Client install root privileges check
ipa-client-install was failing and returning traceback when
wasn't run by root. It was caused by logging initialization that
was taking part before the root privileges check. To correct it,
the check was moved before the logging initialization.

https://fedorahosted.org/freeipa/ticket/2123
2011-11-21 09:39:50 +01:00
Martin Kosek
57841aad29 Let PublicError accept Gettext objects
Make sure that PublicError does not crash when it receives
Gettext/NGettext object. Instead of throwing a type error, do the
translation to receive the required unicode text.

https://fedorahosted.org/freeipa/ticket/2096
2011-11-16 11:00:05 +01:00
Martin Kosek
d301007e69 Fix ipa-managed-entries bind procedure
Make sure that when Directory Manager password is entered,
we directly do a simple bind instead of trying binding via GSSAPI.
Also capture ldap.INVALID_CREDENTIALS exception and provide nice
error message than crash.

https://fedorahosted.org/freeipa/ticket/1927
2011-11-16 08:53:39 +01:00
Rob Crittenden
452eaf5436 Don't allow default objectclass list to be empty.
https://fedorahosted.org/freeipa/ticket/1945
2011-11-09 08:50:25 +01:00
Endi S. Dewata
c6d19960d5 Added current password field.
The reset password dialog for user has been modified to provide
a field to specify the current password when changing the user's
own password.

Ticket #2065
2011-11-07 14:18:35 +01:00
Simo Sorce
afece97712 Modify random salt creation for interoperability
port to ipa-2-1
ameneded math safety issue

See:
https://fedorahosted.org/freeipa/ticket/2038
2011-11-05 19:01:33 -04:00
Martin Kosek
76c1452549 Fix ipa-replica-conncheck port labels
https://fedorahosted.org/freeipa/ticket/2057
2011-11-04 08:55:34 +01:00
Martin Kosek
c960e0a4b0 Fix ipa-server-install answer cache
Current Answer Cache storing mechanism is not ideal for storing
non-trivial Python types like arrays, custom classes, etc.
RawConfigParser just translates values to string, which
are not correctly decoded when the Answer Cache is parsed and
restored in the installer.

This patch replaces RawConfigParser with Python's standard pickle
module, which is a recommended way for serialization in Python.

https://fedorahosted.org/freeipa/ticket/2054
2011-11-03 21:47:50 +01:00
Rob Crittenden
c10db54aee Fix nis netgroup config entry so users appear in netgroup triple.
https://fedorahosted.org/freeipa/ticket/2028
2011-10-27 09:56:14 +02:00
Martin Kosek
e366ae17f8 Fix ipa-managed-entries password option long form
https://fedorahosted.org/freeipa/ticket/1913
2011-10-26 08:55:16 +02:00
Alexander Bokovoy
7a5ff3bc20 Quote multiple workers option
https://fedorahosted.org/freeipa/ticket/2023
2011-10-25 18:13:50 +02:00
Alexander Bokovoy
fb7276f9c3 Update spec file to F-16 2011-10-24 15:09:18 +02:00
Alexander Bokovoy
5451328bc5 Spin for connection success also when socket is not (yet) available
We were spinning for socket connection if attempt to connect returned errno 111
(connection refused). However, it is not enough for local AF_UNIX sockets as
heavy applications might not be able to start yet and therefore the whole path
might be missing. So spin for errno 2 (no such file or directory) as well.

Partial fix for
  https://fedorahosted.org/freeipa/ticket/1990
2011-10-24 15:08:50 +02:00
Alexander Bokovoy
95d6a2256c Add support for systemd environments and use it to support Fedora 16
https://fedorahosted.org/freeipa/ticket/1192
2011-10-24 15:07:27 +02:00
Rob Crittenden
7bde6a7da9 Fix problems in help system
Fixes 3 issues:

- If a topic has all its commands disabled, it should be disabled
- If a command is disabled its help should be disabled
- The show-mappings help was missing a doc string so no help was displayed

https://fedorahosted.org/freeipa/ticket/1998
2011-10-20 18:25:51 -04:00
John Dennis
9b7639a89d Ticket 1201 - Unable to Download Certificate with Browser
Certificates are passed through the IPA XML-RPC and JSON as binary
data in DER X509 format. Queries peformed against the LDAP server
also return binary DER X509 format. In all cases the binary DER
data is base-64 encoded.

PEM is standard text format for certificates. It also uses base64 to
encode the binary DER data, but had specific formatting
requirements. The base64 data must be wrapped inside PEM delimiters
and the base64 data must be line wrapped at 64 characters.

Most external software which accepts certificates as input will only
accept DER or PEM format (e.g. openssl & NSS). Although base64 is
closely related to PEM it is not PEM unless the PEM delimters are
present and the base64 data is line wrapped at 64 characters.

We already convert binary DER certificates which have been passed as
base64 in other parts of the IPA code. However this conversion has not
been available in the web UI. When the web UI presented certificates
it did so by filling a dialog box with a single line of base64 data. A
user could not copy this data and use it as input to openssl or NSS
for example.

We resolve this problem by introducing new javascript functions in
certificate.js. IPA.cert.pem_cert_format(text) will examine the text
input and if it's already in PEM format just return it unmodified,
otherwise it will line wrap the base64 data and add the PEM
delimiters. Thus it is safe to call on either a previously formated
PEM cert or a binary DER cert encoded as base64. This applies to
pem_csr_format() as well for CSR's.

Because pem_cert_format() is safe to call on either format the web UI
will see the use of the flag add_pem_delimiters was eliminated except
in the one case where the IPA.cert.download_dialog() was being abused
to display PKCS12 binary data (pkcs12 is neither a cert nor a cert
request). Because of the abuse of the cert.download_dialog() for
pkcs12 it was necessary to retain the flag which in effect said "do
not treat the data as PEM".

Modify the CSR (Certificate Signing Request) dialog box to accept a
PEM formatted CSR. Remove the artifical PEM delimiters above and below
the dialog box which were used to suggest the input needed to be sans
the delimiters. The dialog box continues to accept bare base64 thus
allowing either text format.

Also note this solves the display of certificate data in the UI
without touching anything existing code in the server or command line,
thus it's isolated.
2011-10-21 15:30:10 +00:00
Alexander Bokovoy
28692ef60f hbactest fails while you have svcgroup in hbacrule
https://fedorahosted.org/freeipa/ticket/1988
2011-10-20 17:23:06 -04:00
Martin Kosek
a2d0ca2794 Fix client krb5 domain mapping and DNS
Add Kerberos mapping for clients outside of server domain. Otherwise
certmonger had problems issuing the certificate. Also make sure that
client DNS records on the server are set before certmonger is started
and certificate is requested.

Based on Lars Sjostrom patch.

https://fedorahosted.org/freeipa/ticket/2006
2011-10-21 14:53:20 +02:00
Rob Crittenden
c4ca29cfc2 Become IPA 2.1.3 2011-10-17 15:47:42 -04:00
Petr Vobornik
f3a5d48836 Fixed: Unable to add external user for RunAs User for Sudo rules
https://fedorahosted.org/freeipa/ticket/1987

There is no way to add root or any external user as a RunAs User for a Sudo
Rule.
2011-10-17 14:02:20 -02:00
Martin Kosek
5a3268fc7d Improve hostgroup/netgroup collision checks
When the NGP plugin is enabled, a managed netgroup is created for
every hostgroup. We already check that netgroup with the same
name does not exist and provide a meaningful error message.
However, this error message was also printed when a duplicate
hostgroup existed.

This patch checks for duplicate hostgroup existence first and
netgroup on the second place. It also makes sure that when NGP
plugin is (temporarily) disabled, a colliding netgroup cannot
be created.

https://fedorahosted.org/freeipa/ticket/1914
2011-10-17 17:09:57 +02:00
Rob Crittenden
e365bc5379 Fix typo in invalid PTR record error message
https://fedorahosted.org/freeipa/ticket/1982
2011-10-13 22:52:57 -04:00
Rob Crittenden
3506dc8ed4 If our domain is already configured in sssd.conf start with a new config.
https://fedorahosted.org/freeipa/ticket/1989
2011-10-13 21:24:34 -04:00
Rob Crittenden
1104a8898c Update all LDAP configuration files that we can.
LDAP can be configured in any number of places, we need to update everything
we find.

https://fedorahosted.org/freeipa/ticket/1986
2011-10-13 20:44:49 -04:00
Alexander Bokovoy
cc0e30a1bb Use set class instead of dictview class as set is wider supported 2011-10-13 18:26:09 -04:00
Rob Crittenden
c75b177dc6 Handle an empty value in a name/value pair in config_replace_variables()
This would blow up if you tried to append a value to an entry that looked
like:

NAME=

https://fedorahosted.org/freeipa/ticket/1983
2011-10-13 16:37:23 -04:00
Rob Crittenden
0ead8b4194 Set min nvr of 389-ds-base to 1.2.10-0.4.a4 for limits fixes (740942, 742324) 2011-10-13 15:29:20 -04:00
Martin Kosek
b73ac20a2b Fix ipa-client-install -U option alignment 2011-10-14 10:35:24 +02:00
Alexander Bokovoy
440f96a373 Document --preserve-sssd option of ipa-client-install
Add documentation about --preserve-sssd, an ipa-client-install's option to
honor previously available SSSD configuration in case it is not possible to
merge it cleanly with the new one. In this case ipa-client-install will fail
and ask user to fix SSSD config before continuing.

Additional fix for
https://fedorahosted.org/freeipa/ticket/1750
https://fedorahosted.org/freeipa/ticket/1769
2011-10-14 10:30:48 +02:00
Rob Crittenden
2427d3bb6f Add explicit instructions to ipa-replica-manage for winsync replication
https://fedorahosted.org/freeipa/ticket/1946
2011-10-14 09:05:13 +02:00
Rob Crittenden
16fc9f847c Save the value of hostname even if it doesn't appear in /etc/sysconfig/network
https://fedorahosted.org/freeipa/ticket/1871
2011-10-13 01:01:15 -04:00
Martin Kosek
58918c4593 Check /etc/hosts file in ipa-server-install
There may already be a record in /etc/hosts for chosen IP address
which may not be detected under some circumstances. Make sure
that /etc/hosts is checked properly.

https://fedorahosted.org/freeipa/ticket/1923
2011-10-13 00:56:22 -04:00
Martin Kosek
b8eafa43ac Hostname used by IPA must be a system hostname
Make sure that the hostname IPA uses is a system hostname. If user
passes a non-system hostname, update the network settings and
system hostname in the same way that ipa-client-install does.

This step should prevent various services failures which may not
be ready to talk to IPA with non-system hostname.

https://fedorahosted.org/freeipa/ticket/1931
2011-10-13 00:56:17 -04:00
Martin Kosek
93feb52932 Check hostname resolution sanity
Always check (even with --setup-dns or --no-host-dns) that if the
host name or ip address resolves, it resolves to sane value. Otherwise
report an error. Misconfigured /etc/hosts causing these errors could
harm the installation later.

https://fedorahosted.org/freeipa/ticket/1923
2011-10-13 00:56:13 -04:00
Adam Young
edd334c67a Fix dynamic display of UI tabs based on rights
Fixes the webui for the case wherea user is not admin but has a role. In
that case, the UI should show the full administrative tabset, but was
instead limited to the selfservice tabset.

The problem was rolegroup had been renamed to role but the UI hadn't
been updated to reflect this.

Addresses
https://bugzilla.redhat.com/show_bug.cgi?id=745957
https://fedorahosted.org/freeipa/ticket/1970
2011-10-12 23:20:07 -04:00
Rob Crittenden
411c303ae8 Work around limits not being updatable in 389-ds.
The bug to fix updates, BZ 741744, isn't working. For the short
term add the attributes we want to update to the REPLACE
whitelist so rather than using an ADD and DEL operation it will
use a REPLACE.

https://fedorahosted.org/freeipa/ticket/1888
2011-10-12 22:42:45 -04:00
Simo Sorce
36c63ee8eb updates: Change default limits on ldap searches
Fixes: https://fedorahosted.org/freeipa/ticket/1867
       https://fedorahosted.org/freeipa/ticket/1888
2011-10-12 22:42:39 -04:00