json web token based authentication server & easy authentication javascript sdk.
- Node.js 6โ
- Mongodb 3.4โ
- git
git clone https://github.com/ahribori/jwt_auth_server.git
cd jwt_auth_server
npm install
create file _config.yml into project root.
# Server Configuration
server:
# Server Port -> ex) 8080
port:
# MongoDB URI -> ex) mongodb://localhost:27017/jwt_auth
mongo_uri:
# Secret Key -> ex) MySeCrEtKey!2#4%6&8(0
secret:
token:
# JWT token expires -> ex) 1d or 3h or 20m...
expiresIn:
# JWT token issuer -> ex) your company or nickname
issuer:
# Client configuration
client:
# SDK configuration
sdk:
# Auth SDK global object name (not required)
global_name:
# your jwt auth server origin -> ex) https://account.yourJwtAuthServerDomain.com
server_origin:
require configuration first
npm run build
require build first
npm run boot