-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdlFilter.mrc
6776 lines (6247 loc) · 260 KB
/
dlFilter.mrc
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
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
DLFILTER -=- Firewall, anti-spam for mIRC
and message filter for file sharing channels.
Authors: © DukeLupus and Sophist
Worried about hackers sending you malicious files without your consent? Annoyed by advertising messages from the various file serving bots? Fed up with endless channel messages from other users searching for and requesting files? Are the responses to your own requests getting lost in the crowd?
This script filters out the crud, leaving only the useful messages displayed in the channel. By default, the filtered messages are thrown away, but you can direct them to custom windows if you wish. Functions include:
• For file sharing channels, filter other peoples messages, server adverts and spam
• Collect @find results from file sharing channels into a custom window
• Protect your computer from DCC Sends from other users, except those you have explicitly requested - files you have explicitly requested are accepted automatically
• Limit spam messages of all types from other users
• If you are a channel op, provide a separate chat window for operators
Version 2 is a significant upgrade from the previous major release 1.16 with significant new functionality, which we hope will encourage strong take-up.
Version 2.08 fixes the updater and makes the Options dialog work on high resolution e.g. 4K screens with Windows 10 Display Scaling > 100%.
Feedback on this new version is appreciated. dlFilter is now also an Open Source project, hosted on Github, and we welcome contributions of bug fixes and further improvement from the community.
To load: use /load -rs dlFilter.mrc
Note that dlFilter loads itself automatically as either the first (or second if you are also running sbClient) or last script (depending on options). If you are having problems with other scripts processing the same messages, try changing this option.
Roadmap
=======
• Improve the ability of users to report issues (e.g. channel messages handled incorrectly) directly from dlFilter popup menus via GitReports.
• Integrate sbClient functionality and rename to sbFilter.
• Support mIRC options for Socks4/5/Proxy for script update.
• Support channel / user specific custom filters.
• A security wizard that checks mIRC settings that could make you insecure, and helps you to set them to be more secure.
Acknowledgements
================
dlFilter uses the following code from other people:
• GetFileName originally based on code from TipiTunes' OS-Quicksearch
• automatic version check based originally on code developed for dlFilter by TipiTunes
• Support for AG6 & 7 by TipiTunes
• Some of the spam definitions are from HugHug's SoftSnow filter.
• Vadi wrote special function to vPowerGet dll that allows sending files from [email protected] window to vPowerGet.
*/
/* CHANGE LOG
Immediate TODO
Test location and filename for oNotice log files
Be smarter about matching nicks responding to file requests with triggers when they don't quite match.
(Add another field to the hash for the nick - check whether trigger exactly matches a nick and if not try to identify a close match (either by looking for matching @trigger in ads window or by looking for very similar nicks e.g. pondering vs. pondering42. Or check the ads windows for equivalent @ triggers.)
Copy files received which are not identified as triggers to current window.
Colour DCC SEND channel messages so as to distinguish filenames and sending user and stats.
If settings not AutoAccept (which uses temporary trust) then ask user (once per nick per session) if they want to Trust untrusted servers they are requesting files from.
Autoaccept / autotrust from all voiced or opped or half-opped nicks.
Handle search response files where "-" is replaced by space. (Analyse sbserver to see how it handles special characters.)
Does not auto-accept search results for search with a hyphenated word or fullstop.
File Get retry clears input box.
DCC RESUME doesn't seem to work properly.
DCC RESUME should start again from the beginning if file is already fully downloaded.
DCC RESUME when file already fully downloaded says Resumed but never completes.
Status window has: DCC Send from xxxxx rejected (invalid parameters)
Don't retry a get of search results that fails because it doesn't work!!
When starting to transfer a @search file, "waited" value is 23:59:xx which is clearly wrong.
Do not resume @search results
Validate resume i.e. don't resume if start point for resume is after entire stated file length.
When you open a query window, trawl for history in all other open windows for that network.
Reset stats for a channel on JOIN.
Sort out spaces in private DCC Send messages
If "CRC(xxxxx)" is in the DCC Send Notice then when file completes, check the CRC is correct and flag if not.
If Op, option to highlight to self or other ops or ban user after x spam messages / reports from other ops.
If user disables or unloads, remove stats from channel titles.
Add option for showing parts and joins etc. for anyone who has spoken in channel (non-filtered messages)
or anyone who user has communicated with or notify users or users who were ops / hops / voiced when they last parted/quit.
Option to maintain list of servers (using SLOTS or Ads) and hide anything (with colours?) that they send when you haven't requested anything from them.
Message to all dlf channels when you enable or disable DLF.
Ops oNotice about spammer needs to be more intelligent - not just on a single spam message from a user like "Hello."
Fix oNotice list of people leaving / people changing nicks
Copy all ops messages to oNotice window i.e. any joins / parts bans kicks etc. by or of Ops.
Option to auto-open oNotice window when you are opped in a channel (if there are at least 2 ops).
Autoaccept DCC chat from trusted nicks. May need to set autoaccept from everyone and then cancel those you don't want to accept.
File transfer messages (red) from trusted nicks not appearing in windows.
Do not filter out dlFilter messages from other Ops in channels where you are an op if op filter checkbox is clear.
Error messages sent to too many windows i.e. nick name already in use.
Record voiced / ops users in DLF channels when they quit / part and show joins for these users if they rejoin.
Show kicks / bans if op actions displayed.
Ops option - When user says something that is not filtered, show quits / parts and triggers etc. until they do a trigger correctly. Also retrieve and display previous from filter window if available.
!seen in #ebooks gets a channel message which is erroneously sent to query window if open for that user.
Send responses to own /away to all server windows.
Add to "Blocked private message" instructions to whitelist user using mIRC notify.
File get DCC messages sent to current window not channel window where they were requested.
On LOAD enable dlFilter if disabled. BUT (obviously) NOT when you are simply restarting mIRC or dlF is reloading itself.
Only filter out topic when joining channel - dont filter if e.g. user types /topic #channel
Ideas for possible future enhancements
Create pop-up box option for channels to allow people to cut and paste a line which should be filtered but isn't and create a gitreports call.
Implement toolbar functionality with right click menu
mIRC security wizard to check that mIRC settings are not too lax
Manage filetype ignore list like trust list i.e. temp add for requested filetypes.
More menu options equivalent to dialog options
Make it work on AdiIRC and update version check to handle AdiIRC versions.
Merge in sbClient functionality + add functionality to process CSEv2 DCC results.
Trim lines from Ads window for servers which have been offline for xx hours.
Configurable F1 etc. aliases to toggle Options, Ads, Filters, Catch-all by F key or other keys.
(Use On Keydown to capture and check keystrokes, have a key field for each of the options to toggle.)
(Might be better as a separate script with documented commands you can paste in.
Add right click menu items to @find windows to re-sort list by trigger and filename.
Add @dlFilter / !dlFilter to serve dlFilter if running current version.
Split ads / announcements into two types - those that are also filtered and those that are displayed once (per absolutely identical) and then filtered.
(Voiced / Oped users would have option for all items filtered.)
Remote support - allow DLF to send watch logs via DCC chat.
Also send UNfiltered messages to the filter screen so that you get full context there.
2.00 Major version number for release.
2.01 Send file blocking messages to common channel.
Close dialog when updating
2.02 Fix file get requests failing if e.g. ::INFO:: is included in the request
2.03 Add option to prevent new query windows opening
2.04 Record ctcp requests and process replies.
2.05 Handle filtering of op events better (i.e. show voice / part of voiced users if settings allow)
Do not display ctcp SLOTS for notify users
Fix version checking
2.06 Option to disable version checking
2.07 Option to run DLF last rather than first in order to avoid causing issues with other scripts. See Github #44.
DLF is intended to filter stuff from the screen not from other scripts.
DLF halts messages that are filtered (not displayed as standard) or which DLF wants to display in a different window than mIRC's default.
This can cause conflicts with other scripts that also halt messages in order to display them themselves.
Other scripts should check $halted==$false before acting on or echoing messages related to the event.
Note: Previously we said running first "avoids problems where other scripts halt events preventing this scripts events from running",
however mIRC runs events in all scripts unless the ON statement is prefixed with an "&".
Additional porn filter
Fix server notices shown in query window
Process messages (like ads) from notify users
Only check for updates on first connection
DLF.Watch timestamps coloured correctly as per mIRC timestamp setting.
Improvements to DLF.Watch messages
Only enable Ops tab if Ops in DLF channel not if only ops in non-DLF channel.
Respect Enable Custom Filters global setting.
Fix filter stats miscounting CTCP SLOTS from fileservers and notify user messages.
Respect global option to enable / disable Custom Filters.
Reactivate dialog on show of Filter / Ads windows.
Fix oNotice window user lists not populating on rejoin.
Fix oNotice available when not an op in a dlF channel.
Restrict autotrust to a specific network.
Reset watch tick counter on events not triggered by server message.
Handle manual trusts which include a specific network.
Improved handling of topics if channel window is not open.
Improved handling of messages from a Notify user.
Undernet X added as a service.
Prevent DLF.Watch.Log errors if watch window was closed.
Improved handling of DLF.Watch on servers that use tags.
Clean up unnecessary handling of raw messages and reduce replicated code.
Avoid duplicate echoing of messages to status window.
Add support for /MSG nick XDCC SEND as a file request.
Close filter window now closes / hides (depending on keep in background) all Filter / FilterSearch windows.
Options dialog is now associated with active window's connection so show of Filter / Ads makes correct window active.
On start / load warn user if "Options/Sounds/Requests/Send '!nick file' as Private Message" is checked (since it misdirects triggers).
Fix interception of DCC ACCEPT CTCP messages preventing DCC SEND resumes.
Alert user if requested file already exists and mIRC is set to Cancel DCCs.
Improve DCC SEND start / resume / finished / interrupted messages.
2.08 Improve options dialog display on high resolution screens (e.g. 4K) when Windows scaling is > 100%.
Make options dialog tab sticky (i.e. when you close and reopen dialog, active tab is maintained.
Fix downloads only keeping last section - may require a manual update.
Fix downloads when script is in a read-only directory.
2.09 Fix error when DLF is being advertised by a channel op.
Fix 2 errors reporting spam from another user to channel ops.
Include web version in channel advertising and show received adverts if current version does not match
Fix auto-accept of @search results where search includes an apostrophe
2.10 Allow DCC Send resumes when running a file-server by not halting CTCP DCC RESUME.
Don't send ctcp to query window
Don't echo notices to active window
Don't echo anything to active windows which are custom windows unless an ochat window.
Fix DCC Get resume reported bytes received when no bytes were received.
If advertising DLF, check for updates daily instead of weekly.
Move some options between tabs in options dialogue.
Use $fulladdress instead of $address($nick,5)
Tweak ops advertising filtering to not filter if advertised version is > this version.
Replace capture of trigger requests using ON INPUT to use ON PARSELINE instead
(in order to capture requests made by other scripts - and retries by DLF).
Fix misplaced channel menu lines
Add function to repeat Notify users on / offline to additional windows
Fix incorrect blocking of DCC Sends from users who have been manually trusted.
Fix filtering of DLF advertising messages
Highlight new event in debug window
Fix onotices when not active window
Fix filenames with embedded CR/LF
Fix trust timers not unique
Fix onotice users not being removed on quit
Handle DCC resume better when file exists but sending file has spaces replaced by underscores
Fix resume for files which have been renamed to remove underscores.
Improve file transfer stats and fix stats for resumed files.
Fix DCC Send tracking to cope with requests where server is DCC passive
Handle DCC send requests received as a result of your DCC SEND with passive set.
Query for searchbots if search is done for trigger not in table (to avoid blocked response files).
Additional filters.
Additional menu items.
Fix search responses not being autoaccepted. Triggers not being requested because @search-Triggers sent too early in channel with mode +d talk delay.
Remove search triggers when you leave channel so that they are re-requested when you join in case list has changed.
Re-request search triggers if nick search* joins or @search* called and nick/trigger is not in table.
Fix handling of self join / part calling routines twice.
Fix dlf.watch for quit server response.
2.11 Fix bug with missing variable when changing Ads window lines if server changes nick. (Thx to Ook for reporting this.)
Added generalised support for searchbot names i.e. seek* & locate* as well as search*
Added check for searchbots in channel before requesting searchbot triggers
Fixed over frequent @searchbot-trigger calls when a non-existent search trigger is used.
2.12 Update filters for trivia and server ads.
Fix issue with autoget in mIRC v7.57 and below only doing autoget on first trust entry by resequencing existing trust entries to after the new one.
Only save searchbot requests for 5 minutes instead of 24 hours (in case server is offline we don't want to requeue searchbot requests).
Fix messages being copied to active window from other connections.
Fix issue with update not working on IPv6 connections.
2.13 Fix reload doesn't work when current directory is not writeable.
2.14 Revert change in 2.13
Enhance socket error message for better diagnosis
Add auto open option for oNotice window for channels where you are an Op. Actual autoopen still to be coded.
Fix oNotice for joins parts etc.
Copy all Ops actions to oNotice window if open.
Additional filters
Fix issue with ops advertising period
Fix colours limited to 0-15 instead of 0-99
*/
; Increase this when you have sufficient changes to justify a release
; When you want to trigger updates for existing users, change the version file.
alias -l DLF.SetVersion {
%DLF.version = 2.14
return %DLF.version
}
; Check mIRC is sufficiently new for functions needed
alias -l DLF.mIRCversion {
var %app $nopath($mircexe)
; AdiIRC - not sure what version is specifically needed
; 2.8 is the version at the time of starting to think about AdiIRC support.
if (AdiIRC* iswm %app) {
if ($version >= 2.8) return 0
%DLF.enabled = 0
DLF.Groups.Events
return AdiIRC 2.8
}
; mirc - We need returnex first implemented in 6.17
; mirc - We need regex /F first implemented in 7.44
elseif ($version >= 7.44) return 0
%DLF.enabled = 0
DLF.Groups.Events
return mIRC 7.44
}
; ========== Initialisation / Termination ==========
; Reload script to reposition first/last and Initialise new variables
on *:start: {
if ($script != $script($DLF.LoadPosition)) DLF.Reload
DLF.Initialise
return
:error
DLF.Error During start: $qt($error)
}
; Reload at defined position and reinitialise
alias -l DLF.Reload {
.timer -m 1 100 .signal DLF.Initialise
var %file $DLF.Script
.reload -rs $+ $DLF.LoadPosition $qt(%file)
if (%file != $script) .unload -rsn $qt($script)
halt
}
; Define the script loading position
alias -l DLF.LoadPosition {
if (%DLF.loadlast) return $script(0)
if ((sbClient.* iswm $nopath($script(1))) || (sbClient.* iswm $nopath($script(2)))) return 2
return 1
}
; Rename variables if needed to upgrade from 1.16 names to 2.x names
alias -l DLF.RenameVar {
if ($($+(%,DLF.,$2),2) == $null) return
.set $($+(%,DLF.,$1),1) $($+(%,DLF.,$2),2)
.unset $($+(%,DLF.,$2),1)
}
on *:signal:DLF.Initialise: { DLF.Initialise $1- }
alias -l DLF.Initialise {
; No incoming debug event - so need a manual reset of tick offset
DLF.Watch.Called DLF.Initialise : $1-
; Handle obsolete variables
.unset %DLF.custom.selected
.unset %DLF.filtered.limit
.unset %DLF.newreleases
.unset %DLF.privrequests
.unset %DLF.ptext
.unset %DLF.server.limit
.unset %DLF.showstatus
.unset %DLF.chspam
.unset %DLF.spam.addignore
; Rename variables from 1.16 names to 2.x names
DLF.RenameVar dccsend.dangerous askregfile.type
DLF.RenameVar dccsend.nocomchan nocomchan.dcc
DLF.RenameVar dccsend.untrusted askregfile
DLF.RenameVar filter.ads ads
DLF.RenameVar filter.aways away
DLF.RenameVar filter.joins joins
DLF.RenameVar filter.kicks kicks
DLF.RenameVar filter.modeschan chmode
DLF.RenameVar filter.modesuser usrmode
DLF.RenameVar filter.nicks nicks
DLF.RenameVar filter.parts parts
DLF.RenameVar filter.quits quits
DLF.RenameVar filter.requests requests
DLF.RenameVar filter.spamchan chspam
DLF.RenameVar filter.spampriv privspam
DLF.RenameVar opwarning.spamchan chspam.opnotify
DLF.RenameVar opwarning.spampriv privspam.opnotify
DLF.RenameVar private.nocomchan nocomchan
DLF.RenameVar filter.privother noregmsg
DLF.RenameVar serverwin server
DLF.RenameVar update.betas betas
DLF.RenameVar win-filter.log filtered.log
DLF.RenameVar win-filter.strip filtered.strip
DLF.RenameVar win-filter.timestamp filtered.timestamp
DLF.RenameVar win-filter.wrap filtered.wrap
DLF.RenameVar win-onotice.enabled o.enabled
DLF.RenameVar win-onotice.log o.log
DLF.RenameVar win-onotice.timestamp o.timestamp
DLF.RenameVar win-server.log server.log
DLF.RenameVar win-server.strip server.strip
DLF.RenameVar win-server.timestamp server.timestamp
DLF.RenameVar win-server.wrap server.wrap
; Make variables more consistent
if (%DLF.netchans == $null) %DLF.netchans = %DLF.channels
; oNotice functionality is integrated - so unload other versions
if ($script(onotice.mrc)) .unload -rs onotice.mrc
if ($script(onotice.txt)) .unload -rs onotice.txt
if (%DLF.JustLoaded) var %init Loading
else var %init Starting
DLF.StatusAll %init $c(4,version $DLF.SetVersion) by DukeLupus & Sophist.
DLF.StatusAll Please visit dlFilter homepage $br($c(12,9,$u(https://github.com/DukeLupus/dlFilter))) for help.
; Create other files used (to enable single file install / update)
;DLF.CreateGif
; Hashtables hold the strings to match against
DLF.CreateHashTables
; Initialise options variables
DLF.Options.Initialise
; Enable / disable DLF functionality
DLF.Groups.Events
; Enable self-advertising if ops
DLF.Ops.AdvertsEnable
var %ver $DLF.mIRCversion
if (%ver != 0) DLF.Error dlFilter requires %ver $+ +. dlFilter disabled until mIRC is updated.
if ($sendPlingNickAsPrivate) DLF.Warning You have $qt(Options/Sounds/Requests/Send '!nick file' as Private Message) checked - if you are using dlFilter in a channel which uses ! as a trigger character, you should uncheck this mIRC option.
}
; If user manually unloads, do clean-up
on *:unload: {
; Turn off all debugging
DLF.Watch.Unload
DLF.StatusAll Closing open dlFilter windows
if ($dialog(DLF.Options.GUI)) .dialog -x DLF.Options.GUI DLF.Options.GUI
close -a@ @dlF.Filter.*
close -a@ @dlF.FilterSearch.*
close -a@ @dlF.Server.*
close -a@ @dlF.ServerSearch.*
close -a@ @dlF.@find.*
close -a@ @dlF.Ads.*
close -a@ @#*
; Offer to keep or remove options
var %keepvars $?!="Do you want to keep your dlFilter configuration?"
DLF.StatusAll Unloading $c(4,9,version $DLF.SetVersion) by DukeLupus & Sophist.
if (%keepvars == $false) {
DLF.StatusAll Unsetting variables..
.unset %DLF.*
}
DLF.StatusAll Unloading complete.
DLF.StatusAll $space
DLF.StatusAll To reload run /load -rs $qt($script)
DLF.StatusAll $space
}
; ========== Main popup menus ==========
menu menubar {
dlFilter
.$iif(%DLF.filter.controlcodes,Don't filter,Filter) coloured messages: DLF.Options.ToggleOption filter.controlcodes 340
.$iif(%DLF.showfiltered,Hide,Show) filter window(s): DLF.Options.ToggleShowFilter
.$iif(%DLF.serverads,Hide,Show) ads window(s): DLF.Options.ToggleShowAds
.-
.List channel filter stats: DLF.Stats
.-
.Reload filter definitions: DLF.CreateHashTables
.Options: DLF.Options.Show
.-
.Visit dlFilter website: .url -a https://github.com/DukeLupus/dlFilter/
.Unload dlFilter: if ($?!="Do you want to unload dlFilter?" == $true) .unload -rs $qt($script)
}
menu status {
dlFilter
.$iif(%DLF.filter.controlcodes,Don't filter,Filter) coloured messages: DLF.Options.ToggleOption filter.controlcodes 340
.$iif(%DLF.showfiltered,Hide,Show) filter window(s): DLF.Options.ToggleShowFilter
.$iif(%DLF.serverads,Hide,Show) ads window(s): DLF.Options.ToggleShowAds
.-
.List channel filter stats: DLF.Stats
.List Searchbots on $network: DLF.Searchbots
.-
.Reload filter definitions: DLF.CreateHashTables
.Options: DLF.Options.Show
}
menu channel {
-
dlFilter
.$iif($DLF.Chan.IsDlfChan($chan,$false),Remove this channel from,Add this channel to) filtering: DLF.Chan.AddRemove
.Filter all channels currently joined on $network : DLF.Chan.AddJoinedNetwork
.$iif($scon(0) > 1,Filter all currently joined channels) : DLF.Chan.AddJoinedAll
.$iif(%DLF.netchans == $hashtag,$style(3)) Filter all channels you join : {
DLF.Chan.Set $hashtag
DLF.StatusAll $c(6,Channels set to $c(4,$hashtag))
}
.-
.$iif($DLF.Trivia.IsTriviaChan($menu),$iif(%DLF.filter.trivia,Don't filter,Filter) trivia questions): DLF.Options.ToggleOption filter.trivia 330
.$iif(%DLF.filter.controlcodes,Don't filter,Filter) coloured messages: DLF.Options.ToggleOption filter.controlcodes 340
.$iif(%DLF.showfiltered,Hide,Show) filter window(s): DLF.Options.ToggleShowFilter
.$iif(%DLF.serverads,Hide,Show) ads window(s): DLF.Options.ToggleShowAds
.-
.List channel filter stats: DLF.Stats
.List outstanding file requests: DLF.Requests
.List Searchbots in $chan: DLF.Searchbots
.-
.Reload filter definitions: DLF.CreateHashTables
.Options: DLF.Options.Show
-
$iif($DLF.oNotice.IsOp($chan),Open oNotice chat window) : DLF.oNotice.Open
}
; ============================== Event catching ==============================
; ========= Events even if dlFilter is not enabled ==========
ctcp ^*:VERSION*:#: {
if (($nick isop $chan) && ($DLF.Chan.IsDlfChan($chan))) DLF.Priv.ctcpReply.Version
elseif (%DLF.enabled) DLF.Chan.ctcpBlock $1-
}
ctcp ^*:VERSION*:?: {
if (($query($nick)) || ($chat($nick,0)) || ($comchan($nick,0) > 0)) DLF.Priv.ctcpReply.Version
elseif (%DLF.enabled) DLF.Priv.ctcpBlock $1-
}
on *:close:@#*: { DLF.oNotice.Close $target }
on *:close:#*: { DLF.Event.MeLeave $1- }
; Send SNOTICES always to Status
on ^*:snotice:*: {
if (!$halted) echo -stc Notice $+(-,$nick,-) $1-
halt
}
; ========= Events when dlFilter is enabled ==========
#dlf_events on
; Channel user activity
; join, part, quit, nick changes, kick
on ^*:join:#: {
var %txt, %joins, %joined
if ($1-) %txt = : $1-
if ($shortjoinsparts) %joins = Joins:
else %joined = has joined $chan $+ %txt
if ($nick !== $me) DLF.Event.Join %joins $nick $br($address) %joined %txt
else DLF.Event.MeJoin $1-
if ($DLF.IsSearchbot($nick)) DLF.SearchBot.GetTriggers $1 $nick
}
; raw 324 Channel mode response
raw 324:*: { DLF.SearchBot.MeJoin $2- }
; raw 324 Channel user list complete
raw 366:*: { DLF.Event.MeJoinComplete $1- }
on ^*:part:#: {
var %txt, %parts, %hasleft
if ($1-) %txt = $br($1-)
if ($shortjoinsparts) %parts = Parts:
else %hasleft = has left $chan %txt
var %msg %parts $nick $br($address) %hasleft %txt
if ($nick !== $me) DLF.Event.Leave %msg
else DLF.Event.MeLeave %msg
}
on ^*:kick:#: {
var %txt, %addr, %fromchan
if ($1-) var %txt $br($1-)
if ($shortjoinsparts) %addr = $br($address($knick,5))
else %fromchan = from $chan
var %msg $knick %addr was kicked %fromchan by $nick %txt
if ($knick == $me) DLF.Event.MeLeave %msg
else DLF.Event.Leave %msg
}
on ^*:nick: {
if ($nick == $newnick) DLF.Halt Nick failed.
DLF.Event.Nick $nick is now known as $newnick
}
on ^*:quit: {
var %txt, %quits, %quit
if ($1-) var %txt $br($1-)
if ($shortjoinsparts) %quits = Quits:
else %quit = quit
DLF.Event.Quit $nick %quits $nick $br($address) %quit %txt
}
on *:connect: {
DLF.Event.MeConnect $1-
}
on *:disconnect: {
DLF.Event.Disconnect $1-
}
; User mode changes
; ban, unban, op, deop, voice, devoice etc.
on ^*:ban:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$bnick)) DLF.Chan.Mode $1-
}
on ^*:unban:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$bnick)) DLF.Chan.Mode $1-
}
on ^*:op:%DLF.channels: {
if ($opnick != $me) DLF.oNotice.AddNick
else DLF.oNotice.AddChanNicks $chan
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:deop:%DLF.channels: {
DLF.oNotice.DelNick
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:owner:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:deowner:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:voice:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$vnick)) DLF.Chan.Mode $1-
}
on ^*:devoice:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$vnick)) DLF.Chan.Mode $1-
}
on ^*:serverop:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:serverdeop:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$opnick)) DLF.Chan.Mode $1-
}
on ^*:servervoice:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$vnick)) DLF.Chan.Mode $1-
}
on ^*:serverdevoice:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modesuser,$vnick)) DLF.Chan.Mode $1-
}
on ^*:mode:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modeschan)) DLF.Chan.Mode $1-
}
on ^*:servermode:%DLF.channels: {
if ($DLF.Chan.IsChanEvent(%DLF.filter.modeschan)) DLF.Chan.Mode $1-
}
; filter topic changes and when joining channel
on ^*:topic:%DLF.channels: {
DLF.Watch.Called $null : $1-
DLF.AlreadyHalted $1-
var %msg $DLF.TopicForChannel($nick changes topic,for $2,to: $sqt($1-))
if ($DLF.Chan.IsChanEvent(%DLF.filter.topic)) DLF.Win.Filter %msg
DLF.TopicRedirect $2 %msg
}
raw 332:*: {
DLF.Watch.Called $null : $1-
DLF.AlreadyHalted $1-
var %msg $DLF.TopicForChannel(Topic,for $2,is: $sqt($3-))
if (($DLF.Chan.IsDlfChan($2)) && (%DLF.filter.topic == 1)) DLF.Win.Filter %msg
DLF.TopicRedirect $2 %msg
}
raw 331:*: {
DLF.Watch.Called $null : $1-
DLF.AlreadyHalted $1-
DLF.TopicRedirect $2 No topic is set for $2 $+ .
}
raw 333:*: {
DLF.Watch.Called $null : $1-
DLF.AlreadyHalted $1-
Var %msg $DLF.TopicForChannel(Topic,for $2,set by $3 on $asctime($4,ddd mmm dd HH:nn:ss yyyy))
if (($DLF.Chan.IsDlfChan($2)) && (%DLF.filter.topic == 1)) DLF.Win.Filter Set by $3 on $asctime($4,ddd mmm dd HH:nn:ss yyyy)
DLF.TopicRedirect $2 %msg
}
alias -l DLF.TopicForChannel {
if ($window($1)) return $1 $3
return $1 $2 $3
}
alias -l DLF.TopicRedirect {
if ($halted) halt
if ($window($1)) echo -tc Topic $1 * $2-
else echo -atc Topic * $2-
halt
}
; Remove trailing CR if it exists
alias -l parseline {
if ($asc($right($parseline,1)) != 10) return $parseline
return $left($parseline,-1)
}
; if a search window, refilter on new search string
on *:input:@dlF.*Search.*: { DLF.Search.Show $winscript $1- }
; if an oNotice window, process as oNotice text
on *:input:@#*: { DLF.oNotice.Input $1- }
on *:input:#: { DLF.Event.Input $chan $1- }
on *:input:?: { DLF.Event.Input Private $1- }
on $*:parseline:out:$(/^PRIVMSG .* :[@!].*/): {
tokenize 32 $.parseline
var %request $right($3-,-1)
if (%request == @SearchBot-Trigger) return
var %trig $gettok(%request,1,$asc($space))
if ((%trig == @find) || (%trig == @locator)) [email protected] $2-
else DLF.DccSend.Request $2 %request
}
;on *:parseline:in:$($+(* PRIVMSG ,$me, :,$chr(1),DCC SEND *)): { echo -s DCC SEND ParseIn $.parseline }
;on *:parseline:in:$($+(* PRIVMSG ,$me, :,$chr(1),DCC ACCEPT *,$chr(1),*)): { echo -s DCC ACCEPT ParseIn $.parseline }
;on *:parseline:in:$($+(* PRIVMSG ,$me, :,$chr(1),DCC RESUME *,$chr(1),*)): { echo -s DCC RESUME ParseIn $.parseline }
;on *:parseline:in:$(*PRIVMSG *:*DCC *): { echo -s DCC ParseIn $.parseline }
;on *:parseline:out:$($+(PRIVMSG *:,$chr(1),DCC SEND * ,$longip($ip), *,$chr(1),*)): { echo -s SEND ParseOut $.parseline }
;on *:parseline:out:$($+(PRIVMSG *:,$chr(1),DCC ACCEPT *,$chr(1),*)): { echo -s DCC ACCEPT ParseOut $.parseline }
;on *:parseline:out:$($+(PRIVMSG *:,$chr(1),DCC RESUME *,$chr(1),*)): { echo -s DCC RESUME ParseOut $.parseline }
;on *:parseline:out:PRIVMSG #*: { echo -s CHAN ParseOut $.parseline }
;on $*:parseline:out:$($+(/^PRIVMSG .* :[^,$chr(1),]/)): { echo -s PRIV ParseOut $.parseline }
;on *:parseline:out:PRIVMSG *: { echo -s DFLT ParseOut $.parseline }
on *:filercvd:*: DLF.DccSend.FileRcvd $1-
on *:getfail:*: DLF.DccSend.GetFailed $1-
; Channel messages
on ^*:text:*:%DLF.channels: {
if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1-
if ($DLF.Chan.IsChanEvent) DLF.Chan.Text $1-
}
on ^*:action:*:%DLF.channels: {
if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1-
if ($DLF.Chan.IsChanEvent) DLF.Chan.Action $1-
}
on ^*:notice:*:%DLF.channels: {
if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1-
if ($DLF.Chan.IsChanEvent) DLF.Chan.Notice $1-
}
; oNotice events
on ^@*:text:*:#: { if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1- }
on ^@*:action:*:#: { if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1- }
on ^@*:notice:*:#: { if ($DLF.oNotice.IsoNotice) DLF.oNotice.Channel $1- }
; Private messages
on ^*:text:*$decode*:?: { DLF.Priv.DollarDecode $1- }
on ^*:notice:*$decode*:?: { DLF.Priv.DollarDecode $1- }
on ^*:action:*$decode*:?: { DLF.Priv.DollarDecode $1- }
on ^*:open:?:*$decode*: { DLF.Priv.DollarDecode $1- }
on ^*:text:*:?: {
DLF.Priv.Text $1-
}
on ^*:notice:DCC CHAT *:?: {
DLF.DccChat.ChatNotice $1-
}
on ^*:notice:DCC SEND *:?: {
DLF.DccSend.SendNotice $1-
}
on ^*:action:*:?: {
DLF.Priv.Action $1-
}
on ^*:notice:*:?: {
DLF.Priv.Notice $1-
}
on ^*:open:?:*: {
DLF.Priv.Open $1-
}
; ctcp
ctcp ^*:FINGER*:#: { DLF.Chan.ctcpBlock $1- }
ctcp ^*:TIME*:#: { DLF.Chan.ctcpBlock $1- }
ctcp ^*:PING*:#: { DLF.Chan.ctcpBlock $1- }
ctcp ^*:FINGER*:?: { DLF.Priv.ctcpBlock $1- }
ctcp ^*:TIME*:?: { DLF.Priv.ctcpBlock $1- }
ctcp ^*:PING*:?: { DLF.Priv.ctcpBlock $1- }
ctcp *:DCC CHAT *:?: { DLF.DccChat.Chat $1- }
ctcp *:DCC SEND *:?: { DLF.DccSend.Send $1- }
; Do not process DCC ACCEPT and RESUME - allow mIRC to handle them.
ctcp *:DCC ACCEPT *:?: { noop }
ctcp *:DCC RESUME *:?: { noop }
ctcp *:*:?: { DLF.Priv.ctcp $1- }
ctcp *:*:%DLF.channels: { if ($DLF.Chan.IsChanEvent) DLF.Chan.ctcp $1- }
on *:ctcpreply:VERSION *: {
if (%DLF.ops.advertpriv) DLF.Ops.VersionReply $1-
DLF.Event.ctcpReply $1-
}
on *:ctcpreply:*: { DLF.Event.ctcpReply $1- }
; We should not need to handle the open event because unwanted dcc chat requests have been halted.
;on ^*:open:=: { DLF.DccChat.Open $1- }
; RPL_iSupport 005 CNOTICE / CPRIVMSG to avoid 439 Target change too frequently message
raw 005:*: { DLF.iSupport.Raw005 $1- }
; Filter away messages
raw 301:*: { DLF.Away.Filter $1- }
; Show messages in status AND active windows (rather than just status)
; Too many channels
raw 405:*: { DLF.Redirect $1-2 unable to join channel (too many channels open) }
; Unknown command
raw 421:*: { DLF.Redirect $1- }
; Nickname is already in use
raw 433:*: { DLF.Redirect $1- }
; Nick change too fast
raw 438:*: { DLF.Redirect $1- }
; Channel requires authentication
raw 477:*: { DLF.Redirect $1 $3-5 $2 $6- }
; Echo messages to active window as well as status window
; If active window is NOT on same CID, echo to all channel / private windows
alias -l DLF.Redirect {
DLF.Watch.Called DLF.Redirect $1-
DLF.AlreadyHalted $1-
if ($halted) halt
var %single
if ($dqwindow & 2) %single = d
echo -ti2fcs $+ %single Normal $2-
; Echo to channels
var %i $chan(0)
while (%i) {
echo -ti2fc Normal $chan(%i) $2-
dec %i
}
; Echo to query windows
var %i $query(0)
while (%i) {
echo -ti2fc Normal $query(%i) $2-
dec %i
}
; Echo to ops chat windows
var %i $window(@#*,0)
while (%i) {
if ($window(@#*,%i).type = custom) echo -ti2fc Normal $window(@#*,%i) $2-
dec %i
}
halt
}
on *:close:@DLF.Ads.*: { DLF.Ads.Close }
on *:close:@DLF.Filter.*: { DLF.Filter.Close }
; Adjust titlebar on window change
on *:active:*: { DLF.Stats.Active }
; Process Ctrl-C on @find window
on *:keydown:@dlf.@find.*:*: { if ((!$keyrpt) && ($keyval == 3)) [email protected] }
; Echo notice users online/offline to query windows
on *:notify: { if (($query($nick)) && ($query($nick).wid != $activewid)) echo -ct Notify $nick * $nick is on IRC }
on *:unotify: { if (($query($nick)) && ($query($nick).wid != $activewid)) echo -ct Notify $nick * $nick $sbr($address) has left IRC }
#dlf_events end
; Following is just in case group gets turned off
on *:text:*:#: { DLF.Groups.Events }
alias -l DLF.Groups.Events {
if (%DLF.enabled) {
.enable #dlf_events
!.events on
!.raw on
!.ctcps on
}
else .disable #dlf_events
}
; Override /events/raw/ctcp commands if dlF is enabled - without these dlF does not work
alias events { DLF.CommandDisable events $1- }
alias ctcps { DLF.CommandDisable ctcps $1- }
alias raw { DLF.CommandDisable raw $1- }
alias -l DLF.CommandDisable {
if ((%DLF.enabled) && ($2 == off)) echo -ac Info * / $+ $1 $+ : you cannot turn off $1 whilst dlFilter is enabled.
elseif ($show) $(! $+ $1-,2)
else $(!. $+ $1-,2)
}
; Log to filter window if halted by a previous script
alias -l DLF.AlreadyHalted { if ($halted) DLF.Watch.Log Filtered: Already halted by previous script: $1- }
; ========== Event splitters ==========
; Command typed by user
alias -l DLF.Event.Input {
DLF.Watch.Called DLF.Event.Input $1 : $2-
var %win $winscript
; if a ctcp or xdcc request, record it to match to replies
if ($2 == /ctcp) DLF.ctcpSend.Request $1-
elseif ($2 $4 $5 == /MSG XDCC SEND) DLF.DccSend.Request $1 $+(XDCC-,$3) $2-
}
; Record ctcp requests issued by the user for 60s so we can determine whether ctcpreply is solicited or unsolicited
alias -l DLF.ctcpSend.Request {
hadd -mu60z DLF.ctcpSend.Requests $+($network,|,$3,|,$4,|,$1) 60
}
; ctcpreplies are always private - need to look inside to determine whether it is in response to a private or channel ctcp
alias -l DLF.Event.ctcpReply {
DLF.ctcpSend.Reply $1-
var %chan $gettok($rawmsg,3,$asc($space))
if ($left(%chan,1) !isin $chantypes) DLF.Priv.ctcpReply $1-
elseif ($DLF.Chan.IsDlfChan(%chan)) DLF.Chan.ctcpReply $1-
}
; If response to manual ctcp, echo to appropriate windows and halt
alias -l DLF.ctcpSend.Reply {
var %match $+($network,|*|,$1,|*)
var %i $hfind(DLF.ctcpSend.Requests,%match,0,w), %found $false
while (%i) {
var %item $hfind(DLF.ctcpSend.Requests,%match,%i,w)
var %target $gettok(%item,2,$asc(|))
var %win $gettok(%item,4,$asc(|))
if ((($left(%target,1) !isin $chantypes) && (%target == $nick)) $&
|| (($left(%target,1) isin $chantypes) && ($nick(%target,$nick)))) {
DLF.Win.Echo $event $gettok(%win,1,$asc($space)) $nick $1-
%found = $true
}
dec %i
}
if (%found) halt
}
; When someone else joins a channel...
alias -l DLF.Event.Join {
DLF.Watch.Called DLF.Event.Join : $1-
DLF.AlreadyHalted $1-
; Colour this users responses in @find windows
[email protected] $nick 3
if ($DLF.Chan.IsChanEvent) {
; Colour this users advertisement lines
DLF.Ads.ColourLines $event $nick $chan
; Resend any pending triggers that would have been dropped when user parted
DLF.DccSend.Rejoin
; If advertising privately, see if they are running mIRC / dlf
; Wait for 5 sec for user's modes to be applied to avoid checking ops
if ((%DLF.ops.advertpriv) && ($me isop $chan)) .timer 1 5 .signal DLF.Ops.RequestVersion $nick
if (%DLF.filter.joins) DLF.User.Channel $1-
}
}
; When I join a channel...
; This event happens at start of join process before channel user list has been sent to mirc
; Most handling needs to happen after list of users is received
alias -l DLF.Event.MeJoin {
DLF.Watch.Called DLF.Event.MeJoin : $1-
DLF.AlreadyHalted $1-
if ($DLF.Chan.IsDlfChan($chan)) DLF.Update.Announce
}
; When userlist of the channel I joined is complete...
alias -l DLF.Event.MeJoinComplete {
DLF.Watch.Called DLF.Event.MeJoinComplete : $1-
DLF.AlreadyHalted $1-
; Add operators to existing oNotice windows
DLF.oNotice.AddChanNicks $2
DLF.AlreadyHalted $1-
; Recolour responses in @find windows
[email protected] Join $2
; Recolour responses in ads windows
if ($DLF.Chan.IsDlfChan($2)) DLF.Ads.ColourLines Join $1-2
}
; When someone else parts a channel or is kicked...
alias -l DLF.Event.Leave {
DLF.Watch.Called DLF.Event.Leave : $1-
DLF.AlreadyHalted $1-
; Remove user from oNotice windows
DLF.oNotice.DelNick
; Recolour responses in @find windows
[email protected] $nick 14
if ($DLF.Chan.IsChanEvent) {
; Recolour responses in ads windows
DLF.Ads.ColourLines $event $nick $chan
if (($event == part) && (%DLF.filter.parts)) DLF.User.Channel $1-
if (($event == kick) && (%DLF.filter.kicks)) DLF.User.Channel $1-
}
}
; When I part a channel or am kicked ...
alias -l DLF.Event.MeLeave {
DLF.Watch.Called DLF.Event.MeLeave : $1-
DLF.AlreadyHalted $1-
DLF.SearchBot.MeLeave $chan
; Remove all users from oNotice window
DLF.oNotice.DelNickAllChans
; Colour find responses now that I am no longer in channel
[email protected] $event $chan
; Colour ads now that I am no longer in channel
if ($DLF.Chan.IsDlfChan($chan)) DLF.Ads.ColourLines $event $nick $chan
}
; When someone else changes their nick...
alias -l DLF.Event.Nick {
DLF.Watch.Called DLF.Event.Nick : $1-
DLF.AlreadyHalted $1-
; Change user in oNotice windows
DLF.oNotice.NickChg $1-
; Change user in Ops hash tables e.g. mIRC version etc.
DLF.Ops.NickChg
; TODO Change user in @find windows
; Change user in Ads windows
DLF.Ads.NickChg
; Change user in query / chat windows
DLF.Win.NickChg
if ($DLF.Chan.IsUserEvent(%DLF.filter.nicks)) DLF.User.NoChannel $1-
}
; When someone else quits...
alias -l DLF.Event.Quit {
DLF.Watch.Called DLF.Event.Quit : $1-
DLF.AlreadyHalted $1-
; Remove user from oNotice window
DLF.oNotice.DelNick
; Recolour responses in @find windows
[email protected] $nick 14
if ($DLF.Chan.IsUserEvent) {
; Recolour responses in ads windows
DLF.Ads.ColourLines $event $nick
if (%DLF.filter.quits) DLF.User.NoChannel $1-
}
}
alias -l DLF.Event.MeConnect {
DLF.Watch.Called DLF.Event.MeConnect : $1-
DLF.AlreadyHalted $1-
set -ez [ [ $+(%,DLF.CONNECT.CID,$cid) ] ] 40
DLF.Win.ChangeNetwork
if ($DLF.ActiveConnections == 1) DLF.Update.Check
}
alias -l DLF.Event.JustConnected {
if ($var($+(DLF.CONNECT.CID,$cid),1).value) return $true