bidi-authorizer
TypeScript icon, indicating that this package has built-in type declarations

0.0.5 • Public • Published

bidi authorizer

This repository is a library that contains 2 main functionalities. First, a Policy Builder that get data from request and payload in order to build the policy structure, then it can check permissions mapping policy structure against resources list.

Second, a decorator. The decorator is able to use it into an api gateway as a generic check or less specific test. Also, this decorator could be used inside a microservice such as a authorizer decorator with more specificity.

##Example ####Generic by resources: @authorizer()

####Specific by tenant: @authorizer({tenantIdField: 'tenantId'})

####Specific by bidi: @authorizer({bidiIdField: 'tenantId'})

####Specific by both

@authorizer({ tenantIdField: 'tenantId', bidiIdField: 'tenantId' })

Readme

Keywords

none

Package Sidebar

Install

npm i bidi-authorizer

Weekly Downloads

2

Version

0.0.5

License

ISC

Unpacked Size

52.1 kB

Total Files

64

Last publish

Collaborators

  • melgard