coreybutler / node-windows

Windows support for Node.JS scripts (daemons, eventlog, UAC, etc).
Other
2.83k stars 356 forks source link

feat: allow empty password in logOnAs #236

Closed r1b closed 4 years ago

r1b commented 5 years ago

If you try to use an empty password in logOnAs (e.g: with Local Service) node-windows does not create a serviceaccount entry because password is falsy. This change defaults any missing credentials to the winsw default (NT AUTHORITY\LocalSystem).

It may be better to express this like if any of [domain,account,password] missing in logOnAs use the default credentials object so no one is surprised by a default in isolation.