Jump to content


Photo

config and enigma2 setttiings file


  • Please log in to reply
4 replies to this topic

#1 mfaraj57

  • Senior Member
  • 1,605 posts

+286
Excellent

Posted 3 October 2019 - 19:48





config.plugins.DreamOSatScript.password = NoSave( ConfigPassword(default='', fixed_size=False, censor='*') ) 

I am writing software using password and the passowrd saved through config system

 but i do not want the passowrd to be save to etc/enigma2/settings file.

is there way to do this?



Re: config and enigma2 setttiings file #2 littlesat

  • PLi® Core member
  • 56,268 posts

+691
Excellent

Posted 3 October 2019 - 21:35

Look like eg fallbacktuner checks the password on a remote server...

WaveFrontier 28.2E | 23.5E | 19.2E | 16E | 13E | 10/9E | 7E | 5E | 1W | 4/5W | 15W


Re: config and enigma2 setttiings file #3 mfaraj57

  • Senior Member
  • 1,605 posts

+286
Excellent

Posted 3 October 2019 - 21:40

forget about the 

config.plugins.DreamOSatScript.password = NoSave( ConfigPassword(default='', fixed_size=False, censor='*') )

i copy it just to demonstrate the question.

i care about config NoSave function to do the jop ,but seems no effect.


Edited by mfaraj57, 3 October 2019 - 21:41.


Re: config and enigma2 setttiings file #4 mfaraj57

  • Senior Member
  • 1,605 posts

+286
Excellent

Posted 4 October 2019 - 09:17

Because of lack of documentation about enigma2 config system i did some investigations regarding config values and i got these points which many of you know them but many also do not know so sharing  here.

-Only config values changed from defaults saved to etc/enigma2/settings file

example

config.Myplugin.downloadLocation = ConfigText(default='/media/hdd', fixed_size=False)



if config.Myplugin.downloadLocation kept as default /media/hdd will not be saved to settings file but if changed to  /media/usb will be saved to settings file

-if you do not want to your changed config value not saved to enigma2 settings file,config NoSave function should  be used as for passwords value

but using NoSave in definition of config value has no effect but should be used properly in plugin setup screen

 

 

NoSave will have no effect and the value will be saved to setting file if changed from default

config.Myplugin.downloadLocation = NoSave(ConfigText(default='/media/hdd', fixed_size=False)) 

while usage like the following the value will not be  saved to settings file.

in plugin setup screen NoSave used like this

self.list.append(getConfigListEntry(_('Download location,press ok to change'), NoSave(config.Myplugin.downloadlocation)))
 

The question now when to use NoSave.

in case of values need security like passwords,usernames.

also good routine to use it when expected the config value will be changed from default to avoid writing extra lines to settings file

 

 



Re: config and enigma2 setttiings file #5 mfaraj57

  • Senior Member
  • 1,605 posts

+286
Excellent

Posted 8 October 2019 - 06:19

Nosave config function only keep the saved password for current open enigma session and not recorded to etc/enigma2/settinsg file but the saved password will be cleared by restart enigma

now the question still the same

how prevent password saved by enigma2 config system from writtten to etc/enigma2/settings file?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users