New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

apx-roles

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apx-roles

Initializer for node-roles for APX API server

  • 0.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
decreased by-66.67%
Maintainers
1
Weekly downloads
 
Created
Source

APX Roles

Kado

STOP AND READ THIS

APX or Apex is no longer maintained and is superseded by Kado.

A new package is available to handle all your JavaScript needs. See kado.org for details.

Summary

Implementation of node-roles through an APX intitializer. Provides apx.roles which can be used to test permissions.

The initializer sets up configuration options to build the definitions used in the role object. Also, apx-helper-crud implements the roles initializer if it is loaded at startup.

Configuration

Apps

  • Variable roles.apps
  • Required yes
  • Default null

This is an array of of apps and their respective roles.

Example

module.exports = {
  apps: [
    {name: 'myapp', roles: ['find','list','save','remove']}
  ]
}

Profiles

  • Variable roles.profiles
  • Required yes
  • Default null

Profiles are used to check roles against the currently logged in user. They are required and should list the available roles to the profile these are called permissions.

Example

module.exports = {
  apps: [
    {name: 'myapp', roles: ['find','list','save','remove']}
  ],
  profiles: [
    {name: 'manager', roles: ['myapp.find','myapp.list','myapp.save']},
    {name: 'admin', roles: ['myapp.*']}
  ]
}

Changelog

0.1.0

  • Initial release

Keywords

FAQs

Package last updated on 11 Mar 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc