Category : Communication (modem) tools and utilities
Archive   : GE_CIS.ZIP
Filename : CIS.SLT

 
Output of file : CIS.SLT contained in archive : GE_CIS.ZIP
// Telix control file -- cis.slt

// Place your ID NO in parentheses in the name field of the
// dialing directory. eg: CIS (XXXXXXX,XXXX)
// Place your password in the field reserved for it in the
// dialing directory.

str user_name[14]; // ID NO extracted from entryname
str errmsg[65]; // Error messages generated by script

main()
{
str dial_no[3] = "3"; // Dial directory entry to dial
int dial_trys = 5; // Matrix - Dial five times if necessary
int link = 1; // Ignore any linked script when dialing

clear_scr();
if (dial(dial_no, dial_trys, link) != stoi(dial_no)) {
errmsg = "Dialing failure -- Aborting.";
errprint();
return;
}
if (username()) {
errprint();
return;
}
if (cislogon()) {
errprint();
return;
}
comm();
hangup();
}
username()
// Extracts user id from inside parentheses in dialing directory name.
// Returns value of 1 and "error in errmsg if parentheses not found.
{
int dstart, dfinish, dchars;

dstart = strposi(_entry_name,"(",0);
dfinish = strposi(_entry_name,")",0);
if (dstart != -1) {
if (dfinish != -1) {
dstart = dstart + 1;
dchars = dfinish - dstart;
substr(_entry_name,dstart,dchars,user_name);
return(0);
}
else {
errmsg = "Missing ( in directory entry name -- Aborting.";
return(1);
}
}
else {
errmsg = "Missing ) in directory entry name -- Aborting.";
return(1);
}
}
cislogon()
// Logon to CIS.
// Returns value of 1 and "error" in errmsg if failure.
{
str attn_msg[5] = "^C", id_req[5] = "ID:", pw_req[6] = "word:";

cputs(attn_msg);
if(waitfor(id_req, 600)) { // Wait for ID request
cputs(user_name); // Send ID number
cputs("^M");
if(waitfor(pw_req, 600)) {
cputs(_entry_pass); // Send password
cputs("^M");
return (0); // Return - all okay...
}
}
errmsg = ("Logon Failure!");
return(1); // Return - failure...
}
comm()
// Open logfile, deleting old one.
// Call read(lookfor) to read incoming text & look for log-off.
// Close Logfile after log-off is detected.
{
str fspec[25] = "c:\comm\tlx\cis.log", buf[20], cmand[24] = "del ";
str logoff[14] = "time =";
str log_found[40] = "CIS.LOG Found... Deleted.";
str log_open[40] = "Opening Capture file... CIS.LOG";
str log_close[40] ="Closing Capture file... CIS.LOG";

capture("*CLOSE*");
if (filefind(fspec, 0, buf)) {
strcat(cmand, fspec);
dos(cmand, 0);
status_wind(log_found, 20);
}
if (capture(fspec) == -1)
status_wind("Error opening capture file.", 20);
status_wind(log_open, 20);
read(logoff);
delay_scr(20);
capture("*CLOSE*");
status_wind(log_close, 15);
}
read(str lookfor)
// Operates in terminal mode, tracks for the string 'lookfor'
// passed by calling function and returns control when it is found.
{
int stat, t1;

t1 = track(lookfor, 0);
while (1) {
terminal();
if(track_hit(0) == t1)
break;
}
track_free(0); // Free those track channels.
}
errprint()
// Print errmsg and hangup the phone
{
status_wind(errmsg, 30);
hangup();
}


  3 Responses to “Category : Communication (modem) tools and utilities
Archive   : GE_CIS.ZIP
Filename : CIS.SLT

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/