Searched hist:"6 d4a44ed" (Results 1 – 2 of 2) sorted by relevance
/openbmc/phosphor-host-ipmid/ |
H A D | transporthandler.hpp | 6d4a44ed Mon Jan 24 01:04:00 CST 2022 Jiaqing Zhao <jiaqing.zhao@intel.com> Check prefix length in Set LAN Config Param 6 & 56
In phosphor-networkd, the allowed prefix length is 1 to 32 for IPv4 and 1 to 128 for IPv6. Calling DBus API with an invalid prefix length will result in uncaught exceptions. This patch checks prefix length before setting it and returns appropriate error code on invalid value.
Tested: * Setting IPv4 SubnetMask to 0.0.0.0 (Param 6) returns 0xcc. * Setting IPv6 static address with PrefixLength==129 (Param 56) returns 0xc9.
Change-Id: I03af233905e415c96c896c85baf98846d0880e95 Signed-off-by: Jiaqing Zhao <jiaqing.zhao@intel.com>
|
H A D | transporthandler.cpp | 6d4a44ed Mon Jan 24 01:04:00 CST 2022 Jiaqing Zhao <jiaqing.zhao@intel.com> Check prefix length in Set LAN Config Param 6 & 56
In phosphor-networkd, the allowed prefix length is 1 to 32 for IPv4 and 1 to 128 for IPv6. Calling DBus API with an invalid prefix length will result in uncaught exceptions. This patch checks prefix length before setting it and returns appropriate error code on invalid value.
Tested: * Setting IPv4 SubnetMask to 0.0.0.0 (Param 6) returns 0xcc. * Setting IPv6 static address with PrefixLength==129 (Param 56) returns 0xc9.
Change-Id: I03af233905e415c96c896c85baf98846d0880e95 Signed-off-by: Jiaqing Zhao <jiaqing.zhao@intel.com>
|