Zdenek Styblik
2013-03-29 20:07:28 UTC
Hello all,
there is a bug in 'lib/ipmi_user.c', resp. # ipmitool user set priv
<user_id> <priv_level> <channel>; which turns off Link
Authorization(details are in the ticket). Originally, it was proposed
to extend 'set priv' for '[link_auth]' parameter, however I find it to
be pointless since this already is covered by 'channel' sub-command.
Then I thought it could be solved by querying BMC for user access and
re-use this information. But I've noticed IPMI specification allows to
disable changes to link/ipmi/callback in Set User Access Command,
p.320 IPMIv2.0 PDF, by setting the 7th bit to 0. However, by doing OR
0x90h this bit is set to 1(I guess because we want to turn on IPMI
messaging).
Now, the question and proposed fix. What I don't understand is why
ipmi_user_set_userpriv() implicitly sets IPMI messaging on since this
is, again, covered by 'channel' sub-command. Is there a reason to do
so? Because I see none.
Anyway, the fix is either to:
~~~
- msg_data[0] |= 0x90; /* enable ipmi messaging */
~~~
or query BMC for user access info and re-use it all the way. I think
the latter is stupid since changes to link/ipmi/callback are 1]
available via 'channel' sub-command 2] changes to link/ipmi/callback
can be ignored by BMC just fine.
Thanks,
Z.
there is a bug in 'lib/ipmi_user.c', resp. # ipmitool user set priv
<user_id> <priv_level> <channel>; which turns off Link
Authorization(details are in the ticket). Originally, it was proposed
to extend 'set priv' for '[link_auth]' parameter, however I find it to
be pointless since this already is covered by 'channel' sub-command.
Then I thought it could be solved by querying BMC for user access and
re-use this information. But I've noticed IPMI specification allows to
disable changes to link/ipmi/callback in Set User Access Command,
p.320 IPMIv2.0 PDF, by setting the 7th bit to 0. However, by doing OR
0x90h this bit is set to 1(I guess because we want to turn on IPMI
messaging).
Now, the question and proposed fix. What I don't understand is why
ipmi_user_set_userpriv() implicitly sets IPMI messaging on since this
is, again, covered by 'channel' sub-command. Is there a reason to do
so? Because I see none.
Anyway, the fix is either to:
~~~
- msg_data[0] |= 0x90; /* enable ipmi messaging */
~~~
or query BMC for user access info and re-use it all the way. I think
the latter is stupid since changes to link/ipmi/callback are 1]
available via 'channel' sub-command 2] changes to link/ipmi/callback
can be ignored by BMC just fine.
Thanks,
Z.