def get_discovery_dict(self):

        dct = {
            'username': self._value_when(self.entry_disc_username),
            'password': self._value_when(self.entry_disc_password),
            'r_username': self._value_when(self.entry_disc_r_username),
            'r_password': self._value_when(self.entry_disc_r_password)
        }
        entered_ip = self.entry_target_ip.value()
        (ip, port) = pih.parse_ip(entered_ip)
        dct["ipaddr"] = ip
        dct["port"] = port
        return dct
Beispiel #2
0
    def get_discovery_dict(self):

        dct = {
            'username' : self._value_when(self.entry_disc_username),
            'password' : self._value_when(self.entry_disc_password),
            'r_username' : self._value_when(self.entry_disc_r_username),
            'r_password' : self._value_when(self.entry_disc_r_password)
            }
        entered_ip = self.entry_target_ip.value()
        (ip, port) = pih.parse_ip(entered_ip)
        dct["ipaddr"] = ip
        dct["port"]   = port
        return dct
Beispiel #3
0
    def discovery_dict(self):
        dct = self._extract_credentials(self.xml)

        auth_kind = self.combobox.get_active_value()
        if auth_kind == pih.CRED_NONE[0]:
            dct["username"] = dct["password"] = \
                dct["r_username"] = dct["r_password"] = None
        elif auth_kind == pih.CRED_ONE[0]:
            dct["r_username"] = dct["r_password"] = None

        entered_ip = self.xml.get_widget("target_ip").get_text()
        (ip, port) = pih.parse_ip(entered_ip)
        dct["ipaddr"] = ip
        dct["port"] = port

        return dct
Beispiel #4
0
    def discovery_dict(self):
        dct = self._extract_credentials(self.xml)

        auth_kind = self.combobox.get_active_value()
        if auth_kind == pih.CRED_NONE[0]:
            dct["username"] = dct["password"] = \
                dct["r_username"] = dct["r_password"] = None
        elif auth_kind == pih.CRED_ONE[0]:
            dct["r_username"] = dct["r_password"] = None

        entered_ip = self.xml.get_widget("target_ip").get_text()
        (ip, port) = pih.parse_ip(entered_ip)
        dct["ipaddr"] = ip
        dct["port"]   = port
        
        return dct