Skip to content

Commit

Permalink
Merge remote-tracking branch 'freebsd/stable/10' into hardened/10-sta…
Browse files Browse the repository at this point in the history
…ble/master
  • Loading branch information
opntr-auto committed Aug 25, 2015
2 parents c7b8c83 + 67ce47d commit 6e89331
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 8 deletions.
6 changes: 3 additions & 3 deletions crypto/openssh/monitor.c
Original file line number Diff line number Diff line change
Expand Up @@ -1027,9 +1027,7 @@ extern KbdintDevice sshpam_device;
int
mm_answer_pam_init_ctx(int sock, Buffer *m)
{

debug3("%s", __func__);
authctxt->user = buffer_get_string(m, NULL);
sshpam_ctxt = (sshpam_device.init_ctx)(authctxt);
sshpam_authok = NULL;
buffer_clear(m);
Expand Down Expand Up @@ -1111,14 +1109,16 @@ mm_answer_pam_respond(int sock, Buffer *m)
int
mm_answer_pam_free_ctx(int sock, Buffer *m)
{
int r = sshpam_authok != NULL && sshpam_authok == sshpam_ctxt;

debug3("%s", __func__);
(sshpam_device.free_ctx)(sshpam_ctxt);
sshpam_ctxt = sshpam_authok = NULL;
buffer_clear(m);
mm_request_send(sock, MONITOR_ANS_PAM_FREE_CTX, m);
auth_method = "keyboard-interactive";
auth_submethod = "pam";
return (sshpam_authok == sshpam_ctxt);
return r;
}
#endif

Expand Down
1 change: 0 additions & 1 deletion crypto/openssh/monitor_wrap.c
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,6 @@ mm_sshpam_init_ctx(Authctxt *authctxt)

debug3("%s", __func__);
buffer_init(&m);
buffer_put_cstring(&m, authctxt->user);
mm_request_send(pmonitor->m_recvfd, MONITOR_REQ_PAM_INIT_CTX, &m);
debug3("%s: waiting for MONITOR_ANS_PAM_INIT_CTX", __func__);
mm_request_receive_expect(pmonitor->m_recvfd, MONITOR_ANS_PAM_INIT_CTX, &m);
Expand Down
6 changes: 4 additions & 2 deletions crypto/openssh/mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,8 @@ process_mux_open_fwd(u_int rid, Channel *c, Buffer *m, Buffer *r)
u_int lport, cport;
int i, ret = 0, freefwd = 1;

fwd.listen_host = fwd.connect_host = NULL;
memset(&fwd, 0, sizeof(fwd));

if (buffer_get_int_ret(&ftype, m) != 0 ||
(fwd.listen_host = buffer_get_string_ret(m, NULL)) == NULL ||
buffer_get_int_ret(&lport, m) != 0 ||
Expand Down Expand Up @@ -783,7 +784,8 @@ process_mux_close_fwd(u_int rid, Channel *c, Buffer *m, Buffer *r)
int i, listen_port, ret = 0;
u_int lport, cport;

fwd.listen_host = fwd.connect_host = NULL;
memset(&fwd, 0, sizeof(fwd));

if (buffer_get_int_ret(&ftype, m) != 0 ||
(fwd.listen_host = buffer_get_string_ret(m, NULL)) == NULL ||
buffer_get_int_ret(&lport, m) != 0 ||
Expand Down
12 changes: 10 additions & 2 deletions sys/x86/include/_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,16 @@ typedef int ___wchar_t;
*/
#ifdef __GNUCLIKE_BUILTIN_VARARGS
typedef __builtin_va_list __va_list; /* internally known to gcc */
#elif defined(lint)
typedef char * __va_list; /* pretend */
#else
#ifdef __LP64__
struct __s_va_list {
__uint32_t _pad1[2]; /* gp_offset, fp_offset */
__uint64_t _pad2[2]; /* overflow_arg_area, reg_save_area */
};
typedef struct __s_va_list __va_list;
#else
typedef char * __va_list;
#endif
#endif
#if defined(__GNUC_VA_LIST_COMPATIBILITY) && !defined(__GNUC_VA_LIST) \
&& !defined(__NO_GNUC_VA_LIST)
Expand Down

0 comments on commit 6e89331

Please sign in to comment.