Add option to disable password expiration
This commit is contained in:
parent
7c16d13f65
commit
cda5aee714
2 changed files with 12 additions and 0 deletions
|
|
@ -43,6 +43,7 @@ BASE_MENUS = {
|
||||||
),
|
),
|
||||||
'Configure System': (
|
'Configure System': (
|
||||||
MenuEntry('Open Shell', 'auto_config_open_shell'),
|
MenuEntry('Open Shell', 'auto_config_open_shell'),
|
||||||
|
MenuEntry('Disable Password Expiration', 'auto_disable_password_expiration'),
|
||||||
MenuEntry('Enable BSoD MiniDumps', 'auto_enable_bsod_minidumps'),
|
MenuEntry('Enable BSoD MiniDumps', 'auto_enable_bsod_minidumps'),
|
||||||
MenuEntry('Enable RegBack', 'auto_enable_regback'),
|
MenuEntry('Enable RegBack', 'auto_enable_regback'),
|
||||||
MenuEntry('Enable System Restore', 'auto_system_restore_enable'),
|
MenuEntry('Enable System Restore', 'auto_system_restore_enable'),
|
||||||
|
|
|
||||||
|
|
@ -426,6 +426,11 @@ def auto_config_open_shell() -> None:
|
||||||
TRY_PRINT.run('Open Shell...', config_open_shell)
|
TRY_PRINT.run('Open Shell...', config_open_shell)
|
||||||
|
|
||||||
|
|
||||||
|
def auto_disable_password_expiration() -> None:
|
||||||
|
"""Disable password expiration for all users."""
|
||||||
|
TRY_PRINT.run('Disable password expiration...', disable_password_expiration)
|
||||||
|
|
||||||
|
|
||||||
def auto_export_aida64_report() -> None:
|
def auto_export_aida64_report() -> None:
|
||||||
"""Export AIDA64 reports."""
|
"""Export AIDA64 reports."""
|
||||||
TRY_PRINT.run('AIDA64 Report...', export_aida64_report)
|
TRY_PRINT.run('AIDA64 Report...', export_aida64_report)
|
||||||
|
|
@ -620,6 +625,12 @@ def disable_chrome_notifications() -> None:
|
||||||
pref_file.write_text(json.dumps(pref_data, separators=(',', ':')))
|
pref_file.write_text(json.dumps(pref_data, separators=(',', ':')))
|
||||||
|
|
||||||
|
|
||||||
|
def disable_password_expiration() -> None:
|
||||||
|
"""Disable password expiration for all users."""
|
||||||
|
cmd = ['wmic', 'UserAccount', 'set', 'PasswordExpires=False']
|
||||||
|
run_program(cmd)
|
||||||
|
|
||||||
|
|
||||||
def enable_bsod_minidumps() -> None:
|
def enable_bsod_minidumps() -> None:
|
||||||
"""Enable saving minidumps during BSoDs."""
|
"""Enable saving minidumps during BSoDs."""
|
||||||
cmd = ['wmic', 'RECOVEROS', 'set', 'DebugInfoType', '=', '3']
|
cmd = ['wmic', 'RECOVEROS', 'set', 'DebugInfoType', '=', '3']
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue