home *** CD-ROM | disk | FTP | other *** search
/ Reverse Code Engineering RCE CD +sandman 2000 / ReverseCodeEngineeringRceCdsandman2000.iso / RCE / L2C / adenozin / SimpleScript.exe / Main / fasts < prev    next >
Encoding:
Text File  |  2000-05-25  |  3.3 KB  |  64 lines

  1. alias ps { if ($dialog(portscanner) == $null) { dialog -m portscanner portscanner } | else halt }
  2. alias pstimeout { if ($dialog(portscanner)) { did -o portscanner 6 1 $chr(160) $+ Server restricts portscan! | did -e portscanner 1 | .timer49 off | halt } }
  3. dialog portscanner {
  4.   title " Server Port Scanner"
  5.   size -1 -1 461 240
  6.   button "Scan Now", 1, 242 120 209 24, ok default
  7.   edit "", 2, 48 10 403 20, disable
  8.   text "Server:", 3, 10 13 40 20
  9.   list 4, 51 35 135 160
  10.   text "Ports:", 5, 17 38 30 20
  11.   edit "Created By Aaron18-", 6, 241 33 210 40
  12.   text "Status:", 7, 204 37 38 20
  13.   edit "", 8, 51 185 55 20, disable
  14.   text "Current:", 9, 8 189 40 20
  15.   button "Clear", 11, 130 196 35 18, ok default
  16.   text "Created by Aaron18-", 12, 310 218 150 20, disable
  17.   box "", 13, 49 27 140 202
  18.   edit "", 14, 51 206 55 20, disable
  19.   text "Fastest:", 15, 8 209 44 20
  20. }
  21. on *:dialog:portscanner:init:*:{
  22.   if ($server != $null) { did -f portscanner 1 }
  23.   did -m portscanner 6
  24.   if ($server == $null) { did -b portscanner 1 | did -b portscanner 4 | did -r portscanner 2 | did -r portscanner 8 | did -o portscanner 6 1 $chr(160) $+ Not connected to server | did -b portscanner 1 | halt }
  25.   did -o portscanner 2 1 $chr(160) $+ $server | did -o portscanner 8 1 $port
  26. }
  27. on *:dialog:portscanner:dclick:*:if ($did == 4) { server $server $+ : $+ $did(4,$did(4).sel) }
  28. on *:dialog:portscanner:sclick:*:{
  29.   if ($did == 1) { did -b portscanner 1 | did -o portscanner 6 1 $chr(160) $+ Scanning... | .timer49 -o 1 3 pstimeout | did -r portscanner 4 | .enable #statsl | stats l | halt }
  30.   if ($did == 11) { did  -r portscanner 4 | halt }
  31. }
  32. #statsl on
  33. raw 211:*:{
  34.   .timer49 off | if ($dialog(portscanner)) && ($left(4,$right(5,$2)) isnum) {
  35.     %ps.tmp = $5 + $7 | set %ps.yn yes | inc %ps.ports 1 | if ($chr(46) isin $left(4,$right(5,$2))) { %ps.ports = %ps.ports - 1 | halt }
  36.     did -a portscanner 4 $left(4,$right(5,$2)) - $chr(40) $+ %ps.tmp KB $+ $chr(41)
  37.     if %ps.psc == $null { %ps.best =  $left(4,$right(5,$2)) | %ps.bp = $5 + $7 | set %ps.psc active }
  38.     else { %ps.tp = $5 + $7 | if (%ps.tp < %ps.bp) { %ps.best = $left(4,$right(5,$2)) | %ps.bp = $5 + $7 } | unset %ps.tp }
  39.   }
  40.   halt
  41. }
  42. raw 219:*:{
  43.   if $2 == l {
  44.     if (%ps.yn == $null) { if ($dialog(portscanner)) { did -o portscanner 6 1 $chr(160) $+ Server restricts port scan! } | unset %ps.yn | goto end }
  45.     if ($dialog(portscanner)) {
  46.       if (%ps.ports == $null) { did -o portscanner 6 1 $chr(160) $+ No port list } | if (%ps.ports = 1) { did -o portscanner 6 1 $chr(160) $+ Found %ps.ports Port }
  47.       if (%ps.ports > 1) { did -o portscanner 6 1 $chr(160) $+ Found %ps.ports Ports } | goto end
  48.     }
  49.     :end | did -e portscanner 1 | did -o portscanner 14 1 %ps.best | .disable #statsl | unset %ps.* | halt
  50.   }
  51. }
  52. #statsl end
  53. on 1:connect:{
  54.   if ($dialog(portscanner)) {
  55.     did -e portscanner 1 | did -e portscanner 4 | did -o portscanner 2 1 $chr(160) $+ $server | did -o portscanner 8 1 $port
  56.     did -r portscanner 6 | did -o portscanner 6 1 $chr(160) $+ Connected
  57.   }
  58. }
  59. on 1:disconnect:{
  60.   if ($dialog(portscanner)) {
  61.     did -o portscanner 6 1 $chr(160) $+ Not connected to server | did -b portscanner 1 | did -b portscanner 4 | did -r portscanner 2 | did -r portscanner 8 | did -r portscanner 14
  62.   }
  63. }
  64.