rikulo_security 1.0.1

  • README.md
  • Installing
  • Versions
  • 65

Rikulo Security

Rikulo Security is a lightweight and highly customizable authentication and access-control framework for Rikulo Stream.

Stream is distributed under an Apache 2.0 License.

Build Status

Installation

Add this to your pubspec.yaml (or create it):

dependencies:
  rikulo_security:

Then run the Pub Package Manager (comes with the Dart SDK):

pub install

Usage

First, you have to implement Authenticator. For sake of description, we use a dummy implementation here called DummyAuthenticator:

 final authenticator = new DummyAuthenticator()
   ..addUser("john", "123", ["user"])
   ..addUser("peter", "123", ["user", "admin"]);

Second, you can use SimpleAccessControl or implement your own access control (AccessControl):

 final accessControl = new SimpleAccessControl({
   "/admin/.*": ["admin"],
   "/member/.*": ["user", "admin"]
 });

Finally, instantiate Security with the authenticator and access control you want:

 final security = new Security(authenticator, accessControl);
 new StreamServer(uriMapping: {
   "/s_login": security.login,
   "/s_logout": security.logout
 }, filterMapping: {
   "/.*": security.filter
 }).start();

Please refer to this sample application for more information.

Notes to Contributors

Fork Rikulo Security

If you'd like to contribute back to the core, you can fork this repository and send us a pull request, when it is ready.

Please be aware that one of Rikulo Security's design goals is to keep the sphere of API as neat and consistency as possible. Strong enhancement always demands greater consensus.

If you are new to Git or GitHub, please read this guide first.

Who Uses

  • Quire - a simple, collaborative, multi-level task management tool.
  • Keikai - a sophisticated spreadsheet for big data

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  rikulo_security: ^1.0.1

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:rikulo_security/plugin.dart';
import 'package:rikulo_security/security.dart';
  
Version Uploaded Documentation Archive
1.0.1 Aug 14, 2018 Go to the documentation of rikulo_security 1.0.1 Download rikulo_security 1.0.1 archive
1.0.0 Aug 10, 2018 Go to the documentation of rikulo_security 1.0.0 Download rikulo_security 1.0.0 archive
0.8.8+2 Sep 25, 2017 Go to the documentation of rikulo_security 0.8.8+2 Download rikulo_security 0.8.8+2 archive
0.8.8+1 Sep 25, 2017 Go to the documentation of rikulo_security 0.8.8+1 Download rikulo_security 0.8.8+1 archive
0.8.8 Sep 25, 2017 Go to the documentation of rikulo_security 0.8.8 Download rikulo_security 0.8.8 archive
0.8.7 Sep 25, 2017 Go to the documentation of rikulo_security 0.8.7 Download rikulo_security 0.8.7 archive
0.8.6 Sep 14, 2017 Go to the documentation of rikulo_security 0.8.6 Download rikulo_security 0.8.6 archive
0.8.5 Apr 12, 2017 Go to the documentation of rikulo_security 0.8.5 Download rikulo_security 0.8.5 archive
0.8.3+2 Mar 16, 2017 Go to the documentation of rikulo_security 0.8.3+2 Download rikulo_security 0.8.3+2 archive
0.8.3+1 Mar 4, 2015 Go to the documentation of rikulo_security 0.8.3+1 Download rikulo_security 0.8.3+1 archive

All 32 versions...

Popularity:
Describes how popular the package is relative to other packages. [more]
61
Health:
Code health derived from static analysis. [more]
75
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
60
Overall:
Weighted score of the above. [more]
65
Learn more about scoring.

We analyzed this package on Sep 18, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0
  • pana: 0.12.3

Platforms

Detected platforms: other

Platform components identified in package: io, mirrors.

Issues and suggestions

Fix lib/src/plugin/authenticator.dart.

Analysis of lib/src/plugin/authenticator.dart failed with 1 error:

line 11 col 26: Undefined class 'HashMap'.

Maintain CHANGELOG.md.

Changelog entries help clients to follow the progress in your code.

Use constrained dependencies.

The pubspec.yaml contains 1 dependency without version constraints. Specify version ranges for the following dependencies: stream.

Format lib/src/plugin/access_control.dart.

Run dartfmt to format lib/src/plugin/access_control.dart.

Format lib/src/security/security_api.dart.

Run dartfmt to format lib/src/security/security_api.dart.

Format lib/src/security/security_impl.dart.

Run dartfmt to format lib/src/security/security_impl.dart.

Maintain an example.

None of the files in your example/ directory matches a known example patterns. Common file name patterns include: main.dart, example.dart or you could also use rikulo_security.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev <3.0.0
stream any 2.0.1+1
Transitive dependencies
args 1.5.0
async 2.0.8
charcode 1.1.2
collection 1.14.11
http 0.11.3+17
http_parser 3.1.3
logging 0.11.3+2
meta 1.1.6
mime 0.9.6+2
path 1.6.2
rikulo_commons 3.0.3+1
source_span 1.4.1
string_scanner 1.0.4
typed_data 1.1.6