Giter VIP home page Giter VIP logo

Comments (8)

arthurblake avatar arthurblake commented on May 26, 2024

I wouldn't mind writing a patch to add this feature, but your latest update on 11/10/13 implied a big code overhaul (that was never checked in)... Any status update on that?

from node-windows.

coreybutler avatar coreybutler commented on May 26, 2024

I might add the ability to run as another user in the next version. The
trick at the moment is making it work across all operating systems. See the
daemon manager module for the work in progress.

There's nothing that can be done about a plain text password. Munging after
the fact will simply render the process invalid on a restart. So I had no
plans to add that.

Generally speaking, there are a lot of changes that have been made for a
new version. No ETA at the moment.
On Jan 27, 2014 8:56 AM, "Arthur Blake" [email protected] wrote:

Thanks for this elegant module. One thing that threw me while reading the
doc is the user attribute. I assumed it was transferred over to the service
logon information on the installed service, but it's not. Instead it's just
the user account used to run the service setup command.

That being said, having the ability to programattically specify the
service logon credentials is something I really need. Why not create
another set of credentials in the config for that? It looks like it would
be a quite simple modification, given that winsw supports this (under the
xml attribute.)

One potential security issue is that the user account and password are
placed in clear text in the xml file, so if this is done perhaps there
would be a post install hook that munges the password in xml?

(P.S. Also, this is minor, but would be great if generateXml created xml
that was formatted nicely for readability.)


Reply to this email directly or view it on GitHubhttps://github.com//issues/39
.

from node-windows.

arthurblake avatar arthurblake commented on May 26, 2024

It should be fine because that part of the xml is only used on the install and uninstall. So it would only mess up a reinstall if you did the reinstall directly with winsw (bypassing node-windows), but since node-windows regenerates the xml each time it should work just fine. I'll play with it and confirm that -- I'm going to have to fork anyway because I need this for production asap. I don't really care about the other OS's - but I understand that's a factor.

from node-windows.

arthurblake avatar arthurblake commented on May 26, 2024

Would you recommend I make my changes forking from daemon-manager or node-windows? Which do you consider more stable?

from node-windows.

arthurblake avatar arthurblake commented on May 26, 2024

Looks like daemon-manager is not in a usable state as of last checkin. Feel free to throw me a bone :)

from node-windows.

coreybutler avatar coreybutler commented on May 26, 2024

Given the urgency of your need, I'd suggest forking node-windows and
keeping an eye on the project for future releases.
On Jan 28, 2014 9:21 AM, "Arthur Blake" [email protected] wrote:

Looks like daemon-manager is not in a usable state as of last checkin.
Feel free to throw me a bone :)


Reply to this email directly or view it on GitHubhttps://github.com//issues/39#issuecomment-33487711
.

from node-windows.

arthurblake avatar arthurblake commented on May 26, 2024

FWIW, all of this except for the extra password security part is now implemented and working at https://github.com/arthurblake/node-windows

I discovered a much better way to do the password security part; the latest release of winsw (1.14) allows for a new option, /p. When this is used, winsw will prompt for the user name and password to use for the service credentials directly.

I have not implemented that part yet because node-windows has many ways to run the winsw process (privileged, sudo, etc.) and none of them currently allow for passing information into the child process on stdin.

But conceptually it should not be hard to allow for that.

The /p feature is not documented in WINSW but there is more info about it here:
winsw/winsw#19

I opened an issue request to have that documented.
winsw/winsw#30

from node-windows.

vsspt avatar vsspt commented on May 26, 2024

I'm having the following error when using the /p feature:
`C:\Program Files\WinSW>winsw.exe install /p
2017-07-19 14:34:40,896 INFO - Starting ServiceWrapper in the CLI mode
Username: admin
Password: **********
Set Account rights to allow log on as a service (y/n)?: y
2017-07-19 14:34:49,567 FATAL - WMI Operation failure: StatusInvalidServiceAccount
WMI.WmiException: StatusInvalidServiceAccount
at WMI.WmiRoot.BaseHandler.CheckError(ManagementBaseObject result)
at WMI.WmiRoot.ClassHandler.Invoke(Object proxy, MethodInfo method, Object[] args)
at WMI.Win32ServicesProxy.Create(String , String , String , ServiceType , ErrorControl , StartMode , Boolean , String , String , String[]
)
at winsw.WrapperService.Run(String[] _args, ServiceDescriptor descriptor)
at winsw.WrapperService.Main(String[] args)
WMI.WmiException: StatusInvalidServiceAccount
at WMI.WmiRoot.BaseHandler.CheckError(ManagementBaseObject result)
at WMI.WmiRoot.ClassHandler.Invoke(Object proxy, MethodInfo method, Object[] args)
at WMI.Win32ServicesProxy.Create(String , String , String , ServiceType , ErrorControl , StartMode , Boolean , String , String , String[]
)
at winsw.WrapperService.Run(String[] _args, ServiceDescriptor descriptor)
at winsw.WrapperService.Main(String[] args)

C:\Program Files\WinSW>`

I'm using the WinSW 2.1.0.0 version.

from node-windows.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.