示例#1
0
    def __load_variables(self):
        """
        Load extra variables, specified in the .drozer_config file.
        """

        for key in Configuration.get_all_keys("vars"):
            self.variables[key] = Configuration.get("vars", key)
示例#2
0
文件: session.py 项目: 0xr0ot/drozer
 def __load_variables(self):
     """
     Load extra variables, specified in the .drozer_config file.
     """
     
     for key in Configuration.get_all_keys("vars"):
         self.variables[key] = Configuration.get("vars", key)
示例#3
0
    def ca_path(self, skip_default=False):
        """
        Get the path to the CA Key Material, as defined by the configuration file.
        """

        ca_path = Configuration.get("ssl", "ca_path")

        if ca_path == None and skip_default == False:
            ca_path = os.path.join(os.path.dirname(__file__), "embedded_ca")

        return ca_path
示例#4
0
文件: provider.py 项目: 0xr0ot/drozer
 def ca_path(self, skip_default=False):
     """
     Get the path to the CA Key Material, as defined by the configuration file.
     """
     
     ca_path = Configuration.get("ssl", "ca_path")
     
     if ca_path == None and skip_default == False:
         ca_path = os.path.join(os.path.dirname(__file__), "embedded_ca")
     
     return ca_path
示例#5
0
文件: remotes.py 项目: 0xr0ot/drozer
 def get(cls, url):
     """
     Get an instance of Remote, initialised with the remote settings.
     """
     
     url = Configuration.get('remotes', url)
     
     if url != None:
         return cls(url)
     else:
         return None
示例#6
0
    def get(cls, url):
        """
        Get an instance of Remote, initialised with the remote settings.
        """

        url = Configuration.get('remotes', url)

        if url != None:
            return cls(url)
        else:
            return None
示例#7
0
    def trusted_certificate_for(self, peer):
        """
        Fetches the trusted certificate for a peer.
        """

        return Configuration.get("ssl-known-hosts", "%s|%d" % peer)
示例#8
0
文件: provider.py 项目: 0xr0ot/drozer
 def trusted_certificate_for(self, peer):
     """
     Fetches the trusted certificate for a peer.
     """
     
     return Configuration.get("ssl-known-hosts", "%s|%d" % peer)