Fix the getLan config

We did the filtering during IPAddress parameter
to avoid link local address but left it for subnetMask
and vlan parameter.
With the introduction of zeroconfig IP we have
multiIPaddress can exist on the interface.
This commit introduces the filtering for subnetmask and
vlan parameter also.

Resolves openbmc/openbmc#2664

Change-Id: I244bfe8b9d7efbf55fc1b7051489a8a204182906
Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
diff --git a/utils.hpp b/utils.hpp
index 0b2b2db..55978fb 100644
--- a/utils.hpp
+++ b/utils.hpp
@@ -45,19 +45,19 @@
                              const std::string& subtreePath = ROOT,
                              const std::string& match = {});
 
-/** @brief Gets the ipAddres of first dbus IP object of Non-LinkLocalIPAddress
+/** @brief Get the ipObject of first dbus IP object of Non-LinkLocalIPAddress
  *         type from the given subtree, if not available gets IP object of
  *         LinkLocalIPAddress type.
  *  @param[in] bus - DBUS Bus Object.
  *  @param[in] interface - Dbus interface.
  *  @param[in] subtreePath - subtree from where the search should start.
  *  @param[in] match - identifier for object.
- *  @return On success returns the ipAddress.
+ *  @return On success returns the object having objectpath and servicename.
  */
-std::string getIPAddress(sdbusplus::bus::bus& bus,
-                         const std::string& interface,
-                         const std::string& subtreePath,
-                         const std::string& match);
+DbusObjectInfo getIPObject(sdbusplus::bus::bus& bus,
+                           const std::string& interface,
+                           const std::string& subtreePath,
+                           const std::string& match);
 
 /** @brief Gets the value associated with the given object
  *         and the interface.