Todd C. Miller
6c3d20cb41
Convert PVS-Studio comment to ANSI C.
2018-10-26 08:39:09 -06:00
Todd C. Miller
64e5d34c57
Add comments in .c files so PVS-Studio will check them.
2018-10-21 08:46:05 -06:00
Todd C. Miller
1e5af35564
Refactor code to convert defaults to tags and do conversion on
...
output for "sudo -l".
Remove the short_list (was long_list) global in favor of a verbose
argument.
2018-08-05 07:17:34 -06:00
Todd C. Miller
db387a53a6
fix typo
2018-08-04 07:38:47 -06:00
Todd C. Miller
70d519c8ad
o Move userspecs, defaults and aliases into a new struct sudoers_parse_tree.
...
o The parse tree is now passed to the alias, match and defaults functions.
o The nss API has been changed so that the nss parse() function returns
a pointer to a struct sudoers_parse_tree which will be filled in
by the getdefs() and query() functions.
2018-07-26 15:12:33 -06:00
Todd C. Miller
71e98d9493
Include parse.h in sudoers.h since it will soon be required.
2018-05-14 09:05:02 -06:00
Todd C. Miller
df7a6ea4e8
Don't always expand aliases when formatting a host-based Defaults
...
line. This was missed when expand_aliases support was added.
2018-04-12 06:25:35 -06:00
Todd C. Miller
910f288948
fix compilation on Solaris
2018-03-10 20:16:20 -07:00
Todd C. Miller
bb31544fcc
In sudoers_format_userspecs make the separator optional and silence
...
a printf format warning.
2018-03-06 13:42:56 -07:00
Todd C. Miller
6014b4075c
Kill dead store found by clang-analyzer.
2018-03-04 11:59:45 -07:00
Todd C. Miller
5c36f9dec3
Initial support for adding comments that will be emitted when
...
sudoers is formatted. Currently adds a comment for the source
sudoRole when converting from ldif -> sudoers.
2018-03-04 07:03:43 -07:00
Todd C. Miller
670d8e6d77
Special case comment lines in lbufs.
2018-03-04 07:03:41 -07:00
Todd C. Miller
c9b70940cf
When formatting as sudoers, flush the lbuf after each userspec.
2018-03-03 07:42:10 -07:00
Todd C. Miller
19502307aa
Deal with user_name not being set in cvtsudoers.
2018-02-22 10:43:47 -07:00
Todd C. Miller
337ace6441
Prepend digest to command if present.
...
Fix printing of group IDs and non-unix groups.
2018-02-21 21:08:37 -07:00
Todd C. Miller
4f9296928c
Add option to cvtsudoers to expand aliases in the output.
2018-02-19 15:32:56 -07:00
Todd C. Miller
64e99328e3
Move sudoers formatting code into fmtsudoers.
2018-02-09 18:22:04 -07:00