コード例 #1
0
    def __init__(self, config: ciphey.iface.Config):
        # Suppresses warning
        super().__init__(config)
        self.mh = mh.mathsHelper()

        phases = config.get_resource(self._params()["phases"])

        self.thresholds_phase1 = phases["1"]
        self.thresholds_phase2 = phases["2"]
        self.top1000Words = config.get_resource(self._params().get("top1000"))
        self.wordlist = config.get_resource(self._params()["wordlist"])
        self.stopwords = config.get_resource(self._params().get("stopwords"))

        self.len_phase1 = len(self.thresholds_phase1)
        self.len_phase2 = len(self.thresholds_phase2)
コード例 #2
0
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.MORSE_CODE_DICT = config.get_resource(self._params()["dict"],
                                                ciphey.iface.Translation)
     self.MORSE_CODE_DICT_INV = {
         v: k
         for k, v in self.MORSE_CODE_DICT.items()
     }
コード例 #3
0
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.lower: Union[str, bool] = self._params()["lower"]
     if type(self.lower) != bool:
         self.lower = util.strtobool(self.lower)
     self.group = list(self._params()["group"])
     self.expected = config.get_resource(self._params()["expected"])
     self.cache = config.cache
     self.p_value = float(self._params()["p_value"])
コード例 #4
0
ファイル: xorcrypt.py プロジェクト: tars-c/APP-Ciphey
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.expected = config.get_resource(self._params()["expected"])
     self.cache = config.cache
     self.keysize = self._params().get("keysize")
     if self.keysize is not None:
         self.keysize = int(self.keysize)
     self.p_value = self._params()["p_value"]
     self.MAX_KEY_LENGTH = 16
コード例 #5
0
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.lower: Union[str, bool] = self._params()["lower"]
     if type(self.lower) != bool:
         self.lower = util.strtobool(self.lower)
     self.group = list(self._params()["group"])
     self.expected = config.get_resource(self._params()["expected"])
     self.cache = config.cache
     self.keysize = self._params().get("keysize")
     if self.keysize is not None:
         self.keysize = int(self.keysize)
     self.p_value = self._params()["p_value"]
     self.MAX_KEY_LENGTH = 16
コード例 #6
0
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.translate = config.get_resource(self._params()["dict"],
                                          Translation)
コード例 #7
0
ファイル: xor_single.py プロジェクト: tars-c/APP-Ciphey
 def __init__(self, config: ciphey.iface.Config):
     super().__init__(config)
     self.expected = config.get_resource(self._params()["expected"])
     self.cache = config.cache
     self.p_value = self._params()["p_value"]