This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| app-notes:changing-password [2026/09/01 12:49] – [3. Additional information] gray | app-notes:changing-password [2026/09/08 12:57] (current) – [3. Additional information] gray | ||
|---|---|---|---|
| Line 315: | Line 315: | ||
| | | ||
| } | } | ||
| + | # Store password unencrypted | ||
| + | | ||
| + | save = nb_config_get(store_password); | ||
| + | | ||
| + | | ||
| + | | ||
| + | ret = nb_config_done(); | ||
| + | while (ret){ | ||
| + | printf(" | ||
| + | ret = nb_config_done(); | ||
| + | sleep(1); | ||
| + | } | ||
| + | } | ||
| | | ||
| | | ||
| Line 320: | Line 333: | ||
| daten = ''; | daten = ''; | ||
| | | ||
| + | | ||
| } | } | ||
| | | ||
| Line 596: | Line 610: | ||
| | | ||
| } | } | ||
| + | # Store password unencrypted | ||
| + | | ||
| + | save = nb_config_get(store_password); | ||
| + | | ||
| + | | ||
| + | | ||
| + | ret = nb_config_done(); | ||
| + | while (ret){ | ||
| + | printf(" | ||
| + | ret = nb_config_done(); | ||
| + | sleep(1); | ||
| + | } | ||
| + | } | ||
| | | ||
| | | ||
| Line 601: | Line 628: | ||
| daten = ''; | daten = ''; | ||
| | | ||
| + | | ||
| } | } | ||
| | | ||
| Line 607: | Line 635: | ||
| </ | </ | ||
| ++++ | ++++ | ||
| + | |||
| + | If you want to automatically reset passwords to a fixed default password, you can use these two scripts. | ||
| The script resets the stored user passwords to a default password every month. | The script resets the stored user passwords to a default password every month. | ||
| Line 683: | Line 713: | ||
| for (i = 0; i < 20; i++){ | for (i = 0; i < 20; i++){ | ||
| user_temp = nb_config_get(sprintf(" | user_temp = nb_config_get(sprintf(" | ||
| - | if(user_temp != '' | + | |
| + | if(user_temp != '' | ||
| + | // who has been added to the system. | ||
| + | // If you want to reset only a specific user, | ||
| + | // you can do so by making this change | ||
| + | // if(user_temp == “< | ||
| daten = sprintf(" | daten = sprintf(" | ||
| | | ||
| Line 689: | Line 725: | ||
| while (ret){ | while (ret){ | ||
| printf(" | printf(" | ||
| + | ret = nb_config_done(); | ||
| + | sleep(1); | ||
| + | } | ||
| + | } | ||
| + | # Store password unencrypted | ||
| + | | ||
| + | save = nb_config_get(store_password); | ||
| + | | ||
| + | | ||
| + | | ||
| + | ret = nb_config_done(); | ||
| + | while (ret){ | ||
| + | printf(" | ||
| ret = nb_config_done(); | ret = nb_config_done(); | ||
| sleep(1); | sleep(1); | ||
| Line 699: | Line 748: | ||
| daten = ''; | daten = ''; | ||
| password = ''; | password = ''; | ||
| + | store_encrypt = ''; | ||
| } | } | ||
| } | } | ||
| Line 712: | Line 762: | ||
| <code – Set_a_default_password_every_week.are> | <code – Set_a_default_password_every_week.are> | ||
| # The script resets the stored user passwords to a default password every week. | # The script resets the stored user passwords to a default password every week. | ||
| - | |||
| nb_config_set(" | nb_config_set(" | ||
| Line 782: | Line 831: | ||
| for (i = 0; i < 20; i++){ | for (i = 0; i < 20; i++){ | ||
| user_temp = nb_config_get(sprintf(" | user_temp = nb_config_get(sprintf(" | ||
| - | if(user_temp != '' | + | |
| + | if(user_temp != '' | ||
| + | // who has been added to the system. | ||
| + | // If you want to reset only a specific user, | ||
| + | // you can do so by making this change | ||
| + | // if(user_temp == “< | ||
| + | |||
| + | |||
| + | |||
| daten = sprintf(" | daten = sprintf(" | ||
| | | ||
| Line 788: | Line 845: | ||
| while (ret){ | while (ret){ | ||
| printf(" | printf(" | ||
| + | ret = nb_config_done(); | ||
| + | sleep(1); | ||
| + | } | ||
| + | } | ||
| + | # Store password unencrypted | ||
| + | | ||
| + | save = nb_config_get(store_password); | ||
| + | | ||
| + | | ||
| + | | ||
| + | ret = nb_config_done(); | ||
| + | while (ret){ | ||
| + | printf(" | ||
| ret = nb_config_done(); | ret = nb_config_done(); | ||
| sleep(1); | sleep(1); | ||
| Line 798: | Line 868: | ||
| daten = ''; | daten = ''; | ||
| password = ''; | password = ''; | ||
| + | store_encrypt = ''; | ||
| } | } | ||
| } | } | ||