Zdenek Styblik
af276d4082
Fix out-of-bound-reads in get_supermicro_evt_desc()
...
CID#1149029 and CID#1149030
2015-01-08 20:22:15 +01:00
Zdenek Styblik
e4be291c65
Re-work 'channel getaccess' and 'channel setaccess'
...
Commit is a re-work of 'channel getaccess' and 'channel setaccess'. These are
using _ipmi_* now. Also, bitfields and two structs are replaced by one unified
struct.
2015-01-08 19:45:22 +01:00
Zdenek Styblik
bb35d370ba
Add eval_ccode() into helper
...
Commit adds eval_ccode() into helper in order to save some code repetition on
evaluation of retvals from _ipmi_* functions.
2015-01-08 19:43:27 +01:00
Zdenek Styblik
31f9d4c635
Add _ipmi_get_user_access() and _ipmi_set_user_access()
...
Commit adds reusable functions _ipmi_get_user_access() and
_ipmi_set_user_access().
2015-01-08 16:44:18 +01:00
Zdenek Styblik
6d1afbf3a7
Add _ipmi_get_user_name()
...
Commit adds function _ipmi_get_user_name() which does nothing but fetches User
Name as per 22.29. There are no print-outs when the called.
2015-01-08 16:13:51 +01:00
Zdenek Styblik
d9acbc4cd0
ID:358 - check data length in else branch of ipmi_spd_print()
...
Commit adds data length check into '} else {' branch of ipmi_spd_print() in
order to avoid out-of-bound access.
2015-01-04 14:58:37 +01:00
Jim Mankovich
9811f79eae
ID:357 - out-of-bound access in DDR4 code
...
ID:356 - DIMM4 Die Count is unreachable
2015-01-01 09:16:34 -07:00
Zdenek Styblik
2d66f8d5cf
Change expression in ipmi_pef_list_policies() in order to silence Coverity
2014-12-31 12:23:56 +01:00
Zdenek Styblik
8775af38f5
Remove dead code - rsp can't be NULL at this point - CID#1149005
2014-12-31 05:53:24 +01:00
Zdenek Styblik
9fc4a39fda
Remove dead(duplicate) code from ipmi_sol_main() - CID#1148996
2014-12-31 05:47:00 +01:00
Zdenek Styblik
a6957f875c
Delete dead code from ipmi_sunoem_echo() - CID#1261338
...
Commit removes a dead code from ipmi_sunoem_echo(). Code didn't make any sense
in given context.
2014-12-30 20:12:11 +01:00
Zdenek Styblik
4ef4618366
Remove commented-out code in ipmi_picmg_clk_set() - CID#1261339
...
Originally ``Printf arg type mismatch''.
2014-12-30 20:07:12 +01:00
Zdenek Styblik
8ac8361aca
Fix Identical code for different branches in ipmi_tsol_main() - CID#1261346
...
Commit adds error message and retval (-1) for an invalid tsol command/parameter.
2014-12-30 20:00:56 +01:00
Zdenek Styblik
fb69b5dc9e
Fix Assign instead of compare in KfwumGetDeviceInfo() - CID#1149034
2014-12-30 18:20:34 +01:00
Zdenek Styblik
c2e65d0dce
Fix dead code in ipmi_firewall_reset() - CID#1261342
2014-12-30 17:40:07 +01:00
Zdenek Styblik
12eeca602c
Fix missing return in ipmi_kontronoem_main() - CID#1261317
2014-12-30 17:20:49 +01:00
Zdenek Styblik
c076fde0a6
Fix file descriptor leak in ipmi_exec_main() - CID#1149040
2014-12-30 16:21:52 +01:00
Zdenek Styblik
ecfaeb2706
Change expression in ipmi_pef_get_info() in order to silence Coverity
...
Commit changes expression from ``if (!ptbl)'' to ``if (ptbl != NULL)'' in order
to silence Coverity. CID#1149049
2014-12-30 16:02:21 +01:00
Zdenek Styblik
61db4df637
Fix memory leak in ipmi_ek_display_board_info_area() - CID#1149051
2014-12-30 15:51:49 +01:00
Zdenek Styblik
e37e3ab7de
Fix memory leak in get_supermicro_evt_desc()
...
Commit fixes memory leak in get_supermicro_evt_desc() - CID#1149050
2014-12-30 15:43:55 +01:00
Zdenek Styblik
c97dbd3461
Fix eval logic in ipmi_user_priv()
...
Commit fixes bug in eval logic of user input sanitization, resp. && -> ||. Also,
priv_level and user_id variables are initialized to 0 now(CID#1261318).
2014-12-30 15:33:05 +01:00
Zdenek Styblik
48117f5ddf
ID:355 - Fix ``ISO C forbids omitting the middle term of a ?: expression''
...
Commit fixes omitted middle terms of ternary expressions.
2014-12-30 08:00:23 +01:00
Zdenek Styblik
70984dcad5
ID:355 - Fix ``obsolete use of designated initializer with ‘:’'' warning
...
Commit fixes compiler warning ``obsolete use of designated initializer with
‘:’''. Use of ``fieldname: value'' has been obsolete since GCC 2.5.
2014-12-29 09:33:22 +01:00
Zdenek Styblik
ce02ffaf2a
ID:354 - forcefully switch to C99 and more strict CFLAGS
...
Commit changes CFLAGS which include C99 and more strict flags. Watch out for
falling rocks.
2014-12-23 14:37:25 +01:00
Zdenek Styblik
3105812a44
ID:354 - struct member h_addr has been replaced
...
Struct member h_addr has been replaced some time ago and kept for backward
compatibility. Let's reflect on this and replace it with h_addr_list[0].
2014-12-23 14:33:29 +01:00
Zdenek Styblik
148d0e0904
ID:354 - uint8_t >= 0 is always true, don't test it
...
Commit removes test whether value is greater or equal to 0 in
is_ipmi_channel_num(), because it's always true(and it makes compiler mad).
2014-12-23 14:22:00 +01:00
Zdenek Styblik
6ca88cb687
ID:354 - replace/drop caddr_t in IMB
...
Commit replaces caddr_t in IMB driver with char *. This is a wild guess
replacement, because caddr_t doesn't have to be char *. However, it shouldn't be
used and so shouldn't mmap(). So we'll have to see how things work out.
http://computer-programming-forum.com/47-c-language/556a90938d01f023.htm
2014-12-23 14:10:34 +01:00
Zdenek Styblik
6d4e2bb632
ID:354 - Replace obsolete u_int[0-9]+_t with standardized types in Free iface
2014-12-23 12:29:07 +01:00
Zdenek Styblik
104a7176ac
ID:354 - Replace obsolete u_int with uint32_t in dimm_spd.c
2014-12-23 12:21:11 +01:00
Zdenek Styblik
d9f89a8da0
Fix of previous commit - memset() expects pointer
...
Commit fixes replacement of bzero() with memset(). memset() expects pointer and
pointer should be given to it.
2014-12-23 05:56:47 +01:00
Zdenek Styblik
0a1f5c03e5
Replace deprecated bzero() with memset()
...
Commit replaces deprecated bzero() with memset().
2014-12-23 05:46:28 +01:00
Zdenek Styblik
140add9d77
Fix user input validation in Channel and User sub-commands
...
Commit fixes validation of user input in Channel and User sub-commands.
2014-12-22 18:21:51 +01:00
Zdenek Styblik
0562c809af
Cleanup if/else in ipmi_channel_main()
2014-12-22 08:49:58 +01:00
Zdenek Styblik
a87b2ccc67
Cleanup of code formatting in ipmi_channel.c
...
At least a bit.
2014-12-22 07:57:18 +01:00
Zdenek Styblik
ad77da2065
ID:349 - user set password - add option to choose 16/20 byte password
...
Commit adds option to 'user set password' to choose whether password should be
stored as 16 byte or 20 byte. From now on, it's possible to store even 5 bytes
long password as 20 byte password which should make it useless for IPMI v1.5
auth/sessions.
2014-12-20 16:40:55 +01:00
Zdenek Styblik
6e6a04f971
Make user User Privilege Limit is within range
...
Despite the fact we could leave this up to IPMI stack, we won't do that.
Therefore, is_ipmi_user_priv_limit() is added and user provided value checked.
2014-12-20 13:57:06 +01:00
Zdenek Styblik
befb21497f
Create ask_password() and re-use code
...
Commit add function ask_password() which leads to code re-usability and shedding
couple lines of otherwise redundant code.
2014-12-20 13:43:38 +01:00
Zdenek Styblik
1d1ce49bf4
Fix 'user help' output
...
Commit fixes padding of 'user help' output. Also, list of expected values of
privilege leves have been added.
2014-12-19 09:57:49 +01:00
Zdenek Styblik
50bd7d01a8
Don't use tmp variable since it's not necessary in ipmi_user_test()
2014-12-19 08:49:20 +01:00
Zdenek Styblik
4d3decc4c0
Split ipmi_user_main() into smaller functions
...
Commit splits ipmi_user_main() into smaller functions. Hopefully, this will be
better than giant main() function.
2014-12-18 18:40:51 +01:00
Zdenek Styblik
f8ce85ee6c
Clenaup formatting in ipmi_user_main()
2014-12-09 18:59:37 +01:00
Zdenek Styblik
2aa5d8c902
Code cleanup in ipmi_user_main()
...
This is just a tip of an iceberg, really.
2014-12-09 18:59:36 +01:00
Zdenek Styblik
3c34aa0e1d
Cleanup formatting in ipmi_user_main()
2014-12-09 18:59:36 +01:00
Zdenek Styblik
a58a627fae
Remove trailing white-spaces in ipmi_user.c
2014-12-09 18:59:36 +01:00
Zdenek Styblik
aaf98b89d5
ID:348 Add support for the "System Firmware Version"
...
Add support for the "System Firmware Version" parameter selector (1) to the "Get
System Info Parameters" command ("mc getsysinfo system_fw_version"). The "mc
getsysinfo" command was already implemented and supported, but strangely, only
standard parameter selecter values 2, 3, 4 and Dell-defined parameters were
supported; the standard parameter value 1 (system firmare version) was not
supported.
2014-12-05 14:15:02 +01:00
Zdenek Styblik
7cd86aaf1e
ID:347 - Incorrect reserved channel number
...
Fix validation of IPMI channel numbers according to IPMIv2.0 rev1.1 and update
documentation as well.
2014-12-05 13:39:31 +01:00
Zdenek Styblik
dd4cab8153
ID:343 - Remove AC_FUNC_MALLOC
...
Fix cross-compile build error regarding to 'rpl_malloc'.
ipmitool actually does not need the GNU's malloc(0) behavior.
So, remove AC_FUNC_MALLOC from AC-script in order to help
cross-compiling ipmitool without need to directly specify
ac_cv_func_malloc_0_nonnull environment variable.
2014-12-05 13:33:12 +01:00
Zdenek Styblik
d671052143
ID:345 - Do not do several close session retries when catching SIGINT
...
Reduce number of retries to 1 when closing interface on SIGINT.
This reduces time needed to terminate the LAN connection.
2014-11-29 18:06:13 +01:00
Zdenek Styblik
e9c3de03c3
ID:346 - lib/ipmi_sdradd.c ipmi_sdr_read_record has a file descriptor leak
...
'lib/ipmi_sdradd.c' ipmi_sdr_read_records() opens a file descriptor and never
closes it. Here is a patch in use by SGI for quite some time now. Suggested
patch attached.
2014-11-29 17:52:18 +01:00
Zdenek Styblik
1cf65c3236
ID:344 - Fix HPM.2 long message support
...
Due to a typo in the result checking. HPM.2 long message support detection does
not work.
2014-11-29 17:45:41 +01:00