commit | cf91c8c4becff235d731c15e00c06ee630775127 | [log] [tgz] |
---|---|---|
author | Asmitha Karunanithi <asmitk01@in.ibm.com> | Fri Jan 24 04:39:15 2025 -0600 |
committer | Ed Tanous <ed@tanous.net> | Tue Jan 28 03:54:11 2025 +0000 |
tree | d69d993603ab05a98ad79258f06e005ca9455a7e | |
parent | d2ec1bd7a0267cfd259615b979a4a2119f09a7d6 [diff] |
Fix crash when modifying static v6 default gateway When modifying a static default gateway, the existing entry is deleted, and a new D-Bus object is created with the updated gateway. Currently, this operation fails with an Internal Server Error and causes a bmcweb crash because the gateway value is passed as a std::string_view. Debugging revealed that the data's lifetime ends before it is accessed. This commit resolves the issue by replacing std::string_view with const std::string&. Tested By: Assuming there are currently three IPv6StaticDefaultGateways configured, the following command modifies the second entry: ''' PATCH -D patch.txt -d '{"IPv6StaticDefaultGateways": [{},{"Address": "<new modified gateway>"},{}]}' https://${bmc}/redfish/v1/Managers/bmc/EthernetInterfaces/eth1 ''' Change-Id: I1bd18005fb71a1567b1844b04c4cc4cd322cdf6e Signed-off-by: Asmitha Karunanithi <asmitk01@in.ibm.com>
This component attempts to be a "do everything" embedded webserver for OpenBMC.
The webserver implements a few distinct interfaces:
bmcweb at a protocol level supports http and https. TLS is supported through OpenSSL.
Bmcweb supports multiple authentication protocols:
Each of these types of authentication is able to be enabled or disabled both via runtime policy changes (through the relevant Redfish APIs) or via configure time options. All authentication mechanisms supporting username/password are routed to libpam, to allow for customization in authentication implementations.
All authorization in bmcweb is determined at routing time, and per route, and conform to the Redfish PrivilegeRegistry.
*Note: Non-Redfish functions are mapped to the closest equivalent Redfish privilege level.
bmcweb is configured per the meson build files. Available options are documented in meson_options.txt
meson setup builddir ninja -C builddir
If any of the dependencies are not found on the host system during configuration, meson will automatically download them via its wrap dependencies mentioned in bmcweb/subprojects
.
bmcweb relies on some on-system data for storage of persistent data that is internal to the process. Details on the exact data stored and when it is read/written can seen from the persistent_data
namespace.
When SSL support is enabled and a usable certificate is not found, bmcweb will generate a self-signed a certificate before launching the server. Please see the bmcweb source code for details on the parameters this certificate is built with.
bmcweb is capable of aggregating resources from satellite BMCs. Refer to AGGREGATION.md for more information on how to enable and use this feature.