~ubuntu-branches/ubuntu/lucid/openssh/lucid

« back to all changes in this revision

Viewing changes to sshd.c

  • Committer: Bazaar Package Importer
  • Author(s): Colin Watson
  • Date: 2010-01-26 13:07:40 UTC
  • mfrom: (1.13.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20100126130740-d7r70jqrqlbvz3r0
Tags: 1:5.3p1-1ubuntu1
* Resynchronise with Debian.  Remaining changes:
  - Add support for registering ConsoleKit sessions on login.
  - Drop openssh-blacklist and openssh-blacklist-extra to Suggests; they
    take up a lot of CD space, and I suspect that rolling them out in
    security updates has covered most affected systems now.
  - Convert to Upstart.  The init script is still here for the benefit of
    people running sshd in chroots.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $OpenBSD: sshd.c,v 1.366 2009/01/22 10:02:34 djm Exp $ */
 
1
/* $OpenBSD: sshd.c,v 1.367 2009/05/28 16:50:16 andreas Exp $ */
2
2
/*
3
3
 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4
4
 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
117
117
#include "ssh-gss.h"
118
118
#endif
119
119
#include "monitor_wrap.h"
 
120
#include "roaming.h"
120
121
#include "version.h"
121
122
 
122
123
#ifdef USE_SECURITY_SESSION_API
430
431
        server_version_string = xstrdup(buf);
431
432
 
432
433
        /* Send our protocol version identification. */
433
 
        if (atomicio(vwrite, sock_out, server_version_string,
 
434
        if (roaming_atomicio(vwrite, sock_out, server_version_string,
434
435
            strlen(server_version_string))
435
436
            != strlen(server_version_string)) {
436
437
                logit("Could not write ident string to %s", get_remote_ipaddr());
440
441
        /* Read other sides version identification. */
441
442
        memset(buf, 0, sizeof(buf));
442
443
        for (i = 0; i < sizeof(buf) - 1; i++) {
443
 
                if (atomicio(read, sock_in, &buf[i], 1) != 1) {
 
444
                if (roaming_atomicio(read, sock_in, &buf[i], 1) != 1) {
444
445
                        logit("Did not receive identification string from %s",
445
446
                            get_remote_ipaddr());
446
447
                        cleanup_exit(255);
588
589
static void
589
590
privsep_preauth_child(void)
590
591
{
591
 
        u_int32_t rnd[256];
 
592
        u_int32_t rnd[256];
592
593
        gid_t gidset[1];
593
594
 
594
595
        /* Enable challenge-response authentication for privilege separation */