IIsSmtpServiceSetting - WMI sample in Python
The foundations for Manageability in Windows 2019/2012/2008/ and Windows 10/8/7/Vista/XP are Windows Management Instrumentation (WMI; formerly WBEM) and WMI extensions for Windows Driver Model (WDM).
ActiveXperts Network Monitor provides the ability to build monitor check routines based on WMI. ActiveXperts has collected more than a hundred WMI samples. You can use these samples as a base for new check routines you can write yourself.
On this site, you can find many WMI samples.
The IIsSmtpServiceSetting WMI class can be used in ActiveXperts Network Monitor to monitor your servers.
IIsSmtpServiceSetting
Example(s)
from win32com.client import GetObject objWMI = GetObject('winmgmts:\\\\.\\root\\MicrosoftIISv2').InstancesOf('IIsSmtpServiceSetting') for obj in objWMI: if obj.AccessExecute != None: print("AccessExecute:" + str(obj.AccessExecute)) if obj.AccessFlags != None: print("AccessFlags:" + str(obj.AccessFlags)) if obj.AccessNoPhysicalDir != None: print("AccessNoPhysicalDir:" + str(obj.AccessNoPhysicalDir)) if obj.AccessNoRemoteExecute != None: print("AccessNoRemoteExecute:" + str(obj.AccessNoRemoteExecute)) if obj.AccessNoRemoteRead != None: print("AccessNoRemoteRead:" + str(obj.AccessNoRemoteRead)) if obj.AccessNoRemoteScript != None: print("AccessNoRemoteScript:" + str(obj.AccessNoRemoteScript)) if obj.AccessNoRemoteWrite != None: print("AccessNoRemoteWrite:" + str(obj.AccessNoRemoteWrite)) if obj.AccessRead != None: print("AccessRead:" + str(obj.AccessRead)) if obj.AccessScript != None: print("AccessScript:" + str(obj.AccessScript)) if obj.AccessSource != None: print("AccessSource:" + str(obj.AccessSource)) if obj.AccessSSL != None: print("AccessSSL:" + str(obj.AccessSSL)) if obj.AccessSSL128 != None: print("AccessSSL128:" + str(obj.AccessSSL128)) if obj.AccessSSLFlags != None: print("AccessSSLFlags:" + str(obj.AccessSSLFlags)) if obj.AccessSSLMapCert != None: print("AccessSSLMapCert:" + str(obj.AccessSSLMapCert)) if obj.AccessSSLNegotiateCert != None: print("AccessSSLNegotiateCert:" + str(obj.AccessSSLNegotiateCert)) if obj.AccessSSLRequireCert != None: print("AccessSSLRequireCert:" + str(obj.AccessSSLRequireCert)) if obj.AccessWrite != None: print("AccessWrite:" + str(obj.AccessWrite)) if obj.AddNoHeaders != None: print("AddNoHeaders:" + str(obj.AddNoHeaders)) if obj.AdminACLBin != None: print("AdminACLBin:" + str(obj.AdminACLBin)) if obj.AllowAnonymous != None: print("AllowAnonymous:" + str(obj.AllowAnonymous)) if obj.AlwaysUseSsl != None: print("AlwaysUseSsl:" + str(obj.AlwaysUseSsl)) if obj.AnonymousOnly != None: print("AnonymousOnly:" + str(obj.AnonymousOnly)) if obj.AnonymousPasswordSync != None: print("AnonymousPasswordSync:" + str(obj.AnonymousPasswordSync)) if obj.AnonymousUserName != None: print("AnonymousUserName:" + str(obj.AnonymousUserName)) if obj.AnonymousUserPass != None: print("AnonymousUserPass:" + str(obj.AnonymousUserPass)) if obj.AuthAnonymous != None: print("AuthAnonymous:" + str(obj.AuthAnonymous)) if obj.AuthBasic != None: print("AuthBasic:" + str(obj.AuthBasic)) if obj.AuthFlags != None: print("AuthFlags:" + str(obj.AuthFlags)) if obj.AuthMD5 != None: print("AuthMD5:" + str(obj.AuthMD5)) if obj.AuthNTLM != None: print("AuthNTLM:" + str(obj.AuthNTLM)) if obj.AuthPassport != None: print("AuthPassport:" + str(obj.AuthPassport)) if obj.AzEnable != None: print("AzEnable:" + str(obj.AzEnable)) if obj.AzScopeName != None: print("AzScopeName:" + str(obj.AzScopeName)) if obj.AzStoreName != None: print("AzStoreName:" + str(obj.AzStoreName)) if obj.BadMailDirectory != None: print("BadMailDirectory:" + str(obj.BadMailDirectory)) if obj.Caption != None: print("Caption:" + str(obj.Caption)) if obj.ConnectionTimeout != None: print("ConnectionTimeout:" + str(obj.ConnectionTimeout)) if obj.ConnectResponse != None: print("ConnectResponse:" + str(obj.ConnectResponse)) if obj.DefaultDomain != None: print("DefaultDomain:" + str(obj.DefaultDomain)) if obj.DefaultLogonDomain != None: print("DefaultLogonDomain:" + str(obj.DefaultLogonDomain)) if obj.Description != None: print("Description:" + str(obj.Description)) if obj.DisableSocketPooling != None: print("DisableSocketPooling:" + str(obj.DisableSocketPooling)) if obj.DoMasquerade != None: print("DoMasquerade:" + str(obj.DoMasquerade)) if obj.DontLog != None: print("DontLog:" + str(obj.DontLog)) if obj.DropDirectory != None: print("DropDirectory:" + str(obj.DropDirectory)) if obj.EnableReverseDnsLookup != None: print("EnableReverseDnsLookup:" + str(obj.EnableReverseDnsLookup)) if obj.EtrnDays != None: print("EtrnDays:" + str(obj.EtrnDays)) if obj.EtrnSubdomains != None: print("EtrnSubdomains:" + str(obj.EtrnSubdomains)) if obj.FullyQualifiedDomainName != None: print("FullyQualifiedDomainName:" + str(obj.FullyQualifiedDomainName)) if obj.HopCount != None: print("HopCount:" + str(obj.HopCount)) if obj.LimitRemoteConnections != None: print("LimitRemoteConnections:" + str(obj.LimitRemoteConnections)) if obj.LocalRetryAttempts != None: print("LocalRetryAttempts:" + str(obj.LocalRetryAttempts)) if obj.LocalRetryInterval != None: print("LocalRetryInterval:" + str(obj.LocalRetryInterval)) if obj.LogExtFileBytesRecv != None: print("LogExtFileBytesRecv:" + str(obj.LogExtFileBytesRecv)) if obj.LogExtFileBytesSent != None: print("LogExtFileBytesSent:" + str(obj.LogExtFileBytesSent)) if obj.LogExtFileClientIp != None: print("LogExtFileClientIp:" + str(obj.LogExtFileClientIp)) if obj.LogExtFileComputerName != None: print("LogExtFileComputerName:" + str(obj.LogExtFileComputerName)) if obj.LogExtFileCookie != None: print("LogExtFileCookie:" + str(obj.LogExtFileCookie)) if obj.LogExtFileDate != None: print("LogExtFileDate:" + str(obj.LogExtFileDate)) if obj.LogExtFileFlags != None: print("LogExtFileFlags:" + str(obj.LogExtFileFlags)) if obj.LogExtFileHost != None: print("LogExtFileHost:" + str(obj.LogExtFileHost)) if obj.LogExtFileHttpStatus != None: print("LogExtFileHttpStatus:" + str(obj.LogExtFileHttpStatus)) if obj.LogExtFileHttpSubStatus != None: print("LogExtFileHttpSubStatus:" + str(obj.LogExtFileHttpSubStatus)) if obj.LogExtFileMethod != None: print("LogExtFileMethod:" + str(obj.LogExtFileMethod)) if obj.LogExtFileProtocolVersion != None: print("LogExtFileProtocolVersion:" + str(obj.LogExtFileProtocolVersion)) if obj.LogExtFileReferer != None: print("LogExtFileReferer:" + str(obj.LogExtFileReferer)) if obj.LogExtFileServerIp != None: print("LogExtFileServerIp:" + str(obj.LogExtFileServerIp)) if obj.LogExtFileServerPort != None: print("LogExtFileServerPort:" + str(obj.LogExtFileServerPort)) if obj.LogExtFileSiteName != None: print("LogExtFileSiteName:" + str(obj.LogExtFileSiteName)) if obj.LogExtFileTime != None: print("LogExtFileTime:" + str(obj.LogExtFileTime)) if obj.LogExtFileTimeTaken != None: print("LogExtFileTimeTaken:" + str(obj.LogExtFileTimeTaken)) if obj.LogExtFileUriQuery != None: print("LogExtFileUriQuery:" + str(obj.LogExtFileUriQuery)) if obj.LogExtFileUriStem != None: print("LogExtFileUriStem:" + str(obj.LogExtFileUriStem)) if obj.LogExtFileUserAgent != None: print("LogExtFileUserAgent:" + str(obj.LogExtFileUserAgent)) if obj.LogExtFileUserName != None: print("LogExtFileUserName:" + str(obj.LogExtFileUserName)) if obj.LogExtFileWin32Status != None: print("LogExtFileWin32Status:" + str(obj.LogExtFileWin32Status)) if obj.LogFileDirectory != None: print("LogFileDirectory:" + str(obj.LogFileDirectory)) if obj.LogFilePeriod != None: print("LogFilePeriod:" + str(obj.LogFilePeriod)) if obj.LogFileTruncateSize != None: print("LogFileTruncateSize:" + str(obj.LogFileTruncateSize)) if obj.LogModuleList != None: print("LogModuleList:" + str(obj.LogModuleList)) if obj.LogOdbcDataSource != None: print("LogOdbcDataSource:" + str(obj.LogOdbcDataSource)) if obj.LogOdbcPassword != None: print("LogOdbcPassword:" + str(obj.LogOdbcPassword)) if obj.LogOdbcTableName != None: print("LogOdbcTableName:" + str(obj.LogOdbcTableName)) if obj.LogOdbcUserName != None: print("LogOdbcUserName:" + str(obj.LogOdbcUserName)) if obj.LogPluginClsid != None: print("LogPluginClsid:" + str(obj.LogPluginClsid)) if obj.LogType != None: print("LogType:" + str(obj.LogType)) if obj.MasqueradeDomain != None: print("MasqueradeDomain:" + str(obj.MasqueradeDomain)) if obj.MaxBandwidth != None: print("MaxBandwidth:" + str(obj.MaxBandwidth)) if obj.MaxBatchedMessages != None: print("MaxBatchedMessages:" + str(obj.MaxBatchedMessages)) if obj.MaxConnections != None: print("MaxConnections:" + str(obj.MaxConnections)) if obj.MaxDirChangeIOSize != None: print("MaxDirChangeIOSize:" + str(obj.MaxDirChangeIOSize)) if obj.MaxEndpointConnections != None: print("MaxEndpointConnections:" + str(obj.MaxEndpointConnections)) if obj.MaxMailObjects != None: print("MaxMailObjects:" + str(obj.MaxMailObjects)) if obj.MaxMessageSize != None: print("MaxMessageSize:" + str(obj.MaxMessageSize)) if obj.MaxOutConnections != None: print("MaxOutConnections:" + str(obj.MaxOutConnections)) if obj.MaxOutConnectionsPerDomain != None: print("MaxOutConnectionsPerDomain:" + str(obj.MaxOutConnectionsPerDomain)) if obj.MaxRecipients != None: print("MaxRecipients:" + str(obj.MaxRecipients)) if obj.MaxSessionSize != None: print("MaxSessionSize:" + str(obj.MaxSessionSize)) if obj.MaxSmtpErrors != None: print("MaxSmtpErrors:" + str(obj.MaxSmtpErrors)) if obj.Name != None: print("Name:" + str(obj.Name)) if obj.NameResolutionType != None: print("NameResolutionType:" + str(obj.NameResolutionType)) if obj.NTAuthenticationProviders != None: print("NTAuthenticationProviders:" + str(obj.NTAuthenticationProviders)) if obj.PickupDirectory != None: print("PickupDirectory:" + str(obj.PickupDirectory)) if obj.QueueDirectory != None: print("QueueDirectory:" + str(obj.QueueDirectory)) if obj.Realm != None: print("Realm:" + str(obj.Realm)) if obj.RelayForAuth != None: print("RelayForAuth:" + str(obj.RelayForAuth)) if obj.RelayIpList != None: print("RelayIpList:" + str(obj.RelayIpList)) if obj.RemoteRetryAttempts != None: print("RemoteRetryAttempts:" + str(obj.RemoteRetryAttempts)) if obj.RemoteRetryInterval != None: print("RemoteRetryInterval:" + str(obj.RemoteRetryInterval)) if obj.RemoteSmtpPort != None: print("RemoteSmtpPort:" + str(obj.RemoteSmtpPort)) if obj.RemoteSmtpSecurePort != None: print("RemoteSmtpSecurePort:" + str(obj.RemoteSmtpSecurePort)) if obj.RemoteTimeout != None: print("RemoteTimeout:" + str(obj.RemoteTimeout)) if obj.RouteAction != None: print("RouteAction:" + str(obj.RouteAction)) if obj.RoutePassword != None: print("RoutePassword:" + str(obj.RoutePassword)) if obj.RouteUserName != None: print("RouteUserName:" + str(obj.RouteUserName)) if obj.RoutingDll != None: print("RoutingDll:" + str(obj.RoutingDll)) if obj.SaslLogonDomain != None: print("SaslLogonDomain:" + str(obj.SaslLogonDomain)) if obj.SendBadTo != None: print("SendBadTo:" + str(obj.SendBadTo)) if obj.SendNdrTo != None: print("SendNdrTo:" + str(obj.SendNdrTo)) if obj.ServerAutoStart != None: print("ServerAutoStart:" + str(obj.ServerAutoStart)) if obj.ServerComment != None: print("ServerComment:" + str(obj.ServerComment)) if obj.ServerListenTimeout != None: print("ServerListenTimeout:" + str(obj.ServerListenTimeout)) if obj.SettingID != None: print("SettingID:" + str(obj.SettingID)) if obj.ShouldDeliver != None: print("ShouldDeliver:" + str(obj.ShouldDeliver)) if obj.ShouldPickupMail != None: print("ShouldPickupMail:" + str(obj.ShouldPickupMail)) if obj.ShouldPipelineIn != None: print("ShouldPipelineIn:" + str(obj.ShouldPipelineIn)) if obj.ShouldPipelineOut != None: print("ShouldPipelineOut:" + str(obj.ShouldPipelineOut)) if obj.SmartHost != None: print("SmartHost:" + str(obj.SmartHost)) if obj.SmartHostType != None: print("SmartHostType:" + str(obj.SmartHostType)) if obj.SmtpAdvQueueDll != None: print("SmtpAdvQueueDll:" + str(obj.SmtpAdvQueueDll)) if obj.SmtpAqueueWait != None: print("SmtpAqueueWait:" + str(obj.SmtpAqueueWait)) if obj.SmtpAuthTimeout != None: print("SmtpAuthTimeout:" + str(obj.SmtpAuthTimeout)) if obj.SmtpBdatTimeout != None: print("SmtpBdatTimeout:" + str(obj.SmtpBdatTimeout)) if obj.SmtpClearTextProvider != None: print("SmtpClearTextProvider:" + str(obj.SmtpClearTextProvider)) if obj.SmtpCommandLogMask != None: print("SmtpCommandLogMask:" + str(obj.SmtpCommandLogMask)) if obj.SmtpConnectTimeout != None: print("SmtpConnectTimeout:" + str(obj.SmtpConnectTimeout)) if obj.SmtpDataTimeout != None: print("SmtpDataTimeout:" + str(obj.SmtpDataTimeout)) if obj.SmtpDisableRelay != None: print("SmtpDisableRelay:" + str(obj.SmtpDisableRelay)) if obj.SmtpDomainValidationFlags != None: print("SmtpDomainValidationFlags:" + str(obj.SmtpDomainValidationFlags)) if obj.SmtpDotStuffPickupDirFiles != None: print("SmtpDotStuffPickupDirFiles:" + str(obj.SmtpDotStuffPickupDirFiles)) if obj.SmtpDSNLanguageID != None: print("SmtpDSNLanguageID:" + str(obj.SmtpDSNLanguageID)) if obj.SmtpDSNOptions != None: print("SmtpDSNOptions:" + str(obj.SmtpDSNOptions)) if obj.SmtpEventlogLevel != None: print("SmtpEventlogLevel:" + str(obj.SmtpEventlogLevel)) if obj.SmtpFlushMailFile != None: print("SmtpFlushMailFile:" + str(obj.SmtpFlushMailFile)) if obj.SmtpHeloNoDomain != None: print("SmtpHeloNoDomain:" + str(obj.SmtpHeloNoDomain)) if obj.SmtpHeloTimeout != None: print("SmtpHeloTimeout:" + str(obj.SmtpHeloTimeout)) if obj.SmtpInboundCommandSupportOptions != None: print("SmtpInboundCommandSupportOptions:" + str(obj.SmtpInboundCommandSupportOptions)) if obj.SmtpIpRestrictionFlag != None: print("SmtpIpRestrictionFlag:" + str(obj.SmtpIpRestrictionFlag)) if obj.SmtpLocalDelayExpireMinutes != None: print("SmtpLocalDelayExpireMinutes:" + str(obj.SmtpLocalDelayExpireMinutes)) if obj.SmtpLocalNDRExpireMinutes != None: print("SmtpLocalNDRExpireMinutes:" + str(obj.SmtpLocalNDRExpireMinutes)) if obj.SmtpMailFromTimeout != None: print("SmtpMailFromTimeout:" + str(obj.SmtpMailFromTimeout)) if obj.SmtpMailNoHelo != None: print("SmtpMailNoHelo:" + str(obj.SmtpMailNoHelo)) if obj.SmtpMaxRemoteQThreads != None: print("SmtpMaxRemoteQThreads:" + str(obj.SmtpMaxRemoteQThreads)) if obj.SmtpOutboundCommandSupportOptions != None: print("SmtpOutboundCommandSupportOptions:" + str(obj.SmtpOutboundCommandSupportOptions)) if obj.SmtpRcptToTimeout != None: print("SmtpRcptToTimeout:" + str(obj.SmtpRcptToTimeout)) if obj.SmtpRemoteDelayExpireMinutes != None: print("SmtpRemoteDelayExpireMinutes:" + str(obj.SmtpRemoteDelayExpireMinutes)) if obj.SmtpRemoteNDRExpireMinutes != None: print("SmtpRemoteNDRExpireMinutes:" + str(obj.SmtpRemoteNDRExpireMinutes)) if obj.SmtpRemoteProgressiveRetry != None: print("SmtpRemoteProgressiveRetry:" + str(obj.SmtpRemoteProgressiveRetry)) if obj.SmtpRemoteRetryThreshold != None: print("SmtpRemoteRetryThreshold:" + str(obj.SmtpRemoteRetryThreshold)) if obj.SmtpRsetTimeout != None: print("SmtpRsetTimeout:" + str(obj.SmtpRsetTimeout)) if obj.SmtpSaslTimeout != None: print("SmtpSaslTimeout:" + str(obj.SmtpSaslTimeout)) if obj.SmtpSSLCertHostnameValidation != None: print("SmtpSSLCertHostnameValidation:" + str(obj.SmtpSSLCertHostnameValidation)) if obj.SmtpSSLRequireTrustedCA != None: print("SmtpSSLRequireTrustedCA:" + str(obj.SmtpSSLRequireTrustedCA)) if obj.SmtpTurnTimeout != None: print("SmtpTurnTimeout:" + str(obj.SmtpTurnTimeout)) if obj.SmtpUseTcpDns != None: print("SmtpUseTcpDns:" + str(obj.SmtpUseTcpDns)) if obj.UpdatedDefaultDomain != None: print("UpdatedDefaultDomain:" + str(obj.UpdatedDefaultDomain)) if obj.UpdatedFQDN != None: print("UpdatedFQDN:" + str(obj.UpdatedFQDN)) print("") print("########") print("")