tomcat-11: fix mediator version and license
[oi-userland.git] / components / network / hpn-ssh / patches / 0016-PAM-setcred-failures.patch
blob70a2694efab004936fe8242d474d821675c5df93
1 --- hpn-ssh-hpn-18.4.2/auth-pam.c.orig
2 +++ hpn-ssh-hpn-18.4.2/auth-pam.c
3 @@ -1248,12 +1248,19 @@
4 sshpam_cred_established = 1;
5 return;
8 +#ifdef PAM_BUGFIX
9 + /* Server will fatal out when pam_setcred() failed. */
10 + fatal("PAM: pam_setcred(): %s", pam_strerror(sshpam_handle,
11 + sshpam_err));
12 +#else /* orig */
13 if (sshpam_authenticated)
14 fatal("PAM: pam_setcred(): %s",
15 pam_strerror(sshpam_handle, sshpam_err));
16 else
17 debug("PAM: pam_setcred(): %s",
18 pam_strerror(sshpam_handle, sshpam_err));
19 +#endif /* PAM_BUGFIX */
22 static int
23 @@ -1353,10 +1360,16 @@
24 if (sshpam_err == PAM_SUCCESS)
25 sshpam_session_open = 1;
26 else {
27 +#ifdef PAM_BUGFIX
28 + /* Server will fatal out when pam_open_session() failed */
29 + fatal("PAM: pam_open_session(): %s",
30 + pam_strerror(sshpam_handle, sshpam_err));
31 +#else /* orig */
32 sshpam_session_open = 0;
33 auth_restrict_session(ssh);
34 error("PAM: pam_open_session(): %s",
35 pam_strerror(sshpam_handle, sshpam_err));
36 +#endif /* PAM_BUGFIX */