Deleted Added
sdiff udiff text old ( 303975 ) new ( 322343 )
full compact
1/* $OpenBSD: auth-passwd.c,v 1.44 2014/07/15 15:54:14 millert Exp $ */
2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
5 * All rights reserved
6 * Password authentication. This file contains the functions to check whether
7 * the password is valid for the user.
8 *

--- 52 unchanged lines hidden (view full) ---

61#ifdef HAVE_LOGIN_CAP
62extern login_cap_t *lc;
63#endif
64
65
66#define DAY (24L * 60 * 60) /* 1 day in seconds */
67#define TWO_WEEKS (2L * 7 * DAY) /* 2 weeks in seconds */
68
69void
70disable_forwarding(void)
71{
72 no_port_forwarding_flag = 1;
73 no_agent_forwarding_flag = 1;
74 no_x11_forwarding_flag = 1;
75}
76

--- 5 unchanged lines hidden (view full) ---

82auth_password(Authctxt *authctxt, const char *password)
83{
84 struct passwd * pw = authctxt->pw;
85 int result, ok = authctxt->valid;
86#if defined(USE_SHADOW) && defined(HAS_SHADOW_EXPIRE)
87 static int expire_checked = 0;
88#endif
89
90#ifndef HAVE_CYGWIN
91 if (pw->pw_uid == 0 && options.permit_root_login != PERMIT_YES)
92 ok = 0;
93#endif
94 if (*password == '\0' && options.permit_empty_passwd == 0)
95 return 0;
96
97#ifdef KRB5

--- 119 unchanged lines hidden ---