Skip to contentSkip to conversation

Question of ipmi command "Set User Access" in phosphor-host-ipmid

DISCUSSION Tony Lee (李文富) 3 participants 5 messages May 25, 2020 – Jun 1, 2020

lore
Share & tools
lore
#0 lore raw

Hi Richard,

In the process of creating an user,
I used the ipmi command "ipmitool priv <user id> <privilege level> [<channel number>]". The "UserPrivilege" of the user I created in dbus is empty. Because my LAN channel number is not 1.

https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_channel/user_mgmt.cpp#L878

Why did it need to check the request channel number before setting the dbus? I can't find the related restriction of it in "Set User Access Command" in IPMI SPEC.

Thanks
Best Regards,
Tony

#1 lore raw

Hi Tony,

Only IPMI offers channel based user level privilege as of now, Redfish uses single privilege across all channels. OpenBMC user management is designed to have single user level privilege. IPMI is designed to bind one of the channel privilege user to the user management, and rest maintain in it's own database. LAN 1 is used for that sync.

Note: Discussion started in Redfish forum to have a channel based restriction, but it's not yet materialized and requires more takers.

Regards,

Richard

Quoted 12 lines · Tony Lee (李文富)

In the process of creating an user,
I used the ipmi command "ipmitool priv <user id> <privilege level> [<channel number>]". The "UserPrivilege" of the user I created in dbus is empty. Because my LAN channel number is not 1.

https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_channel/user_mgmt.cpp#L878

Why did it need to check the request channel number before setting the dbus? I can't find the related restriction of it in "Set User Access Command" in IPMI SPEC.

Thanks
Best Regards,
Tony

#2 lore raw

Hi Richard,

So, it need to check the request channel number before setting the dbus because it has to be in sync with system user privilege level.

Since my LAN1 and the request channel number are both 2. Once we can get LAN1 channel number dynamically
https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_channel/user_mgmt.cpp#L512

This issue will be solved right?

Quoted 42 lines

From: Thomaiyar, Richard Marian <[email protected]>
Sent: Tuesday, May 26, 2020 12:28 AM
To: Tony Lee (李文富) <[email protected]>
Cc: [email protected]
Subject: Re: Question of ipmi command "Set User Access" in phosphor-host-ipmid

Hi Tony,

Only IPMI offers channel based user level privilege as of now, Redfish uses single privilege across all channels. OpenBMC user management is designed to have single user level privilege. IPMI is designed to bind one of the channel privilege user to the user management, and rest maintain in it's own database. LAN 1 is used for that sync.

Note: Discussion started in Redfish forum to have a channel based restriction, but it's not yet materialized and requires more takers.

Regards,

Richard

Quoted 2 lines · Tony Lee (李文富)

In the process of creating an user,
I used the ipmi command "ipmitool priv <user id> <privilege level>

[<channel number>]".

Quoted 1 line

The "UserPrivilege" of the user I created in dbus is empty. Because my LAN

channel number is not 1.

Quoted 2 lines

https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_chann
e

Quoted 3 lines

l/user_mgmt.cpp#L878

Why did it need to check the request channel number before setting the

dbus?

Quoted 1 line

I can't find the related restriction of it in "Set User Access Command" in IPMI

SPEC.

Quoted 4 lines

Thanks
Best Regards,
Tony

#3 lore raw

Hi Tony,

Yes, that's correct. We already support  channel configuration using json(channel_config.json under phosphor-ipmi-config), and sync channel can be identified by the first LAN medium channel number - else we can add one more configuration as well).

I am ok if you want to go ahead and fix it, else will try to fix the same in couple of weeks.

Regards,

Richard

Quoted 51 lines · Tony Lee (李文富)

Hi Richard,

So, it need to check the request channel number before setting the dbus because it has to be in sync with system user privilege level.

Since my LAN1 and the request channel number are both 2. Once we can get LAN1 channel number dynamically
https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_channel/user_mgmt.cpp#L512

This issue will be solved right?

Quoted 40 lines

From: Thomaiyar, Richard Marian <[email protected]>
Sent: Tuesday, May 26, 2020 12:28 AM
To: Tony Lee (李文富) <[email protected]>
Cc: [email protected]
Subject: Re: Question of ipmi command "Set User Access" in phosphor-host-ipmid

Hi Tony,

Only IPMI offers channel based user level privilege as of now, Redfish uses single privilege across all channels. OpenBMC user management is designed to have single user level privilege. IPMI is designed to bind one of the channel privilege user to the user management, and rest maintain in it's own database. LAN 1 is used for that sync.

Note: Discussion started in Redfish forum to have a channel based restriction, but it's not yet materialized and requires more takers.

Regards,

Richard

Quoted 2 lines · Tony Lee (李文富)

In the process of creating an user,
I used the ipmi command "ipmitool priv <user id> <privilege level>

[<channel number>]".

Quoted 1 line

The "UserPrivilege" of the user I created in dbus is empty. Because my LAN

channel number is not 1.

Quoted 1 line

https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_chann
e

Quoted 3 lines

l/user_mgmt.cpp#L878

Why did it need to check the request channel number before setting the

dbus?

Quoted 1 line

I can't find the related restriction of it in "Set User Access Command" in IPMI

SPEC.

Quoted 3 lines

Thanks
Best Regards,
Tony

#4 lore raw
In reply to Thomaiyar, Richard Marian
Quoted 5 lines · Richard Marian

Hi Tony,

Only IPMI offers channel based user level privilege as of now, Redfish uses single privilege across all channels. OpenBMC user management is designed to have single user level privilege. IPMI is designed to bind one of the channel privilege user to the user management, and rest maintain in it's own database. LAN 1 is used for that sync.

Note: Discussion started in Redfish forum to have a channel based restriction, but it's not yet materialized and requires more takers.

here: https://redfishforum.com/thread/279/channel-privilege-support-direction-redfish

Quoted 19 lines

Regards,

Richard

Quoted 13 lines · Tony Lee (李文富)

In the process of creating an user,
I used the ipmi command "ipmitool priv <user id> <privilege level> [<channel number>]". The "UserPrivilege" of the user I created in dbus is empty. Because my LAN channel number is not 1.

https://github.com/openbmc/phosphor-host-ipmid/blob/master/user_channel/user_mgmt.cpp#L878

Why did it need to check the request channel number before setting the dbus? I can't find the related restriction of it in "Set User Access Command" in IPMI SPEC.

Thanks
Best Regards,
Tony