• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

How safe is NodeJs for public websites/applications ?

Newbie Spellweaver
Joined
Dec 4, 2009
Messages
73
Reaction score
4
So, I was wondering how safe would be NodeJs for my web application as I am willing to use it with Socket.io and node-mysql. How safe would it be vs javascript injections and from not letting people browsing my server source files?

Thanks...
 
Elite Diviner
Joined
May 30, 2011
Messages
443
Reaction score
95
So, I was wondering how safe would be NodeJs for my web application as I am willing to use it with Socket.io and node-mysql. How safe would it be vs javascript injections and from not letting people browsing my server source files?

Thanks...

Node.js is as safe as its users are competent. It runs on top of V8, so there's no obvious exploits.
 
Joined
Jun 8, 2007
Messages
1,985
Reaction score
490
mysql isn't very good for a non-blocking server. Node is a great tool. There are a fair amount of frameworks/modules and we're starting to see more and more node.js applications. As far as security goes, you're on your own. Building the server, implementing security, and protecting your server's code is up to you. If you tell Node.JS to serve your entire file-system and allow people to upload files everywhere, then you get what you expect- everyone can mess up your server. If you download node.js, you just get a language to code in and the node tools- not a web server with any possible security risks.

You also need to think about things like finding a good framework that implements HTTP standards correctly. Or if you'd rather read the fine print, do it yourself. With that said, be sure to research security in the frameworks you choose. I'm sure somebody implemented something badly, but I couldn't tell you which of the 1000s of modules is secure and which isn't. I believe the NPM repository is said to be clear of malware, I don't think integrity is a guarantee though.
 
Last edited:
Back
Top