Exemplo n.º 1
0
    def _load_lists(self):

        # Load content types to filter
        self._filter_cont_types = load_keywords_list(
            self.conf["content_types_blacklist"], lower=False)
        self.log("Content types to filter reloaded")

        # Load Tika content types to analyze
        self._tika_whitelist_cont_types = set()
        if self.conf["tika"]["enabled"]:
            self._tika_whitelist_cont_types = load_keywords_list(
                self.conf["tika"]["valid_content_types"], lower=False)
            self.log("Whitelist Tika content types reloaded")
Exemplo n.º 2
0
    def _load_lists(self):

        # Load subjects keywords
        self.subject_keys = load_keywords_list(self.conf["lists"]["subjects"])
        self.log("Phishing subjects keywords reloaded")

        # Load targets keywords
        self.target_keys = load_keywords_dict(self.conf["lists"]["targets"])
        self.log("Phishing targets keywords reloaded")
Exemplo n.º 3
0
    def _load_lists(self):

        # Load subjects keywords
        self.subject_keys = load_keywords_list(
            self.conf["lists"].get("subjects", {}))
        self.log("Phishing subjects keywords reloaded", "debug")

        # Load targets keywords
        self.target_keys = load_keywords_dict(
            self.conf["lists"].get("targets", {}))
        self.log("Phishing targets keywords reloaded", "debug")
Exemplo n.º 4
0
    def _load_lists(self):
        settings = copy.deepcopy(self.conf)

        for k in self.conf:
            for i, j in self.conf[k].get("lists", {}).items():
                settings[k][i] = load_keywords_list(j)
                self.log("Loaded lists {!r} for {!r}".format(i, k), "debug")
                self.log(
                    "Keys[{!r}][{!r}]: {}".format(k, i,
                                                  ", ".join(settings[k][i])),
                    "debug")
        else:
            return settings