home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Pier Shareware 6
/
The_Pier_Shareware_Number_6_(The_Pier_Exchange)_(1995).iso
/
005
/
callb_28.zip
/
CALLBLOC.PPE
(
.txt
)
< prev
next >
Wrap
PCBoard Programming Language Executable
|
1994-08-25
|
8KB
|
424 lines
;------------------------------------------------------------------------------
; .ss.
; `²²'
; .,sS$Ss,,s$ .,sS$$$Ss. .,sS$Ss,,s$ .ss. .sSs.
; .d$$²^°²$$$$'.d$P²°^^²$P'.d$$²^°²$$$$'.$$$' .$$$²Sb,.
; $$$' .$$$' $$$²Sçsµ²' .$$$' .$$$'.$$$' .$$$' `$$b.
; $$$b,,d$$$' ,$$$b,....,s$$$$b,,d$$$'.$$$;.,$$$' ;$$$
; `²S$$S²²S$$S²°²S$$$$S²°°²S$$$$$$',$$S²°²S$S'.sS$$$P²'
; .sS²°$$$²²°"' d²°'
; .$$² .$$'
; $$$.,d$$'
; `²S$$S²'
;------------------------------------------------------------------------------
; P.P.L.X. 2.OO (C)1996 - Lone Runner / AEGiS CoRP'96
;------------------------------------------------------------------------------
; PPE 1.OO (plain) - Analysis ON - Postprocessing ON
;------------------------------------------------------------------------------
Boolean BOOLEAN001
Integer INTEGER001
Integer INTEGER002
Integer INTEGER003
Integer INTEGER004
Integer INTEGER005
Integer INTEGER006
Integer INTEGER007
Integer INTEGER008
Integer INTEGER009
Integer INTEGER010
Integer INTEGER011
Integer INTEGER012
String STRING001
String STRING002
String STRING003
String STRING004
String STRING005
String STRING006
String STRING007
String STRING008
String STRING009
String STRING010
String STRING011
String STRING012
String STRING013
String STRING014
String STRING015
String STRING016
String STRING017
String STRING018
String STRING019
String STRING020
String STRING021
String STRING022
String STRING023
String STRING024
String STRING025
String STRING026
String STRING027
String STRING028
;------------------------------------------------------------------------------
STRING003 = PPEPath() + "BAD-MSG"
STRING005 = PPEPath() + PPEName() + ".LOG"
STRING006 = PPEPath() + PPEName() + ".CFG"
STRING012 = PPEPath() + "BAD"
STRING019 = PPEPath() + "OVERRIDE.NUM"
STRING021 = PPEPath() + "BADCALL.NUM"
STRING024 = PPEPath() + "BLOK"
STRING025 = PPEPath() + "PRIV-MSG"
STRING026 = PPEPath() + "RECL"
STRING002 = "ANON"
BOOLEAN001 = 0
STRING004 = ""
STRING010 = ""
INTEGER003 = 10
INTEGER004 = 1
STRING014 = "------------------- [ Valid User Logon ] -------------------"
STRING013 = "============================================================"
STRING015 = "@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@"
STRING018 = "O"
STRING023 = "P"
STRING028 = "************************************************************"
PrintLn "@X0A...Searching Phone Records...Please Standby!...@X07"
PrintLn "@X0B....CALLBLOC v2.8 (c) 1993/94 by Al Segura....@X07"
DbgLevel 1
If (Exist(STRING006)) Then
FOpen 1, STRING006, 0, 0
Newline
SPrintLn "...Loading CID Records...(CALLBLOC.PPE)."
Newline
FGet 1, INTEGER005
FGet 1, INTEGER001
FGet 1, INTEGER012
FGet 1, INTEGER002
FGet 1, STRING016
FGet 1, STRING011
FGet 1, STRING001
FGet 1, INTEGER006
FGet 1, INTEGER003
FGet 1, INTEGER007
FClose 1
Else
Log "CALLBLOC.PPE using built-in defaults!", 1
INTEGER005 = 1
INTEGER001 = 0
INTEGER012 = 0
INTEGER002 = 1
STRING016 = "1"
STRING011 = "@X0EWhat is your FIRST name"
STRING001 = "SYSOP"
INTEGER006 = 0
INTEGER003 = 10
INTEGER007 = 0
Endif
If (OnLocal()) Then
Newline
PrintLn "@X0F...CALLBLOC.PPE is bypassed in LOCAL mode!@X07"
Log "LOCAL mode detected, CALLBLOC.PPE bypassed!", 1
Newline
Else
Select Case (STRING016)
Case "1"
STRING009 = "NMBR = "
Case "2"
STRING009 = "NUMBER: "
Case Else
STRING009 = STRING016
End Select
STRING010 = CallId()
If (STRING010 == "") Then
Log "No CALLERID info available!..(CALLBLOC.PPE)", 1
If (INTEGER006) Goto LABEL006
STRING022 = "BLANK!"
Goto LABEL008
Endif
INTEGER010 = InStr(STRING010, STRING009)
INTEGER008 = Len(STRING009)
If (INTEGER008 == 0) Then
Log "Your CID Key is BLANK! (CALLBLOC.PPE).", 1
Log "Verify proper CID Key for your modem!", 1
Goto LABEL008
ElseIf (INTEGER010 == 0) Then
Log "Could not find CID key: " + STRING009 + " (CALLBLOC.PPE).", 1
Log "Verify proper CID Key for your modem!", 1
Goto LABEL008
Endif
STRING022 = Upper(Trim(Mid(STRING010, INTEGER010 + INTEGER008, INTEGER003), " "))
If (Left(STRING022, 1) == STRING018) Then
Gosub LABEL010
Else
If (Len(STRING022) <> INTEGER003) Then
Log "CID Number not = " + String(INTEGER003) + " digits. (CALLBLOC.PPE).", 1
Goto LABEL008
Endif
For INTEGER010 = 1 To INTEGER003
If (InStr(Mask_Num(), Mid(STRING022, INTEGER010, 1)) == 0) Then
Log "Garbage found in CID number! (CALLBLOC.PPE).", 1
Goto LABEL008
Endif
Next
If ((Left(STRING022, 1) == STRING023) || InStr(Upper(STRING022), STRING002)) Then
Message 0, STRING001, "CALLBLOC.PPE", "Blocked Number User", "R", 0, 0, 0, STRING025
STRING014 = "<<<<<<<<<<<<<<<<<< [ BLOCKED User Logon ] >>>>>>>>>>>>>>>>>>"
Gosub LABEL010
If (Exist(STRING024)) Then
DispFile STRING024, 4 + 2 + 1
Else
Log "File BLOK is missing! (CALLBLOC.PPE).", 1
Endif
If (INTEGER012) Goto LABEL011
Else
If (Exist(STRING021)) Then
FOpen 2, STRING021, 0, 0
Newlines 2
FGet 2, STRING027
Gosub LABEL007
:LABEL001
If (Ferr(2)) Goto LABEL005
FGet 2, STRING027
If ((Len(STRING027) <> INTEGER003) && (STRING027 <> "")) Then
Log "Number in BADCALL.NUM is not correct digits! (CALLBLOC).", 1
Log "# read is: " + STRING027 + " (CALLBLOC).", 1
Endif
If (InStr(STRING027, STRING022)) Then
Goto LABEL009
ElseIf (InStr(Upper(STRING027), "XXXX")) Then
If (InStr(STRING027, Left(STRING022, Len(STRING027) - 4))) Then
If (Exist(STRING019)) Then
FOpen 1, STRING019, 0, 0
:LABEL002
If (Ferr(1)) Goto LABEL003
FGet 1, STRING020
If ((Len(STRING020) <> INTEGER003) && (STRING020 <> "")) Then
Log "Number in OVERRIDE.NUM is not correct digits! (CALLBLOC).", 1
Log "# read is: " + STRING020 + " (CALLBLOC).", 1
Endif
If (InStr(STRING020, STRING022)) Then
FClose 1
Log "Exchange Override number detected! (CALLBLOC.PPE)", 0
Goto LABEL004
Endif
Goto LABEL002
:LABEL003
FClose 1
Endif
Log "Exchange-Lockout number detected! (CALLBLOC.PPE)", 1
Goto LABEL009
Endif
Endif
:LABEL004
If (INTEGER007 == 0) FGet 2, STRING004
Goto LABEL001
:LABEL005
FClose 2
Else
Log "Can't find file BADCALL.NUM..(CALLBLOC.PPE).", 1
Newlines 2
PrintLn "@X0C....TELL SYSOP BADCALL.NUM file is missing!@X07"
Newlines 2
Goto LABEL006
Endif
Gosub LABEL010
Newline
SPrintLn "CALLBLOC.PPE Successfully Completed!"
Endif
Endif
Endif
:LABEL006
DbgLevel 0
Newlines 2
Print STRING011
End
:LABEL007
If (STRING027 == "1234567890") Then
SPrintLn
SPrintLn "..CallerID file integrity passed...(CALLBLOC.PPE)."
SPrintLn
Else
Sound 440
Delay 24
Sound 0
Delay 8
SPrintLn
SPrintLn "..CallerID file integrity FAILED!!...(CALLBLOC.PPE)."
SPrintLn
Log "CallerID file integrity FAILED! (CALLBLOC.PPE)", 1
Log STRING028, 1
FClose 2
Goto LABEL006
Endif
Return
:LABEL008
Log "CALLBLOC CID info faulty: " + STRING022, 1
STRING014 = "//////////////////// [ GARBAGE CID # ] \\\\\\\\\\\\\\\\\\\\"
Gosub LABEL010
If (Exist(STRING026)) Then
Newlines 6
StartDisp 1
DispFile STRING026, 4 + 2 + 1
Newlines 2
Else
Newlines 2
PrintLn "Tell SysOp file RECL is missing! (CALLBLOC.PPE)"
Newlines 2
Log "File RECL is now missing..(CALLBLOC.PPE).", 1
Endif
If (INTEGER002) Goto LABEL011
Goto LABEL006
:LABEL009
If (INTEGER007 == 0) FGet 2, STRING004
BOOLEAN001 = 1
FClose 2
CdChkOff
STRING014 = "****************** [ Invalid User Logon ] ******************"
Gosub LABEL010
Message 0, STRING001, "CALLBLOC.PPE", "BADBOY Called", "R", 0, 0, 0, STRING003
Log "BADBOY called again! Check Logs..(CALLBLOC.PPE).", 1
Cls
If (Exist(STRING012)) Then
Newlines 6
StartDisp 1
DispFile STRING012, 4 + 2 + 1
Newlines 2
Else
Log "The file BAD is missing..(CALLBLOC.PPE).", 1
Endif
CdChkOn
Goto LABEL011
:LABEL010
STRING017 = String(Date()) + " / " + String(Time())
INTEGER011 = InStr(STRING010, "NAME")
INTEGER009 = Len(STRING010) - INTEGER011 + 1
If (INTEGER011 > 0) Then
STRING007 = Left(STRING010, INTEGER011 - 1)
STRING008 = Mid(STRING010, INTEGER011, INTEGER009)
INTEGER004 = 2
Else
STRING007 = STRING010
Endif
If (!Exist(STRING005) && INTEGER005) Then
FCreate 1, STRING005, 2, 0
FPutLn 1, STRING015
FPutLn 1, "@@ CALLBLOC.PPE Log File @@"
FPutLn 1, STRING015
FPutLn 1, STRING014
FPutLn 1, Modem()
FPutLn 1, STRING007
If (INTEGER004 == 2) FPutLn 1, STRING008
FPutLn 1, STRING017
If ((BOOLEAN001 == 1) && (INTEGER007 == 0)) FPutLn 1, STRING004
FPutLn 1, STRING013
FClose 1
ElseIf (INTEGER005) Then
FAppend 1, STRING005, 2, 0
FPutLn 1, STRING014
FPutLn 1, Modem()
FPutLn 1, STRING007
If (INTEGER004 == 2) FPutLn 1, STRING008
FPutLn 1, STRING017
If ((BOOLEAN001 == 1) && (INTEGER007 == 0)) FPutLn 1, STRING004
FPutLn 1, STRING013
FClose 1
Endif
If (INTEGER001 == 1) Then
Log STRING007, 1
If (INTEGER004 == 2) Log STRING008, 1
Endif
Return
:LABEL011
Log STRING028, 1
DbgLevel 0
Hangup
End
;------------------------------------------------------------------------------
;
; Usage report (before postprocessing)
;
; ■ Statements used :
;
; 2 End
; 1 Cls
; 63 Goto
; 52 Let
; 1 Print
; 5 PrintLn
; 40 If
; 3 DispFile
; 1 FCreate
; 3 FOpen
; 1 FAppend
; 8 FClose
; 15 FGet
; 17 FPutLn
; 2 StartDisp
; 1 Hangup
; 26 Log
; 6 Gosub
; 2 Return
; 1 CdChkOn
; 1 CdChkOff
; 2 Delay
; 5 Newline
; 10 Newlines
; 2 Message
; 2 Sound
; 8 SPrintLn
; 3 DbgLevel
;
;
; ■ Functions used :
;
; 31 +
; 3 -
; 19 ==
; 5 <>
; 1 <
; 1 <=
; 1 >
; 2 >=
; 31 !
; 7 &&
; 2 ||
; 6 Len(
; 3 Upper()
; 3 Mid()
; 4 Left()
; 2 Ferr()
; 8 InStr()
; 1 Trim()
; 1 Date()
; 1 Time()
; 3 String()
; 1 Mask_Num()
; 9 PPEPath()
; 1 OnLocal()
; 1 CallId()
; 7 Exist()
; 2 PPEName()
; 2 Modem()
;
;------------------------------------------------------------------------------
;
; Analysis flags : B
;
; B - Brute hangup ■ 1
; Program hangup without notification. This may be a good way to
; disconnect a user, but if used randomly, may be very nasty
; ■ Search for : HANGUP, DTROFF
;
;------------------------------------------------------------------------------
;
; Postprocessing report
;
; 1 For/Next
; 0 While/EndWhile
; 25 If/Then or If/Then/Else
; 1 Select Case
;
;------------------------------------------------------------------------------
; AEGiS Corp - Break the routines, code against the machines!
;------------------------------------------------------------------------------