tis-glpi-plugin-export-to-glpi10
15-20
Package for tis-glpi-plugin-export-to-glpi
5175 downloads
See build result See VirusTotal scan
control
package : tis-glpi-plugin-export-to-glpi10
version : 15-20
architecture : all
section : base
priority : optional
name :
categories :
maintainer : sfonteneau
description : Package for tis-glpi-plugin-export-to-glpi
depends :
conflicts :
maturity : PROD
locale : all
target_os : all
min_wapt_version :
sources :
installed_size :
impacted_process :
description_fr : Paquet pour tis-glpi-plugin-export-to-glpi
description_pl : Pakiet dla tis-glpi-plugin-export-to-glpi
description_de : Paket für tis-glpi-plugin-export-to-glpi
description_es : Paquete para tis-glpi-plugin-export-to-glpi
description_pt : Pacote para tis-glpi-plugin-export-to-glpi
description_it : Pacchetto per tis-glpi-plugin-export-to-glpi
description_nl : Pakket voor tis-glpi-plugin-export-naar-glpi
description_ru : Пакет для tis-glpi-plugin-export-to-glpi
audit_schedule : 1h
editor :
keywords :
licence :
homepage :
package_uuid : a929ea36-77ae-4cfd-b21b-4717fd282357
valid_from :
valid_until :
forced_install_on :
changelog :
min_os_version :
max_os_version :
icon_sha256sum : dbe1285588343cbdf5a6d18fd0cf0038de795d7a8a79cbaf90fb34720f7be890
signer : Tranquil IT
signer_fingerprint: 8c5127a75392be9cc9afd0dbae1222a673072c308c14d88ab246e23832e8c6bb
signature_date : 2024-09-16T15:03:55.000000
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,homepage,package_uuid,valid_from,valid_until,forced_install_on,changelog,min_os_version,max_os_version,icon_sha256sum,signer,signer_fingerprint,signature_date,signed_attributes
signature : EOBixTaZtw81hlDxg1AxkYR4lIVE3GZ+vzod7iNM3qxjl/VvrQDS4e4f2qElzrX+7pfbp3kmCO2rKcC8PS/ZVuH+ncXt36r/4aBOsgniXoMzY7ltXnlHvYb3G/VeABXsj175PZfXfqyx5v6z8QBWi0wVZ2IUeZ20zoT7ijkOpHPmD5fiJbs155WlfB2z55X3t8gRa1DpB4tdx6+f6rX1aBA1V2lDQzP7uwAehLkOBaOWA3an6HQNe+DE70wc5gzMJuAayHVY9DjdYgxI95qNHeHs5Smxbvt921D3aQvIMMNg1PGbrClkFY6E7MBDgcBzkWnCZilwk56i3Hi5IQ98FQ==
Setup.py
# -*- coding: utf-8 -*-
## -----------------------------------------------------------------
## This file is part of WAPT Software Deployment
## Copyright (C) 2012 - 2022 Tranquil IT https://www.tranquil.it
## All Rights Reserved.
##
## This package is to be used with a valid WAPT Enterprise license only
##
## WAPT helps systems administrators to efficiently deploy
## setup, update and configure applications.
## ------------------------------------------------------------------
from setuphelpers import *
from configparser import ConfigParser
import copy
import hashlib
import json
import sys
import os
import time
import ctypes
import requests
import re
import datetime
import platform
def install():
if not inifile_readstring("glpi.ini",'glpi','password') == 'glpi' :
error('This package must not contain login/password !, you have to go directly into %s to edit the files,' % makepath(WAPT.private_dir, "glpi.ini"))
if not inifile_readstring("wapt_api.ini",'wapt','password') == 'password' :
error('This package must not contain login/password !, you have to go directly into %s to edit the files,' % makepath(WAPT.private_dir, "wapt_api.ini"))
if not isfile(makepath(WAPT.private_dir, "glpi.ini")):
filecopyto("glpi.ini", makepath(WAPT.private_dir, "glpi.ini"))
if not isfile(makepath(WAPT.private_dir, "wapt_api.ini")):
filecopyto("wapt_api.ini", makepath(WAPT.private_dir, "wapt_api.ini"))
def audit():
tools = Tools()
CONFWAPT = ConfigParser()
CONFWAPT.read(makepath(WAPT.private_dir, "wapt_api.ini"))
username_wapt = CONFWAPT.get("wapt", "username")
password_wapt = CONFWAPT.get("wapt", "password")
WAPT.waptserver.post('api/v3/login' ,data=json.dumps({'user': username_wapt, 'password': password_wapt}))
# certifi import with system_redirection but install run without system_redirection so copy cacert.pem
if platform.system() == 'Windows':
if isfile(r'C:\Windows\SysWOW64\config\systemprofile\AppData\Local\.certifi\cacert.pem'):
mkdirs(r'C:\WINDOWS\system32\config\systemprofile\AppData\Local\.certifi')
filecopyto(r'C:\Windows\SysWOW64\config\systemprofile\AppData\Local\.certifi\cacert.pem',r'C:\WINDOWS\system32\config\systemprofile\AppData\Local\.certifi\cacert.pem')
CONFGLPI = ConfigParser()
CONFGLPI.read(makepath(WAPT.private_dir, "glpi.ini"))
if CONFGLPI.has_option('glpi', 'verify_cert'):
try:
verify_cert_glpi = CONFGLPI.getboolean('glpi', 'verify_cert')
except:
verify_cert_glpi = CONFGLPI.get('glpi', 'verify_cert')
else:
verify_cert_glpi = True
list_excluded_ou=[]
if CONFGLPI.has_option('glpi', 'list_excluded_ou'):
list_excluded_ou = CONFGLPI.get('glpi', 'list_excluded_ou').split('|')
list_pc_wapt = WAPT.waptserver.get(
"api/v3/hosts?columns=host_audit%2Fglpi%2Fupload%2Fvalue%2Flastid,host_audit%2Fglpi%2Fupload%2Fvalue%2Fhash&limit=10000"
)["result"]
vlist = ["wmi", "dmi", "host_info", "uuid", "host_metrics","host_networking"]
for pc in list_pc_wapt:
for excluded_ou in list_excluded_ou:
if str(pc['host_capabilities']['dn']).lower().endswith(excluded_ou.lower()):
continue
last_hash = pc.get("host_audit/glpi/upload/value/hash", "")
data_audit_glpi_inventory = None
data = WAPT.waptserver.get('api/v3/audit_data?section=audit-glpi-inventory&keys=audit-glpi-inventory&latest_only=1&host_uuids=%s' % pc["uuid"])
if data["result"]:
data_audit_glpi_inventory = data["result"][0]['value']
data_audit_glpi_inventory['deviceid'] = pc["uuid"]
else:
host_data = WAPT.waptserver.get('api/v3/hosts?columns=dmi,wmi,host_info,host_metrics,waptwua_status,wuauserv_status,host_capabilities,host_networking,wapt_status&uuid=%s' % pc["uuid"])["result"][0]
data = WAPT.waptserver.get('api/v3/audit_data?section=audit-wmi&keys=audit-wmi&latest_only=1&host_uuids=%s' % pc["uuid"])
if data["result"]:
host_data['wmi'] = data["result"][0]['value']
data = WAPT.waptserver.get('api/v3/audit_data?section=audit-dmi&keys=audit-dmi&latest_only=1&host_uuids=%s' % pc["uuid"])
if data["result"]:
host_data['dmi'] = data["result"][0]['value']
qlist = [host_data["wmi"], host_data["dmi"], host_data["host_info"], pc["uuid"], host_data["host_metrics"],host_data.get("host_networking",{})]
# in 2.4 version and above, netowrking info are in host_networking but before, it's not the case, so we'll try to find another way
if Version(host_data['wapt_version']) < Version("2.4.0") :
print("Your agent on this host %s is too old for this package. Wanted min version is 2.4 and you seems to be under : %s" % (host_data['computer_fqdn'],host_data['wapt_version'] ))
continue
# qlist = [list_pc_wapt[]]
d = copy.deepcopy(default)
for y in range(len(vlist)):
if qlist[y]:
(d[vlist[y]], qlist[y]) = tools.merge_dicts(d[vlist[y]], qlist[y])
list_soft = WAPT.waptserver.get("api/v3/host_data?field=installed_softwares&uuid=%s" % pc["uuid"])["result"]
d["installed_softwares"] = list_soft
try:
HI = HostInventory()
if not data_audit_glpi_inventory:
HI.data = d
HI.data_refactoring(refactoring_data=False)
datajson = HI.json_glpi()
else:
datajson = data_audit_glpi_inventory
if CONFGLPI.has_option('glpi','tag'):
if CONFGLPI.get('glpi','tag'):
datajson['tag']=CONFGLPI.get('glpi','tag')
datahash = hashlib.sha256(json.dumps(datajson).encode("utf-8")).hexdigest()
if (not force) and (datahash == last_hash):
print("Skip %s hash not change" % pc["uuid"])
continue
datajson["content"]["accesslog"]["logdate"] = str(datetime.datetime.now()).rsplit(".", 1)[0]
datajson = json.dumps(datajson, sort_keys=True, indent=4)
HI.inventory_data = datajson
## with open(r"c:\testglpi\%s.json" % pc["uuid"], "w") as f:
## f.write(datajson)
result = HI.upload_to_glpi(CONFGLPI.get("glpi", "username"), CONFGLPI.get("glpi", "password"), CONFGLPI.get("glpi", "url"),verify_cert=verify_cert_glpi)
output = result.content.decode("utf-8")
except Exception as e:
datahash = 'failed'
output = e
if not '{"RESPONSE":"SEND"}' in str(output):
status = "ERROR"
datahash = 'failed'
else:
status = "OK"
if pc.get("host_audit/glpi/upload/value/lastid", ""):
value_id = int(pc["host_audit/glpi/upload/value/lastid"])
else:
value_id = int(time.monotonic() * 1000)
result_glpi = {"status": status, "output": str(output), "hash": datahash, "synchro_date": str(datetime.datetime.now()), "lastid": value_id}
waptdata = []
waptdata.append(
{
"host_id": pc["uuid"],
"value_id": value_id,
"value_date": datetime2isodate(datetime.datetime.utcnow()),
"value_section": "glpi",
"value_key": "upload",
"value": result_glpi,
"expiration_date": datetime2isodate(datetime.datetime.utcnow() + datetime.timedelta(days=365)),
}
)
print(WAPT.waptserver.post("api/v3/update_hosts_audit_data", data=json.dumps(waptdata)))
time.sleep(0.0000001)
return "OK"
def srn(serialnumber):
if serialnumber >= 0:
return hex(serialnumber)[2:-1].upper()
else:
return hex(int(ctypes.c_uint32(serialnumber).value))[2:-1].upper()
def get_cpu_infos(data):
cpu = {}
items_key = ["Core_Count", "Thread_Count", "ID", "Max_Speed", "Manufacturer", "Serial_Number"]
items = ["core", "thread", "id", "speed", "manufacturer", "serial"]
stepping = re.split("stepping", data["host_info"]["cpu_identifier"], flags=re.IGNORECASE)
if len(stepping) > 1:
cpu["stepping"] = [v.strip() for v in stepping[1].split(" ") if v.isdigit()][0]
else:
cpu["stepping"] = ""
for i in range(len(items)):
if not items_key[i] in data["dmi"]["Processor_Information"][0].keys():
continue
cpu[items[i]] = data["dmi"]["Processor_Information"][0][items_key[i]]
cpu["speed"] = cpu["speed"].replace(" MHz", "")
cpu["name"] = data["host_info"]["cpu_name"]
cpu["model"] = data["host_info"]["cpu_identifier"]
try:
val = data["dmi"]["Processor_Information"][0]["Signature"]
if "Family" in val:
cpu["familynumber"] = val.split("Family")[1].split(",")[0].strip()
cpu["modelnumber"] = val.split("Model")[1].split(",")[0].strip()
except:
pass
if "intel" in cpu["manufacturer"].lower():
cpu["manufacturer"] = "Intel"
return cpu
def delete_empty_entry_in_dict(data):
list_delete = []
for entry in data:
if (not data[entry]) or (data[entry] == "Unknown"):
list_delete.append(entry)
for entry in list_delete:
del data[entry]
return data
def convert_int_if_possible(value, defaultvalue=None):
try:
return int(value)
except:
return defaultvalue
def get_ram_infos(data):
ram = []
nb = 0
for entry in data["dmi"]["Memory_Device"]:
d = {}
nb = nb + 1
d["capacity"] = str(entry.get("Size", ""))
if "No Module Installed" == d["capacity"]:
d["capacity"] = None
if d["capacity"]:
if "mb" in d["capacity"].lower():
d["capacity"] = d["capacity"].split(" ")[0]
elif "gb" in d["capacity"].lower():
d["capacity"] = int(d["capacity"].split(" ")[0]) * 1024
elif "tb" in d["capacity"].lower():
d["capacity"] = int(d["capacity"].split(" ")[0]) * 1024 * 1024
else:
d["capacity"] = d["capacity"].split(" ")[0]
else:
del d["capacity"]
d["caption"] = entry.get("Locator", "")
d["description"] = entry.get("From_Factor", "")
d["manufacturer"] = entry.get("Manufacturer", "")
d["model"] = entry.get("Part_Number", "")
d["numslots"] = str(str(nb))
d["serialnumber"] = entry.get("Serial_Number", "")
d["speed"] = entry.get("Speed", "")
d["type"] = entry.get("Type", "")
ram.append(d)
return ram
class HostInventory:
def __init__(self):
self.data = {}
self.date = time.strftime("%Y-%m-%d") + " " + time.strftime("%H:%M:%S")
self.inventory_data = None
def json_glpi(self):
# DEFAULT
jsondata = {
"action": "inventory",
"content": {
"accesslog": {"logdate": None},
"antivirus": [],
"batteries": [],
"bios": {},
"controllers": [],
"cpus": [],
"drives": [],
"envs": [],
"firewalls": [],
"hardware": {},
"inputs": [],
"local_groups": [],
"local_users": [],
"memories": [],
"monitors": [],
"networks": [],
"operatingsystem": {},
"ports": [],
"printers": [],
"slots": [],
"softwares": [],
"sounds": [],
"storages": [],
"usbdevices": [],
"users": {},
"versionclient": "GLPI-Inventory_v1.2",
"versionprovider": {"comments": ["Provided by WAPT"], "etime": 61, "name": "GLPI", "program": "WAPT", "version": "2.4"},
"videos": [],
"virtualmachines": [],
},
"deviceid": self.data["uuid"],
"itemtype": "Computer",
}
# BATTERY
for battery in self.data["dmi"].get("Portable_Battery", []):
try:
datetest = datetime.datetime.strptime(battery.get("SBDS_Manufacture_Date", ""), "%d/%m/%Y").strftime("%Y-%m-%d")
except:
datetest = None
jsondata["content"]["batteries"].append(
delete_empty_entry_in_dict(
{
"capacity": int(battery.get("Design_Capacity", 0))
if type(battery.get("Design_Capacity", 0)) == int or type(battery.get("Design_Capacity", 0)) == float
else 0,
"chemistry": battery.get("SBDS_Chemistry", ""),
"date": datetest,
"manufacturer": battery.get("Manufacturer", ""),
"name": battery.get("Name", ""),
"serial": str(battery.get("SBDS_Serial_Number", "")),
"voltage": int(battery.get("Design_Voltage", 0))
if type(battery.get("Design_Voltage", 0)) == int or type(battery.get("Design_Capacity", 0)) == float
else 0,
}
)
)
try:
bdate = datetime.datetime.strptime(self.data["dmi"].get("BIOS_Information", {}).get("Release_Date", ""), "%m/%d/%Y").strftime("%Y-%m-%d")
except:
bdate = None
# Cleanup multi chassis
if "Chassis_Information" in self.data["dmi"] :
if isinstance(self.data["dmi"][ "Chassis_Information"],list):
for entry in self.data["dmi"]["Chassis_Information"]:
if not "docking" in entry.get('Type',"").lower():
self.data["dmi"]['Chassis_Information'] = entry
break
# BIOS
jsondata["content"]["bios"]["assettag"] = self.data["dmi"].get("Chassis_Information", {}).get("Asset_Tag", "")
jsondata["content"]["bios"]["bdate"] = bdate
jsondata["content"]["bios"]["bmanufacturer"] = self.data["dmi"].get("BIOS_Information", {}).get("Vendor", "")
jsondata["content"]["bios"]["bversion"] = self.data["dmi"].get("BIOS_Information", {}).get("Version", "")
jsondata["content"]["bios"]["mmanufacturer"] = self.data["dmi"].get("Base_Board_Information", {}).get("Manufacturer", "")
jsondata["content"]["bios"]["mmodel"] = self.data["dmi"].get("System_Information", {}).get("Product_Name", "")
jsondata["content"]["bios"]["msn"] = self.data["dmi"].get("Base_Board_Information", {}).get("Serial_Number")
jsondata["content"]["bios"]["skunumber"] = self.data["dmi"].get("System_Information", {}).get("SKU_Number", "")
jsondata["content"]["bios"]["smanufacturer"] = self.data["dmi"].get("System_Information", {}).get("Manufacturer", "")
jsondata["content"]["bios"]["smodel"] = self.data.get("smodel", "")
jsondata["content"]["bios"]["ssn"] = self.data["dmi"].get("System_Information", {}).get("Serial_Number", self.data["uuid"])
jsondata["content"]["bios"] = delete_empty_entry_in_dict(jsondata["content"]["bios"])
# TODO controllers
# CPU
jsondata["content"]["cpus"] = [delete_empty_entry_in_dict(self.data.get("cpu", {}))]
for entry in jsondata["content"]["cpus"]:
if "modelnumber" in entry:
del entry["modelnumber"]
# DRIVES
for drive in self.data["wmi"].get("Win32_LogicalDisk", {}):
if drive["Name"]:
newdrive = {}
if drive.get("Description"):
newdrive["description"] = drive["Description"]
# TODO encrypt_algo
# TODO encrypt_name
# TODO encrypt_status
if drive.get("FileSystem"):
newdrive["filesystem"] = drive["FileSystem"]
if drive.get("FreeSpace"):
newdrive["free"] = int(int(drive["FreeSpace"]) / 1024 / 1024)
if drive.get("VolumeName"):
newdrive["label"] = drive["VolumeName"]
if drive.get("Name"):
newdrive["letter"] = drive["Name"]
if drive.get("VolumeSerialNumber"):
newdrive["serial"] = drive["VolumeSerialNumber"]
if drive.get("Name") and drive["Name"] == self.data["wmi"].get("Win32_OperatingSystem", {}).get("SystemDrive", "Vide"):
newdrive["systemdrive"] = True
else:
newdrive["systemdrive"] = False
if drive.get("Size"):
newdrive["total"] = int(int(drive["Size"]) / 1024 / 1024)
## if drive.get("typedisk"):
## newdrive["type"] = drive['typedisk']
if drive.get("VolumeName"):
newdrive["volumn"] = drive["VolumeName"]
jsondata["content"]["drives"].append(delete_empty_entry_in_dict(newdrive))
for drive in self.data["wmi"].get("Win32_Volume", []):
newdrive = {}
if drive["Label"]:
if drive.get("InstallDate"):
newdrive["createdate"] = drive["InstallDate"]
if drive.get("Description"):
newdrive["description"] = drive["Description"]
if drive.get("FileSystem"):
newdrive["filesystem"] = drive["FileSystem"]
if drive.get("FreeSpace"):
newdrive["free"] = int(int(drive["FreeSpace"]) / 1024 / 1024)
if drive.get("Label"):
newdrive["label"] = drive["Label"]
newdrive["letter"] = drive["Label"]
if drive.get("SerialNumber"):
newdrive["serial"] = srn(drive["SerialNumber"])
if drive.get("Label") and (drive["Label"] == self.data.get("wmi", {}).get("Win32_OperatingSystem", {}).get("SystemDrive", "")):
newdrive["systemdrive"] = True
else:
newdrive["systemdrive"] = False
if drive.get("Capacity"):
newdrive["total"] = int(int(drive["Capacity"]) / 1024 / 1024)
if drive.get("DriveType"):
newdrive["type"] = "Local Disk" if drive["DriveType"] == "3" else "Removable Disk"
if drive.get("Label"):
newdrive["volumn"] = drive["Label"]
jsondata["content"]["drives"].append(delete_empty_entry_in_dict(newdrive))
for env in self.data.get("host_info", {}).get("environ", {}):
jsondata["content"]["envs"].append({"key": env, "val": self.data["host_info"]["environ"][env]})
jsondata["content"]["hardware"] = delete_empty_entry_in_dict(
{
"chassis_type": self.data["dmi"].get("Chassis_Information", {}).get("Type", ""),
"defaultgateway": self.data["host_info"].get("gateways", [""])[0],
"description": self.data["host_info"].get("description", ""),
"dns": self.data["host_info"].get("dns_servers", [""])[0],
"lastloggeduser": self.data["host_metrics"].get("last_logged_on_user", ""),
# TODO IN XML not in JSON ?
# "ipaddr":self.data['allip'],
# "osverssion": self.data['host_info'].get('os_version',''),
#
"memory": self.data["host_metrics"].get("physical_memory", ""),
"name": self.data["host_info"].get("computer_name", "").lower(),
"uuid": self.data['uuid'],
"vmsystem": "Physical" if self.data["is_virtual"] == 0 else "Virtual",
"wincompany": self.data["host_info"].get("registered_organization", ""),
"winlang": str(
self.data["wmi"]["Win32_OperatingSystem"]["OSLanguage"]
if self.data["wmi"].get("Win32_OperatingSystem", {}).get("OSLanguage", "")
else self.data["host_info"].get("environ", {}).get("LANG", "")
),
"winowner": self.data["host_info"].get("registered_owner", ""),
"winprodid": self.data["host_info"].get("windows_product_infos", {}).get("product_id", ""),
"winprodkey": self.data["host_info"].get("product_key", ""),
"workgroup": self.data["host_info"].get("domain_name", ""),
}
)
# TODO inputs
# TODO local_groups
# TODO local_users
# MEMORIES
jsondata["content"]["memories"] = self.data["ram"]
# MONITOR
for monitor in self.data["host_info"].get("monitors", {}):
newmonitor = {
"base64": monitor.get("b64_edid", ""),
"caption": monitor.get("name", "") if monitor.get("name", "") else "Not Found",
"description": monitor.get("manufactured", ""),
"manufacturer": monitor.get("manufacturer", ""),
"port": monitor.get("port", ""),
"serial": str(monitor.get("serialno", "")),
}
jsondata["content"]["monitors"].append(delete_empty_entry_in_dict(newmonitor))
# NETWORKS
if self.data["wmi"].get("Win32_NetworkAdapter", []):
for network in self.data["wmi"].get("Win32_NetworkAdapter", []):
if not network.get("AdapterType", ""):
continue
newnetwork = {
"description": network.get("Description", ""),
"ipaddress": self.data["dict_mac_addr"].get(network.get("MACAddress", {}), {}).get("addr", "")
if not ":" in self.data["dict_mac_addr"].get(network.get("MACAddress", {}), {}).get("addr", "")
else "",
# TODO DHCP "ipdhcp": "172.16.144.0",
# TODO MASK "ipmask": "255.255.255.0",
# TODO SUBNET "ipsubnet": "172.16.144.0",
"mac": network.get("MACAddress", ""),
"pnpdeviceid": network.get("PNPDeviceID", ""),
"speed": str(int(int(network.get("Speed", "")) / 1000 / 1000 if network.get("Speed", "") else 0)),
# TODO STATUS "status": "up",
"virtualdev": False if network.get("PhysicalAdapter", "") else True,
"type": "ethernet"
if "ethernet" in str(network.get("AdapterType", "")).lower()
else "wifi"
if "wifi" in str(network.get("AdapterType", "")).lower()
else "bluetooth"
if "bluetooth" in str(network.get("AdapterType", "")).lower()
else "",
}
jsondata["content"]["networks"].append(delete_empty_entry_in_dict(newnetwork))
if not jsondata["content"]["networks"]:
for u in self.data["dict_mac_addr"]:
newnetwork = {
"ipaddress": self.data["dict_mac_addr"][u].get("ip",''),
"description":" ",
# TODO DHCP "ipdhcp": "172.16.144.0",
# TODO MASK "ipmask": "255.255.255.0",
# TODO SUBNET "ipsubnet": "172.16.144.0",
"mac": u,
# TODO STATUS "status": "up",
"type": "ethernet"
if "ethernet" in str(self.data["dict_mac_addr"][u].get('iface')).lower()
else "wifi"
if "wifi" in str(self.data["dict_mac_addr"][u].get('iface')).lower()
else "bluetooth"
if "bluetooth" in str(self.data["dict_mac_addr"][u].get('iface')).lower()
else "",
}
jsondata["content"]["networks"].append(delete_empty_entry_in_dict(newnetwork))
# OPERATINGSYSTEM
jsondata["content"]["operatingsystem"] = delete_empty_entry_in_dict(
{
"arch": self.data["wmi"]["Win32_OperatingSystem"]["OSArchitecture"]
if self.data["wmi"].get("Win32_OperatingSystem", {}).get("OSArchitecture", "")
else "64 bits",
"boot_time": self.data.get("host_metrics", {}).get("last_bootup_time", "").rsplit(".", 1)[0],
"dns_domain": self.data.get("host_info", {}).get("domain_name", ""),
"fqdn": self.data.get("host_info", {}).get("computer_fqdn", ""),
"full_name": self.data.get("wmi", {}).get("Win32_OperatingSystem", {}).get("Caption", ""),
"install_date": self.data.get("wmi", {}).get("Win32_OperatingSystem", {}).get("InstallDate", ""),
"kernel_name": "MSWin32" if self.data.get("host_info", {}).get("os", "") == "windows" else "",
"kernel_version": self.data["host_info"]["kernel_version"]
if self.data["host_info"].get("kernel_version", "")
else self.data["host_info"].get("os_version", ""),
"name": self.data["host_info"].get("os_shortname", ""),
# TODO
"timezone": {"name": "Europe/Paris", "offset": "+0200"},
"version": self.data.get("operatingsystem_version", ""),
}
)
jsondata["content"]["operatingsystem"] = delete_empty_entry_in_dict(jsondata["content"]["operatingsystem"])
# TODO PORT
for printer in self.data["wmi"].get("Win32_Printer", []):
if not printer["Name"]:
continue
newprint = {
"driver": printer["DriverName"],
"name": printer["Name"],
"network": True if printer["Network"] else False,
"port": printer["PortName"],
"printprocessor": printer["PrintProcessor"],
"resolution": str("0" if int(str(printer["VerticalResolution"]).replace("None", "0")) < 0 else str(printer["VerticalResolution"]))
+ "x"
+ str("0" if int(str(printer["HorizontalResolution"]).replace("None", "0")) < 0 else str(printer["HorizontalResolution"])),
"shared": True if printer["Shared"] else False,
# TODO STATUS ?
"status": "Idle",
}
jsondata["content"]["printers"].append(delete_empty_entry_in_dict(newprint))
# TODO slots
# SOFTWARES
for software in self.data.get("installed_softwares", []):
newsoft = {
# TODO arch
# "arch": "x86_64",
"from": "registry",
"guid": software["key"],
"install_date": software["install_date"],
"name": software["name"],
"publisher": software["publisher"],
"system_category": "application",
"uninstall_string": software["uninstall_string"],
"version": software["version"],
}
jsondata["content"]["softwares"].append(delete_empty_entry_in_dict(newsoft))
# TODO SOUND
# TODO STORAGES
# TOCO USBDEVICES
jsondata["content"]["users"] = [
delete_empty_entry_in_dict(
{
"domain": self.data["host_info"]["domain_name"]
if self.data["host_info"].get("domain_name", "")
else self.data["host_info"].get("workgroup_name", ""),
"login": self.data["host_metrics"].get("last_logged_on_user", ""),
}
)
]
# VIDEO
jsondata["content"]["videos"]: [
delete_empty_entry_in_dict(
{
# TODO "chipset": "Intel(R) HD Graphics Family",
"name": self.data["wmi"].get("Win32_VideoController", {}).get("Name", ""),
# TODO "resolution": "1920x1080"
}
)
]
# TODO virtualmachines
return jsondata
def data_refactoring(self, refactoring_data=True):
if not self.data:
return -1
newsoft = []
for soft in self.data["installed_softwares"]:
try:
if refactoring_data:
soft["install_date"] = datetime.datetime.strptime(soft["install_date"], "%Y-%m-%d %H:%M:%S").strftime("%d/%m/%Y")
else:
datetime.datetime.strptime(soft["install_date"], "%Y-%m-%d %H:%M:%S")
except:
soft["install_date"] = ""
pass
newsoft.append(soft)
self.data["installed_softwares"] = newsoft
if type(self.data["wmi"]["Win32_LogicalDisk"]) == dict:
self.data["wmi"]["Win32_LogicalDisk"] = [self.data["wmi"]["Win32_LogicalDisk"]]
if type(self.data["wmi"]["Win32_Volume"]) == dict:
self.data["wmi"]["Win32_Volume"] = [self.data["wmi"]["Win32_Volume"]]
if type(self.data["wmi"]["Win32_NetworkAdapter"]) == dict:
self.data["wmi"]["Win32_NetworkAdapter"] = [self.data["wmi"]["Win32_NetworkAdapter"]]
if type(self.data["wmi"]["Win32_Printer"]) == dict:
self.data["wmi"]["Win32_Printer"] = [self.data["wmi"]["Win32_Printer"]]
if type(self.data["dmi"]["Processor_Information"]) == dict:
self.data["dmi"]["Processor_Information"] = [self.data["dmi"]["Processor_Information"]]
if type(self.data["dmi"]["Memory_Device"]) == dict:
self.data["dmi"]["Memory_Device"] = [self.data["dmi"]["Memory_Device"]]
if self.data["host_info"].get("workgroup_name", "") in ("AUTORITE NT", "NT AUTHORITY"):
self.data["host_info"]["workgroup_name"] = self.data["host_info"]["computer_name"]
self.data["host_metrics"]["physical_memory"] = int(int(self.data["host_metrics"].get("physical_memory", "0")) / 1024 / 1024)
self.data["is_virtual"] = ""
model = None
if self.data["wmi"]["Win32_ComputerSystem"]["Model"]:
model = self.data["wmi"]["Win32_ComputerSystem"]["Model"]
elif self.data["dmi"]["System_Information"]["Product_Name"]:
model = self.data["dmi"]["System_Information"]["Product_Name"]
if model is not None:
self.data["is_virtual"] = int((any(vm_type in model.lower() for vm_type in ("vmware", "hvm", "virtual")) == True))
if self.data["host_metrics"].get("last_logged_on_user"):
if isinstance(self.data["host_metrics"].get("last_logged_on_user"), list):
self.data["host_metrics"]["last_logged_on_user"] = self.data["host_metrics"]["last_logged_on_user"][0].split("\\")[-1]
else:
self.data["host_metrics"]["last_logged_on_user"] = self.data["host_metrics"]["last_logged_on_user"].split("\\")[-1]
self.data["typedisk"] = ["Unknown", "No Root Directory", "Removable Disk", "Local Disk", "Network Drive", "Compact Disc", "RAM Disk"]
self.data["cpu"] = get_cpu_infos(self.data) # TODO reconstruction of cpu informations from database to json
self.data["ram"] = get_ram_infos(self.data)
self.data["allip"] = "/".join([addr for addr in self.data["host_info"]["connected_ips"] if addr])
if self.data["wmi"]["Win32_OperatingSystem"]["OSArchitecture"]:
if self.data["wmi"]["Win32_OperatingSystem"]["OSArchitecture"] == "64 bits":
self.data["wmi"]["Win32_OperatingSystem"]["OSArchitecture"] = "64-bit"
if self.data["wmi"]["Win32_OperatingSystem"]["LastBootUpTime"]:
val = self.data["wmi"]["Win32_OperatingSystem"]["LastBootUpTime"]
self.data["wmi"]["Win32_OperatingSystem"]["LastBootUpTime"] = "%s-%s-%s %s:%s:%s" % (
val[0:4],
val[4:6],
val[6:8],
val[8:10],
val[10:12],
val[12:14],
)
if self.data["wmi"]["Win32_OperatingSystem"]["InstallDate"]:
val = self.data["wmi"]["Win32_OperatingSystem"]["InstallDate"]
self.data["wmi"]["Win32_OperatingSystem"]["InstallDate"] = "%s-%s-%s %s:%s:%s" % (
val[0:4],
val[4:6],
val[6:8],
val[8:10],
val[10:12],
val[12:14],
)
if self.data["host_info"]["windows_version"]:
corresp = {
"10240": "1507",
"10586": "1511",
"14393": "1607",
"15063": "1703",
"16299": "1709",
"17134": "1803",
"17763": "1809",
"18362": "1903",
"18363": "1909",
"19041": "2004",
"19042": "20H2",
"19043": "21H1",
"19044": "21H2",
"19045": "22H2",
}
try:
if "windows_version_releaseid" in self.data["host_info"]:
self.data["operatingsystem_version"] = self.data["host_info"]["windows_version_releaseid"]
if "windows_version_prettyname" in self.data["host_info"]:
self.data["operatingsystem_version"] = self.data["host_info"]["windows_version_prettyname"]
if not "operatingsystem_version" in self.data:
self.data["operatingsystem_version"] = corresp[self.data["host_info"]["windows_version"].split(".")[-1]]
except:
pass
if self.data["wmi"]["Win32_OperatingSystem"]["CSDVersion"] == None:
self.data["wmi"]["Win32_OperatingSystem"]["CSDVersion"] = ""
if "windows" in self.data["host_info"]["os_name"].lower():
self.data["host_info"]["os_shortname"] = "Windows"
else:
self.data["host_info"]["os_shortname"] = self.data["host_info"]["os_name"]
if "Portable_Battery" in self.data["dmi"]:
orig_data = self.data["dmi"]["Portable_Battery"]
temp_list = list()
if isinstance(orig_data, dict):
orig_data = [orig_data]
for battery in orig_data:
battery["Design_Capacity"] = battery["Design_Capacity"].replace("mWh", "").strip()
try:
val = battery["SBDS_Manufacture_Date"]
except:
val = battery["Manufacture_Date"]
battery["SBDS_Manufacture_Date"] = "%s/%s/%s" % (val[8:10], val[5:7], val[0:4])
try:
val = battery["SBDS_Serial_Number"]
except:
val = battery["Serial_Number"]
try:
battery["SBDS_Serial_Number"] = int(val, 16)
except:
pass
battery["Design_Voltage"] = battery["Design_Voltage"].replace("mV", "").strip()
temp_list.append(battery)
self.data["dmi"]["Portable_Battery"] = temp_list
self.data["host_metrics"]["last_bootup_time"] = self.data["host_metrics"]["last_bootup_time"].replace("T", " ")
# for env_var in data['host_info']['environ']:
if self.data["wmi"]["Win32_OperatingSystem"]["Caption"]:
self.data["host_info"]["os_name"] = self.data["wmi"]["Win32_OperatingSystem"]["Caption"]
dict_mac_addr = {}
for network in self.data['host_networking']['interfaces'] :
#dict_mac_addr[network["mac"]] = {"ip": "", "netmask": ""}
if network.get("addr") and type(network["addr"]) == list:
if network["mac"] != "" :
dict_mac_addr[network["mac"]] = {"ip": network["addr"][0]["addr"], "netmask": network["addr"][0]["netmask"]}
self.data["dict_mac_addr"] = dict_mac_addr
if self.data["dmi"]["System_Information"]["Manufacturer"] == "LENOVO":
self.data["smodel"] = self.data["dmi"]["System_Information"]["Version"]
else:
self.data["smodel"] = self.data["dmi"]["System_Information"]["Product_Name"]
return 0
def upload_to_glpi(self, username, password, endpoint, headers=None, quiet=False,verify_cert=True):
if not self.inventory_data:
return
if not headers:
headers = {"charset": "utf-8", "Pragma": "no-cache", "content-type": "json"}
creds = (username.encode(encoding="UTF-8"), password.encode(encoding="UTF-8"))
r = requests.post(endpoint, data=self.inventory_data.encode("utf-8"), headers=headers, auth=creds,verify=verify_cert)
return r
class Tools:
def sort_dict(self, d):
result = {}
keys = list(d.keys())
keys.sort()
for k in keys:
result[k] = d[k]
return result
def merge_dicts(self, d1, d2):
"""
Replace d1 values by d2 ones
d1 key created from d2 if doesn't exist yet
if types are different, d2 erase d1
return: (d1, d2)
"""
try:
if d1 == d2:
return (d1, d2)
if type(d2) == str or type(d2) == int or type(d2) != type(d1):
d1 = d2
return (d1, d2)
if type(d2) == dict:
for k in d2.keys():
if k not in d1.keys():
d1[k] = d2[k]
continue
(d1[k], d2[k]) = self.merge_dicts(d1[k], d2[k])
return (d1, d2)
if type(d2) == list:
added = [d2[i] for i in range(len(d2)) if d2[i] not in d1]
d1 = added + [d1[i] for i in range(len(d1)) if d1[i] or (len(d1) > len(added) + i)]
return (d1, d2)
return (d1, d2)
except Exception as e:
print(e)
#print(d1,d2)
default = {
"wmi": {
"Win32_BIOS": {
"Name": "",
"Status": "",
"Caption": "",
"CodeSet": None,
"Version": "",
"BIOSVersion": ["", ""],
"BuildNumber": None,
"Description": "",
"InstallDate": None,
"PrimaryBIOS": True,
"ReleaseDate": "",
"Manufacturer": "",
"SerialNumber": "",
"OtherTargetOS": None,
"SMBIOSPresent": True,
"CurrentLanguage": None,
"LanguageEdition": None,
"ListOfLanguages": [],
"SMBIOSBIOSVersion": "",
"SoftwareElementID": "",
"IdentificationCode": None,
"SMBIOSMajorVersion": 0,
"SMBIOSMinorVersion": 0,
"BiosCharacteristics": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
"InstallableLanguages": None,
"SoftwareElementState": 0,
"TargetOperatingSystem": 0,
},
"Win32_Volume": [
{
"Name": "",
"Label": "",
"Access": None,
"Status": None,
"Caption": "",
"Purpose": None,
"Capacity": "",
"DeviceID": "",
"Automount": True,
"BlockSize": "",
"DriveType": 0,
"FreeSpace": "",
"BootVolume": True,
"Compressed": False,
"FileSystem": "",
"StatusInfo": None,
"SystemName": "",
"Description": None,
"DirtyBitSet": False,
"DriveLetter": "",
"InstallDate": None,
"PNPDeviceID": None,
"Availability": None,
"ErrorCleared": None,
"SerialNumber": 0,
"SystemVolume": True,
"LastErrorCode": None,
"QuotasEnabled": False,
"NumberOfBlocks": None,
"IndexingEnabled": True,
"PageFilePresent": True,
"ErrorDescription": None,
"ErrorMethodology": None,
"QuotasIncomplete": False,
"QuotasRebuilding": False,
"CreationClassName": None,
"SupportsDiskQuotas": True,
"MaximumFileNameLength": 0,
"ConfigManagerErrorCode": None,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": None,
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
"SupportsFileBasedCompression": True,
},
{
"Name": "",
"Label": None,
"Access": None,
"Status": None,
"Caption": "",
"Purpose": None,
"Capacity": None,
"DeviceID": "",
"Automount": True,
"BlockSize": None,
"DriveType": 0,
"FreeSpace": None,
"BootVolume": None,
"Compressed": None,
"FileSystem": None,
"StatusInfo": None,
"SystemName": "",
"Description": None,
"DirtyBitSet": None,
"DriveLetter": "",
"InstallDate": None,
"PNPDeviceID": None,
"Availability": None,
"ErrorCleared": None,
"SerialNumber": None,
"SystemVolume": None,
"LastErrorCode": None,
"QuotasEnabled": None,
"NumberOfBlocks": None,
"IndexingEnabled": None,
"PageFilePresent": None,
"ErrorDescription": None,
"ErrorMethodology": None,
"QuotasIncomplete": None,
"QuotasRebuilding": None,
"CreationClassName": None,
"SupportsDiskQuotas": None,
"MaximumFileNameLength": None,
"ConfigManagerErrorCode": None,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": None,
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
"SupportsFileBasedCompression": None,
},
],
"Win32_Printer": [
{
"Name": "",
"Local": True,
"Direct": False,
"Hidden": False,
"Queued": False,
"Shared": False,
"Status": "",
"Caption": "",
"Comment": None,
"Default": True,
"Network": False,
"RawOnly": False,
"DeviceID": "",
"Location": None,
"PortName": "",
"Priority": 0,
"MaxCopies": None,
"Published": False,
"ShareName": None,
"StartTime": None,
"UntilTime": None,
"Attributes": 0,
"DriverName": "",
"EnableBIDI": False,
"Parameters": None,
"ServerName": None,
"StatusInfo": None,
"SystemName": "",
"Description": None,
"InstallDate": None,
"MaxNumberUp": None,
"PNPDeviceID": None,
"WorkOffline": False,
"Availability": None,
"Capabilities": [0, 0, 0, 0],
"ErrorCleared": None,
"PrinterState": 0,
"SpoolEnabled": True,
"DefaultCopies": None,
"LastErrorCode": None,
"PrinterStatus": 0,
"SeparatorFile": None,
"CurrentCharSet": None,
"PrintProcessor": "",
"CurrentLanguage": None,
"CurrentMimeType": None,
"DefaultLanguage": None,
"DefaultMimeType": None,
"DefaultNumberUp": None,
"DefaultPriority": 0,
"DoCompleteFirst": True,
"KeepPrintedJobs": False,
"TimeOfLastReset": None,
"CurrentPaperType": None,
"DefaultPaperType": None,
"ErrorDescription": None,
"ErrorInformation": None,
"MaxSizeSupported": None,
"PrintJobDataType": "",
"CharSetsSupported": None,
"CreationClassName": "",
"MarkingTechnology": None,
"PrinterPaperNames": [
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
],
"AvailableJobSheets": None,
"DetectedErrorState": 0,
"LanguagesSupported": None,
"MimeTypesSupported": None,
"VerticalResolution": 0,
"CurrentCapabilities": None,
"DefaultCapabilities": None,
"EnableDevQueryPrint": False,
"PaperSizesSupported": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
],
"PaperTypesAvailable": None,
"HorizontalResolution": 0,
"AveragePagesPerMinute": 0,
"ExtendedPrinterStatus": 0,
"CapabilityDescriptions": ["", "", "", ""],
"ConfigManagerErrorCode": None,
"CurrentNaturalLanguage": None,
"JobCountSinceLastReset": 0,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"NaturalLanguagesSupported": None,
"ExtendedDetectedErrorState": 0,
"PowerManagementCapabilities": None,
},
{
"Name": "",
"Local": True,
"Direct": False,
"Hidden": False,
"Queued": False,
"Shared": False,
"Status": "",
"Caption": "",
"Comment": None,
"Default": False,
"Network": False,
"RawOnly": False,
"DeviceID": "",
"Location": None,
"PortName": "",
"Priority": 0,
"MaxCopies": None,
"Published": False,
"ShareName": None,
"StartTime": None,
"UntilTime": None,
"Attributes": 0,
"DriverName": "",
"EnableBIDI": False,
"Parameters": None,
"ServerName": None,
"StatusInfo": None,
"SystemName": "",
"Description": None,
"InstallDate": None,
"MaxNumberUp": None,
"PNPDeviceID": None,
"WorkOffline": False,
"Availability": None,
"Capabilities": [0, 0],
"ErrorCleared": None,
"PrinterState": 0,
"SpoolEnabled": True,
"DefaultCopies": None,
"LastErrorCode": None,
"PrinterStatus": 0,
"SeparatorFile": None,
"CurrentCharSet": None,
"PrintProcessor": "",
"CurrentLanguage": None,
"CurrentMimeType": None,
"DefaultLanguage": None,
"DefaultMimeType": None,
"DefaultNumberUp": None,
"DefaultPriority": 0,
"DoCompleteFirst": False,
"KeepPrintedJobs": False,
"TimeOfLastReset": None,
"CurrentPaperType": None,
"DefaultPaperType": None,
"ErrorDescription": None,
"ErrorInformation": None,
"MaxSizeSupported": None,
"PrintJobDataType": "",
"CharSetsSupported": None,
"CreationClassName": "",
"MarkingTechnology": None,
"PrinterPaperNames": [
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
"",
],
"AvailableJobSheets": None,
"DetectedErrorState": 0,
"LanguagesSupported": None,
"MimeTypesSupported": None,
"VerticalResolution": 0,
"CurrentCapabilities": None,
"DefaultCapabilities": None,
"EnableDevQueryPrint": False,
"PaperSizesSupported": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
],
"PaperTypesAvailable": None,
"HorizontalResolution": 0,
"AveragePagesPerMinute": 0,
"ExtendedPrinterStatus": 0,
"CapabilityDescriptions": ["", ""],
"ConfigManagerErrorCode": None,
"CurrentNaturalLanguage": None,
"JobCountSinceLastReset": 0,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"NaturalLanguagesSupported": None,
"ExtendedDetectedErrorState": 0,
"PowerManagementCapabilities": None,
},
],
"Win32_DiskDrive": {
"Name": "",
"Size": "",
"Index": 0,
"Model": "",
"Status": "",
"Caption": "",
"SCSIBus": 0,
"DeviceID": "",
"SCSIPort": 0,
"MediaType": "",
"Signature": 0,
"Partitions": 0,
"StatusInfo": None,
"SystemName": "",
"TotalHeads": 0,
"Description": "",
"InstallDate": None,
"MediaLoaded": True,
"PNPDeviceID": "",
"TotalTracks": "",
"Availability": None,
"Capabilities": [0, 0],
"ErrorCleared": None,
"Manufacturer": "",
"MaxBlockSize": None,
"MaxMediaSize": None,
"MinBlockSize": None,
"SCSITargetId": 0,
"SerialNumber": "",
"TotalSectors": "",
"InterfaceType": "",
"LastErrorCode": None,
"NeedsCleaning": None,
"BytesPerSector": 0,
"TotalCylinders": "",
"SCSILogicalUnit": 0,
"SectorsPerTrack": 0,
"DefaultBlockSize": None,
"ErrorDescription": None,
"ErrorMethodology": None,
"FirmwareRevision": "",
"CompressionMethod": None,
"CreationClassName": "",
"TracksPerCylinder": 0,
"CapabilityDescriptions": ["", ""],
"ConfigManagerErrorCode": 0,
"NumberOfMediaSupported": None,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
},
"Win32_LogicalDisk": [
{
"Name": "",
"Size": "",
"Access": 0,
"Status": None,
"Caption": "",
"Purpose": None,
"DeviceID": "",
"BlockSize": None,
"DriveType": 0,
"FreeSpace": "",
"MediaType": 0,
"Compressed": False,
"FileSystem": "",
"StatusInfo": None,
"SystemName": "",
"VolumeName": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": None,
"VolumeDirty": False,
"Availability": None,
"ErrorCleared": None,
"ProviderName": None,
"LastErrorCode": None,
"NumberOfBlocks": None,
"QuotasDisabled": True,
"ErrorDescription": None,
"ErrorMethodology": None,
"QuotasIncomplete": False,
"QuotasRebuilding": False,
"CreationClassName": "",
"SupportsDiskQuotas": True,
"VolumeSerialNumber": "",
"ConfigManagerErrorCode": None,
"MaximumComponentLength": 0,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
"SupportsFileBasedCompression": True,
},
{
"Name": "",
"Size": None,
"Access": None,
"Status": None,
"Caption": "",
"Purpose": None,
"DeviceID": "",
"BlockSize": None,
"DriveType": 0,
"FreeSpace": None,
"MediaType": 0,
"Compressed": None,
"FileSystem": None,
"StatusInfo": None,
"SystemName": "",
"VolumeName": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": None,
"VolumeDirty": None,
"Availability": None,
"ErrorCleared": None,
"ProviderName": None,
"LastErrorCode": None,
"NumberOfBlocks": None,
"QuotasDisabled": None,
"ErrorDescription": None,
"ErrorMethodology": None,
"QuotasIncomplete": None,
"QuotasRebuilding": None,
"CreationClassName": "",
"SupportsDiskQuotas": None,
"VolumeSerialNumber": None,
"ConfigManagerErrorCode": None,
"MaximumComponentLength": None,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
"SupportsFileBasedCompression": None,
},
],
"Win32_USBController": {
"Name": "",
"Status": "",
"Caption": "",
"DeviceID": "",
"StatusInfo": None,
"SystemName": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"Availability": None,
"ErrorCleared": None,
"Manufacturer": "",
"LastErrorCode": None,
"TimeOfLastReset": None,
"ErrorDescription": None,
"CreationClassName": "",
"ProtocolSupported": 0,
"MaxNumberControlled": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
},
"Win32_ComputerSystem": {
"Name": "",
"Model": "",
"Roles": ["", "", ""],
"Domain": "",
"Status": "",
"Caption": "",
"UserName": None,
"Workgroup": None,
"DomainRole": 0,
"NameFormat": None,
"PowerState": 0,
"ResetCount": 0,
"ResetLimit": 0,
"SystemType": "",
"WakeUpType": 0,
"BootupState": "",
"DNSHostName": "",
"Description": "",
"InstallDate": None,
"LastLoadInfo": None,
"Manufacturer": "",
"PCSystemType": 0,
"PartOfDomain": True,
"ThermalState": 0,
"OEMStringArray": ["", ""],
"CurrentTimeZone": 0,
"InitialLoadInfo": None,
"PauseAfterReset": "",
"ResetCapability": 0,
"BootROMSupported": True,
"DaylightInEffect": True,
"PowerSupplyState": 0,
"PrimaryOwnerName": "",
"BootOptionOnLimit": None,
"CreationClassName": "",
"InfraredSupported": False,
"ChassisBootupState": 0,
"NumberOfProcessors": 0,
"SystemStartupDelay": None,
"AdminPasswordStatus": 0,
"PrimaryOwnerContact": None,
"TotalPhysicalMemory": "",
"BootOptionOnWatchDog": None,
"SystemStartupOptions": None,
"SystemStartupSetting": None,
"FrontPanelResetStatus": 0,
"PowerOnPasswordStatus": 0,
"KeyboardPasswordStatus": 0,
"AutomaticManagedPagefile": True,
"AutomaticResetBootOption": True,
"AutomaticResetCapability": True,
"NetworkServerModeEnabled": True,
"PowerManagementSupported": None,
"EnableDaylightSavingsTime": True,
"NumberOfLogicalProcessors": 0,
"SupportContactDescription": None,
"PowerManagementCapabilities": None,
},
"Win32_DesktopMonitor": {
"Name": "",
"Status": "",
"Caption": "",
"DeviceID": "",
"IsLocked": None,
"Bandwidth": None,
"StatusInfo": None,
"SystemName": "",
"Description": "",
"DisplayType": None,
"InstallDate": None,
"MonitorType": "",
"PNPDeviceID": "",
"ScreenWidth": None,
"Availability": 0,
"ErrorCleared": None,
"ScreenHeight": None,
"LastErrorCode": None,
"ErrorDescription": None,
"CreationClassName": "",
"MonitorManufacturer": "",
"PixelsPerXLogicalInch": 0,
"PixelsPerYLogicalInch": 0,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"PowerManagementCapabilities": None,
},
"Win32_NetworkAdapter": [
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": None,
"ProductName": "",
"ServiceName": None,
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": None,
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": None,
"ConfigManagerUserConfig": None,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": None,
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": None,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": "",
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": 0,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": "",
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": 0,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": "",
"Name": "",
"Index": 0,
"Speed": "",
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": "",
"NetEnabled": True,
"StatusInfo": None,
"SystemName": "",
"AdapterType": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": 0,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": "",
"PhysicalAdapter": True,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": 0,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
{
"GUID": None,
"Name": "",
"Index": 0,
"Speed": None,
"Status": None,
"Caption": "",
"DeviceID": "",
"MaxSpeed": None,
"AutoSense": None,
"Installed": True,
"MACAddress": None,
"NetEnabled": None,
"StatusInfo": None,
"SystemName": "",
"AdapterType": "",
"Description": "",
"InstallDate": None,
"PNPDeviceID": "",
"ProductName": "",
"ServiceName": "",
"Availability": 0,
"ErrorCleared": None,
"Manufacturer": "",
"AdapterTypeId": 0,
"LastErrorCode": None,
"InterfaceIndex": 0,
"NetConnectionID": None,
"PhysicalAdapter": False,
"TimeOfLastReset": "",
"ErrorDescription": None,
"NetworkAddresses": None,
"PermanentAddress": None,
"CreationClassName": "",
"MaxNumberControlled": 0,
"NetConnectionStatus": None,
"ConfigManagerErrorCode": 0,
"ConfigManagerUserConfig": False,
"SystemCreationClassName": "",
"PowerManagementSupported": False,
"PowerManagementCapabilities": None,
},
],
"Win32_OperatingSystem": {
"Name": "",
"Debug": False,
"CSName": "",
"Locale": "",
"OSType": 0,
"Status": "",
"Caption": "",
"CodeSet": "",
"Primary": True,
"Version": "",
"BuildType": "",
"SuiteMask": 0,
"BootDevice": "",
"CSDVersion": "",
"OSLanguage": 0,
"PAEEnabled": None,
"BuildNumber": "",
"CountryCode": "",
"Description": "",
"Distributed": False,
"InstallDate": "",
"ProductType": 0,
"SystemDrive": "",
"MUILanguages": [""],
"Manufacturer": "",
"Organization": "",
"SerialNumber": "",
"SystemDevice": "",
"LocalDateTime": "",
"NumberOfUsers": 0,
"PlusProductID": None,
"LastBootUpTime": "",
"OSArchitecture": "",
"OSProductSuite": 0,
"RegisteredUser": "",
"CurrentTimeZone": 0,
"EncryptionLevel": 0,
"SystemDirectory": "",
"LargeSystemCache": None,
"WindowsDirectory": "",
"CreationClassName": "",
"FreeVirtualMemory": "",
"NumberOfProcesses": 0,
"PlusVersionNumber": None,
"FreePhysicalMemory": "",
"OperatingSystemSKU": 0,
"TotalSwapSpaceSize": None,
"CSCreationClassName": "",
"MaxNumberOfProcesses": 0,
"MaxProcessMemorySize": "",
"OtherTypeDescription": None,
"NumberOfLicensedUsers": 0,
"FreeSpaceInPagingFiles": "",
"TotalVirtualMemorySize": "",
"TotalVisibleMemorySize": "",
"ServicePackMajorVersion": 0,
"ServicePackMinorVersion": 0,
"SizeStoredInPagingFiles": "",
"ForegroundApplicationBoost": 0,
"DataExecutionPrevention_Drivers": True,
"DataExecutionPrevention_Available": True,
"DataExecutionPrevention_SupportPolicy": 0,
"DataExecutionPrevention_32BitApplications": True,
},
"Win32_VideoController": {
"Name": "",
"Status": "",
"Caption": "",
"DeviceID": "",
"ICMIntent": None,
"ICMMethod": None,
"VideoMode": None,
"AdapterRAM": None,
"DitherType": None,
"DriverDate": "",
"InfSection": "",
"Monochrome": False,
"StatusInfo": None,
"SystemName": "",
"Description": "",
"InfFilename": "",
"InstallDate": None,
"PNPDeviceID": "",
"Availability": 0,
"ErrorCleared": None,
"DriverVersion": "",
"LastErrorCode": None,
"AdapterDACType": None,
"MaxRefreshRate": None,
"MinRefreshRate": None,
"VideoProcessor": None,
"CurrentScanMode": None,
"TimeOfLastReset": None,
"VideoMemoryType": 0,
"ErrorDescription": None,
"ColorTableEntries": None,
"CreationClassName": "",
"ProtocolSupported": None,
"VideoArchitecture": 0,
"CurrentRefreshRate": None,
"DeviceSpecificPens": None,
"MaxMemorySupported": None,
"NumberOfVideoPages": None,
"CurrentBitsPerPixel": None,
"CurrentNumberOfRows": None,
"MaxNumberControlled": None,
"NumberOfColorPlanes": None,
"AdapterCompatibility": "",
"SpecificationVersion": None,
"SystemPaletteEntries": None,
"VideoModeDescription": None,
"CurrentNumberOfColors": None,
"CapabilityDescriptions": None,
"ConfigManagerErrorCode": 0,
"CurrentNumberOfColumns": None,
"AcceleratorCapabilities": None,
"ConfigManagerUserConfig": False,
"InstalledDisplayDrivers": None,
"SystemCreationClassName": "",
"PowerManagementSupported": None,
"CurrentVerticalResolution": None,
"CurrentHorizontalResolution": None,
"PowerManagementCapabilities": None,
"ReservedSystemPaletteEntries": None,
},
"Win32_ComputerSystemProduct": {
"Name": "",
"UUID": "",
"Vendor": "",
"Caption": "",
"Version": "",
"SKUNumber": None,
"Description": "",
"IdentifyingNumber": "",
},
},
"dmi": {
"Base_Board_Information": {"Manufacturer": ""},
"OEM_Strings": {"String_1": "", "String_2": ""},
"Memory_Device": {
"Set": "",
"Size": "",
"Type": "",
"Speed": "",
"Locator": "",
"Asset_Tag": "",
"Data_Width": "",
"Form_Factor": "",
"Part_Number": "",
"Total_Width": "",
"Type_Detail": "",
"Bank_Locator": "",
"Manufacturer": "",
"Serial_Number": "",
},
"BIOS_Information": {
"Vendor": "",
"Address": "",
"Version": "",
"ROM_Size": "",
"Release_Date": "",
"Runtime_Size": "",
"BIOS_Revision": "",
"Characteristics": ["", "", ""],
},
"System_Information": {
"UUID": "",
"Family": "",
"Version": "",
"SKU_Number": "",
"Manufacturer": "",
"Product_Name": "",
"Wake-up_Type": "",
"Serial_Number": "",
},
"Chassis_Information": {
"Lock": "",
"Type": "",
"Height": "",
"Version": "",
"Asset_Tag": "",
"Manufacturer": "",
"Boot-up_State": "",
"Serial_Number": "",
"Thermal_State": "",
"OEM_Information": "",
"Security_Status": "",
"Contained_Elements": "",
"Power_Supply_State": "",
"Number_Of_Power_Cords": "",
},
"Physical_Memory_Array": {"Use": "", "Location": "", "Maximum_Capacity": "", "Number_Of_Devices": "", "Error_Correction_Type": ""},
"Processor_Information": [
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
{
"ID": "",
"Type": "",
"Family": "",
"Status": "",
"Upgrade": "",
"Version": "",
"Voltage": "",
"Asset_Tag": "",
"Max_Speed": "",
"Part_Number": "",
"Manufacturer": "",
"Current_Speed": "",
"Serial_Number": "",
"External_Clock": "",
"Socket_Designation": "",
},
],
"System_Boot_Information": {"Status": ""},
"Memory_Array_Mapped_Address": {"Range_Size": "", "Ending_Address": "", "Partition_Width": "", "Starting_Address": ""},
"Memory_Device_Mapped_Address": {"Range_Size": "", "Ending_Address": "", "Starting_Address": "", "Partition_Row_Position": ""},
},
"host_info": {
"mac": [""],
"win64": True,
"environ": {
"OS": "",
"TMP": "",
"PATH": "",
"TEMP": "",
"PUBLIC": "",
"WINDIR": "",
"APPDATA": "",
"COMSPEC": "",
"PATHEXT": "",
"USERNAME": "",
"SYSTEMROOT": "",
"USERDOMAIN": "",
"PROGRAMDATA": "",
"SYSTEMDRIVE": "",
"USERPROFILE": "",
"COMPUTERNAME": "",
"LOCALAPPDATA": "",
"OPENSSL_CONF": "",
"PROGRAMFILES": "",
"PROGRAMW6432": "",
"PSMODULEPATH": "",
"DOKANLIBRARY1": "",
"UD_INSTALL_DIR": "",
"ALLUSERSPROFILE": "",
"MOZ_PLUGIN_PATH": "",
"PROCESSOR_LEVEL": "",
"FP_NO_HOST_CHECK": "",
"PROGRAMFILES(X86)": "",
"COMMONPROGRAMFILES": "",
"COMMONPROGRAMW6432": "",
"PROCESSOR_REVISION": "",
"NUMBER_OF_PROCESSORS": "",
"PROCESSOR_IDENTIFIER": "",
"PROCESSOR_ARCHITECTURE": "",
"PROCESSOR_ARCHITEW6432": "",
"COMMONPROGRAMFILES(X86)": "",
},
"main_ip": ["", ""],
"os_name": "",
"cpu_name": "",
"gateways": [""],
"platform": "",
"dnsdomain": "",
"uac_level": "",
"networking": [
{
"mac": "",
"addr": [
{"addr": "", "netmask": "", "broadcast": "", "connected": True},
{"addr": "", "netmask": "", "broadcast": "", "connected": True},
],
"iface": "",
}
],
"os_version": "",
"description": "",
"dns_servers": ["", ""],
"domain_name": "",
"local_users": ["", "", ""],
"local_groups": {
"Invités": [""],
"IIS_IUSRS": [""],
"Duplicateurs": [],
"Utilisateurs": ["", "", "", ""],
"Administrateurs": ["", "", "", "", ""],
"Opérateurs de sauvegarde": [],
"Utilisateurs avec pouvoir": [],
"Opérateurs de chiffrement": [],
"Utilisateurs du Bureau à distance": ["", ""],
"Opérateurs de configuration réseau": [],
"Lecteurs des journaux d'événements": [],
"Utilisateurs du modèle COM distribué": [],
"Utilisateurs du journal de performances": [],
"Utilisateurs de l'Analyseur de performances": [],
},
"repositories": "",
"computer_fqdn": "",
"computer_name": "",
"connected_ips": ["", "", ""],
"computer_ad_dn": "",
"cpu_identifier": "",
"local_profiles": [
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
{"sid": "", "user": "", "profile_path": ""},
],
"profiles_users": ["", "", "", "", "", "", "", "", "", "", "", ""],
"workgroup_name": "",
"windows_version": "",
"computer_ad_site": "",
"registered_owner": "",
"domain_controller": "",
"installation_date": "",
"wua_agent_version": "",
"computer_ad_groups": [""],
"domain_info_source": "",
"system_productname": "",
"system_manufacturer": "",
"local_administrators": ["", ""],
"windows_product_infos": {"version": "", "key_match": True, "product_id": "", "product_key": "", "product_partnr": "", "product_source": ""},
"windows_startup_items": {"run": [], "common_startup": [{"name": "", "command": ""}, {"name": "", "command": ""}]},
"registered_organization": "",
"domain_controller_address": "",
},
"host_metrics": {
"boot_count": "0",
"local_drives": {},
"virtual_memory": 0,
"logged_in_users": [],
"physical_memory": 0,
"last_bootup_time": "",
"wapt-memory-usage": {
"rss": 0,
"vms": 0,
"wset": 0,
"private": 0,
"pagefile": 0,
"peak_wset": 0,
"paged_pool": 0,
"nonpaged_pool": 0,
"peak_pagefile": 0,
"num_page_faults": 0,
"peak_paged_pool": 0,
"peak_nonpaged_pool": 0,
},
"last_logged_on_user": "",
},
"host_networking": {
"mac": {},
"connected_ips": {},
"gateways": {},
"dbs_servers": {},
"physical_memory": 0,
"interfaces": [{"mac":"","iface":"","addr":[{"netmask":"","connected":True,"broadcast":"","addr":""}]}],
"main_ip": {},
"dnsdomain": "",
},
"uuid": "",
}
38d056ab130f7bf7c481c12636a4e9959de36561d3dfcbe54c6e3571bc0c1dc3 : WAPT/certificate.crt
9f02b1b7fe227f0eff05bf01ae02083e19dfb0c3ecf56704357f6bba3c50301d : WAPT/control
dbe1285588343cbdf5a6d18fd0cf0038de795d7a8a79cbaf90fb34720f7be890 : WAPT/icon.png
c4360f8eff757166a3406b2d3b36828eeff949aab43c412013f97412c22ac3d6 : glpi.ini
d4635f1ad70245207ad52a3e75aa7ff86f8de4910da54b1a195c56a2fa2825e1 : luti.json
f338f7e518b392500cf66eddfead799b1a08bdbb2e51392779d89e6d95b9a574 : setup.py
36f8fe489fd06551fb0bd3389b6689a12dedce8ec63c014f242f7b3edc2655b6 : wapt_api.ini