NodeJs Ez Accounts (JavaScript)

ezaccounts

User account management system inNodeJs made easy.
EzAccounts provides a starter NodeJs server that allows you to build your own sites.

Many sites need the ability to have users create accounts, log in, log out, change their password, etc.
When building your own sites, you need to code all that stuff,
quite often, before you can get to the meat of what your site actually does.
And it is cumbersome too.

… Well, not any more!
With EzAccounts, it is plug and play.
You do not need to worry about writing the code that deals with user accounts.
Simply use the starter server, which has all that baked in,
and start coding the main stuff on your site!

Features

  • Token based authentication
  • Sign Up for Accouunt
    • Sends email to user, with activation instructions
  • Activate Account
    • Sends email to user confirming that account is active
  • Change Password for Account
  • Log In to Account
  • Log Out of Account
  • All based on JSON APIs
    • GET API URLs or POST JSON to API URLs
    • Response in JSON
    • No need for web pages
    • Ideal for single page applications
    • Ideal for native apps
  • Uses MongoDB
  • Easy configuration
  • Descriptive comments that document exactly what is happening

Installation

First, install some prerequisites:

Next, in the folder where you have this module installed, run:

npm install

Usage

Configure the app.

cp config-settings.js.template config-settings.js

Then edit config-settings.js, to customise it for your site.

Next, you will need to obtain SSL certificates in order to run your site over HTTPS.
To do this, you will need to use openssl commands in the terminal,
or purchase them from a certificate authority.
Note that when users visit HTTPS sites using self-signed SSL certificates,
warning messages will be displayed in the browser.

To create self-signed certificates:

openssl genrsa -out private-key.pem 1024
openssl req -new -key private-key.pem -out certificate-request.csr
#This command is interactive, you will be prompted for various details about the owner of the certificate
openssl x509 -req -in certificate-request.csr -signkey private-key.pem -out public-key.pem

If you do not wish to do this,
you can serve your site over HTTP instead.
While this is OK for development purposes,
you certainly should not be doing this in production.
To do this edit config-settings.js and set config.server.https to false.

Now run the server.

node start

Lastly, visit http://0.0.0.0:3000/ in your browser,
and you should be prompted with the main page, where you can shorten your first URL.

Issues/ Requests

Please let me know in the Comments section for this item.

Licence

This module is available dual licenced under

As such, this module is not available from the npm registry.
Instead of npm installing this, you must copy the folder to the appropriate location.

Please purchase the regular licence if you wish to use this in a single application for a single client,
and purchase the extended licence if you wish to use this in multiple applications or for multiple clients.
Read the full details of the licences from the pages above.

Author

Brendan Graetz

 

Download NodeJs Ez Accounts (JavaScript)

Leave a Reply

Your email address will not be published. Required fields are marked *