version 1.87, 2021/01/20 07:30:51 |
version 1.88, 2021/01/21 08:13:59 |
|
|
auth_session_t *as; |
auth_session_t *as; |
int fd = -1; |
int fd = -1; |
|
|
if (persist) { |
if (persist) |
fd = open("/dev/tty", O_RDWR); |
fd = open("/dev/tty", O_RDWR); |
if (fd != -1) { |
if (fd != -1) { |
if (ioctl(fd, TIOCCHKVERAUTH) == 0) |
if (ioctl(fd, TIOCCHKVERAUTH) == 0) |
goto good; |
goto good; |
} |
|
} else { |
|
if (pledge("stdio rpath getpw exec id unveil", NULL) == -1) |
|
err(1, "pledge"); |
|
} |
} |
|
|
if (!(as = auth_userchallenge(myname, login_style, "auth-doas", |
if (!(as = auth_userchallenge(myname, login_style, "auth-doas", |