Is it possible to run node script from a web page as differnt user?

Posted by Blame on Stack Overflow See other posts from Stack Overflow or by Blame
Published on 2013-10-30T15:50:55Z Indexed on 2013/10/30 15:53 UTC
Read the original article Hit count: 177

Filed under:
|
|

I'am searching for days now but could not get an answer. I would like to do the following:

  1. User connects to editor.html (Apache2 with basic http auth)
  2. User want to open a file on the server with his user/pass (same as in passwd)
  3. Node.js Script gets startet with user rights from above and user can edit file

The Node Script will handly the connection via websockets and read/writes files.

I think the biggest problem is that its not possible to run a node script on the server from a web page... and I don´t want to involve any php/cgi scripts... only Apache and Node.js / JS.

Please also comment or answer if you know that it is really not possible...

Thanks!

Kodak

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about node.js