Commit Graph

73 Commits

Author SHA1 Message Date
Nicolas Williams
a51708c356 kadmin: Fix kdb_attrs[] units order 2022-04-25 22:24:51 -05:00
Nicolas Williams
a4d3832675 kadmin: Remove unnecessary callback data ret field 2022-03-24 14:52:22 -05:00
Nicolas Williams
1dbfd4e835 kadmin: Use kadm5_iter_principals() to list princs
Now that we have a properly working API for listing principals in an
online way, and a server-side implementation of it, use it.

This should work with old and new servers, but it will only be online
and fast when talking to new servers.

(Old servers have a bug though that prevents LIST from working.)
2022-03-20 18:32:14 -05:00
Nicolas Williams
4eb80e0e93 kadm5: deltat2str(): Improve "unlimited" 2022-03-14 13:41:47 -05:00
Luke Howard
0165633964 hdb: add no-auth-data-reqd flag to HDB entry
Add a new flag, no-auth-data-reqd, to the HDB entry which indicates that a PAC
should not be included on issued service tickets.
2021-12-23 13:52:12 +11:00
Nicolas Williams
ba98690a0a kadmin: Add add_alias, del_alias 2021-10-11 13:58:15 -05:00
Nicolas Williams
8ac3452fd7 kadmin: Add missing attributes; sort units
Sorting the units fixes a bug introduced in:

    ae8908bf8 kadmin: Add disallow-client attribute

that I had fixed via:

    f6ac4ee86 roken: Fix parse flags bug

which wasn't a bug at all.
2021-06-22 14:47:38 -05:00
Nicolas Williams
ae8908bf81 kadmin: Add disallow-client attribute
This is useful for services that need not be clients.  For example, an
untrusted service that need only accept authentication from clients,
but not initiate authentication to other services.
2021-06-22 13:01:24 -05:00
Nicolas Williams
e17f78c738 kadmin: Allow negative time offsets 2020-09-07 22:15:52 -05:00
Nicolas Williams
f2bb83c088 Add default to policy prompt and fix harmless bug in edit_policy() 2011-07-22 16:07:06 -05:00
Nicolas Williams
fad463bbd9 Fix policy validation bug (parse_policy() should return success when the policy name is OK!) 2011-07-22 16:07:06 -05:00
Nicolas Williams
af23757829 Trivial policy bug fix. 2011-07-22 16:06:01 -05:00
Nicolas Williams
1f349a6aba kadmin support for policies. 2011-07-22 16:05:21 -05:00
Jeffrey Altman
6850d6a65f avoid uninit variable and unreachable code warnings
most of these warnings are not problems because of ample
use of abort() calls.  However, the large number of warnings
makes it difficult to identify real problems.  Initialize
the variables to shut up the compilers.

Change-Id: I8477c11b17c7b6a7d9074c721fdd2d7303b186a8
2011-05-17 12:02:16 -04:00
Love Hornquist Astrand
17b38758ff patch from Christos Zoulas 2011-04-23 18:25:40 -07:00
Love Hornquist Astrand
433b1d5073 drop RCSID 2010-03-16 12:52:58 -07:00
Love Hörnquist Åstrand
5be004f3fa Handle relative time syntax using +<parse_time>.
Example: kadmin mod --pw-expiration-time='+1month 1day'

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24642 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-02-07 15:11:22 +00:00
Love Hörnquist Åstrand
1f77290fb2 switch to krb5_clear_error_message
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23917 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-14 02:56:48 +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
8d40c2994b check return value of alloc functions, from Charles Longeau
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21745 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-07-31 16:11:25 +00:00
Love Hörnquist Åstrand
c9cde2b10b Clear error string, just to be sure.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21707 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-07-26 20:20:59 +00:00
Love Hörnquist Åstrand
93eb1b8a47 Make str2time_t parser more robust.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19489 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-12-22 17:28:27 +00:00
Love Hörnquist Åstrand
0e5d5e7f5e Add KRB5_KDB_ALLOW_DIGEST
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17926 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-08-24 10:49:46 +00:00
Love Hörnquist Åstrand
3d6786f066 (kdb_attrs): Add KRB5_KDB_ALLOW_KERBEROS4
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17652 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-06-14 18:35:08 +00:00
Love Hörnquist Åstrand
e00b4f01bc (kdb_attrs): Add trusted-for-delegation
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17632 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-06-06 21:31:14 +00:00
Love Hörnquist Åstrand
091fba8a25 return 1 on failure, update (c)
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16658 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-01-25 12:29:46 +00:00
Love Hörnquist Åstrand
ff51c4fa4c (foreach_principal): If any of calls to `func' failes, the first error
is returned when all principals are processed.


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16652 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-01-25 12:11:09 +00:00
Love Hörnquist Åstrand
5654000990 lower amount of shadow and const warnings
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15587 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-07-07 22:06:50 +00:00
Love Hörnquist Åstrand
92c6949daf (kdb_attrs): add ok-as-delegate
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15313 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-30 20:47:04 +00:00
Love Hörnquist Åstrand
3746090a7d (foreach_principal): initialize ret to make sure it have a value
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14860 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-20 10:37:25 +00:00
Johan Danielsson
d970c48c81 print error messages to stderr; change all in-string quoting to use "
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14021 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-07-04 15:09:42 +00:00
Johan Danielsson
efe1bcc986 (str2time_t): fix end-of-day logic, from Duncan McEwan/Mark Davies.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13840 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-05-07 09:03:31 +00:00
Love Hörnquist Åstrand
b44cea4ef2 (str2time_t): allow whitespace between date and time
From: Bob Beck <beck@cvs.openbsd.org> and adharw@yahoo.com


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12965 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-10-04 05:36:29 +00:00
Love Hörnquist Åstrand
c74a90def6 cast argument to tolower to unsigned char,
from Christian Biere <christianbiere@gmx.de> via NetBSD


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12010 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-14 11:55:27 +00:00
Johan Danielsson
7f955379c6 (get_response): print a newline if interrupted
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11558 ec53bebd-3082-4978-b11e-865c3cabbd6b
2002-12-03 14:14:51 +00:00
Johan Danielsson
646457d75e remove unused variable; reported by Hans Insulander
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11034 ec53bebd-3082-4978-b11e-865c3cabbd6b
2002-06-07 18:28:46 +00:00
Assar Westerlund
7b1eba193f (edit_timet): make non-static to be consistent
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10570 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-08-27 23:07:36 +00:00
Assar Westerlund
cdcfeeaefa (get_response): fix krb5_err call
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10480 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-08-10 15:22:20 +00:00
Johan Danielsson
c80e917ff9 do something to handle C-c in prompts
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10477 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-08-10 14:25:32 +00:00
Johan Danielsson
d8b679ffd3 (edit_entry): move setting of default values to a separate function,
set_defaults


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10455 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-08-10 08:00:26 +00:00
Assar Westerlund
d0ddf23f4f (foreach_principal): rely on krb5_warn to get reasonable error
messages


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9939 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-05-14 06:17:20 +00:00
Assar Westerlund
437b1230c7 (foreach_principal): add `funcname' and try printing the error string
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9850 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-05-07 05:29:45 +00:00
Assar Westerlund
0fbfbb5860 (parse_attributes): make empty string mean no attributes, specifying
the empty string at the command line should give you no attributes,
but just pressing return at the prompt gives you default attributes
(edit_entry): only pick up values from the default principal if they
aren't set in the principal being edited


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9473 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-01-11 23:07:29 +00:00
Assar Westerlund
3a443f6afa (str2time_t): rename to make it work
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8982 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-08-20 01:11:04 +00:00
Assar Westerlund
c071ee122c (str2time_t): add alias for `now'.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8977 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-08-19 13:19:52 +00:00
Assar Westerlund
2530f9d474 remove unused variable
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8784 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-07-23 03:14:10 +00:00
Assar Westerlund
72ba28e10a (str2time_t): be more careful with strptime that might zero out the
`struct tm'


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8783 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-07-23 03:10:02 +00:00
Johan Danielsson
9becec7aee (deltat2str): treat 0 and INT_MAX as never
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8641 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-07-11 13:01:27 +00:00
Assar Westerlund
3e52cd86f1 (hex2n, parse_des_key): add
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8055 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-03-23 22:55:16 +00:00