CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2002
    Location
    NJ
    Posts
    1

    unix remote login from WIN C++ App ??

    I need to figure out a way to login to a unix box and run shell scripts from a C++ application running on a PC (WIN 2000). The unix box and PC are on a standard TCP/IP ethernet network. I have searched all over the internet and found nothing. Any suggestions would be great. Thanks.

  2. #2
    Join Date
    Feb 2001
    Location
    teh INTARWEB
    Posts
    542
    There are several options, two of which are:

    1. You can run an application on the unix box, listening at a particular port. Your application on the win32 box can connect to it (use sockets), authenticate itself, and then pass on the commands. Remember to run the unix application under a non-root / restricted user.

    2. A far easier method would be to use a C++ wrapper for Telnet protocol (google for it), utilize it to telnet to the unix box and run scripts on that box, you want. You may want to opt for SSH if there is sensitive data to be transmitted in this communication.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured