Install group_file and system_group plugins by default.
mkinstalldirs
mkpkg
pathnames.h.in
+plugins/group_file/Makefile.in
+plugins/group_file/getgrent.c
+plugins/group_file/group_file.c
+plugins/group_file/group_file.exp
+plugins/group_file/plugin_test.c
plugins/sample/Makefile.in
plugins/sample/sample_plugin.c
plugins/sample/sample_plugin.exp
-plugins/sample_group/Makefile.in
-plugins/sample_group/getgrent.c
-plugins/sample_group/plugin_test.c
-plugins/sample_group/sample_group.c
-plugins/sample_group/sample_group.exp
plugins/sudoers/Makefile.in
plugins/sudoers/aixcrypt.exp
plugins/sudoers/alias.c
#
-# Copyright (c) 2010-2011 Todd C. Miller <Todd.Miller@courtesan.com>
+# Copyright (c) 2010-2013 Todd C. Miller <Todd.Miller@courtesan.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
sudoers_mode = @SUDOERS_MODE@
shlib_mode = @SHLIB_MODE@
-SUBDIRS = compat common @ZLIB_SRC@ plugins/sudoers src include doc
-
-SAMPLES = plugins/sample plugins/sample_group plugins/system_group
+SUBDIRS = compat common @ZLIB_SRC@ plugins/group_file plugins/sudoers \
+ plugins/system_group src include doc
VERSION = @PACKAGE_VERSION@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
--flag easprintf:3:c-format --flag lbuf_append:2:c-format \
--flag lbuf_append_quoted:3:c-format --foreign-user
-all: config.status
- for d in $(SUBDIRS) $(SAMPLES); \
- do (cd $$d && exec $(MAKE) $@) && continue; \
- exit $$?; \
- done
-
-check pre-install: config.status
+all check pre-install: config.status
for d in $(SUBDIRS); \
do (cd $$d && exec $(MAKE) $@) && continue; \
exit $$?; \
fi; \
$(srcdir)/mkdep.pl $(srcdir)/common/Makefile.in \
$(srcdir)/compat/Makefile.in $(srcdir)/plugins/sample/Makefile.in \
- $(srcdir)/plugins/sample_group/Makefile.in \
+ $(srcdir)/plugins/group_file/Makefile.in \
$(srcdir)/plugins/sudoers/Makefile.in \
$(srcdir)/plugins/system_group/Makefile.in \
$(srcdir)/src/Makefile.in $(srcdir)/zlib/Makefile.in; \
./config.status --file $(srcdir)/common/Makefile \
--file $(srcdir)/compat/Makefile \
--file $(srcdir)/plugins/sample/Makefile \
- --file $(srcdir)/plugins/sample_group/Makefile \
+ --file $(srcdir)/plugins/group_file/Makefile \
--file $(srcdir)/plugins/sudoers/Makefile \
--file $(srcdir)/plugins/system_group/Makefile \
--file $(srcdir)/src/Makefile --file $(srcdir)/zlib/Makefile
version=$(VERSION) $(PPVARS)
clean: config.status
- for d in $(SUBDIRS) $(SAMPLES); do \
+ for d in $(SUBDIRS); do \
(cd $$d && exec $(MAKE) $@); \
done
mostlyclean: clean
distclean: config.status
- for d in $(SUBDIRS) $(SAMPLES); do \
+ for d in $(SUBDIRS); do \
(cd $$d && exec $(MAKE) $@); \
done
-rm -rf Makefile pathnames.h config.h config.status config.cache \
test "$localstatedir" = '${prefix}/var' && localstatedir='$(prefix)/var'
test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/etc'
-ac_config_files="$ac_config_files Makefile common/Makefile compat/Makefile doc/Makefile include/Makefile src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/sample_group/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers"
+ac_config_files="$ac_config_files Makefile common/Makefile compat/Makefile doc/Makefile include/Makefile src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
"src/sudo_usage.h") CONFIG_FILES="$CONFIG_FILES src/sudo_usage.h" ;;
"src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
"plugins/sample/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/sample/Makefile" ;;
- "plugins/sample_group/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/sample_group/Makefile" ;;
+ "plugins/group_file/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/group_file/Makefile" ;;
"plugins/system_group/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/system_group/Makefile" ;;
"plugins/sudoers/Makefile") CONFIG_FILES="$CONFIG_FILES plugins/sudoers/Makefile" ;;
"plugins/sudoers/sudoers") CONFIG_FILES="$CONFIG_FILES plugins/sudoers/sudoers" ;;
dnl
dnl Substitute into the Makefile and man pages
dnl
-AC_CONFIG_FILES([Makefile common/Makefile compat/Makefile doc/Makefile include/Makefile src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/sample_group/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers])
+AC_CONFIG_FILES([Makefile common/Makefile compat/Makefile doc/Makefile include/Makefile src/sudo_usage.h src/Makefile plugins/sample/Makefile plugins/group_file/Makefile plugins/system_group/Makefile plugins/sudoers/Makefile plugins/sudoers/sudoers])
AC_OUTPUT
dnl
For example, given _\b/_\be_\bt_\bc_\b/_\bs_\bu_\bd_\bo_\b-_\bg_\br_\bo_\bu_\bp, a group file in Unix
group format, the sample group plugin can be used:
- Defaults group_plugin="sample_group.so /etc/sudo-group"
+ Defaults group_plugin="group_file.so /etc/sudo-group"
For more information see sudo_plugin(4).
.nf
.sp
.RS 0n
-Defaults group_plugin="sample_group.so /etc/sudo-group"
+Defaults group_plugin="group_file.so /etc/sudo-group"
.RE
.fi
.sp
.Pa /etc/sudo-group ,
a group file in Unix group format, the sample group plugin can be used:
.Bd -literal
-Defaults group_plugin="sample_group.so /etc/sudo-group"
+Defaults group_plugin="group_file.so /etc/sudo-group"
.Ed
.Pp
For more information see
#
-# Copyright (c) 2011 Todd C. Miller <Todd.Miller@courtesan.com>
+# Copyright (c) 2011, 2013 Todd C. Miller <Todd.Miller@courtesan.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# File extension, mode and map file to use for shared libraries/objects
soext = @SOEXT@
shlib_mode = @SHLIB_MODE@
-shlib_exp = $(srcdir)/sample_group.exp
-shlib_map = sample_group.map
-shlib_opt = sample_group.opt
+shlib_exp = $(srcdir)/group_file.exp
+shlib_map = group_file.map
+shlib_opt = group_file.opt
# OS dependent defines
DEFS = @OSDEFS@
SHELL = @SHELL@
-OBJS = sample_group.lo getgrent.lo
+OBJS = group_file.lo getgrent.lo
LIBOBJDIR = $(top_builddir)/@ac_config_libobj_dir@/
VERSION = @PACKAGE_VERSION@
-all: sample_group.la
+all: group_file.la
Makefile: $(srcdir)/Makefile.in
- (cd $(top_builddir) && ./config.status --file plugins/sample_group/Makefile)
+ (cd $(top_builddir) && ./config.status --file plugins/group_file/Makefile)
.SUFFIXES: .o .c .h .lo
$(shlib_opt): $(shlib_exp)
@sed 's/^/+e /' $(shlib_exp) > $@
-sample_group.la: $(OBJS) $(LT_LIBS) @LT_LDDEP@
+group_file.la: $(OBJS) $(LT_LIBS) @LT_LDDEP@
$(LIBTOOL) --mode=link $(CC) $(LDFLAGS) $(LT_LDFLAGS) -o $@ $(OBJS) $(LIBS) -module -avoid-version -rpath $(plugindir)
pre-install:
install-doc:
-install-plugin: install-dirs sample_group.la
- $(INSTALL) -b~ -m $(shlib_mode) .libs/sample_group$(soext) $(DESTDIR)$(plugindir)
+install-plugin: install-dirs group_file.la
+ $(INSTALL) -b~ -m $(shlib_mode) .libs/group_file$(soext) $(DESTDIR)$(plugindir)
uninstall:
- -rm -f $(DESTDIR)$(plugindir)/sample_group$(soext)
+ -rm -f $(DESTDIR)$(plugindir)/group_file$(soext)
check:
# Autogenerated dependencies, do not modify
getgrent.lo: $(srcdir)/getgrent.c $(top_builddir)/config.h $(incdir)/missing.h
$(LIBTOOL) --mode=compile $(CC) -c $(CPPFLAGS) $(CFLAGS) $(PIE_CFLAGS) $(SSP_CFLAGS) $(DEFS) $(srcdir)/getgrent.c
-sample_group.lo: $(srcdir)/sample_group.c $(top_builddir)/config.h \
+group_file.lo: $(srcdir)/group_file.c $(top_builddir)/config.h \
$(top_srcdir)/compat/stdbool.h $(incdir)/sudo_plugin.h \
$(incdir)/missing.h
- $(LIBTOOL) --mode=compile $(CC) -c $(CPPFLAGS) $(CFLAGS) $(PIE_CFLAGS) $(SSP_CFLAGS) $(DEFS) $(srcdir)/sample_group.c
+ $(LIBTOOL) --mode=compile $(CC) -c $(CPPFLAGS) $(CFLAGS) $(PIE_CFLAGS) $(SSP_CFLAGS) $(DEFS) $(srcdir)/group_file.c
/*
- * Copyright (c) 2005,2008,2010-2011 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 2005,2008,2010-2013 Todd C. Miller <Todd.Miller@courtesan.com>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
/*
- * Copyright (c) 2010 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 2010-2013 Todd C. Miller <Todd.Miller@courtesan.com>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
if (GROUP_API_VERSION_GET_MAJOR(version) != GROUP_API_VERSION_MAJOR) {
sudo_log(SUDO_CONV_ERROR_MSG,
- "sample_group: incompatible major version %d, expected %d\n",
+ "group_file: incompatible major version %d, expected %d\n",
GROUP_API_VERSION_GET_MAJOR(version),
GROUP_API_VERSION_MAJOR);
return -1;
/* Sanity check the specified group file. */
if (argv == NULL || argv[0] == NULL) {
sudo_log(SUDO_CONV_ERROR_MSG,
- "sample_group: path to group file not specified\n");
+ "group_file: path to group file not specified\n");
return -1;
}
if (stat(argv[0], &sb) != 0) {
sudo_log(SUDO_CONV_ERROR_MSG,
- "sample_group: %s: %s\n", argv[0], strerror(errno));
+ "group_file: %s: %s\n", argv[0], strerror(errno));
return -1;
}
if ((sb.st_mode & (S_IWGRP|S_IWOTH)) != 0) {
/*
- * Copyright (c) 2010-2011 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 2010-2013 Todd C. Miller <Todd.Miller@courtesan.com>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
main(int argc, char *argv[])
{
int ch, i, found;
- char *plugin = "sample_group.so";
+ char *plugin = "group_file.so";
char *user, *group;
struct passwd *pwd;