Ejemplo n.º 1
0
def runLaZagne(category_selected='all', subcategories={}, password=None):
    """
    This function will be removed, still there for compatibility with other tools
    Everything is on the config/run.py file
    """
    for pwd_dic in run_lazagne(category_selected=category_selected, subcategories=subcategories, password=password):
        yield pwd_dic
Ejemplo n.º 2
0
def runLaZagne(category_selected='all', subcategories={}, password=None):
    """
    This function will be removed, still there for compatibility with other tools
    Everything is on the config/run.py file
    """
    for pwd_dic in run_lazagne(category_selected=category_selected, subcategories=subcategories, password=password):
        yield pwd_dic
Ejemplo n.º 3
0
    def password_dump(self, password=None):
        with tempfile.TemporaryDirectory() as tmp:
            constant.st = StandardOutput()

            out = StringIO()

            constant.output = 'txt'
            constant.folder_name = tmp

            level = logging.getLogger(LOGGER_ID).level

            if level == logging.DEBUG:
                constant.quiet_mode = False
            else:
                constant.quiet_mode = True

            formatter = logging.Formatter(fmt='%(message)s')
            stream = logging.StreamHandler(out)
            stream.setFormatter(formatter)
            root = logging.getLogger(__name__)
            root.setLevel(level)

            for r in root.handlers:
                r.setLevel(logging.CRITICAL)
            root.addHandler(stream)

            constant.st.first_title()

            if platforms.OS in [platforms.WINDOWS, platforms.DARWIN]:
                constant.user_password = password

                for _ in run_lazagne(category_selected="all", subcategories={password: password}, password=password):
                    pass
            else:
                for _ in run_lazagne(category_selected="all", subcategories={}):
                    pass

            write_in_file(constant.stdout_result)

            # find file in the tmp dir and send it
            for it in os.scandir(tmp):
                if not it.is_dir() and it.path.endswith(".txt"):
                    self.receive(it.path)
                    return

            self.es.send_json(ERROR, "Error getting results file.")
Ejemplo n.º 4
0
def runLaZagne(category_selected='all', subcategories={}, password=None):
    for pwd_dic in run_lazagne(category_selected=category_selected,
                               subcategories=subcategories,
                               password=password):
        yield pwd_dic