| 117 | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
| 118 | # get capabilities via HTTPS |
| 119 | def https(self, host): |
| 120 | try: |
| 121 | # poor man's way get https title |
| 122 | sys.stdout.write("Checking for HTTPS support: ") |
| 123 | html = requests.get("https://" + host, verify=False).text |
| 124 | # cause we are to parsimonious to import BeautifulSoup ;) |
| 125 | title = re.findall("<title.*?>\n?(.+?)\n?</title>", |
| 126 | html, re.I | re.M | re.S) |
| 127 | # get name of device |
| 128 | model = item(title) |
| 129 | # get language support |
| 130 | self.set_support(model) |
| 131 | output().green("found") |
| 132 | except Exception as e: |
| 133 | output().errmsg("not found", e) |
| 134 | |
| 135 | # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
| 136 | # get capabilities via SNMP |