summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThorsten Kukuk <kukuk@thkukuk.de>2006-06-14 15:28:43 +0000
committerThorsten Kukuk <kukuk@thkukuk.de>2006-06-14 15:28:43 +0000
commitfe8d0ce8e594a8d362f3b034aa8d5240db8f09f0 (patch)
treef14cca2f6bd83cb6e074dac0949dba694fae19f2
parent1b8c3c439aca2b3849328666a0d022c1685b7bdf (diff)
Relevant BUGIDs:
Purpose of commit: cleanup Commit summary: --------------- 2006-06-14 Thorsten Kukuk <kukuk@thkukuk.de> * configure.in: Remove --enable-memory-debug, add option to disable prelude if installed. * modules/pam_tally/pam_tally.c: Remove MEMORY_DEBUG * modules/pam_filter/upperLOWER/upperLOWER.c: Likewise. * modules/pam_unix/unix_chkpwd.c: Likewise. * libpam/include/security/_pam_types.h: Likewise. * libpam/libpam.map: Remove LIBPAM_MALLOC_DEBUG export. * libpam/pam_malloc.c: Remove file. * libpam/Makefile.am: Remove pam_malloc.c and pam_malloc.h.
-rw-r--r--ChangeLog11
-rw-r--r--NEWS1
-rw-r--r--configure.in28
-rw-r--r--libpam/Makefile.am4
-rw-r--r--libpam/include/security/_pam_types.h9
-rw-r--r--libpam/libpam.map9
-rw-r--r--modules/pam_filter/upperLOWER/upperLOWER.c6
-rw-r--r--modules/pam_tally/pam_tally.c7
-rw-r--r--modules/pam_unix/unix_chkpwd.c8
-rw-r--r--po/POTFILES.in1
10 files changed, 24 insertions, 60 deletions
diff --git a/ChangeLog b/ChangeLog
index 027fc0d2..2554bf42 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,16 @@
2006-06-14 Thorsten Kukuk <kukuk@thkukuk.de>
+ * configure.in: Remove --enable-memory-debug, add option
+ to disable prelude if installed.
+
+ * modules/pam_tally/pam_tally.c: Remove MEMORY_DEBUG
+ * modules/pam_filter/upperLOWER/upperLOWER.c: Likewise.
+ * modules/pam_unix/unix_chkpwd.c: Likewise.
+ * libpam/include/security/_pam_types.h: Likewise.
+ * libpam/libpam.map: Remove LIBPAM_MALLOC_DEBUG export.
+ * libpam/pam_malloc.c: Remove file.
+ * libpam/Makefile.am: Remove pam_malloc.c and pam_malloc.h.
+
* libpam/pam_handlers.c (extract_modulename): Use _pam_strdup
instead of strdup.
diff --git a/NEWS b/NEWS
index 5cccd162..9bb648cb 100644
--- a/NEWS
+++ b/NEWS
@@ -8,6 +8,7 @@ Linux-PAM NEWS -- history of user-visible changes.
pam_localuser, pam_mail, pam_motd, pam_nologin, pam_permit,
pam_rootok, pam_securetty, pam_shells, pam_userdb, pam_warn,
pam_time
+* The libpam memory debug code was removed
Release 0.99.4.0
diff --git a/configure.in b/configure.in
index 2478d41a..23faeab6 100644
--- a/configure.in
+++ b/configure.in
@@ -180,9 +180,14 @@ dnl
dnl options and defaults
dnl
-AM_PATH_LIBPRELUDE([0.9.0])
-if test "$LIBPRELUDE_CONFIG" != "no" ; then
- LIBPRELUDE_CFLAGS="$LIBPRELUDE_CFLAGS -DPRELUDE=1"
+AC_ARG_ENABLE([prelude],
+ AC_HELP_STRING([--disable-prelude],[do not use prelude]),
+ WITH_PRELUDE=$enableval, WITH_PRELUDE=yes)
+if test "$WITH_PRELUDE" == "yes" ; then
+ AM_PATH_LIBPRELUDE([0.9.0])
+ if test "$LIBPRELUDE_CONFIG" != "no" ; then
+ LIBPRELUDE_CFLAGS="$LIBPRELUDE_CFLAGS -DPRELUDE=1"
+ fi
fi
dnl lots of debugging information goes to /var/run/pam-debug.log
@@ -194,23 +199,6 @@ AC_ARG_ENABLE([debug],
WITH_DEBUG=no)
AC_SUBST(WITH_DEBUG)
-AC_ARG_ENABLE([memory-debug],
- AC_HELP_STRING([--enable-memory-debug],[specify you want every malloc etc. call tracked]),
- WITH_MEMORY_DEBUG=$enableval, WITH_MEMORY_DEBUG=no)
-if test "$WITH_MEMORY_DEBUG" != "no" ; then
- AC_DEFINE([MEMORY_DEBUG], 1, [Every malloc etc. call will be tracked])
-fi
-AH_VERBATIM([_MEMORY_DEBUG],
-[#ifdef MEMORY_DEBUG
-/*
- * this is basically a hack - we need to include a semiarbitrary
- * number of headers to ensure that we don't get silly prototype/macro
- */
-# include <string.h>
-# include <stdlib.h>
-# include <security/pam_malloc.h>
-#endif /* MEMORY_DEBUG */])
-
AC_ARG_ENABLE(securedir,
[ --enable-securedir=<path to location of PAMs> [default \$libdir/security]],
SECUREDIR=$enableval, SECUREDIR=$libdir/security)
diff --git a/libpam/Makefile.am b/libpam/Makefile.am
index a137a242..56d59f88 100644
--- a/libpam/Makefile.am
+++ b/libpam/Makefile.am
@@ -15,7 +15,7 @@ CLEANFILES = *~
EXTRA_DIST = libpam.map
include_HEADERS = $(addprefix include/security/, _pam_compat.h _pam_macros.h _pam_types.h \
- pam_appl.h pam_malloc.h pam_modules.h pam_ext.h pam_modutil.h)
+ pam_appl.h pam_modules.h pam_ext.h pam_modutil.h)
noinst_HEADERS = pam_prelude.h pam_private.h pam_tokens.h \
pam_modutil_private.h pam_static_modules.h
@@ -33,7 +33,7 @@ lib_LTLIBRARIES = libpam.la
libpam_la_SOURCES = pam_account.c pam_auth.c pam_data.c pam_delay.c \
pam_dispatch.c pam_end.c pam_env.c pam_handlers.c pam_item.c \
- pam_malloc.c pam_misc.c pam_password.c pam_prelude.c \
+ pam_misc.c pam_password.c pam_prelude.c \
pam_session.c pam_start.c pam_static.c pam_strerror.c \
pam_vprompt.c pam_syslog.c pam_dynamic.c pam_audit.c \
pam_modutil_cleanup.c pam_modutil_getpwnam.c pam_modutil_ioloop.c \
diff --git a/libpam/include/security/_pam_types.h b/libpam/include/security/_pam_types.h
index 85658f3b..45bae97b 100644
--- a/libpam/include/security/_pam_types.h
+++ b/libpam/include/security/_pam_types.h
@@ -212,15 +212,6 @@ pam_getenvlist(pam_handle_t *pamh);
#define HAVE_PAM_FAIL_DELAY
extern int pam_fail_delay(pam_handle_t *pamh, unsigned int musec_delay);
-#ifdef MEMORY_DEBUG
-/*
- * this defines some macros that keep track of what memory has been
- * allocated and indicates leakage etc... It should not be included in
- * production application/modules.
- */
-#include <security/pam_malloc.h>
-#endif
-
/* ------------ The Linux-PAM conversation structures ------------ */
/* Message styles */
diff --git a/libpam/libpam.map b/libpam/libpam.map
index 596754a8..1c2c4480 100644
--- a/libpam/libpam.map
+++ b/libpam/libpam.map
@@ -22,15 +22,6 @@ LIBPAM_1.0 {
local:
*;
};
-LIBPAM_MALLOC_DEBUG_1.0 {
- global:
- pam_malloc;
- pam_calloc;
- pam_free;
- pam_realloc;
- pam_exit;
- pam_strdup;
-};
LIBPAM_EXTENSION_1.0 {
global:
pam_prompt;
diff --git a/modules/pam_filter/upperLOWER/upperLOWER.c b/modules/pam_filter/upperLOWER/upperLOWER.c
index 314d2fed..c0fc5b17 100644
--- a/modules/pam_filter/upperLOWER/upperLOWER.c
+++ b/modules/pam_filter/upperLOWER/upperLOWER.c
@@ -1,6 +1,4 @@
/*
- * $Id$
- *
* This is a sample filter program, for use with pam_filter (a module
* provided with Linux-PAM). This filter simply transposes upper and
* lower case letters, it is intended for demonstration purposes and
@@ -9,10 +7,6 @@
#include "config.h"
-#ifdef MEMORY_DEBUG
-# undef exit
-#endif /* MEMORY_DEBUG */
-
#include <stdio.h>
#include <stdlib.h>
#include <syslog.h>
diff --git a/modules/pam_tally/pam_tally.c b/modules/pam_tally/pam_tally.c
index 12cb5bfa..66fc5f35 100644
--- a/modules/pam_tally/pam_tally.c
+++ b/modules/pam_tally/pam_tally.c
@@ -10,15 +10,12 @@
* Stuff stolen from pam_rootok and pam_listfile
*
* Changes by Tomas Mraz <tmraz@redhat.com> 5 January 2005
- * Audit option added for Tomas patch by Sebastien Tricaud <toady@gscore.org> 13 January 2005
+ * Audit option added for Tomas patch by
+ * Sebastien Tricaud <toady@gscore.org> 13 January 2005
*/
#include "config.h"
-#if defined(MAIN) && defined(MEMORY_DEBUG)
-# undef exit
-#endif /* defined(MAIN) && defined(MEMORY_DEBUG) */
-
#include <stdio.h>
#include <string.h>
#include <unistd.h>
diff --git a/modules/pam_unix/unix_chkpwd.c b/modules/pam_unix/unix_chkpwd.c
index d63387b6..407909a4 100644
--- a/modules/pam_unix/unix_chkpwd.c
+++ b/modules/pam_unix/unix_chkpwd.c
@@ -1,6 +1,4 @@
/*
- * $Id$
- *
* This program is designed to run setuid(root) or with sufficient
* privilege to read all of the unix password databases. It is designed
* to provide a mechanism for the current user (defined by this
@@ -15,12 +13,6 @@
#include "config.h"
-#ifdef MEMORY_DEBUG
-# undef exit
-# undef strdup
-# undef free
-#endif /* MEMORY_DEBUG */
-
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/po/POTFILES.in b/po/POTFILES.in
index d5f9890f..f6c996a3 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -68,7 +68,6 @@
./libpam/pam_session.c
./libpam/pam_prelude.c
./libpam/pam_account.c
-./libpam/pam_malloc.c
./libpam/pam_syslog.c
./libpam/pam_vprompt.c
./libpam/pam_modutil_getlogin.c