home *** CD-ROM | disk | FTP | other *** search
Unknown | 1999-09-27 | 2.6 KB |
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was not able to be converted.
This format is not currently supported by dexvert.
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| file
| data
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 00 00 00 00 00 00 00 | 7d 29 63 6c 61 73 73 20 |........|})class |
|00000010| 57 65 62 53 65 72 76 65 | 72 20 65 78 70 61 6e 64 |WebServe|r expand|
|00000020| 73 20 54 63 70 4c 69 6e | 6b 3b 0d 0a 0d 0a 76 61 |s TcpLin|k;....va|
|00000030| 72 20 63 6f 6e 66 69 67 | 20 73 74 72 69 6e 67 20 |r config| string |
|00000040| 41 70 70 6c 69 63 61 74 | 69 6f 6e 73 5b 31 30 5d |Applicat|ions[10]|
|00000050| 3b 0d 0a 76 61 72 20 63 | 6f 6e 66 69 67 20 73 74 |;..var c|onfig st|
|00000060| 72 69 6e 67 20 41 70 70 | 6c 69 63 61 74 69 6f 6e |ring App|lication|
|00000070| 50 61 74 68 73 5b 31 30 | 5d 3b 0d 0a 76 61 72 20 |Paths[10|];..var |
|00000080| 63 6f 6e 66 69 67 20 69 | 6e 74 20 4c 69 73 74 65 |config i|nt Liste|
|00000090| 6e 50 6f 72 74 3b 0d 0a | 76 61 72 20 63 6f 6e 66 |nPort;..|var conf|
|000000a0| 69 67 20 69 6e 74 20 4d | 61 78 43 6f 6e 6e 65 63 |ig int M|axConnec|
|000000b0| 74 69 6f 6e 73 3b 0d 0a | 76 61 72 20 63 6f 6e 66 |tions;..|var conf|
|000000c0| 69 67 20 73 74 72 69 6e | 67 20 53 65 72 76 65 72 |ig strin|g Server|
|000000d0| 4e 61 6d 65 3b 0d 0a 76 | 61 72 20 63 6f 6e 66 69 |Name;..v|ar confi|
|000000e0| 67 20 62 6f 6f 6c 20 62 | 45 6e 61 62 6c 65 64 3b |g bool b|Enabled;|
|000000f0| 0d 0a 0d 0a 76 61 72 20 | 73 74 72 69 6e 67 20 53 |....var |string S|
|00000100| 65 72 76 65 72 55 52 4c | 3b 0d 0a 76 61 72 20 57 |erverURL|;..var W|
|00000110| 65 62 41 70 70 6c 69 63 | 61 74 69 6f 6e 20 41 70 |ebApplic|ation Ap|
|00000120| 70 6c 69 63 61 74 69 6f | 6e 4f 62 6a 65 63 74 73 |plicatio|nObjects|
|00000130| 5b 31 30 5d 3b 0d 0a 0d | 0a 76 61 72 20 69 6e 74 |[10];...|.var int|
|00000140| 20 43 6f 6e 6e 65 63 74 | 69 6f 6e 43 6f 75 6e 74 | Connect|ionCount|
|00000150| 3b 0d 0a 0d 0a 66 75 6e | 63 74 69 6f 6e 20 42 65 |;....fun|ction Be|
|00000160| 67 69 6e 50 6c 61 79 28 | 29 0d 0a 7b 0d 0a 09 6c |ginPlay(|)..{...l|
|00000170| 6f 63 61 6c 20 69 6e 74 | 20 69 3b 0d 0a 09 6c 6f |ocal int| i;...lo|
|00000180| 63 61 6c 20 63 6c 61 73 | 73 3c 57 65 62 41 70 70 |cal clas|s<WebApp|
|00000190| 6c 69 63 61 74 69 6f 6e | 3e 20 41 70 70 6c 69 63 |lication|> Applic|
|000001a0| 61 74 69 6f 6e 43 6c 61 | 73 73 3b 0d 0a 09 6c 6f |ationCla|ss;...lo|
|000001b0| 63 61 6c 20 49 70 41 64 | 64 72 20 6c 3b 0d 0a 09 |cal IpAd|dr l;...|
|000001c0| 6c 6f 63 61 6c 20 73 74 | 72 69 6e 67 20 73 3b 0d |local st|ring s;.|
|000001d0| 0a 0d 0a 09 69 66 28 21 | 62 45 6e 61 62 6c 65 64 |....if(!|bEnabled|
|000001e0| 29 0d 0a 09 7b 0d 0a 09 | 09 4c 6f 67 28 22 57 65 |)...{...|.Log("We|
|000001f0| 62 73 65 72 76 65 72 20 | 69 73 20 6e 6f 74 20 65 |bserver |is not e|
|00000200| 6e 61 62 6c 65 64 2e 20 | 20 53 65 74 20 62 45 6e |nabled. | Set bEn|
|00000210| 61 62 6c 65 64 20 74 6f | 20 54 72 75 65 20 69 6e |abled to| True in|
|00000220| 20 41 64 76 61 6e 63 65 | 64 20 4f 70 74 69 6f 6e | Advance|d Option|
|00000230| 73 2e 22 29 3b 0d 0a 09 | 09 44 65 73 74 72 6f 79 |s.");...|.Destroy|
|00000240| 28 29 3b 0d 0a 09 09 72 | 65 74 75 72 6e 3b 0d 0a |();....r|eturn;..|
|00000250| 09 7d 0d 0a 0d 0a 09 53 | 75 70 65 72 2e 42 65 67 |.}.....S|uper.Beg|
|00000260| 69 6e 50 6c 61 79 28 29 | 3b 0d 0a 09 0d 0a 09 66 |inPlay()|;......f|
|00000270| 6f 72 28 69 3d 30 3b 69 | 3c 31 30 3b 69 2b 2b 29 |or(i=0;i|<10;i++)|
|00000280| 0d 0a 09 7b 0d 0a 09 09 | 69 66 28 41 70 70 6c 69 |...{....|if(Appli|
|00000290| 63 61 74 69 6f 6e 73 5b | 69 5d 20 3d 3d 20 22 22 |cations[|i] == ""|
|000002a0| 29 0d 0a 09 09 09 62 72 | 65 61 6b 3b 0d 0a 0d 0a |).....br|eak;....|
|000002b0| 09 09 41 70 70 6c 69 63 | 61 74 69 6f 6e 43 6c 61 |..Applic|ationCla|
|000002c0| 73 73 20 3d 20 63 6c 61 | 73 73 3c 57 65 62 41 70 |ss = cla|ss<WebAp|
|000002d0| 70 6c 69 63 61 74 69 6f | 6e 3e 28 44 79 6e 61 6d |plicatio|n>(Dynam|
|000002e0| 69 63 4c 6f 61 64 4f 62 | 6a 65 63 74 28 41 70 70 |icLoadOb|ject(App|
|000002f0| 6c 69 63 61 74 69 6f 6e | 73 5b 69 5d 2c 20 63 6c |lication|s[i], cl|
|00000300| 61 73 73 27 43 6c 61 73 | 73 27 29 29 3b 0d 0a 09 |ass'Clas|s'));...|
|00000310| 09 69 66 28 41 70 70 6c | 69 63 61 74 69 6f 6e 43 |.if(Appl|icationC|
|00000320| 6c 61 73 73 20 21 3d 20 | 4e 6f 6e 65 29 0d 0a 09 |lass != |None)...|
|00000330| 09 7b 0d 0a 09 09 09 41 | 70 70 6c 69 63 61 74 69 |.{.....A|pplicati|
|00000340| 6f 6e 4f 62 6a 65 63 74 | 73 5b 69 5d 20 3d 20 4e |onObject|s[i] = N|
|00000350| 65 77 28 4e 6f 6e 65 29 | 20 41 70 70 6c 69 63 61 |ew(None)| Applica|
|00000360| 74 69 6f 6e 43 6c 61 73 | 73 3b 0d 0a 09 09 09 41 |tionClas|s;.....A|
|00000370| 70 70 6c 69 63 61 74 69 | 6f 6e 4f 62 6a 65 63 74 |pplicati|onObject|
|00000380| 73 5b 69 5d 2e 4c 65 76 | 65 6c 20 3d 20 4c 65 76 |s[i].Lev|el = Lev|
|00000390| 65 6c 3b 0d 0a 09 09 09 | 41 70 70 6c 69 63 61 74 |el;.....|Applicat|
|000003a0| 69 6f 6e 4f 62 6a 65 63 | 74 73 5b 69 5d 2e 57 65 |ionObjec|ts[i].We|
|000003b0| 62 53 65 72 76 65 72 20 | 3d 20 53 65 6c 66 3b 0d |bServer |= Self;.|
|000003c0| 0a 09 09 09 41 70 70 6c | 69 63 61 74 69 6f 6e 4f |....Appl|icationO|
|000003d0| 62 6a 65 63 74 73 5b 69 | 5d 2e 50 61 74 68 20 3d |bjects[i|].Path =|
|000003e0| 20 41 70 70 6c 69 63 61 | 74 69 6f 6e 50 61 74 68 | Applica|tionPath|
|000003f0| 73 5b 69 5d 3b 0d 0a 09 | 09 09 41 70 70 6c 69 63 |s[i];...|..Applic|
|00000400| 61 74 69 6f 6e 4f 62 6a | 65 63 74 73 5b 69 5d 2e |ationObj|ects[i].|
|00000410| 49 6e 69 74 28 29 3b 0d | 0a 09 09 7d 0d 0a 09 7d |Init();.|...}...}|
|00000420| 0d 0a 0d 0a 09 69 66 28 | 53 65 72 76 65 72 4e 61 |.....if(|ServerNa|
|00000430| 6d 65 20 3d 3d 20 22 22 | 29 0d 0a 09 7b 0d 0a 09 |me == ""|)...{...|
|00000440| 09 47 65 74 4c 6f 63 61 | 6c 49 50 28 6c 29 3b 0d |.GetLoca|lIP(l);.|
|00000450| 0a 09 09 73 20 3d 20 49 | 70 41 64 64 72 54 6f 53 |...s = I|pAddrToS|
|00000460| 74 72 69 6e 67 28 6c 29 | 3b 0d 0a 09 09 69 20 3d |tring(l)|;....i =|
|00000470| 20 49 6e 53 74 72 28 73 | 2c 20 22 3a 22 29 3b 0d | InStr(s|, ":");.|
|00000480| 0a 09 09 69 66 28 69 20 | 21 3d 20 2d 31 29 0d 0a |...if(i |!= -1)..|
|00000490| 09 09 09 73 20 3d 20 4c | 65 66 74 28 73 2c 20 69 |...s = L|eft(s, i|
|000004a0| 29 3b 0d 0a 09 09 53 65 | 72 76 65 72 55 52 4c 20 |);....Se|rverURL |
|000004b0| 3d 20 22 68 74 74 70 3a | 2f 2f 22 24 73 3b 0d 0a |= "http:|//"$s;..|
|000004c0| 09 7d 0d 0a 09 65 6c 73 | 65 0d 0a 09 09 53 65 72 |.}...els|e....Ser|
|000004d0| 76 65 72 55 52 4c 20 3d | 20 22 68 74 74 70 3a 2f |verURL =| "http:/|
|000004e0| 2f 22 24 53 65 72 76 65 | 72 4e 61 6d 65 3b 0d 0a |/"$Serve|rName;..|
|000004f0| 0d 0a 09 69 66 28 4c 69 | 73 74 65 6e 50 6f 72 74 |...if(Li|stenPort|
|00000500| 20 21 3d 20 38 30 29 0d | 0a 09 09 53 65 72 76 65 | != 80).|...Serve|
|00000510| 72 55 52 4c 20 3d 20 53 | 65 72 76 65 72 55 52 4c |rURL = S|erverURL|
|00000520| 20 24 20 22 3a 22 24 73 | 74 72 69 6e 67 28 4c 69 | $ ":"$s|tring(Li|
|00000530| 73 74 65 6e 50 6f 72 74 | 29 3b 0d 0a 0d 0a 09 42 |stenPort|);.....B|
|00000540| 69 6e 64 50 6f 72 74 28 | 20 4c 69 73 74 65 6e 50 |indPort(| ListenP|
|00000550| 6f 72 74 20 29 3b 0d 0a | 09 4c 69 73 74 65 6e 28 |ort );..|.Listen(|
|00000560| 29 3b 0d 0a 7d 0d 0a 0d | 0a 65 76 65 6e 74 20 44 |);..}...|.event D|
|00000570| 65 73 74 72 6f 79 65 64 | 28 29 0d 0a 7b 0d 0a 09 |estroyed|()..{...|
|00000580| 6c 6f 63 61 6c 20 69 6e | 74 20 69 3b 0d 0a 0d 0a |local in|t i;....|
|00000590| 09 66 6f 72 28 69 3d 30 | 3b 69 3c 31 30 3b 69 2b |.for(i=0|;i<10;i+|
|000005a0| 2b 29 0d 0a 09 09 69 66 | 28 41 70 70 6c 69 63 61 |+)....if|(Applica|
|000005b0| 74 69 6f 6e 4f 62 6a 65 | 63 74 73 5b 69 5d 20 21 |tionObje|cts[i] !|
|000005c0| 3d 20 4e 6f 6e 65 29 0d | 0a 09 09 7b 0d 0a 09 09 |= None).|...{....|
|000005d0| 09 41 70 70 6c 69 63 61 | 74 69 6f 6e 4f 62 6a 65 |.Applica|tionObje|
|000005e0| 63 74 73 5b 69 5d 2e 43 | 6c 65 61 6e 75 70 28 29 |cts[i].C|leanup()|
|000005f0| 3b 0d 0a 09 09 09 41 70 | 70 6c 69 63 61 74 69 6f |;.....Ap|plicatio|
|00000600| 6e 4f 62 6a 65 63 74 73 | 5b 69 5d 2e 4c 65 76 65 |nObjects|[i].Leve|
|00000610| 6c 20 3d 20 4e 6f 6e 65 | 3b 0d 0a 09 09 09 41 70 |l = None|;.....Ap|
|00000620| 70 6c 69 63 61 74 69 6f | 6e 4f 62 6a 65 63 74 73 |plicatio|nObjects|
|00000630| 5b 69 5d 2e 57 65 62 53 | 65 72 76 65 72 20 3d 20 |[i].WebS|erver = |
|00000640| 4e 6f 6e 65 3b 0d 0a 09 | 09 09 41 70 70 6c 69 63 |None;...|..Applic|
|00000650| 61 74 69 6f 6e 4f 62 6a | 65 63 74 73 5b 69 5d 20 |ationObj|ects[i] |
|00000660| 3d 20 4e 6f 6e 65 3b 0d | 0a 09 09 7d 0d 0a 0d 0a |= None;.|...}....|
|00000670| 09 53 75 70 65 72 2e 44 | 65 73 74 72 6f 79 65 64 |.Super.D|estroyed|
|00000680| 28 29 3b 0d 0a 7d 0d 0a | 0d 0a 65 76 65 6e 74 20 |();..}..|..event |
|00000690| 47 61 69 6e 65 64 43 68 | 69 6c 64 28 20 41 63 74 |GainedCh|ild( Act|
|000006a0| 6f 72 20 43 20 29 0d 0a | 7b 0d 0a 09 53 75 70 65 |or C )..|{...Supe|
|000006b0| 72 2e 47 61 69 6e 65 64 | 43 68 69 6c 64 28 43 29 |r.Gained|Child(C)|
|000006c0| 3b 0d 0a 09 43 6f 6e 6e | 65 63 74 69 6f 6e 43 6f |;...Conn|ectionCo|
|000006d0| 75 6e 74 2b 2b 3b 0d 0a | 0d 0a 09 2f 2f 20 69 66 |unt++;..|...// if|
|000006e0| 20 74 6f 6f 20 6d 61 6e | 79 20 63 6f 6e 6e 65 63 | too man|y connec|
|000006f0| 74 69 6f 6e 73 2c 20 63 | 6c 6f 73 65 20 64 6f 77 |tions, c|lose dow|
|00000700| 6e 20 6c 69 73 74 65 6e | 2e 0d 0a 09 69 66 28 4d |n listen|....if(M|
|00000710| 61 78 43 6f 6e 6e 65 63 | 74 69 6f 6e 73 20 3e 20 |axConnec|tions > |
|00000720| 30 20 26 26 20 43 6f 6e | 6e 65 63 74 69 6f 6e 43 |0 && Con|nectionC|
|00000730| 6f 75 6e 74 20 3e 20 4d | 61 78 43 6f 6e 6e 65 63 |ount > M|axConnec|
|00000740| 74 69 6f 6e 73 20 26 26 | 20 4c 69 6e 6b 53 74 61 |tions &&| LinkSta|
|00000750| 74 65 20 3d 3d 20 53 54 | 41 54 45 5f 4c 69 73 74 |te == ST|ATE_List|
|00000760| 65 6e 69 6e 67 29 0d 0a | 09 7b 0d 0a 09 09 4c 6f |ening)..|.{....Lo|
|00000770| 67 28 22 57 65 62 53 65 | 72 76 65 72 3a 20 54 6f |g("WebSe|rver: To|
|00000780| 6f 20 6d 61 6e 79 20 63 | 6f 6e 6e 65 63 74 69 6f |o many c|onnectio|
|00000790| 6e 73 20 2d 20 63 6c 6f | 73 69 6e 67 20 64 6f 77 |ns - clo|sing dow|
|000007a0| 6e 20 4c 69 73 74 65 6e | 2e 22 29 3b 0d 0a 09 09 |n Listen|.");....|
|000007b0| 43 6c 6f 73 65 28 29 3b | 0d 0a 09 7d 0d 0a 7d 0d |Close();|...}..}.|
|000007c0| 0a 0d 0a 65 76 65 6e 74 | 20 4c 6f 73 74 43 68 69 |...event| LostChi|
|000007d0| 6c 64 28 20 41 63 74 6f | 72 20 43 20 29 0d 0a 7b |ld( Acto|r C )..{|
|000007e0| 0d 0a 09 53 75 70 65 72 | 2e 4c 6f 73 74 43 68 69 |...Super|.LostChi|
|000007f0| 6c 64 28 43 29 3b 0d 0a | 09 43 6f 6e 6e 65 63 74 |ld(C);..|.Connect|
|00000800| 69 6f 6e 43 6f 75 6e 74 | 2d 2d 3b 0d 0a 0d 0a 09 |ionCount|--;.....|
|00000810| 2f 2f 20 69 66 20 63 6c | 6f 73 65 64 20 64 75 65 |// if cl|osed due|
|00000820| 20 74 6f 20 74 6f 6f 20 | 6d 61 6e 79 20 63 6f 6e | to too |many con|
|00000830| 6e 65 63 74 69 6f 6e 73 | 2c 20 73 74 61 72 74 20 |nections|, start |
|00000840| 6c 69 73 74 65 6e 69 6e | 67 20 61 67 61 69 6e 2e |listenin|g again.|
|00000850| 0d 0a 09 69 66 28 43 6f | 6e 6e 65 63 74 69 6f 6e |...if(Co|nnection|
|00000860| 43 6f 75 6e 74 20 3c 3d | 20 4d 61 78 43 6f 6e 6e |Count <=| MaxConn|
|00000870| 65 63 74 69 6f 6e 73 20 | 26 26 20 4c 69 6e 6b 53 |ections |&& LinkS|
|00000880| 74 61 74 65 20 21 3d 20 | 53 54 41 54 45 5f 4c 69 |tate != |STATE_Li|
|00000890| 73 74 65 6e 69 6e 67 29 | 0d 0a 09 7b 0d 0a 09 09 |stening)|...{....|
|000008a0| 4c 6f 67 28 22 57 65 62 | 53 65 72 76 65 72 3a 20 |Log("Web|Server: |
|000008b0| 4c 69 73 74 65 6e 69 6e | 67 20 61 67 61 69 6e 20 |Listenin|g again |
|000008c0| 2d 20 63 6f 6e 6e 65 63 | 74 69 6f 6e 73 20 68 61 |- connec|tions ha|
|000008d0| 76 65 20 62 65 65 6e 20 | 63 6c 6f 73 65 64 2e 22 |ve been |closed."|
|000008e0| 29 3b 0d 0a 09 09 4c 69 | 73 74 65 6e 28 29 3b 0d |);....Li|sten();.|
|000008f0| 0a 09 7d 0d 0a 7d 0d 0a | 0d 0a 66 75 6e 63 74 69 |..}..}..|..functi|
|00000900| 6f 6e 20 57 65 62 41 70 | 70 6c 69 63 61 74 69 6f |on WebAp|plicatio|
|00000910| 6e 20 47 65 74 41 70 70 | 6c 69 63 61 74 69 6f 6e |n GetApp|lication|
|00000920| 28 73 74 72 69 6e 67 20 | 55 52 49 2c 20 6f 75 74 |(string |URI, out|
|00000930| 20 73 74 72 69 6e 67 20 | 53 75 62 55 52 49 29 0d | string |SubURI).|
|00000940| 0a 7b 0d 0a 09 6c 6f 63 | 61 6c 20 69 6e 74 20 69 |.{...loc|al int i|
|00000950| 2c 20 6c 3b 0d 0a 0d 0a | 09 53 75 62 55 52 49 20 |, l;....|.SubURI |
|00000960| 3d 20 22 22 3b 0d 0a 09 | 66 6f 72 28 69 3d 30 3b |= "";...|for(i=0;|
|00000970| 69 3c 31 30 3b 69 2b 2b | 29 0d 0a 09 7b 0d 0a 09 |i<10;i++|)...{...|
|00000980| 09 69 66 28 41 70 70 6c | 69 63 61 74 69 6f 6e 50 |.if(Appl|icationP|
|00000990| 61 74 68 73 5b 69 5d 20 | 21 3d 20 22 22 29 0d 0a |aths[i] |!= "")..|
|000009a0| 09 09 7b 0d 0a 09 09 09 | 6c 20 3d 20 4c 65 6e 28 |..{.....|l = Len(|
|000009b0| 41 70 70 6c 69 63 61 74 | 69 6f 6e 50 61 74 68 73 |Applicat|ionPaths|
|000009c0| 5b 69 5d 29 3b 0d 0a 09 | 09 09 69 66 28 4c 65 66 |[i]);...|..if(Lef|
|000009d0| 74 28 55 52 49 2c 20 6c | 29 20 3d 3d 20 41 70 70 |t(URI, l|) == App|
|000009e0| 6c 69 63 61 74 69 6f 6e | 50 61 74 68 73 5b 69 5d |lication|Paths[i]|
|000009f0| 20 26 26 20 28 4c 65 6e | 28 55 52 49 29 20 3d 3d | && (Len|(URI) ==|
|00000a00| 20 6c 20 7c 7c 20 4d 69 | 64 28 55 52 49 2c 20 6c | l || Mi|d(URI, l|
|00000a10| 2c 20 31 29 20 3d 3d 20 | 22 2f 22 29 29 0d 0a 09 |, 1) == |"/"))...|
|00000a20| 09 09 7b 0d 0a 09 09 09 | 09 53 75 62 55 52 49 20 |..{.....|.SubURI |
|00000a30| 3d 20 4d 69 64 28 55 52 | 49 2c 20 6c 29 3b 0d 0a |= Mid(UR|I, l);..|
|00000a40| 09 09 09 09 72 65 74 75 | 72 6e 20 41 70 70 6c 69 |....retu|rn Appli|
|00000a50| 63 61 74 69 6f 6e 4f 62 | 6a 65 63 74 73 5b 69 5d |cationOb|jects[i]|
|00000a60| 3b 0d 0a 09 09 09 7d 0d | 0a 09 09 7d 0d 0a 09 7d |;.....}.|...}...}|
|00000a70| 0d 0a 09 72 65 74 75 72 | 6e 20 4e 6f 6e 65 3b 0d |...retur|n None;.|
|00000a80| 0a 7d 0d 0a 0d 0a 00 | |.}..... | |
+--------+-------------------------+-------------------------+--------+--------+