Registry / auth-security / ember-cli-simple-auth

ember-cli-simple-auth

JSON →
library0.8.0jsnpmunverified

An Ember CLI addon that packages the Ember Simple Auth base library for use with Ember applications. Version 0.8.0 is deprecated and unmaintained; the project has been superseded by ember-simple-auth. It provides authentication, authorization, and session management for Ember apps. Differentiators: tight integration with Ember CLI; includes generators for custom authenticators, authorizers, session stores, and sessions; configuration via config/environment.js.

npm install ember-cli-simple-auth
INSTALL
IMPORT
SIG · EMBER-CLI-SIMPLE-A
E
ember-cli-simple-auth
auth-securityjavascriptv0.8.0
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
✓ import SimpleAuth from 'ember-cli-simple-auth'
✗ const SimpleAuth = require('ember-cli-simple-auth')
ES module import; the addon automatically initializes, manual import often not needed.
Authenticator
✓ import Authenticator from 'ember-cli-simple-auth/authenticators/base'
✗ import { Authenticator } from 'ember-cli-simple-auth'
Named import from subpath is incorrect; must import base class from specific path.
Authorizer
✓ import Authorizer from 'ember-cli-simple-auth/authorizers/base'
✗ import { Authorizer } from 'ember-cli-simple-auth'
Same as Authenticator; import from subpath.
Session
✓ import Session from 'ember-cli-simple-auth/sessions/base'
✗ import { Session } from 'ember-cli-simple-auth'
Session base class must be imported from the sessions subpath.
SessionStore
✓ import SessionStore from 'ember-cli-simple-auth/stores/base'
✗ import { SessionStore } from 'ember-cli-simple-auth'
Store base class must be imported from the stores subpath.

Basic installation, configuration, and usage of authentication and session management.

// Install the addon ember install ember-cli-simple-auth // Configure in config/environment.js module.exports = function(environment) { var ENV = { // ... other config 'simple-auth': { routeAfterAuthentication: '/protected', serverTokenEndpoint: '/api/token', serverTokenRevocationEndpoint: '/api/revoke' } }; return ENV; }; // Use the session in a route or controller import Session from 'ember-cli-simple-auth/sessions/base'; export default Ember.Controller.extend({ session: Ember.inject.service(), actions: { login: function() { this.get('session').authenticate('simple-auth-authenticator:oauth2-password-grant', { identification: this.get('username'), password: this.get('password') }); }, logout: function() { this.get('session').invalidate(); } } });
Debug
Known issues
deprecatedThis package is deprecated. Use ember-simple-auth instead.
fix
Replace with ember-simple-auth: remove ember-cli-simple-auth, add ember-simple-auth, update imports and configuration.
affects: >=0.0.0
breakingRequires at least Ember CLI 0.0.44; incompatible with older versions.
fix
Upgrade Ember CLI to at least 0.0.44.
affects: <0.8.0
gotchaInstallation command differs based on Ember CLI version: for 0.2.2 or older use `ember install:addon`, for 0.1.4 or older use manual npm + generate.
fix
Use `ember install ember-cli-simple-auth` for modern Ember CLI (>=0.2.3).
affects: >=0.0.0
gotchaThe addon automatically initializes; manual import of the main module is not required and may cause issues.
fix
Do not manually import 'ember-cli-simple-auth' in your app unless you have a specific reason.
affects: >=0.0.0
Errors
Common errors & fixes
Cannot find module 'ember-cli-simple-auth'
Package not installed or not added to package.json.
fix
Run `ember install ember-cli-simple-auth` to install and add to dependencies.
Uncaught TypeError: Cannot read property 'authenticate' of undefined
Session service not injected or session property is undefined.
fix
Ensure you have the session service injected: session: Ember.inject.service().
Assertion Failed: Unable to find authenticator: simple-auth-authenticator:oauth2-password-grant
Missing or misspelled authenticator name; the authenticator must be registered.
fix
Check that the authenticator is correctly registered, e.g., `export default Ember.SimpleAuth.Authenticators.OAuth2PasswordGrant.extend(...)` or installed via addon.
The `ember-cli-simple-auth` addon requires an Ember CLI version of 0.0.44 or above
Ember CLI version is too old.
fix
Upgrade Ember CLI to at least 0.0.44.
Upgrade
Version history
0.8.0latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
18 hits · last 30 days
node
16
OpenAI (training)
1
Resources
ember-cli-simple-auth — npm install ember-cli-simple-auth · libregistry