Skip to main content

Port Forwarding Feature

The section is descripted how to set and get configurations of port forwarding.

Note
IPv6 not support
Table 1. Port forwarding properties

Name

type

Read

only

Description

Ipv4

Table

true

The history Ipv4 records.

Index

Value

false

Interface Service index value. Index range 1~14, 1~10 are used for forwarding direction: Client -> BMC -> OS, and 11~14 are used for forwarding direction:OS -> BMC ->Client

ServiceEnable

String

false

Indicates if the Service is enabled or disabled.

Address

String

false

Specify destination Ipv4 address: OS or remote client device.

DestinationHostPort

Value

false

DestinationHostPort value of Operation System listened.

Protocol

String

false

Protocol string can use TCP or UDP

SourcePort

Value

false

SourcePort value of BMC.

Request

Get Port Forwarding settings

GET https://{{ip}}/redfish/v1/Managers/Self/NetworkProtocol/Oem/Lenovo/PortForwarding
Content-Type: application/json

Response

ServiceEnable: Disable Case
{
"@odata.context": "/redfish/v1/$metadata#ManagerNetworkProtocol.ManagerNetworkProtocol",
"@odata.etag": "\"1602826076\"",
"@odata.id": "/redfish/v1/Managers/Self/NetworkProtocol/Oem/Lenovo/PortForwarding",
"@odata.type": "#ManagerNetworkProtocol.v1_4_1.ManagerNetworkProtocol",
"Description": "Port Forwarding Configurations",
"Ipv4": [

{
"Index": "3",
"ServiceEnable": "Disable"
},

]

}
ServiceEnable: Enable Case
{
"@odata.context": "/redfish/v1/$metadata#ManagerNetworkProtocol.ManagerNetworkProtocol",
"@odata.etag": "\"1602826076\"",
"@odata.id": "/redfish/v1/Managers/Self/NetworkProtocol/Oem/Lenovo/PortForwarding",
"@odata.type": "#ManagerNetworkProtocol.v1_4_1.ManagerNetworkProtocol",
"Description": "Port Forwarding Configurations",
"Ipv4": [

{
"Address": "169.254.0.18",
"DestinationHostPort": 6990,
"Index": "3",
"Protocol": "TCP",
"Protocol@Redfish.AllowableValues": [
"TCP",
"UDP"
],
"ServiceEnable": "Enable",
"ServiceEnable@Redfish.AllowableValues": [
"Enable",
"Disable"
], …
]

}

Request

PATCH Port Forwarding settings

PATCH https://{{ip}}/redfish/v1/Managers/Self/NetworkProtocol/Oem/Lenovo/PortForwarding
Content-Type: application/json
Example for patch body
{
"Ipv4": [
{
"Address": "169.254.0.18",
"DestinationHostPort": 8080,
"Index": 3,
"Protocol": "TCP",
"ServiceEnable": "Enable",
"SourcePort": 8080
}
]
}

Response

The response content is 204 with no body.