ing
This commit is contained in:
parent
34f3f59837
commit
d9dea68ea6
|
@ -735,15 +735,15 @@ func (ds *ofDiscoverySession) addtionalServiceMDNS(service *omd.Service, meta ma
|
||||||
|
|
||||||
switch portNumber {
|
switch portNumber {
|
||||||
case 515:
|
case 515:
|
||||||
if "printer" == service.Key {
|
if "printer" == service.Name || "printer" == service.Key {
|
||||||
_h := service.Port.Host
|
_h, _ := ds.findHost(service.Port.Host)
|
||||||
_h.HostType = "PRINTER"
|
_h.HostType = "PRINTER"
|
||||||
_h.Name = service.Name
|
_h.Name = service.Name
|
||||||
ds.delegate(_h)
|
ds.delegate(_h)
|
||||||
}
|
}
|
||||||
case 9100:
|
case 9100:
|
||||||
if "pdl-datastream" == service.Key {
|
if "pdl-datastream" == service.Name || "pdl-datastream" == service.Key {
|
||||||
_h := service.Port.Host
|
_h, _ := ds.findHost(service.Port.Host)
|
||||||
_h.HostType = "PRINTER"
|
_h.HostType = "PRINTER"
|
||||||
_h.Name = service.Name
|
_h.Name = service.Name
|
||||||
ds.delegate(_h)
|
ds.delegate(_h)
|
||||||
|
|
|
@ -24,9 +24,12 @@ func scanTCP(discoverySession session.DiscoverySession, targetPort *omd.Port) er
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("Service scan on %s:%s error has occurred %v ", hostAddress, targetPort.PortNumber, err)
|
return fmt.Errorf("Service scan on %s:%s error has occurred %v ", hostAddress, targetPort.PortNumber, err)
|
||||||
}
|
}
|
||||||
if 9100 == portNumber {
|
|
||||||
|
if omm.MetaHostTypeEnumPrinter.String() == targetPort.Host.HostType {
|
||||||
|
if 9100 == portNumber || 515 == portNumber {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
matchCtx := osm.NewMatchCtx(hostAddress, portNumber)
|
matchCtx := osm.NewMatchCtx(hostAddress, portNumber)
|
||||||
connectors := newConnectors()
|
connectors := newConnectors()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user