[9fans] sshserve.c - Plan9

This is a discussion on [9fans] sshserve.c - Plan9 ; Hello, In sshserve.c: void usage(void) { fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip- address\n"); usage(); } This code can make endless loop. Right? Kenji Arisawa...

+ Reply to Thread
Results 1 to 14 of 14

Thread: [9fans] sshserve.c

  1. [9fans] sshserve.c

    Hello,

    In sshserve.c:

    void
    usage(void)
    {
    fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    address\n");
    usage();
    }

    This code can make endless loop. Right?

    Kenji Arisawa



  2. Re: [9fans] sshserve.c

    Yup. usage() is calling itself with no termination condition - and
    what's more, it is tail recursing. It should be

    void
    usage(void)
    {
    fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    address\n");
    exits("usage");
    }

    to keep with the Plan 9 program. Enjoy!

    When this QEMU-on-Leopard-freezes-randomly bug gets fixed, I can fix
    it and any other dangers.

    On Apr 15, 2008, at 6:05 PM, Kenji Arisawa wrote:

    > Hello,
    >
    > In sshserve.c:
    >
    > void
    > usage(void)
    > {
    > fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    > address\n");
    > usage();
    > }
    >
    > This code can make endless loop. Right?
    >
    > Kenji Arisawa
    >
    >




  3. Re: [9fans] sshserve.c

    > Yup. usage() is calling itself with no termination condition - and
    > what's more, it is tail recursing. It should be
    >
    > void
    > usage(void)
    > {
    > fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    > address\n");
    > exits("usage");
    > }
    >
    > to keep with the Plan 9 program. Enjoy!
    >
    > When this QEMU-on-Leopard-freezes-randomly bug gets fixed, I can fix
    > it and any other dangers.
    >
    > On Apr 15, 2008, at 6:05 PM, Kenji Arisawa wrote:
    >
    >> Hello,
    >>
    >> In sshserve.c:
    >>
    >> void
    >> usage(void)
    >> {
    >> fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    >> address\n");
    >> usage();
    >> }
    >>
    >> This code can make endless loop. Right?
    >>
    >> Kenji Arisawa
    >>
    >>


    Submit a patch!
    And don't top-post, damn it. We aren't all MicroSavages here.


    John



  4. Re: [9fans] sshserve.c

    On Apr 15, 2008, at 6:34 PM, john@csplan9.rit.edu wrote:

    >> Yup. usage() is calling itself with no termination condition - and
    >> what's more, it is tail recursing. It should be
    >>
    >> void
    >> usage(void)
    >> {
    >> fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    >> address\n");
    >> exits("usage");
    >> }
    >>
    >> to keep with the Plan 9 program. Enjoy!
    >>
    >> When this QEMU-on-Leopard-freezes-randomly bug gets fixed, I can fix
    >> it and any other dangers.
    >>
    >> On Apr 15, 2008, at 6:05 PM, Kenji Arisawa wrote:
    >>
    >>> Hello,
    >>>
    >>> In sshserve.c:
    >>>
    >>> void
    >>> usage(void)
    >>> {
    >>> fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    >>> address\n");
    >>> usage();
    >>> }
    >>>
    >>> This code can make endless loop. Right?
    >>>
    >>> Kenji Arisawa
    >>>
    >>>

    >
    > Submit a patch!
    > And don't top-post, damn it. We aren't all MicroSavages here.
    >
    >
    > John
    >
    >

    I'm on OS X, and again, I can't have QEMU crash just before rio starts!\



  5. Re: [9fans] sshserve.c

    >> Yup. usage() is calling itself with no termination condition - and
    >> what's more, it is tail recursing. It should be
    >>
    >> void
    >> usage(void)
    >> {
    >> fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    >> address\n");
    >> exits("usage");
    >> }
    >>
    >> to keep with the Plan 9 program. Enjoy!
    >>
    >> When this QEMU-on-Leopard-freezes-randomly bug gets fixed, I can fix
    >> it and any other dangers.
    >>
    >> On Apr 15, 2008, at 6:05 PM, Kenji Arisawa wrote:
    >>
    >>> Hello,
    >>>
    >>> In sshserve.c:
    >>>
    >>> void
    >>> usage(void)
    >>> {
    >>> fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-ip-
    >>> address\n");
    >>> usage();
    >>> }
    >>>
    >>> This code can make endless loop. Right?
    >>>
    >>> Kenji Arisawa
    >>>
    >>>

    >
    > Submit a patch!
    > And don't top-post, damn it. We aren't all MicroSavages here.
    >
    >
    > John


    please explain why bottom posting is better.

    - erik

    p.s. ☺



  6. Re: [9fans] sshserve.c

    Thanks Pietro,

    I am glad if someone can help me.
    Using MacFUSE + sshfs, I have:
    -bash$ sshfs ar.aichi-u.ac.jp: /n/ar
    remote host has disconnected
    -bash$
    Then /sys/log/ssh says:
    ar Apr 16 07:53:15 [359853] connect from 124.241.154.73!53142
    /bin/aux/sshserve: reading server version: unexpected EOF

    The host ar is a Plan 9 cpu server servicing tcp22 as
    exec /bin/aux/sshserve -A 'password' `{cat $3/remote} >>[2]/
    sys/log/ssh

    Of course I can connect to ar using
    ssh ar.aichi-u.ac.jp

    Kenji Arisawa

    On 2008/04/16, at 7:29, Pietro Gagliardi wrote:
    > Yup. usage() is calling itself with no termination condition - and
    > what's more, it is tail recursing. It should be
    >
    > void
    > usage(void)
    > {
    > fprint(2, "usage: sshserve [-A authlist] [-c cipherlist] client-
    > ip-address\n");
    > exits("usage");
    > }
    >
    > to keep with the Plan 9 program. Enjoy!
    >
    > When this QEMU-on-Leopard-freezes-randomly bug gets fixed, I can
    > fix it and any other dangers.
    >



  7. Re: [9fans] sshserve.c

    eric quanstrom wrote:
    >
    > please explain why bottom posting is better.
    >
    > - erik
    >
    > p.s. ☺


    Because it screws up conversation order.
    >Why is top-posting bad?
    >>Top-posting.
    >>>What is the most annoying thing on Usenet?




  8. Re: [9fans] sshserve.c

    > Because it screws up conversation order.

    that depends if you think a conversation is a stack or a heap.

    - erik



  9. Re: [9fans] sshserve.c

    On Tue, 2008-04-15 at 19:17 -0400, erik quanstrom wrote:
    > > Because it screws up conversation order.

    >
    > that depends if you think a conversation is a stack or a heap.


    And even if it is a stack -- which way it grows.

    Thanks,
    Roman.



  10. Re: [9fans] sshserve.c

    > Using MacFUSE + sshfs, I have:
    > -bash$ sshfs ar.aichi-u.ac.jp: /n/ar
    > remote host has disconnected
    > -bash$
    > Then /sys/log/ssh says:
    > ar Apr 16 07:53:15 [359853] connect from 124.241.154.73!53142
    > /bin/aux/sshserve: reading server version: unexpected EOF


    I don't believe the Plan 9 ssh supports the protocol
    that sshfs needs, which is sftp not scp.

    I apologize for dragging this conversation back on topic.

    Russ



  11. Re: [9fans] sshserve.c

    On Wed, Apr 16, 2008 at 12:29 PM, Russ Cox wrote:
    > > Using MacFUSE + sshfs, I have:
    > > -bash$ sshfs ar.aichi-u.ac.jp: /n/ar
    > > remote host has disconnected
    > > -bash$
    > > Then /sys/log/ssh says:
    > > ar Apr 16 07:53:15 [359853] connect from 124.241.154.73!53142
    > > /bin/aux/sshserve: reading server version: unexpected EOF

    >
    > I don't believe the Plan 9 ssh supports the protocol
    > that sshfs needs, which is sftp not scp.
    >
    > I apologize for dragging this conversation back on topic.
    >
    > Russ


    We did learn thet pietro doesn't actually run plan9. God knows what
    his responses will be when he finishes his Gedankenexperiment stage.

    But yeah, ssh has limited protocol support. Fix it or complain someone.

    brucee


  12. Re: [9fans] sshserve.c

    On Apr 15, 2008, at 11:30 PM, Bruce Ellis wrote:

    > On Wed, Apr 16, 2008 at 12:29 PM, Russ Cox wrote:
    >>> Using MacFUSE + sshfs, I have:
    >>> -bash$ sshfs ar.aichi-u.ac.jp: /n/ar
    >>> remote host has disconnected
    >>> -bash$
    >>> Then /sys/log/ssh says:
    >>> ar Apr 16 07:53:15 [359853] connect from 124.241.154.73!53142
    >>> /bin/aux/sshserve: reading server version: unexpected EOF

    >>
    >> I don't believe the Plan 9 ssh supports the protocol
    >> that sshfs needs, which is sftp not scp.
    >>
    >> I apologize for dragging this conversation back on topic.
    >>
    >> Russ

    >
    > We did learn thet pietro doesn't actually run plan9. God knows what
    > his responses will be when he finishes his Gedankenexperiment stage.


    Since when is virtualization not running an OS? Please speak up. I
    have been running Plan 9 on my virtualization software for months. If
    you look for my virtualizer review on thinkmac.net, you will notice it
    in one of the screenshots.

    >
    >
    > But yeah, ssh has limited protocol support. Fix it or complain
    > someone.
    >
    > brucee
    >




  13. Re: [9fans] sshserve.c

    On Wed, Apr 16, 2008 at 10:12 PM, Pietro Gagliardi wrote:
    > On Apr 15, 2008, at 11:30 PM, Bruce Ellis wrote:
    >
    > > On Wed, Apr 16, 2008 at 12:29 PM, Russ Cox wrote:
    > >
    > > >
    > > > > Using MacFUSE + sshfs, I have:
    > > > > -bash$ sshfs ar.aichi-u.ac.jp: /n/ar
    > > > > remote host has disconnected
    > > > > -bash$
    > > > > Then /sys/log/ssh says:
    > > > > ar Apr 16 07:53:15 [359853] connect from 124.241.154.73!53142
    > > > > /bin/aux/sshserve: reading server version: unexpected EOF
    > > > >
    > > >
    > > > I don't believe the Plan 9 ssh supports the protocol
    > > > that sshfs needs, which is sftp not scp.
    > > >
    > > > I apologize for dragging this conversation back on topic.
    > > >
    > > > Russ
    > > >

    > >
    > > We did learn thet pietro doesn't actually run plan9. God knows what
    > > his responses will be when he finishes his Gedankenexperiment stage.
    > >

    >
    > Since when is virtualization not running an OS? Please speak up. I have
    > been running Plan 9 on my virtualization software for months. If you look
    > for my virtualizer review on thinkmac.net, you will notice it in one of the
    > screenshots.
    >


    You seem to be particularly confused today. After stressing that you
    can't submit a patch because your plan9 doesn't work you say this. Oh
    why do I bother.

    brucee


  14. Re: [9fans] sshserve.c

    Sshfs uses ssh to start a file server program (generally called sftp) on the remote server.

    Under sshv2 this is described as an external subsystem, i.e. a specific message is sent
    to the server to start the file server subsystem.

    Under sshv1 which is what the plan9 ssh server supports, the client needs to envoke
    sftp binary directly.

    I believe the sftp binary from the openssh port should "just work" if the fuse sshfs port
    is capable of working with sshv1 and being told the command to send.

    sftp in this context is unrelated to the port 115 simple file transfer protocol (sadly also
    known as SFTP) nor to the traditional port 21 ftp server.

    an sftp client for plan9 has been on my todo list for... years.

    -Steve


+ Reply to Thread