Commit Graph

89 Commits

Author SHA1 Message Date
Love Hornquist Astrand
1d84562886 add HDBGET: that only supports get, iteration doesnt really make sense for the HDB keytab except when dumping 2013-10-15 12:40:39 +02:00
Viktor Dukhovni
72f0690694 Temporary fix for high-priority iprop issues
Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
2013-04-24 16:29:34 -07:00
Viktor Dukhovni
eface6d31f Fix free before use in ipropd_master slaves-stats open function
Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
2013-04-24 16:27:34 -07:00
Love Hornquist Astrand
60472d48ea set vno to unconfuse coverity 2012-11-27 21:58:05 -08:00
Love Hornquist Astrand
0a237dc778 don't use free'd string 2012-10-01 09:53:52 -07:00
Roland C. Dowdeswell
539ba5fb87 Fix issue where master HDB can be locked while waiting for network I/O.
We should not hold locks on the master's database while waiting
for network I/O which may take a terribly long time to complete as
this will block out all writers and could therefore be slightly
problematic.  ipropd-master was holding a shared lock on the database
while sending a complete propation to slaves which are out of sync
with the log file.  We fix this by writing what we intend to send
in record format into a file hdb_db_dir()/ipropd.dumpfile while
holding a shared lock on the database and then we send the contents
of the file after releasing the lock.  We also save and re-use the file
that we generated during future complete propagation events as long
as the log is long enough to get us back to the state previously
dumped.
2012-06-06 22:29:03 +01:00
Roland C. Dowdeswell
cc47c8fa7b Turn on -Wextra -Wno-sign-compare -Wno-unused-paramter and fix issues.
We turn on a few extra warnings and fix the fallout that occurs
when building with --enable-developer.  Note that we get different
warnings on different machines and so this will be a work in
progress.  So far, we have built on NetBSD/amd64 5.99.64 (which
uses gcc 4.5.3) and Ubuntu 10.04.3 LTS (which uses gcc 4.4.3).

Notably, we fixed

	1.  a lot of missing structure initialisers,

	2.  unchecked return values for functions that glibc
	    marks as __attribute__((warn-unused-result)),

	3.  made minor modifications to slc and asn1_compile
	    which can generate code which generates warnings,
	    and

	4.  a few stragglers here and there.

We turned off the extended warnings for many programs in appl/ as
they are nearing the end of their useful lifetime, e.g.  rsh, rcp,
popper, ftp and telnet.

Interestingly, glibc's strncmp() macro needed to be worked around
whereas the function calls did not.

We have not yet tried this on 32 bit platforms, so there will be
a few more warnings when we do.
2012-02-20 19:45:41 +00:00
Love Hörnquist Åstrand
bf37778dbd make ipropd_slave tell its status in a status file
The ipropd_slave will log its status to /var/heimdal/ipropd-slave-status
if its connecting, up to date, or disconnected.

The master will now also confirm to slaves that are are in fact up to date
if they just restart, before there was no confirmation, the slave just didn't
get any deltas.
2012-02-15 20:59:54 -08:00
Nicolas Williams
40a7d4b62f More fixes for -Werror (GCC 4.6 catches more stuff) 2011-11-02 23:20:55 -05:00
Love Hornquist Astrand
0879b9831a remove trailing whitespace 2011-05-21 11:57:31 -07:00
Love Hornquist Astrand
f5f9014c90 Warning fixes from Christos Zoulas
- shadowed variables
- signed/unsigned confusion
- const lossage
- incomplete structure initializations
- unused code
2011-04-29 20:25:05 -07:00
Love Hornquist Astrand
b3811999f7 fix error condition 2011-04-23 20:03:57 -07:00
Love Hornquist Astrand
311b3c4f32 catch error from asprintf()
Patch from Tom Payerle
2011-04-23 19:31:43 -07:00
Love Hornquist Astrand
9427bcc22e log more version numbers 2011-01-03 12:12:18 +01:00
Asanka C. Herath
880d728e02 Un-const as necessary to silence compiler warnings 2010-11-24 15:33:07 -05:00
Love Hornquist Astrand
dd9e076e47 reorder to remove if (0); 2009-12-25 10:45:26 +01:00
Love Hornquist Astrand
15cff173a2 Use #ifdef SIGXCPU instead of #ifndef NO_SIGXCPU 2009-12-25 10:44:40 +01:00
Love Hornquist Astrand
160ddd0e43 use rk_closesocket 2009-12-23 14:06:37 +01:00
Love Hornquist Astrand
f1c0c1bba3 prefix SOCKET symbols with rk_ 2009-11-25 05:29:18 +01:00
Asanka Herath
c6b8fad5dc Consistency updates for lib/kadm5 and don't check fd_set size if it's not necessary 2009-11-24 10:18:20 -08:00
Asanka Herath
d84119813e No AF_UNIX on Windows and no SIGPIPE and SIGXCPU 2009-11-24 10:12:44 -08:00
Love Hornquist Astrand
d3d9e5ecb5 free sp on error/full send 2009-10-06 11:19:27 -07:00
Love Hornquist Astrand
ff87429593 Make LDAP code fetch less attributes from LDAP server when KDC is asking
Johan Gadsjö did a awesome analysis of the LDAP access pattens
and sent us a patch that reduced the calls the ldap server by 4
times as many. The patch was adopted and change to avoid compile
time depencies and make the determination runtime instead. Thanks!
2009-10-03 13:20:41 -07:00
Love Hornquist Astrand
3b761fddc0 check the clients with current_version, and if client have newer, whine 2009-09-05 14:41:03 -07:00
Love Hornquist Astrand
03b6f9a09b Don't send diffs to dead slaves 2009-09-05 14:31:49 -07:00
Love Hornquist Astrand
0d49d0f1c4 Free ticket earlier [CID-108] 2009-07-30 10:39:52 +02:00
Love Hörnquist Åstrand
a96fa6cacd plug memory leak
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@25092 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-04-04 17:10:41 +00:00
Love Hörnquist Åstrand
cbfc88f691 wrap detach
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24411 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-01-25 00:39:45 +00:00
Love Hörnquist Åstrand
7beb192394 update (c)
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23855 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-09-22 06:32:03 +00:00
Love Hörnquist Åstrand
6937d41a02 remove trailing whitespace
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23815 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-09-13 09:21:03 +00:00
Love Hörnquist Åstrand
e172367898 switch to utf8 encoding of all files
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23814 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-09-13 08:53:55 +00:00
Love Hörnquist Åstrand
c6f6defa06 Only log "sending AYT" once, pointed out by Dr A V Le Blanc.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23074 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-04-23 15:06:51 +00:00
Love Hörnquist Åstrand
811319445f warnings on platforms where sig_atomic_t is not a int, from netbsd via Michael van Elst, Havard Eidnes and T K Spindler
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@22773 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-03-24 19:13:46 +00:00
Love Hörnquist Åstrand
284d45bbbc use hdb_db_dir() and hdb_default_db()
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@22211 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-12-07 19:27:27 +00:00
Love Hörnquist Åstrand
5a0bf63c71 Update (c).
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21831 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-08-07 17:34:51 +00:00
Love Hörnquist Åstrand
3d9f731d98 - don't push whole database to the new client every time.
- make slaves get the whole new database if they have a newer log the
  the master (and thus have them go back in time).


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21824 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-08-06 02:18:13 +00:00
Love Hörnquist Åstrand
0b286093fe Sprinkle more info about what versions the master thinks about the client versions.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21806 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-08-03 13:09:20 +00:00
Love Hörnquist Åstrand
598b915110 Start the server at the current version, not 0.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21804 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-08-03 12:57:02 +00:00
Love Hörnquist Åstrand
8d095c0457 Add more logging, to figure out what is happening in the master.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21791 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-08-02 18:46:34 +00:00
Love Hörnquist Åstrand
0382061b7b add configuration for signal file and acl file, let user select hostname, catch signals and print why we are quiting, make nop cause one new version, not two
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21756 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-07-31 22:15:08 +00:00
Love Hörnquist Åstrand
2849d42835 (send_diffs): make current slave's version uptodate when diff have been sent.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21729 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-07-30 14:54:13 +00:00
Love Hörnquist Åstrand
3154e1056e Use strcspn to remove \n from string returned by fgets.
From Björn Sandell


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19233 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-12-06 08:04:05 +00:00
Love Hörnquist Åstrand
cb704efeeb Rename u_intXX_t to uintXX_t
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17445 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-05-05 10:37:46 +00:00
Love Hörnquist Åstrand
0c2369acd0 Wrap hdb_entry with hdb_entry_ex, patch originally from Andrew Bartlet
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16378 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-12-12 12:40:12 +00:00
Love Hörnquist Åstrand
608845b433 Make compile.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15972 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-08-24 14:29:59 +00:00
Love Hörnquist Åstrand
1cf12f2fbe Update to new signature of kadm5_log_previous.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15970 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-08-24 14:27:52 +00:00
Love Hörnquist Åstrand
04dcbbc45a rename local variable slave to s, optind -> optidx
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15485 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-06-17 05:23:46 +00:00
Love Hörnquist Åstrand
af6eb0f463 Don't test HAVE_DAEMON since roken supplies it.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15213 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-23 17:39:35 +00:00
Love Hörnquist Åstrand
32b515fccb add the documented option --port
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14964 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-25 19:23:15 +00:00
Johan Danielsson
524a064514 add help strings to some options
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14254 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-09-23 12:55:08 +00:00