Anurag S. Maskey wrote:
> Bump for comments.
>
> Anurag S. Maskey wrote:
>   
>> I am implementing the enforcement of read-only properties and objects in 
>> the library.  So far, I've added a boolean flag (called read_only) in 
>> the handle for ENM, LOC, and NCU.  This flag is set from the "read-only" 
>> property when an object is read in (i.e., selected in nwamcfg terms). 
>>
>> The nwam_ncu_set_prop_value() performs validity checking every time the 
>> value is changed.  It will also check if the object is read-only.  I 
>> propose adding "flags" to this function so that the read-only 
>> enforcement can be overwritten (as in nwam_*_commit() and 
>> nwam_*_destroy() functions with the NWAM_FLAG_OKAY_TO_WRITE).  Also, add 
>> flags to create and delete so that the read-only property can be 
>> overwritten.
>>
>> The reason for this is to allow nwamd to create NCU's and change 
>> properties of the read-only NCU's.
>>
>> Also, the library should not allow properties of read-only objects to be 
>> set, and then later reject a commit for those changes.  We already check 
>> validity of values and reject setting invalid values.
>>
>> By extension, the flags would be added to the respective enm, loc, and 
>> wlan functions also.  (BTW, should nwamd be able to override the 
>> read-only property of these objects?)
>>
>> Comments?
>> Thanks,
>> Anurag
>>
>>     
This all feels quite complex to me. If I remember
correctly, the issue is that as a matter of policy we
wish to preclude the UIs (nwamcfg and the GUI) from
changing to the automatic NCP. My argument was
that although we could potentially solve this policy
issue in one place (in the library), that it might instead
make sense to have logic in both nwamcfg and the
GUI to preclude this (e.g. "if  NCP == automatic setprop
should fail", or "if NCP == automatic gray out text").
I understand that architecturally it seems better to solve
this in one place - the library - but given that there's only
one object (the automatic NCP) that we want to make
read-only, the approach of changing the library like this
seems like a lot of work. It also feels a bit confusing having
a readonly property that we sometimes ignore with
an OKAY_TO_WRITE property, at least to me. Thanks!

Alan
>>
>> _______________________________________________
>> nwam-dev mailing list
>> nwam-dev at opensolaris.org
>> http://mail.opensolaris.org/mailman/listinfo/nwam-dev
>>   
>>     
> _______________________________________________
> nwam-dev mailing list
> nwam-dev at opensolaris.org
> http://mail.opensolaris.org/mailman/listinfo/nwam-dev
>   


Reply via email to