From c82d9c977c7fdf28ede2db15601edde1a5819511 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Wed, 5 Oct 2011 12:10:26 +0200 Subject: login: add login.defs code and tests The new logindefs.c file contains /etc/login.defs parser and functions for searching in the list of the login default variables. The patch also contains a new regression test for the code. Based on pam_login-4.0 from Suse. Signed-off-by: Karel Zak --- login-utils/logindefs.h | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 login-utils/logindefs.h (limited to 'login-utils/logindefs.h') diff --git a/login-utils/logindefs.h b/login-utils/logindefs.h new file mode 100644 index 000000000..37d19e1f7 --- /dev/null +++ b/login-utils/logindefs.h @@ -0,0 +1,9 @@ +#ifndef UTIL_LINUX_LOGINDEFS_H +#define UTIL_LINUX_LOGINDEFS_H + +extern int getlogindefs_bool(const char *name, int dflt); +extern long getlogindefs_num(const char *name, long dflt); +extern const char *getlogindefs_str(const char *name, const char *dflt); +extern void free_getlogindefs_data(void); + +#endif /* UTIL_LINUX_LOGINDEFS_H */ -- cgit v1.2.3-55-g7522