Commit Graph

36 Commits

Author SHA1 Message Date
Simo Sorce
67f62709f8 In openvz we found out some interfaces may return a null pointer here.
Skip them if no address is provided or we later get a segfault because
we dereference a null pointer.
2008-07-15 16:16:33 -04:00
Simo Sorce
4b4e0e1516 fix typo 2008-07-15 16:16:33 -04:00
Simo Sorce
66aa3581fc Make sure we have the right prototypes when using openldap libs 2008-07-09 16:51:18 -04:00
Martin Nagy
6cce2f45e8 Fix some small issues that caused compiler warnings, like uninitialized or unused variables or missing krb5 prototypes. 2008-06-30 14:17:10 -04:00
Simo Sorce
77906dce20 Fix typo in inet type 2008-06-11 11:36:14 -04:00
Simo Sorce
4f81c2faec Make ipa_kpasswd listen on each single interface explicitly
instead of 0.0.0.0, this allows us to reply to a UDP request
by using the right source address to build the kerberos reply.
2008-05-29 09:43:39 -04:00
Simo Sorce
dc7d62d543 Fix crash bug in ipa_kpasswd 2008-05-29 09:43:20 -04:00
Simo Sorce
0d023b2680 Fix testing for asprintf errors, we need to test the return value as
per standard the  buffer status is undefined.
While there also introduce a new spearate variable to return the final
error and keep using ret for local error checks. This avoid potentially
overwriting the correct return value when checking for asprintf ...
2008-05-22 11:44:02 -04:00
Jim Meyering
58592c3b4f detect failure to write ipa_kpasswd.pid file
* ipa_kpasswd.c (main): Detect not just open failure,
but also any write failure.
2008-05-15 12:59:28 -04:00
Jim Meyering
0d2212fe2f remove useless if-before-free tests
I've been on a crusade (;-) to remove useless if-before-free tests,
so ran a script that spotted some here.  I think I removed the first
batch (without braces) automatically, then manually removed the ones
with curly braces around the free statements.

You may well have doubts about the portability of removing those
tests, but as long as you don't care about SunOS4 or earlier, you'll
be fine.  I've done similar things for e.g., coreutils, glibc, and git,
and have had no problems.
2008-05-15 12:59:28 -04:00
W. Michael Petullo
29ddbc610c This patch begins the process of replacing OpenLDAP with mozldap.
FreeIPA relies on RedHat's Directory Server, which uses mozldap.
A FreeIPA build using mozldap would reduce the project's dependencies and
redundant code. In addition, mozldap uses NSS instead of OpenSSL.
This is beneficial for the reasons listed in [1].

[1] http://fedoraproject.org/wiki/FedoraCryptoConsolidation
2008-05-01 09:59:43 -04:00
Simo Sorce
c260d63245 Move ipa_kpasswd credential cache in its own directory 2008-04-01 17:33:53 -04:00
Rob Crittenden
97d9c235dd Set the license uniformly to GPLv2 only. 2008-02-04 15:15:52 -05:00
Rob Crittenden
217019e9de Create /var/run/<process>.pid to play nicers with the start scripts
Need to start ipa_webgui as root and drop privs in order to write in /var/run
2008-02-06 11:02:05 -05:00
Rob Crittenden
042fb11fa1 Fix issues reported by rpmlint.
- Removing shebangs (#!) from a bunch of python libraries
- Don't use a variable name in init scripts for the lock file
- Keep the init script name consistent with the binary name, so renamed
  ipa-kpasswd.init to ipa_kpasswd.init
- Add status option to the init scripts
- Move most python scripts out of /usr/share/ipa and into the python
  site-packages directories (ipaserver and ipaclient)
- Remove unnecessary sys.path.append("/usr/share/ipa")
- Fix the license string in the spec files
- Rename ipa-webgui to ipa_webgui everywhere
- Fix a couple of issues reported by pychecker in ipa-python
2008-01-18 16:20:36 -05:00
Simo Sorce
0614024566 Minor fix 2007-12-11 10:59:07 -05:00
Simo Sorce
647063253e Fix kdec.length or we may try to double free() or free() uninitiualized data. 2007-12-07 18:09:49 -05:00
Simo Sorce
bec524485a Fix subtle errors in kpasswd 2007-11-20 17:41:26 -05:00
Simo Sorce
0a5a952c1b - Report correct information back to users when policies prevent a successful
password change.
- Fix some minor error

Initial code to read the Kerberos Master Key from the Directory
2007-11-16 20:17:26 -05:00
Simo Sorce
7502ebe479 Initial implementation of policies support.
This patch uses the kerberos schema policy, this is the same policy used by
kadmin.
While this patch allows for krbPwdPolicy objects anywhere the kldap module
will make the kdc fail to provide tickets if the "krbPwdPolicyReference"
points to any object that is not a child of cn=<REALM>,cn=kerberos,dc=....
To let us set policies anywhere in the tree I enabled the code to actually
look at parent entries and the user entry itself and specify policies directly
on these objects by adding the krbPwdPolicy objectclass to them (I know its
structural but DS seem to allow multiple Structural classes on the same
entry).
The only side effect is that kadmin will not understand this, but we don't
want to use kadmin anyway as it does not understand way too many things about the
directory.

I've tested a few scenarios and all seem working as expected, but further
testing is welcome of course.
2007-11-13 16:21:03 -05:00
Karl MacMillan
1d2c024afa Additional build fixes from autoconf merge. 0001-01-01 00:00:00 +00:00
Karl MacMillan
f8fba3b7dd Autotool ipa-server - patch from William Jon McCann <mccann@jhu.edu>. 0001-01-01 00:00:00 +00:00
Simo Sorce
08855a4d77 Better handling of IPv4/IPv6 sockets in ipa-kpasswd
Tested with UDP and works
2007-10-12 13:24:41 -04:00
Karl MacMillan
d2a19b2009 Karl MacMillan wrote:
> > This largish patch makes the build and installation work on 64bit
> > machines. The only catch here is that to get a 64bit build you need to
> > set LIBDIR on make:
> >
> > make install LIBDIR=/usr/lib64
> >
> > The spec file does this correctly. I couldn't find any reliable way to
> > guess this that works both on real systems and in the almost entirely
> > empty rpm build root (you can't, for example, check for the existence
> > of /usr/lib64).
0001-01-01 00:00:00 +00:00
Simo Sorce
93deded293 IPv6ify, untested 2007-09-28 03:21:17 -04:00
Simo Sorce
5898ae527a In the TCP case there is an extra (redundant) lenght
field before the packet data, address the problem.
2007-09-12 11:51:16 -04:00
Simo Sorce
aacfce9cf1 Remove dependncy on libmhash and use openssl md4 functions
Remove all dependencies on mhash
Remove code optimizatrion from Makefiles, right now these are
developers targeted builds, so it is better to have debugging
symbols around
2007-08-20 15:38:47 -04:00
Simo Sorce
29a8f74fad Complete proper daemonization by closing std* descriptors.
This fixes install as well as /sbin/services does not hang anymore
2007-08-17 12:44:01 -04:00
Simo Sorce
d41db21a09 Add forgotten ipa-kpasswd.init 2007-08-17 10:34:34 -04:00
Simo Sorce
3d5c8b326b Improve ipa-kpasswd so that it can be installed and started
Make it daemonize
Make it use syslog (LOG_DAEMON facility)
2007-08-15 22:15:35 -04:00
Simo Sorce
788149e2e5 Activate the passwd extop plugin and ipa-kpasswd daemon 2007-08-15 18:30:15 -04:00
Simo Sorce
c7aed23e82 Clean up code so that Wall returns 0 complaints 2007-08-15 11:21:49 -04:00
Karl MacMillan
88a1ab65ce Updates to build kpaswd and the slapi plugins. 0001-01-01 00:00:00 +00:00
Simo Sorce
34b439e838 Fix location of the binary
Add a comment on the ldap code for the future
2007-08-09 17:10:41 -04:00
Simo Sorce
a50720e7d4 Make the daemon init it's own tickets.
Make it blacklist clients until the previous operation is not over.
General bugfixing.
2007-08-08 22:18:14 -04:00
Simo Sorce
7ca7a4b9e4 move ipa-kpasswd to a new location to conform to the new tree layout 2007-08-01 16:01:52 -04:00