From c1de1178254c786d9cd4fe2b36f72e6e26778f57 Mon Sep 17 00:00:00 2001 From: Jasper Lievisse Adriaanse Date: Sat, 15 Apr 2017 09:39:13 +0200 Subject: Rename all PAM-independant variables/comments. there is nothing PAM-specific about pam_state or pam_state_t. therefore rename them to be authenticator independant. --- unlock_indicator.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'unlock_indicator.h') diff --git a/unlock_indicator.h b/unlock_indicator.h index acfe768..e4a8d8e 100644 --- a/unlock_indicator.h +++ b/unlock_indicator.h @@ -11,12 +11,12 @@ typedef enum { } unlock_state_t; typedef enum { - STATE_PAM_IDLE = 0, /* no PAM interaction at the moment */ - STATE_PAM_VERIFY = 1, /* currently verifying the password via PAM */ - STATE_PAM_LOCK = 2, /* currently locking the screen */ - STATE_PAM_WRONG = 3, /* the password was wrong */ + STATE_AUTH_IDLE = 0, /* no authenticator interaction at the moment */ + STATE_AUTH_VERIFY = 1, /* currently verifying the password via authenticator */ + STATE_AUTH_LOCK = 2, /* currently locking the screen */ + STATE_AUTH_WRONG = 3, /* the password was wrong */ STATE_I3LOCK_LOCK_FAILED = 4 /* i3lock failed to load */ -} pam_state_t; +} auth_state_t; xcb_pixmap_t draw_image(uint32_t* resolution); void redraw_screen(void); -- cgit v1.1 From 68fc2e8b5f8bcd203598e6da2a98d5aa7359af1e Mon Sep 17 00:00:00 2001 From: Jasper Lievisse Adriaanse Date: Sat, 15 Apr 2017 14:41:32 +0200 Subject: Use bsd_auth(3) instead of PAM on OpenBSD Also apply two security measures for OpenBSD: - use explicit_bzero(3) - mlock(2) works for non-root users too --- unlock_indicator.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'unlock_indicator.h') diff --git a/unlock_indicator.h b/unlock_indicator.h index e4a8d8e..2321620 100644 --- a/unlock_indicator.h +++ b/unlock_indicator.h @@ -11,10 +11,10 @@ typedef enum { } unlock_state_t; typedef enum { - STATE_AUTH_IDLE = 0, /* no authenticator interaction at the moment */ - STATE_AUTH_VERIFY = 1, /* currently verifying the password via authenticator */ - STATE_AUTH_LOCK = 2, /* currently locking the screen */ - STATE_AUTH_WRONG = 3, /* the password was wrong */ + STATE_AUTH_IDLE = 0, /* no authenticator interaction at the moment */ + STATE_AUTH_VERIFY = 1, /* currently verifying the password via authenticator */ + STATE_AUTH_LOCK = 2, /* currently locking the screen */ + STATE_AUTH_WRONG = 3, /* the password was wrong */ STATE_I3LOCK_LOCK_FAILED = 4 /* i3lock failed to load */ } auth_state_t; -- cgit v1.1