octoblu / meshblu

Meshblu is a cross-protocol IoT machine-to-machine messaging system.
https://meshblu.readme.io/
MIT License
815 stars 182 forks source link

config.token or environment variable TOKEN is required. Exiting. #133

Closed 198700 closed 8 years ago

198700 commented 8 years ago

Hello Team, When i am running "node server.js --http" command , we get " config.token or environment variable TOKEN is required. Exiting. " message. what is the problem . plz provide me some helping links that contains details steps.

Thank's & Regards Pankaj

royvandewater commented 8 years ago

We have an explanation of what the TOKEN does in the README, but it's not in an logical place :-(

https://github.com/octoblu/meshblu#docker

A note about secrets: We require that whomever runs Meshblu to supply a text secret, in the form of the TOKEN environmnet variable, that we can use as a salt when hashing tokens. Not knowing this secret hinders a malicious user when creating a rainbow table to reverse the hashed tokens.

If you are running on Linux/OSX, then the command env TOKEN="<any random string>" node server.js --http should work. Just make sure that whatever random string you use is the same every time, or the device tokens will not be recognized as valid in Meshblu.