Commit d3a465fd authored by Claes Sjofors's avatar Claes Sjofors

Attribute flag DevHideValue added for password attriubtes

parent 755a618a
......@@ -321,6 +321,16 @@ SObject pwrs:Type
Attr Value = 16777216
EndBody
EndObject
!/**
! The attribute value is hidden in the configurator.
!*/
Object DevHideValue $Bit
Body SysBody
Attr PgmName = "DevHideValue"
Attr Text = "DevHideValue"
Attr Value = 33554432
EndBody
EndObject
EndObject
EndSObject
......
......@@ -146,9 +146,11 @@ int WAttNav::check_attr( int *multiline, brow_tObject *node,
else
sts = item->get_value( (char **)&p);
wnav_attrvalue_to_string( ldhses, item->type_id, p, init_value,
if ( !(item->flags & PWR_MASK_DEVHIDEVALUE)) {
wnav_attrvalue_to_string( ldhses, item->type_id, p, init_value,
&len);
free( p);
free( p);
}
*size = cdh_TypeToMaxStrSize( (pwr_eType)item->type_id, item->size, 1);
if ( item->type_id == pwr_eType_Text)
......
......@@ -330,6 +330,7 @@ static wbl_sSym attr_flags[] =
,{ "PWR_MASK_ALWAYSWBL", PWR_MASK_ALWAYSWBL }
,{ "PWR_MASK_DISABLEATTR", PWR_MASK_DISABLEATTR }
,{ "PWR_MASK_RTHIDE", PWR_MASK_RTHIDE }
,{ "PWR_MASK_DEVHIDEVALUE", PWR_MASK_DEVHIDEVALUE }
,{ "pwr_mClassDef_DevOnly", pwr_mClassDef_DevOnly }
,{ "pwr_mClassDef_System", pwr_mClassDef_System }
......
......@@ -827,11 +827,12 @@ int WNav::check_attr_value( brow_tObject node, int *multiline,
if ( item->flags & PWR_MASK_STATE && !gbl.bypass)
return WNAV__FLAGSTATE;
sts = item->get_value( (char **)&p);
wnav_attrvalue_to_string( ldhses, item->type_id, p, init_value,
if ( !(item->flags & PWR_MASK_DEVHIDEVALUE)) {
sts = item->get_value( (char **)&p);
wnav_attrvalue_to_string( ldhses, item->type_id, p, init_value,
&len);
free( p);
free( p);
}
*size = cdh_TypeToMaxStrSize( (pwr_eType)item->type_id, item->size, 1);
if ( item->type_id == pwr_eType_Text)
......
......@@ -1467,6 +1467,10 @@ int WItemAttr::update()
wnav_attrvalue_to_string( ldhses, type_id, value, &buff, &len);
}
if ( flags & PWR_MASK_DEVHIDEVALUE)
for ( int i = 0; i < len; i++)
buff[i] = '*';
brow_SetAnnotation( node, 1, buff, len);
free( (char *)value);
return WNAV__SUCCESS;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment