NetworkProtocol: fix hardcoded property name in handleProtocolEnabled
handleProtocolEnabled() used the hardcoded string "IPMI/ProtocolEnabled"
as the Redfish property name in both setDbusProperty calls, meaning DBus
errors for SSH were incorrectly reported against IPMI/ProtocolEnabled.
Add a redfishProperty parameter so each call site passes the correct
path. Update the IPMI call site to pass "IPMI/ProtocolEnabled" and the
SSH call site to pass "SSH/ProtocolEnabled" ensuring DBus errors surface
against the right Redfish property.
Tested :
```
curl -k -X PATCH -H "Content-Type: application/json" -d '{"SSH":{"ProtocolEnabled":false}}'
https://${BMC_IP}/redfish/v1/Managers/BMC_0/NetworkProtocol -u root:0penBmc -v
returned
< HTTP/2 204
Terminal validation
#busctl get-property xyz.openbmc_project.Control.Service.Manager \
> /xyz/openbmc_project/control/service/dropbear \
> xyz.openbmc_project.Control.Service.Attributes Running
b false
#systemctl status dropbear.socket
* dropbear.socket
Loaded: loaded (/usr/lib/systemd/system/dropbear.socket; disabled; preset: enabled)
Active: inactive (dead)
Listen: [::]:22 (Stream)
Accepted: 0; Connected: 0;
curl -k https://${BMC_IP}/redfish/v1/Managers/BMC_0/NetworkProtocol -u root:0penBmc -v
{
"@odata.id": "/redfish/v1/Managers/BMC_0/NetworkProtocol",
"@odata.type": "#ManagerNetworkProtocol.v1_9_0.ManagerNetworkProtocol",
"Description": "Manager Network Service",
"FQDN": "gb200nvl-bmc",
"HTTP": {
"Port": null,
"ProtocolEnabled": false
},
"HTTPS": {
"Certificates": {
"@odata.id": "/redfish/v1/Managers/BMC_0/NetworkProtocol/HTTPS/Certificates"
},
"Port": 443,
"ProtocolEnabled": true
},
"HostName": "gb200nvl-bmc",
"IPMI": {
"Port": 623,
"ProtocolEnabled": true
},
"Id": "NetworkProtocol",
"NTP": {
"NTPServers": [],
"NetworkSuppliedServers": [],
"ProtocolEnabled": true
},
"Name": "Manager Network Protocol",
"Oem": {
"Nvidia": {
"Rsyslog": {
"@odata.type": "#NvidiaNetworkProtocol.v1_1_0.Rsyslog",
"Address": "",
"Filter": {
"Facilities": [],
"LowestSeverity": "Error"
},
"Port": 0,
"RFCFormat": "RFC3164",
"State": "Disabled",
"TLS": "Disabled",
"TransportProtocol": "TCP"
}
}
},
"SSH": {
"Port": null,
"ProtocolEnabled": false
},
"Status": {
"Health": "OK",
"State": "Enabled"
}
}
```
Change-Id: I4394c1b33a33f15a5086b2e55baf85dbf80bceca
Signed-off-by: Chandramohan Harkude <chandramohan.harkude@gmail.com> C
Chandramohan Harkude committed
8f98766273d5fb78378dbd443c5abf5e3148cb0b
Parent: 37b599b
Committed by Ed Tanous <ed@tanous.net>
on 7/8/2026, 12:11:16 AM