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.
This commit is contained in:
Zdenek Styblik
2014-12-20 13:57:06 +01:00
parent befb21497f
commit 6e6a04f971
3 changed files with 21 additions and 1 deletions

View File

@@ -86,6 +86,7 @@ int str2uchar(const char * str, uint8_t * uchr_ptr);
int is_fru_id(const char *argv_ptr, uint8_t *fru_id_ptr);
int is_ipmi_channel_num(const char *argv_ptr, uint8_t *channel_ptr);
int is_ipmi_user_id(const char *argv_ptr, uint8_t *ipmi_uid_ptr);
int is_ipmi_user_priv_limit(uint8_t priv_limit);
uint16_t str2val(const char * str, const struct valstr * vs);
void print_valstr(const struct valstr * vs, const char * title, int loglevel);