bimedia-rest-security

2.1.0 • Public • Published

bimedia-rest-security

Provide client authentication to an architect application using a rest plugin

Installation

npm install --save https://github.com/bimedia-fr/bimedia-rest-security.git

Usage

Boot Architect :

var path = require('path');
var architect = require("architect");

var config = architect.loadConfig(path.join(__dirname, "config.js"));

architect.createApp(config, function (err, app) {
    if (err) {
        throw err;
    }
    console.log("app ready");
});

Configure rest-security with Architect config.js :

module.exports = [{
    packagePath: 'bimedia-rest-security',
    keypath: 'http://localhost:8086/api/key/%s', /* Private key server , %s will be replaced with principal */
    timestampValidity: 15*60, /* Timestamp validity, in seconds, default 60 */
    scheme: 'BWS', /* Authorization scheme, default BWS */
    name: 'auth', /* Logger name, default auth */
    httpHeaderPrefix: 'x-bm' /* http prefix name, default x-bm */
}];

Readme

Keywords

Package Sidebar

Install

npm i bimedia-rest-security

Weekly Downloads

55

Version

2.1.0

License

BSD-2-Clause

Unpacked Size

76.9 kB

Total Files

13

Last publish

Collaborators

  • echestier
  • vtricoire
  • jcreigno