home *** CD-ROM | disk | FTP | other *** search
/ CD-ROM Magazin 1996 March / CD_03_96.BIN / direct / qsockpro.qip / ALLCON.MPS < prev    next >
Text File  |  1996-02-14  |  1KB  |  70 lines

  1. # Allcon Flensburg Germany PPP/SLIP/CSLIP login
  2. # 08/08/95 BC
  3.  
  4. String username
  5. String password
  6. String framing
  7. String IPAddress
  8.  
  9. # Trace on
  10. SetTimeout 60
  11.  
  12. CfgGetValue "Username" username
  13. if result = 0 then
  14.         GetInput "Enter your user name" username
  15.     if result = 0 then
  16.         Print "Warning, no username entered"
  17.     else
  18.         Print "Username set to ["; username; "]"
  19.     endif
  20. endif
  21.  
  22. CfgGetValue "Password" password
  23. if result = 0 then
  24.         GetPassword "Enter your password" password
  25.     if result = 0 then
  26.         Print "Warning, no password entered"
  27.     else
  28.         Print "Password set."
  29.     endif
  30. endif
  31.  
  32. CfgGetValue "Framing" framing
  33. if result = 0 then
  34.     Abort "Can't read 'Framing' setting from qdeck.ini"
  35. endif
  36.  
  37. # Start login proc...
  38.     CommWaitFor    "ost:"
  39. if framing = "MPSLIP" then
  40.     CommSend        "slip"        # Set Protocol to VJSLIP/SLIP
  41.     CommSend    "%r"
  42. else
  43.     CommSend        "ppp"        # Set Protocol to VJPPP/PPP
  44.     CommSend    "%r"
  45. endif
  46.     CommWaitFor    "ogin:"
  47. if framing = "MPSLIP" then
  48.     CommSend    "CS"        # CS for VJSLIP, S for SLIP
  49. else
  50.     CommSend    "P"        # P for VJPPP/PPP
  51. endif
  52.     CommSend    username
  53.     CommSend    "%r"
  54.     CommWaitFor    "word:"
  55.     CommSend    password
  56.     CommSend    "%r"
  57.  
  58. if framing = "MPSLIP" then
  59.     CommWaitFor    ") to"
  60.     CommReadIPAddr    IPAddress
  61.     CfgSetValue    "IPAddress"    IPaddress
  62.     Print    ""
  63.     Print    "IP Address set to ["; IPAddress; "]"
  64. else
  65.     Print    "Framing is PPP"
  66. endif
  67.  
  68. END
  69.  
  70.