diff options
Diffstat (limited to 'security/openssh/files/patch-av')
| -rw-r--r-- | security/openssh/files/patch-av | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/security/openssh/files/patch-av b/security/openssh/files/patch-av new file mode 100644 index 000000000000..88cc6a43fd68 --- /dev/null +++ b/security/openssh/files/patch-av @@ -0,0 +1,39 @@ +--- auth.c.orif Thu Apr 20 17:21:58 2000 ++++ auth.c Thu Apr 20 17:50:06 2000 +@@ -26,7 +26,6 @@ + #include "session.h" + #include "dispatch.h" + +- + /* import */ + extern ServerOptions options; + extern char *forced_command; +@@ -106,6 +105,16 @@ + return 0; + } + } ++#ifdef __FreeBSD__ ++ /* Fail if the account's expiration time has passed. */ ++ if (pw->pw_expire != 0) { ++ struct timeval tv; ++ ++ (void)gettimeofday(&tv, NULL); ++ if (tv.tv_sec >= pw->pw_expire) ++ return 0; ++ } ++#endif /* __FreeBSD__ */ + /* We found no reason not to let this user try to log on... */ + return 1; + } +@@ -523,6 +532,11 @@ + pwcopy.pw_gid = pw->pw_gid; + pwcopy.pw_dir = xstrdup(pw->pw_dir); + pwcopy.pw_shell = xstrdup(pw->pw_shell); ++#ifdef __FreeBSD__ ++ pwcopy.pw_class = xstrdup(pw->pw_class); ++ pwcopy.pw_expire = pw->pw_expire; ++ pwcopy.pw_change = pw->pw_change; ++#endif /* __FreeBSD__ */ + pw = &pwcopy; + + /* |
