-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathRIDEN.py
More file actions
2918 lines (2730 loc) · 163 KB
/
RIDEN.py
File metadata and controls
2918 lines (2730 loc) · 163 KB
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
from GENERATOR import *
from datetime import datetime
from time import sleep
from bs4 import BeautifulSoup
from gtts import gTTS
from googletrans import Translator
from multiprocessing import Pool, Process
from ffmpy import FFmpeg
import time, random, asyncio, timeit, sys, json, codecs, threading, glob, re, string, os, requests, subprocess, six, urllib, urllib.parse, ast, pytz, wikipedia, pafy, youtube_dl, atexit
print ("\n\n --- WELCOME TO RFU SEKAWAN ---\n")
cl = RIDEN()
#cl = RIDEN(authTokenRFU="YOUR TOKEN")
cl.log("YOUR TOKEN : {}".format(str(cl.authToken)))
channel = RIDENChannel(cl,cl.server.CHANNEL_ID['LINE_TIMELINE'])
cl.log("CHANNEL TOKEN : " + str(channel.getChannelResult()))
riden1 = RIDEN()
#riden1 = RIDEN(authTokenRFU="YOUR TOKEN")
riden1.log("YOUR TOKEN : {}".format(str(riden1.authToken)))
channel = RIDENChannel(riden1,riden1.server.CHANNEL_ID['LINE_TIMELINE'])
riden1.log("CHANNEL TOKEN : " + str(channel.getChannelResult()))
riden2 = RIDEN()
#riden2 = RIDEN(authTokenRFU="YOUR TOKEN")
riden2.log("YOUR TOKEN : {}".format(str(riden2.authToken)))
channel = RIDENChannel(riden2,riden2.server.CHANNEL_ID['LINE_TIMELINE'])
riden2.log("CHANNEL TOKEN : " + str(channel.getChannelResult()))
riden3 = RIDEN()
#riden3 = RIDEN(authTokenRFU="YOUR TOKEN")
riden3.log("YOUR TOKEN : {}".format(str(riden3.authToken)))
channel = RIDENChannel(riden3,riden3.server.CHANNEL_ID['LINE_TIMELINE'])
riden3.log("CHANNEL TOKEN : " + str(channel.getChannelResult()))
print ("LOGIN SUCCESS RFU")
clProfile = cl.getProfile()
clSettings = cl.getSettings()
RIDEN = RIDENPoll(cl)
Rfu = [cl,riden1,riden2,riden3]
mid = cl.profile.mid
JSMID1 = riden1.profile.mid
JSMID2 = riden2.profile.mid
JSMID3 = riden3.profile.mid
RfuBot=[mid,JSMID1,JSMID2,JSMID3]
Owner=["uc721ad1f11fb7e128453ba5a27424998","u2fd9d66d7006f6dac03dc94950fa83c8"]
RfuSekawan = RfuBot + Rfu + Owner
contact = cl.getProfile()
backup = cl.getProfile()
backup.displayName = contact.displayName
backup.statusMessage = contact.statusMessage
backup.pictureStatus = contact.pictureStatus
Squad = {
"UnsendPesan":False,
"SpamInvite":False,
"Contact":False,
"GName":"Ardian Purnama",
"AutoRespon":False,
"KickRespon":False,
"KillOn":False,
"KickOn":False,
"Upfoto":False,
"UpfotoBot":False,
"UpfotoGroup":False,
"Steal":False,
"Invite":False,
"Copy":False,
"autoAdd":True,
"PesanAdd":"Terima Kasih Sudah Add Saya",
"ContactAdd":{},
"autoBlock":False,
"autoJoin":True,
"AutojoinTicket":False,
"AutoReject":False,
"autoRead":False,
"IDSticker":False,
"Timeline":False,
"Welcome":False,
"BackupBot":True,
"WcText": "Welcome My Friend",
"Leave":False,
"WvText": "See You My Friend",
"Mic":False,
"MicDel":False,
"Adminadd":False,
"AdminDel":False,
"Gift":False,
"readMember":{},
"readPoint":{},
"readTime":{},
"ROM":{},
"Blacklist":{},
"Ban":False,
"Unban":False,
"AddMention":True,
"Admin": {
"uc721ad1f11fb7e128453ba5a27424998":True, #TARO MID ADMIN NYA DISINI
"u2fd9d66d7006f6dac03dc94950fa83c8":True
},
}
Mozilla = {
"userAgent": [
"Mozilla/5.0 (X11; U; Linux i586; de; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (X11; U; Linux amd64; rv:5.0) Gecko/20100101 Firefox/5.0 (Debian)",
"Mozilla/5.0 (X11; U; Linux amd64; en-US; rv:5.0) Gecko/20110619 Firefox/5.0",
"Mozilla/5.0 (X11; Linux) Gecko Firefox/5.0",
"Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 FirePHP/0.5",
"Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 Firefox/5.0",
"Mozilla/5.0 (X11; Linux x86_64) Gecko Firefox/5.0",
"Mozilla/5.0 (X11; Linux ppc; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (X11; Linux AMD64) Gecko Firefox/5.0",
"Mozilla/5.0 (X11; FreeBSD amd64; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 6.2; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:5.0) Gecko/20110619 Firefox/5.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 6.1; rv:6.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 6.1.1; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 5.2; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 5.1; U; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 5.1; rv:2.0.1) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 5.0; WOW64; rv:5.0) Gecko/20100101 Firefox/5.0",
"Mozilla/5.0 (Windows NT 5.0; rv:5.0) Gecko/20100101 Firefox/5.0"
],
"mimic": {
"copy": False,
"conpp": False,
"status": False,
"target": {}
}
}
setTime = {}
setTime = Squad['readTime']
mulai = time.time()
msg_dict = {}
ProfileMe = {
"displayName": "",
"statusMessage": "",
"pictureStatus": ""
}
ProfileMe["displayName"] = clProfile.displayName
ProfileMe["statusMessage"] = clProfile.statusMessage
ProfileMe["pictureStatus"] = clProfile.pictureStatus
RfuProtect = {
'protect':False,
'linkprotect':False,
'inviteprotect':False,
'cancelprotect':False,
'ProtectCancelled':False,
}
RfuCctv={
"Point1":{},
"Point2":{},
"Point3":{}
}
Help ="""
GENERAL PYTHON 3
COMMAND
me
my name
my bio
my picture
my cover
my video
speed
responsename
my bot
my team
spam on [jmlah teks]
cekmkd: [mid]
banlock [@]
banlist
contact ban
ban:on
unban:on
clear ban
blocklist
friendlist
friendlist mid
mid [@]
profile [@]
runtime
broadcast:
contactbc:
adminadd [@]
admindel [@]
admin:add-on
admin:del-on
changename:
changenameall:
changebio:
changebioall:
remove pesan
restart
bot logout
kick [@]
status
allprotect on/off
backup on/off
unsend on/off
changepp on/off
changeppbot on/off
timeline on/off
autojoin on/off
autoreject on/off
auto jointicket on/off
gift:on/off
copy on/off
clone [@]
comeback
steal on/off
contact on/off
mic:add-on
mic:del-on
mimic on/off
mimiclist
refresh
___[ GROUP ]___
guard
riden bye
leaveall grup
kick [on,off->kickall]
invite on/off
kill on/off
rejectall grup
lurking on/off/reset
lurking read
sider on/off
mentionall
welcome on/off
changewelcome: [teks]
leave on/off
changeleave: [teks]
memberlist
link on/off
my grup
r1 grup
r2 grup
r3 grup
gurl
gcreator
invite gcreator
ginfo
grup id
cfotogrup on/off
spaminvite on/off
___[ MEDIA ]____
topnews
data birth:
urban:
sslink:
maps:
cekcuaca:
jadwalshalat:
idline:
say-id:
say-en:
say-jp:
say-ar:
say-ko:
apakah:
kapan:
wikipedia:
kalender
image:
youtube:
___[ TRANSLATOR ]___
indonesian:
english:
korea:
japan:
thailand:
arab:
malaysia:
jawa:
THANKS TO
RFU SEKAWAN
""""________________________"
#------------------------------------------------ SCRIP DEF ----------------------------------------------------------#
def waktu(secs):
mins, secs = divmod(secs,60)
hours, mins = divmod(mins,60)
days, hours = divmod(hours,24)
month, days = divmod(days,30)
year, month = divmod(month,12)
century, year = divmod(year,100)
return '\n%02d Abad\n%02d Tahun\n%02d Bulan\n%02d Hari\n%02d Jam\n%02d Menit\n%02d Detik' % (century, year, month, days, hours, mins, secs)
def restart_program():
python = sys.executable
os.execl(python, python, * sys.argv)
def RIDEN_FAST_USER(fast):
global time
global ast
global groupParam
try:
if fast.type == 0:
return
if fast.type == 5:
if Squad["autoAdd"] == True:
if (Squad["PesanAdd"] in [""," ","\n",None]):
pass
else:
Squad["ContactAdd"][fast.param2] = True
usr = cl.getContact(op.param2)
cl.sendMessage(fast.param1, "Haii {} " + str(Squad["PesanAdd"]).format(usr.displayName))
cl.sendMessage(fast.param1, None, contentMetadata={'mid':mid}, contentType=13)
if fast.type == 5:
if Squad['autoBlock'] == True:
try:
usr = cl.getContact(op.param2)
cl.sendMessage(fast.param1, "Haii {} Sorry Auto Block , Komen di TL dulu ya kalo akun asli baru di unblock".format(usr.displayName))
cl.talk.blockContact(0, fast.param1)
Squad["Blacklist"][fast.param2] = True
except Exception as e:
cl.log("[SEND_MESSAGE] ERROR : " + str(e))
#--------------------------------------------- PARAM SCRIP AUTO JOIN BOT & AUTO REJECT ------------------------------------------------#
if fast.type == 13:
if mid in fast.param3:
if Squad['autoJoin'] == True:
if fast.param2 in RfuSekawan and fast.param2 in Squad["Admin"]:
cl.acceptGroupInvitation(fast.param1)
print ("ANDA JOIN DI GRUP")
if JSMID1 in fast.param3:
if Squad['autoJoin'] == True:
if fast.param2 in RfuSekawan and fast.param2 in Squad["Admin"]:
riden1.acceptGroupInvitation(fast.param1)
print ("BOT 1 JOIN GRUP")
if JSMID2 in fast.param3:
if Squad['autoJoin'] == True:
if fast.param2 in RfuSekawan and fast.param2 in Squad["Admin"]:
riden2.acceptGroupInvitation(fast.param1)
print ("BOT 2 JOIN GRUP")
if JSMID3 in fast.param3:
if Squad['autoJoin'] == True:
if fast.param2 in RfuSekawan and fast.param2 in Squad["Admin"]:
riden3.acceptGroupInvitation(fast.param1)
print ("BOT 3 JOIN GRUP")
pass
if fast.type == 13:
if mid in fast.param3:
if Squad['AutoReject'] == True:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
gid = cl.getGroupIdsInvited()
for i in gid:
cl.rejectGroupInvitation(i)
if JSMID1 in fast.param3:
if Squad["AutoReject"] == True:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
gid = riden1.getGroupIdsInvited()
for i in gid:
riden1.rejectGroupInvitation(i)
if JSMID2 in fast.param3:
if Squad["AutoReject"] == True:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
gid = riden2.getGroupIdsInvited()
for i in gid:
riden2.rejectGroupInvitation(i)
if JSMID3 in fast.param3:
if Squad["AutoReject"] == True:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
gid = riden3.getGroupIdsInvited()
for i in gid:
riden3.rejectGroupInvitation(i)
pass
#------------------- ( 1 ) ------------------------- PEMBATAS SCRIP SIDER & WC LV ------------------------------------------------#
elif fast.type == 55:
try:
if RfuCctv['Point1'][fast.param1]==True:
if fast.param1 in RfuCctv['Point2']:
Name = cl.getContact(fast.param2).displayName
if Name in RfuCctv['Point3'][fast.param1]:
pass
else:
RfuCctv['Point3'][fast.param1] += "\n~" + Name
if " " in Name:
nick = Name.split(' ')
if len(nick) == 2:
cl.mentionWithRFU(fast.param1,fast.param2," Hii\n","" + "\n Nyimak yah kak?" )
else:
cl.mentionWithRFU(fast.param1,fast.param2," Nah\n","" + "\n Nongol Sini Chat kak ??" )
else:
cl.mentionWithRFU(fast.param1,fast.param2," Hey\n","" + "\n What Are You Doing?" )
else:
pass
else:
pass
except:
pass
if fast.type == 55:
try:
if fast.param1 in Squad['readPoint']:
if fast.param2 in Squad['readMember'][fast.param1]:
pass
else:
Squad['readMember'][fast.param1] += fast.param2
Squad['ROM'][fast.param1][fast.param2] = fast.param2
else:
pass
except:
pass
if fast.type == 17:
if Squad["Welcome"] == True:
if fast.param2 not in Rfu:
ginfo = cl.getGroup(fast.param1)
cl.mentionWithRFU(fast.param1,fast.param2," Hii","" + "\n " + str(Squad['WcText']))
cl.sendMessage(fast.param1, None, contentMetadata={'mid':fast.param2}, contentType=13)
print ("MEMBER HAS JOIN THE GROUP")
if fast.type == 15:
if Squad["Leave"] == True:
if fast.param2 not in Rfu:
ginfo = cl.getGroup(fast.param1)
cl.mentionWithRFU(fast.param1,fast.param2," Hii","" + "\n " + str(Squad['LvText']))
cl.sendMessage(fast.param1, None, contentMetadata={'mid':fast.param2}, contentType=13)
print ("MEMBER HAS LEFT THE GROUP")
#--------------------------------------------- PARAM SCRIP FOR BACKUP BOT ------------------------------------------------#
if fast.type == 19:
if Squad["BackupBot"] == True:
if mid in fast.param3:
if fast.param2 in RfuBot:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
pass
else:
Squad["Blacklist"][fast.param2] = True
f=codecs.open('st2__b.json','w','utf-8')
json.dump(Squad, f, sort_keys=True, indent=4,ensure_ascii=False)
try:
riden1.findAndAddContactsByMid(fast.param3)
riden1.kickoutFromGroup(fast.param1,[fast.param2])
riden1.inviteIntoGroup(fast.param1,[fast.param3])
cl.acceptGroupInvitation(fast.param1)
except:
try:
riden2.findAndAddContactsByMid(fast.param3)
riden2.kickoutFromGroup(fast.param1,[fast.param2])
riden2.inviteIntoGroup(fast.param1,[fast.param3])
cl.acceptGroupInvitation(fast.param1)
except:
try:
riden3.findAndAddContactsByMid(fast.param3)
riden3.kickoutFromGroup(fast.param1,[fast.param2])
riden3.inviteIntoGroup(fast.param1,[fast.param3])
cl.acceptGroupInvitation(fast.param1)
except:
try:
x = riden1.getGroup(fast.param1)
x.preventedJoinByTicket = False
riden1.updateGroup(x)
Riden = riden1.reissueGroupTicket(fast.param1)
cl.acceptGroupInvitationByTicket(fast.param1,Riden)
riden1.acceptGroupInvitationByTicket(fast.param1,Riden)
riden2.acceptGroupInvitationByTicket(fast.param1,Riden)
riden3.acceptGroupInvitationByTicket(fast.param1,Riden)
x = cl.getGroup(fast.param1)
x.preventedJoinByTicket = True
cl.updateGroup(x)
riden1.kickoutFromGroup(fast.param1,[fast.param2])
Riden = cl.reissueGroupTicket(fast.param1)
except:
pass
return
if JSMID1 in fast.param3:
if fast.param2 in RfuBot:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
pass
else:
Squad["Blacklist"][fast.param2] = True
f=codecs.open('st2__b.json','w','utf-8')
json.dump(Squad, f, sort_keys=True, indent=4,ensure_ascii=False)
try:
riden2.findAndAddContactsByMid(fast.param3)
riden2.kickoutFromGroup(fast.param1,[fast.param2])
riden2.inviteIntoGroup(fast.param1,[fast.param3])
riden1.acceptGroupInvitation(fast.param1)
except:
try:
riden3.findAndAddContactsByMid(fast.param3)
riden3.kickoutFromGroup(fast.param1,[fast.param2])
riden3.inviteIntoGroup(fast.param1,[fast.param3])
riden1.acceptGroupInvitation(fast.param1)
except:
try:
cl.findAndAddContactsByMid(fast.param3)
cl.kickoutFromGroup(fast.param1,[fast.param2])
cl.inviteIntoGroup(fast.param1,[fast.param3])
riden1.acceptGroupInvitation(fast.param1)
except:
try:
x = riden2.getGroup(fast.param1)
x.preventedJoinByTicket = False
riden2.updateGroup(x)
Riden = riden2.reissueGroupTicket(fast.param1)
riden1.acceptGroupInvitationByTicket(fast.param1,Riden)
x = riden1.getGroup(fast.param1)
x.preventedJoinByTicket = True
riden1.updateGroup(x)
riden2.kickoutFromGroup(fast.param1,[fast.param2])
Ticket = riden1.reissueGroupTicket(fast.param1)
except:
pass
return
if JSMID2 in fast.param3:
if fast.param2 in RfuBot:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
pass
else:
Squad["Blacklist"][fast.param2] = True
f=codecs.open('st2__b.json','w','utf-8')
json.dump(Squad, f, sort_keys=True, indent=4,ensure_ascii=False)
try:
cl.findAndAddContactsByMid(fast.param3)
cl.kickoutFromGroup(fast.param1,[fast.param2])
cl.inviteIntoGroup(fast.param1,[fast.param3])
riden2.acceptGroupInvitation(fast.param1)
except:
try:
riden1.findAndAddContactsByMid(fast.param3)
riden1.kickoutFromGroup(fast.param1,[fast.param2])
riden1.inviteIntoGroup(fast.param1,[fast.param3])
riden2.acceptGroupInvitation(fast.param1)
except:
try:
riden3.findAndAddContactsByMid(fast.param3)
riden3.kickoutFromGroup(fast.param1,[fast.param2])
riden3.inviteIntoGroup(fast.param1,[fast.param3])
riden2.acceptGroupInvitation(fast.param1)
except:
try:
x = cl.getGroup(fast.param1)
x.preventedJoinByTicket = False
cl.updateGroup(x)
Riden = cl.reissueGroupTicket(fast.param1)
riden2.acceptGroupInvitationByTicket(fast.param1,Riden)
x = riden2.getGroup(fast.param1)
x.preventedJoinByTicket = True
riden2.updateGroup(x)
riden3.kickoutFromGroup(fast.param1,[fast.param2])
Ticket = riden2.reissueGroupTicket(fast.param1)
except:
pass
return
if JSMID3 in fast.param3:
if fast.param2 in RfuBot:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
pass
else:
Squad["Blacklist"][fast.param2] = True
f=codecs.open('st2__b.json','w','utf-8')
json.dump(Squad, f, sort_keys=True, indent=4,ensure_ascii=False)
try:
cl.findAndAddContactsByMid(fast.param3)
cl.kickoutFromGroup(fast.param1,[fast.param2])
cl.inviteIntoGroup(fast.param1,[fast.param3])
riden3.acceptGroupInvitation(fast.param1)
except:
try:
riden1.findAndAddContactsByMid(fast.param3)
riden1.kickoutFromGroup(fast.param1,[fast.param2])
riden1.inviteIntoGroup(fast.param1,[fast.param3])
riden3.acceptGroupInvitation(fast.param1)
except:
try:
riden2.findAndAddContactsByMid(fast.param3)
riden2.kickoutFromGroup(fast.param1,[fast.param2])
riden2.inviteIntoGroup(fast.param1,[fast.param3])
riden3.acceptGroupInvitation(fast.param1)
except:
try:
x = cl.getGroup(fast.param1)
x.preventedJoinByTicket = False
cl.updateGroup(x)
Riden = cl.reissueGroupTicket(fast.param1)
riden3.acceptGroupInvitationByTicket(fast.param1,Riden)
x = riden3.getGroup(fast.param1)
x.preventedJoinByTicket = True
riden2.updateGroup(x)
cl.kickoutFromGroup(fast.param1,[fast.param2])
Ticket = riden3.reissueGroupTicket(fast.param1)
except:
pass
return
if fast.type == 13:
if fast.param3 in Squad["Blacklist"]: # AUTO KICK JIKA YG DI BLACKLIST MASUK
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
random.choice(Rfu).cancelGroupInvitation(fast.param1,[fast.param3])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param3])
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist, Please to Unfollow blacklist first.\n")
#---------------------------------- SCRIP PROTECT GRUP -------------------------------------#
if fast.type == 19:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["protect"] == True:
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
cl.findAndAddContactsByMid(fast.param3)
cl.inviteIntoGroup(fast.param1,[fast.param3])
Squad["Blacklist"][fast.param2] = True
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
if fast.type == 11:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["linkprotect"] == True:
Squad["Blacklist"][fast.param2] = True
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
Squad["Blacklist"][fast.param2] = True
if fast.type == 13:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["inviteprotect"] == True:
Squad["Blacklist"][fast.param2] = True
random.choice(Rfu).cancelGroupInvitation(fast.param1,[fast.param3])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param3])
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["inviteprotect"] == True:
Squad["Blacklist"][fast.param2] = True
random.choice(Rfu).cancelGroupInvitation(fast.param1,[fast.param3])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param3])
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["cancelprotect"] == True:
Squad["Blacklist"][fast.param2] = True
random.choice(Rfu).cancelGroupInvitation(fast.param1,[fast.param3])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param3])
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
if fast.type == 32:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in RfuBot:
pass
elif RfuProtect["ProtectCancelled"] == True:
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
cl.findAndAddContactsByMid(fast.param3)
cl.inviteIntoGroup(fast.param1,[fast.param3])
Squad["Blacklist"][fast.param2] = True
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
if fast.type == 19:
if fast.param3 in Squad["Admin"]: # JIKA ADMIN KE KICK
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
riden1.findAndAddContactsByMid(fast.param3)
riden1.inviteIntoGroup(fast.param1,[fast.param3])
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
Squad["Blacklist"][fast.param2] = True
riden1.sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
riden1.sendMessage(fast.param1, "User Added Blacklist (*-_-)/")
if fast.type == 13:
if fast.param2 and fast.param3 in Squad["Blacklist"]: # AUTO KICK JIKA YG DI BLACKLIST MASUK
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
random.choice(Rfu).cancelGroupInvitation(fast.param1,[fast.param3])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param3])
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist, Please to Unfollow blacklist first.\n")
if fast.type == 17:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in Squad["Blacklist"]: # AUTO KICK JIKA YG DI BLACKLIST MASUK
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
Squad["Blacklist"][op.param2] = True
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist, Please to Unfollow blacklist first.\n")
if fast.type == 55:
if fast.param2 not in RfuSekawan and fast.param2 not in Owner and fast.param2 not in Squad["Admin"]:
if fast.param2 in Squad["Blacklist"]: # AUTO KICK JIKA YG DI BLACKLIST MASUK
random.choice(Rfu).kickoutFromGroup(fast.param1,[fast.param2])
G = random.choice(Rfu).getGroup(fast.param1)
G.preventedJoinByTicket = True
random.choice(Rfu).updateGroup(G)
Squad["Blacklist"][op.param2] = True
random.choice(Rfu).sendMessage(fast.param1, None, contentMetadata={'mid': fast.param2}, contentType=13)
random.choice(Rfu).sendMessage(fast.param1, "User Added Blacklist, Please to Unfollow blacklist first.\n")
if fast.type == 46:
if fast.param2 in RfuBot:
cl.removeAllMessages()
riden1.removeAllMessages()
riden2.removeAllMessages()
riden3.removeAllMessages()
#------------------- ( 2 ) ------------------------- PEMBATAS SCRIP ------------------------------------------------#
if fast.type == 26:
msg = fast.message
text = msg.text
rfuText = msg.text
msg_id = msg.id
kirim = msg.to
user = msg._from
if msg.toType == 0 or msg.toType == 2:
if msg.toType == 0:
to = kirim
elif msg.toType == 2:
to = kirim
if msg.contentType == 0:
if Squad["autoRead"] == True:
cl.sendChatChecked(kirim, msg_id)
riden1.sendChatChecked(kirim, msg_id)
riden2.sendChatChecked(kirim, msg_id)
riden3.sendChatChecked(kirim, msg_id)
if kirim in Squad["readPoint"]:
if user not in Squad["ROM"][kirim]:
Squad["ROM"][kirim][user] = True
if user in Mozilla["mimic"]["target"] and Mozilla["mimic"]["status"] == True and Mozilla["mimic"]["target"][user] == True:
text = msg.text
if text is not None:
cl.sendMessage(kirim,text)
if Squad["UnsendPesan"] == True:
msg = fast.message
if msg.toType == 0:
cl.log(" {} - {} ".format(str(user), str(rfuText)))
else:
cl.log(" {} - {} ".format(str(kirim), str(rfuText)))
msg_dict[msg.id] = {"rider": rfuText, "pelaku": user, "createdTime": msg.createdTime, "contentType": msg.contentType, "contentMetadata": msg.contentMetadata}
if Squad["Timeline"] == True:
if msg.contentType == 16:
ret_ = "Info Postingan\n"
if msg.contentMetadata["serviceType"] == "GB":
contact = cl.getContact(user)
auth = "\n Penulis : {}".format(str(contact.displayName))
else:
auth = "\n Penulis : {}".format(str(contact.displayName))
ret_ += auth
if "stickerId" in msg.contentMetadata:
stck = "\n Stiker : https://line.me/R/shop/detail/{}".format(str(msg.contentMetadata["packageId"]))
ret_ += stck
if "mediaOid" in msg.contentMetadata:
object_ = msg.contentMetadata["mediaOid"].replace("svc=myhome|sid=h|","")
if msg.contentMetadata["mediaType"] == "V":
if msg.contentMetadata["serviceType"] == "GB":
ourl = "\n Objek URL : https://obs-us.line-apps.com/myhome/h/download.nhn?tid=612w&{}".format(str(msg.contentMetadata["mediaOid"]))
murl = "\n Media URL : https://obs-us.line-apps.com/myhome/h/download.nhn?{}".format(str(msg.contentMetadata["mediaOid"]))
else:
ourl = "\n Objek URL : https://obs-us.line-apps.com/myhome/h/download.nhn?tid=612w&{}".format(str(object_))
murl = "\n Media URL : https://obs-us.line-apps.com/myhome/h/download.nhn?{}".format(str(object_))
ret_ += murl
else:
if msg.contentMetadata["serviceType"] == "GB":
ourl = "\n Objek URL : https://obs-us.line-apps.com/myhome/h/download.nhn?tid=612w&{}".format(str(msg.contentMetadata["mediaOid"]))
else:
ourl = "\n Objek URL : https://obs-us.line-apps.com/myhome/h/download.nhn?tid=612w&{}".format(str(object_))
ret_ += ourl
if "text" in msg.contentMetadata:
dia = cl.getContact(user)
zx = ""
zxc = ""
zx2 = []
xpesan = 'Pengirim: '
xteam = str(dia.displayName)
pesan = ''
pesan2 = pesan+"@ARDIAN_GANTENG\n"
xlen = str(len(zxc)+len(xpesan))
xlen2 = str(len(zxc)+len(pesan2)+len(xpesan)-1)
zx = {'S':xlen, 'E':xlen2, 'M':dia.mid}
zx2.append(zx)
kata = "\n Tulisan : {}".format(str(msg.contentMetadata["text"]))
purl = "\n Post URL : {}".format(str(msg.contentMetadata["postEndUrl"]).replace("line://","https://line.me/R/"))
ret_ += purl
ret_ += kata
zxc += pesan2
pesan = xpesan + zxc + ret_ + ""
cl.sendMessage(kirim, pesan, contentMetadata={'MENTION':str('{"MENTIONEES":'+json.dumps(zx2).replace(' ','')+'}')}, contentType=0)
if fast.type == 65:
if Squad['UnsendPesan'] == True:
try:
you = fast.param1
msg.id = fast.param2
user = msg._from
if msg.id in msg_dict:
if msg_dict[msg.id]["pelaku"]:
pelaku = cl.getContact(msg_dict[msg.id]["pelaku"])
nama = pelaku.displayName
dia = "Detect Pesan Terhapus\n"
dia += "\n1. Name : " + nama
dia += "\n2. Taken : {}".format(str(msg_dict[msg.id]["createdTime"]))
dia += "\n3. Pesannya : {}".format(str(msg_dict[msg.id]["rider"]))
cl.mentionWithRFU(you,user," Nah","\n\n" +str(dia))
except:
cl.sendMessage(you, "Return")
if fast.type in [25,26]:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 7:
if Squad['IDSticker'] == True:
stk_id = msg.contentMetadata['STKID']
stk_ver = msg.contentMetadata['STKVER']
pkg_id = msg.contentMetadata['STKPKGID']
filler = "STICKER CHECKS\nSTKID : %s\nSTKPKGID : %s\nSTKVER : %s\n\nTHIS IS LINK\n\nline://shop/detail/%s" % (stk_id,pkg_id,stk_ver,pkg_id)
cl.mentionWithRFU(kirim,user,"My Code Sticker\n","" + "\n\n" + str(filler))
else:
pass
if fast.type == 25 or fast.type == 26:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 1:
if Squad['Upfoto'] == True:
if user in Owner:
path = cl.downloadObjectMsg(msg.id)
cl.updateProfilePicture(path)
cl.mentionWithRFU(kirim,user," Update Picture Success ","")
Squad['Upfoto'] = False
if fast.type == 25 or fast.type == 26:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 1:
if Squad['UpfotoBot'] == True:
if user in RfuSekawan or user in Squad["Admin"]:
path1 = riden1.downloadObjectMsg(msg.id)
path2 = riden2.downloadObjectMsg(msg.id)
path3 = riden3.downloadObjectMsg(msg.id)
riden1.updateProfilePicture(path1)
riden2.updateProfilePicture(path2)
riden3.updateProfilePicture(path3)
riden1.mentionWithRFU(kirim,user," Update Picture Success ","")
riden2.mentionWithRFU(kirim,user," Update Picture Success ","")
riden3.mentionWithRFU(kirim,user," Update Picture Success ","")
Squad['UpfotoBot'] = False
if fast.type == 25 or fast.type == 26:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 1:
if Squad['UpfotoGroup'] == True:
if user in RfuSekawan or user in Squad["Admin"]:
path = cl.downloadObjectMsg(msg.id)
cl.updateGroupPicture(kirim, path)
cl.mentionWithRFU(kirim,user," Update Picture Grup Success ","")
Squad['UpfotoGroup'] = False
if fast.type in [25,26]:
if Squad['Contact'] == True:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 13:
if 'displayName' in msg.contentMetadata:
contact = cl.getContact(msg.contentMetadata["mid"])
try:
cover = cl.getProfileCoverURL(user)
except:
cover = ""
cl.sendMessage(kirim,"Nama:\n" + msg.contentMetadata["displayName"] + "\n\nMid:\n" + msg.contentMetadata["mid"] + "\n\nBio:\n" + contact.statusMessage + "\n\nPicture URL:\nhttp://dl.profile.line-cdn.net/" + contact.pictureStatus + "\nCover URL:\n" + str(cover))
else:
contact = cl.getContact(msg.contentMetadata["mid"])
try:
cover = cl.getProfileCoverURL(user)
except:
cover = ""
cl.sendText(kirim,"Nama:\n" + contact.displayName + "\n\nMid:\n" + msg.contentMetadata["mid"] + "\n\nBio:\n" + contact.statusMessage + "\n\nPicture URL\nhttp://dl.profile.line-cdn.net/" + contact.pictureStatus + "\nCover URL:\n" + str(cover))
if fast.type == 25 or fast.type == 26:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 13:
try:
if user in RfuSekawan or user in Squad["Admin"]:
if Squad["Ban"] == True:
if msg.contentMetadata["mid"] in Squad["Blacklist"]:
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Sudah di daftar Blacklist"))
Squad['Ban'] = False
else:
Squad["Blacklist"][msg.contentMetadata["mid"]] = True
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Added in Blacklist"))
Squad['Ban'] = False
if Squad["Unban"] == True:
if msg.contentMetadata["mid"] in Squad["Blacklist"]:
del Squad["Blacklist"][msg.contentMetadata["mid"]]
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Succes dellete in Blacklist"))
Squad['Unban'] = False
else:
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Nothing in Blacklist"))
Squad['Unban'] = False
if Squad["Adminadd"] == True:
if msg.contentMetadata["mid"] in Squad["Admin"]:
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Sudah di daftar Admin"))
Squad['Adminadd'] = False
else:
Squad["Admin"][msg.contentMetadata["mid"]] = True
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Added in Admin"))
Squad['Adminadd'] = False
if Squad["AdminDel"] == True:
if msg.contentMetadata["mid"] in Squad["Admin"]:
del Squad["Admin"][msg.contentMetadata["mid"]]
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Succes dellete in Admin"))
Squad['AdminDel'] = False
else:
name = msg.contentMetadata["displayName"]
cl.sendMessage(kirim, name + str(" Nothing in Admin"))
Squad['AdminDel'] = False
except Exception as error:
cl.sendText(kirim, str(error))
if fast.type == 25 or fast.type == 26:
if Squad['Invite'] == True:
msg = fast.message
user = msg._from
kirim = msg.to
if msg.contentType == 13:
if user in RfuSekawan or user in Squad["Admin"]:
_name = msg.contentMetadata["displayName"]
invite = msg.contentMetadata["mid"]
groups = cl.getGroup(kirim)
pending = groups.invitee
targets = []
for s in groups.members:
if _name in s.displayName:
cl.sendText(msg.to, _name + " Sudah Berada DiGrup Ini")
else:
targets.append(invite)