Implement authentication via client credentials

Implement authentication via client credentials (for resource servers) when running under Node.js
lines below are only indented 1 char. should be 2