aboutsummaryrefslogtreecommitdiff
path: root/include/libbb.h
diff options
context:
space:
mode:
authorKaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>2016-01-02 00:20:39 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2017-04-13 12:39:03 +0200
commit517a82c5b6b5e279f3e96a6774445a2952ca312b (patch)
tree5eff7ec6bb69bceedcea35fce37cf0e4380fea82 /include/libbb.h
parentc054822027a4a6895bc95979c6c10ff5763c7c7e (diff)
downloadbusybox-517a82c5b6b5e279f3e96a6774445a2952ca312b.tar.gz
login: move check_securetty to libbb
Signed-off-by: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'include/libbb.h')
-rw-r--r--include/libbb.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 777a4a884..6b33ffad6 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -1481,6 +1481,11 @@ extern void selinux_or_die(void) FAST_FUNC;
#define SETUP_ENV_NO_CHDIR (1 << 4)
void setup_environment(const char *shell, int flags, const struct passwd *pw) FAST_FUNC;
void nuke_str(char *str) FAST_FUNC;
+#if ENABLE_FEATURE_SECURETTY && !ENABLE_PAM
+int check_securetty(const char *short_tty) FAST_FUNC;
+#else
+static ALWAYS_INLINE int check_securetty(const char *short_tty UNUSED_PARAM) { return 1; }
+#endif
int check_password(const struct passwd *pw, const char *plaintext) FAST_FUNC;
int ask_and_check_password_extended(const struct passwd *pw, int timeout, const char *prompt) FAST_FUNC;
int ask_and_check_password(const struct passwd *pw) FAST_FUNC;