From d902aa7b4f98b49d2a20ad8253bc15afd77e9349 Mon Sep 17 00:00:00 2001 From: Sandeepa Singh Date: Tue, 1 Feb 2022 18:54:33 +0530 Subject: Filtered the IP address to IPv4 on sessions page The IP address on sessions page is comming IPv6. It should be shown IPv4 address. Signed-off-by: Sandeepa Singh Change-Id: I4d5d492b161c09a09f616849ad9d0e6eb32e9fd8 --- src/store/modules/SecurityAndAccess/SessionsStore.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/store/modules/SecurityAndAccess/SessionsStore.js') diff --git a/src/store/modules/SecurityAndAccess/SessionsStore.js b/src/store/modules/SecurityAndAccess/SessionsStore.js index 54607ab6..37ba9fc2 100644 --- a/src/store/modules/SecurityAndAccess/SessionsStore.js +++ b/src/store/modules/SecurityAndAccess/SessionsStore.js @@ -25,10 +25,14 @@ const SessionsStore = { ) .then((sessionUris) => { const allConnectionsData = sessionUris.map((sessionUri) => { + //For filtering IP address to IPv4 + let filteredIPAddress = sessionUri.data?.ClientOriginIPAddress.slice( + 7 + ); return { clientID: sessionUri.data?.Oem?.OpenBMC.ClientID, username: sessionUri.data?.UserName, - ipAddress: sessionUri.data?.ClientOriginIPAddress, + ipAddress: filteredIPAddress, uri: sessionUri.data['@odata.id'], }; }); -- cgit v1.2.3