diff --git a/build/bundle.js b/build/bundle.js index 79e9b61..4a1b5fb 100644 --- a/build/bundle.js +++ b/build/bundle.js @@ -1 +1 @@ -!function(e){function t(u){if(n[u])return n[u].exports;var r=n[u]={i:u,l:!1,exports:{}};return e[u].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};t.m=e,t.c=n,t.d=function(e,n,u){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:u})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=6)}([function(e,t){e.exports=require("mongoose")},function(e,t){e.exports=require("passport")},function(e,t){e.exports=require("express")},function(e,t){e.exports=require("crypto")},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=u(r),s=n(3),i=u(s),d=new o.default.Schema({username:{type:String,unique:!0,required:!0},hashedPassword:{type:String,required:!0},salt:{type:String,required:!0},created_at:{type:Date,default:Date.now}});d.methods.encryptPassword=function(e){return i.default.pbkdf2Sync(e,(void 0).salt,1e4,512,"sha512").toString("hex")},d.virtual("userId").get(function(){return(void 0).id}),d.virtual("password").set(function(e){(void 0)._plainPassword=e,(void 0).salt=i.default.randomBytes(128).toString("hex"),(void 0).hashedPassword=(void 0).encryptPassword(e)}).get(function(){return(void 0)._plainPassword}),d.methods.checkPassword=function(e){return(void 0).encryptPassword(e)===(void 0).hashedPassword},t.default=o.default.model("users",d)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({userId:{type:String,required:!0},clientId:{type:String,required:!0},token:{type:String,unique:!0,required:!0},created_at:{type:Date,default:Date.now}});t.default=r.default.model("access_tokens",o)},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(7),o=u(r),s=n(8),i=u(s),d=o.default.createServer(i.default);d.listen(i.default.get("port"),i.default.get("host"),function(){console.log("Server is running on http://"+i.default.get("host")+":"+i.default.get("port")),console.log("Press CTRL-C to stop")}),t.default=d},function(e,t){e.exports=require("http")},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(2),o=u(r),s=n(9),i=u(s),d=n(10),a=u(d),l=n(11),f=u(l),c=n(12),p=u(c),_=n(13),v=u(_),y=n(1),g=u(y),m=n(14),S=u(m),h=n(15),O=u(h),x=n(17),M=u(x);n(23),n(24),p.default.config({path:"../.env"});var q=(0,o.default)();q.enable("trust proxy"),q.disable("x-powered-by"),q.set("trust proxy",1),q.set("host",process.env.HOST||"127.0.0.1"),q.set("port",process.env.PORT||"3000"),q.use((0,i.default)()),q.use(O.default),q.use((0,f.default)()),q.use((0,a.default)("common")),q.use((0,S.default)({name:"session",keys:[process.env.COOKIE_SESSION_SECRET_KEY1,process.env.COOKIE_SESSION_SECRET_KEY2],maxAge:process.env.COOKIE_SESSION_MAX_AGE})),q.use(v.default.json({extended:!1})),q.use(v.default.urlencoded({extended:!1})),q.use(g.default.initialize()),q.use(g.default.session()),(0,M.default)(q),t.default=q},function(e,t){e.exports=require("helmet")},function(e,t){e.exports=require("morgan")},function(e,t){e.exports=require("compression")},function(e,t){e.exports=require("dotenv")},function(e,t){e.exports=require("body-parser")},function(e,t){e.exports=require("cookie-session")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(16),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o={windowMs:9e5,max:100,delayMs:0};t.default=new r.default(o)},function(e,t){e.exports=require("express-rate-limit")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(18),r=function(e){return e&&e.__esModule?e:{default:e}}(u);t.default=function(e){e.get("/login",function(e,t){t.json({msg:"login"})}),e.use("/api",r.default),e.use(function(e,t,n){t.status(404),t.json({error:"Not found"})}),e.use(function(e,t,n,u){n.status(e.status||500),n.json({error:e.message})})}},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(2),o=n(19),s=u(o),i=n(22),d=u(i),a=(0,r.Router)();a.post("/oauth/token",s.default.token),a.get("/user/me",d.default.info),a.get("/",function(e,t){t.end("express restful api")}),t.default=a},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(20),o=u(r),s=n(1),i=u(s),d=n(3),a=u(d),l=n(4),f=u(l),c=n(5),p=u(c),_=n(21),v=u(_),y=o.default.createServer(),g=function(e,t){if(t)return e(t)},m=function(e,t){var n=g.bind(void 0,t),u=void 0,r=void 0,o=void 0,s=void 0;v.default.remove(e,n),p.default.remove(e,n),s=a.default.randomBytes(32).toString("hex"),r=a.default.randomBytes(32).toString("hex"),e.token=s,o=new p.default(e),e.token=r,u=new v.default(e),u.save(n),o.save(function(e){if(e)return t(e);t(null,s,r,{expires_in:process.env.TOKEN_MAX_AGE})})};y.exchange(o.default.exchange.password(function(e,t,n,u,r){f.default.findOne({username:t},function(t,u){if(t)return r(t);if(!u||!u.checkPassword(n))return r(null,!1);var o={userId:u.userId,clientId:e.clientId};m(o,r)})}));var S=[i.default.authenticate(["oauth2-client-password"],{session:!1}),y.token(),y.errorHandler()];t.default={token:S}},function(e,t){e.exports=require("oauth2orize")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({userId:{type:String,required:!0},clientId:{type:String,required:!0},token:{type:String,unique:!0,required:!0},created:{type:Date,default:Date.now}});t.default=r.default.model("refresh_tokens",o)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(1),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=[r.default.authenticate("bearer",{session:!1}),function(e,t){t.json({id:e.user.id,name:e.user.name,scope:e.authInfo.scope})}];t.default={info:o}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u);r.default.Promise=global.Promise;var o=process.env.MONGODB_HOST||"localhost",s=process.env.MONGODB_PORT||"27017",i=process.env.MONGODB_DB_NAME||"apis";r.default.connect("mongodb://"+o+":"+s+"/"+i),t.default=r.default},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}var r=n(1),o=u(r),s=n(25),i=n(26),d=n(4),a=u(d),l=n(5),f=u(l),c=n(27),p=u(c);o.default.use(new s.Strategy(function(e,t,n){p.default.findOne({clientId:e},function(e,u){return e?n(e):u?u.clientSecret!==t?n(null,!1):n(null,u):n(null,!1)})})),o.default.use(new i.Strategy(function(e,t){f.default.findOne({token:e},function(n,u){return n?t(n):u?Math.round((Date.now()-u.created)/1e3)>process.env.TOKEN_MAX_AGE?(f.default.remove({token:e},function(e){if(e)return t(e)}),t(null,!1,{message:"Token expired"})):void a.default.findById(u.userId,function(e,n){return e?t(e):n?void t(null,n,{scope:"*"}):t(null,!1,{message:"Unknown user"})}):t(null,!1)})}))},function(e,t){e.exports=require("passport-oauth2-client-password")},function(e,t){e.exports=require("passport-http-bearer")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({name:{type:String,unique:!0,required:!0},clientId:{type:String,unique:!0,required:!0},clientSecret:{type:String,required:!0}});t.default=r.default.model("clients",o)}]); \ No newline at end of file +!function(e){function t(u){if(n[u])return n[u].exports;var r=n[u]={i:u,l:!1,exports:{}};return e[u].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};t.m=e,t.c=n,t.d=function(e,n,u){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:u})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=5)}([function(e,t){e.exports=require("mongoose")},function(e,t){e.exports=require("passport")},function(e,t){e.exports=require("express")},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=u(r),s=n(22),a=u(s),i=new o.default.Schema({email:{type:String,unique:!0,required:!0},password:{type:String,required:!0},created_at:{type:Date,default:Date.now}});i.methods.generateHash=function(e){return a.default.hashSync(e,a.default.genSaltSync(8),null)},i.methods.validPassword=function(e){return a.default.compareSync(e,(void 0).password)},t.default=o.default.model("users",i)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({userId:{type:String,required:!0},clientId:{type:String,required:!0},token:{type:String,unique:!0,required:!0},created_at:{type:Date,default:Date.now}});t.default=r.default.model("access_tokens",o)},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(6),o=u(r),s=n(7),a=u(s),i=o.default.createServer(a.default);i.listen(a.default.get("port"),a.default.get("host"),function(){console.log("Server is running on http://"+a.default.get("host")+":"+a.default.get("port")),console.log("Press CTRL-C to stop")}),t.default=i},function(e,t){e.exports=require("http")},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),n(8);var r=n(2),o=u(r),s=n(9),a=u(s),i=n(10),l=u(i),d=n(11),f=u(d),c=n(12),p=u(c),_=n(13),v=u(_),g=n(1),m=u(g),y=n(14),S=u(y),O=n(15),x=u(O),h=n(17),M=u(h);n(25),n(26),p.default.config({path:"../.env"});var q=(0,o.default)();q.enable("trust proxy"),q.disable("x-powered-by"),q.set("trust proxy",1),q.set("host",process.env.HOST||"127.0.0.1"),q.set("port",process.env.PORT||"3000"),q.use((0,a.default)()),q.use(x.default),q.use((0,f.default)()),q.use((0,l.default)("common")),q.use((0,S.default)({name:"session",keys:[process.env.COOKIE_SESSION_SECRET_KEY1,process.env.COOKIE_SESSION_SECRET_KEY2],maxAge:process.env.COOKIE_SESSION_MAX_AGE})),q.use(v.default.json({extended:!1})),q.use(v.default.urlencoded({extended:!1})),q.use(m.default.initialize()),q.use(m.default.session()),(0,M.default)(q),t.default=q},function(e,t){e.exports=require("babel-polyfill")},function(e,t){e.exports=require("helmet")},function(e,t){e.exports=require("morgan")},function(e,t){e.exports=require("compression")},function(e,t){e.exports=require("dotenv")},function(e,t){e.exports=require("body-parser")},function(e,t){e.exports=require("cookie-session")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(16),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o={windowMs:9e5,max:100,delayMs:0};t.default=new r.default(o)},function(e,t){e.exports=require("express-rate-limit")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(18),r=function(e){return e&&e.__esModule?e:{default:e}}(u);t.default=function(e){e.get("/login",function(e,t){t.json({msg:"login"})}),e.use("/api",r.default),e.use(function(e,t,n){t.status(404),t.json({error:"Not found"})}),e.use(function(e,t,n,u){n.status(e.status||500),n.json({error:e.message})})}},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(2),o=n(19),s=u(o),a=n(24),i=u(a),l=(0,r.Router)();l.post("/oauth/token",s.default.token),l.post("/user/signup",i.default.signup,function(e,t){return t.json(e.user)}),l.get("/user/me",i.default.me),l.get("/",function(e,t){t.end("express restful api")}),t.default=l},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var r=n(20),o=u(r),s=n(1),a=u(s),i=n(21),l=u(i),d=n(3),f=u(d),c=n(4),p=u(c),_=n(23),v=u(_),g=o.default.createServer(),m=function(e,t){if(t)return e(t)},y=function(e,t){var n=m.bind(void 0,t),u=void 0,r=void 0,o=void 0,s=void 0;v.default.remove(e,n),p.default.remove(e,n),s=l.default.randomBytes(32).toString("hex"),r=l.default.randomBytes(32).toString("hex"),e.token=s,o=new p.default(e),e.token=r,u=new v.default(e),u.save(n),o.save(function(e){if(e)return t(e);t(null,s,r,{expires_in:process.env.TOKEN_MAX_AGE})})};g.exchange(o.default.exchange.password(function(e,t,n,u,r){f.default.findOne({username:t},function(t,u){if(t)return r(t);if(!u||!u.checkPassword(n))return r(null,!1);var o={userId:u.userId,clientId:e.clientId};y(o,r)})}));var S=[a.default.authenticate(["oauth2-client-password"],{session:!1}),g.token(),g.errorHandler()];t.default={token:S}},function(e,t){e.exports=require("oauth2orize")},function(e,t){e.exports=require("crypto")},function(e,t){e.exports=require("bcrypt-nodejs")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({userId:{type:String,required:!0},clientId:{type:String,required:!0},token:{type:String,unique:!0,required:!0},created:{type:Date,default:Date.now}});t.default=r.default.model("refresh_tokens",o)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(1),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=[r.default.authenticate("bearer",{session:!1}),function(e,t){t.json({id:e.user.id,name:e.user.name,scope:e.authInfo.scope})}],s=r.default.authenticate("local-signup");t.default={me:o,signup:s}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u);r.default.Promise=global.Promise;var o=process.env.MONGODB_HOST||"localhost",s=process.env.MONGODB_PORT||"27017",a=process.env.MONGODB_DB_NAME||"apis";r.default.connect("mongodb://"+o+":"+s+"/"+a),t.default=r.default},function(e,t,n){"use strict";function u(e){return e&&e.__esModule?e:{default:e}}var r=n(1),o=u(r),s=n(27),a=n(28),i=n(29),l=n(3),d=u(l),f=n(4),c=u(f),p=n(30),_=u(p);o.default.serializeUser(function(e,t){return t(null,e.id)}),o.default.deserializeUser(function(e,t){return d.default.findById(e).then(function(e){return t(null,e)})}),o.default.use("local-signup",new s.Strategy({usernameField:"email",passwordField:"password",passReqToCallback:!0,session:!1},function(e,t,n,u){d.default.findOne({email:t},function(e,r){if(e)return u(e);if(r)return u({status:422,message:"That email is already taken."});var o=new d.default;o.email=t,o.password=o.generateHash(n),o.save(function(e){return e?u(e):u(null,o)})})})),o.default.use(new a.Strategy(function(e,t,n){_.default.findOne({clientId:e},function(e,u){return e?n(e):u?u.clientSecret!==t?n(null,!1):n(null,u):n(null,!1)})})),o.default.use(new i.Strategy(function(e,t){c.default.findOne({token:e},function(n,u){return n?t(n):u?Math.round((Date.now()-u.created)/1e3)>process.env.TOKEN_MAX_AGE?(c.default.remove({token:e},function(e){if(e)return t(e)}),t(null,!1,{message:"Token expired"})):void d.default.findById(u.userId,function(e,n){return e?t(e):n?void t(null,n,{scope:"*"}):t(null,!1,{message:"Unknown user"})}):t(null,!1)})}))},function(e,t){e.exports=require("passport-local")},function(e,t){e.exports=require("passport-oauth2-client-password")},function(e,t){e.exports=require("passport-http-bearer")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),r=function(e){return e&&e.__esModule?e:{default:e}}(u),o=new r.default.Schema({name:{type:String,unique:!0,required:!0},clientId:{type:String,unique:!0,required:!0},clientSecret:{type:String,required:!0}});t.default=r.default.model("clients",o)}]); \ No newline at end of file diff --git a/package.json b/package.json index 5bcfa5f..d452e7b 100644 --- a/package.json +++ b/package.json @@ -43,10 +43,11 @@ ] }, "dependencies": { + "babel-polyfill": "^6.26.0", + "bcrypt-nodejs": "^0.0.3", "body-parser": "^1.18.2", "compression": "^1.7.2", "cookie-session": "^2.0.0-beta.3", - "crypto": "^1.0.1", "dotenv": "^5.0.1", "express": "^4.16.2", "express-rate-limit": "^2.11.0", diff --git a/src/app.js b/src/app.js index 3ba31d7..b749455 100644 --- a/src/app.js +++ b/src/app.js @@ -1,3 +1,4 @@ +import 'babel-polyfill' import express from 'express' import helmet from 'helmet' import morgan from 'morgan' diff --git a/src/models/users.js b/src/models/users.js index 39c5148..1ac3956 100644 --- a/src/models/users.js +++ b/src/models/users.js @@ -1,17 +1,13 @@ import mongoose from 'mongoose' -import crypto from 'crypto' +import bcrypt from 'bcrypt-nodejs' -const User = new mongoose.Schema({ - username: { +const Users = new mongoose.Schema({ + email: { type: String, unique: true, required: true }, - hashedPassword: { - type: String, - required: true - }, - salt: { + password: { type: String, required: true }, @@ -21,18 +17,7 @@ const User = new mongoose.Schema({ } }) -User.methods.encryptPassword = password => crypto.pbkdf2Sync(password, this.salt, 10000, 512, 'sha512').toString('hex') - -User.virtual('userId').get(() => this.id) - -User.virtual('password') - .set(password => { - this._plainPassword = password - this.salt = crypto.randomBytes(128).toString('hex') - this.hashedPassword = this.encryptPassword(password) - }) - .get(() => this._plainPassword) - -User.methods.checkPassword = password => this.encryptPassword(password) === this.hashedPassword +Users.methods.generateHash = password => bcrypt.hashSync(password, bcrypt.genSaltSync(8), null) +Users.methods.validPassword = password => bcrypt.compareSync(password, this.password) -export default mongoose.model('users', User) +export default mongoose.model('users', Users) diff --git a/src/routes/api.js b/src/routes/api.js index 8908be0..bc79cb1 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -8,7 +8,8 @@ const router = Router() router.post('/oauth/token', oauth2.token) // user -router.get('/user/me', user.info) +router.post('/user/signup', user.signup, (req, res) => res.json(req.user)) +router.get('/user/me', user.me) router.get('/', (req, res) => { res.end('express restful api') diff --git a/src/services/auth/oauth2.js b/src/services/auth/oauth2.js index 6a7a584..94aed45 100644 --- a/src/services/auth/oauth2.js +++ b/src/services/auth/oauth2.js @@ -41,8 +41,8 @@ const generateTokens = (data, done) => { }) } -server.exchange(oauth2orize.exchange.password(function (client, username, password, scope, done) { - Users.findOne({ username: username }, function (err, user) { +server.exchange(oauth2orize.exchange.password((client, username, password, scope, done) => { + Users.findOne({ username: username }, (err, user) => { if (err) return done(err) if (!user || !user.checkPassword(password)) return done(null, false) diff --git a/src/services/passport/index.js b/src/services/passport/index.js index f57f3f8..daa538a 100644 --- a/src/services/passport/index.js +++ b/src/services/passport/index.js @@ -1,4 +1,5 @@ import passport from 'passport' +import { Strategy as LocalStrategy } from 'passport-local' import { Strategy as ClientPasswordStrategy } from 'passport-oauth2-client-password' import { Strategy as BearerStrategy } from 'passport-http-bearer' @@ -6,6 +7,34 @@ import Users from '../../models/users' import AccessTokens from '../../models/access_tokens' import Clients from '../../models/clients' +passport.serializeUser((user, done) => done(null, user.id)) +passport.deserializeUser((id, done) => Users.findById(id).then(user => done(null, user))) + +passport.use('local-signup', new LocalStrategy({ + usernameField: 'email', + passwordField: 'password', + passReqToCallback: true, + session: false +}, +(req, email, password, done) => { + Users.findOne({ 'email': email }, function (err, user) { + if (err) return done(err) + + if (user) { + return done({status: 422, message: 'That email is already taken.'}) + } else { + const newUser = new Users() + newUser.email = email + newUser.password = newUser.generateHash(password) + newUser.save(function (err) { + if (err) return done(err) + + return done(null, newUser) + }) + } + }) +})) + passport.use(new ClientPasswordStrategy( (clientId, clientSecret, done) => { Clients.findOne({ clientId: clientId }, (err, client) => { diff --git a/src/services/user/index.js b/src/services/user/index.js index 1fccbdf..2c04569 100644 --- a/src/services/user/index.js +++ b/src/services/user/index.js @@ -1,12 +1,15 @@ import passport from 'passport' -const info = [ +const me = [ passport.authenticate('bearer', { session: false }), (request, response) => { response.json({ id: request.user.id, name: request.user.name, scope: request.authInfo.scope }) } ] +const signup = passport.authenticate('local-signup') + export default { - info + me, + signup } diff --git a/yarn.lock b/yarn.lock index ff29a1c..d2a145c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -778,6 +778,14 @@ babel-plugin-transform-strict-mode@^6.24.1: babel-runtime "^6.22.0" babel-types "^6.24.1" +babel-polyfill@^6.26.0: + version "6.26.0" + resolved "https://registry.yarnpkg.com/babel-polyfill/-/babel-polyfill-6.26.0.tgz#379937abc67d7895970adc621f284cd966cf2153" + dependencies: + babel-runtime "^6.26.0" + core-js "^2.5.0" + regenerator-runtime "^0.10.5" + babel-preset-env@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/babel-preset-env/-/babel-preset-env-1.6.1.tgz#a18b564cc9b9afdf4aae57ae3c1b0d99188e6f48" @@ -925,6 +933,10 @@ batch@0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/batch/-/batch-0.6.1.tgz#dc34314f4e679318093fc760272525f94bf25c16" +bcrypt-nodejs@^0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/bcrypt-nodejs/-/bcrypt-nodejs-0.0.3.tgz#c60917f26dc235661566c681061c303c2b28842b" + bcrypt-pbkdf@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz#63bc5dcb61331b92bc05fd528953c33462a06f8d" @@ -1552,10 +1564,6 @@ crypto-random-string@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e" -crypto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/crypto/-/crypto-1.0.1.tgz#2af1b7cad8175d24c8a1b0778255794a21803037" - cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0": version "0.3.2" resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.2.tgz#b8036170c79f07a90ff2f16e22284027a243848b" @@ -4725,6 +4733,10 @@ regenerate@^1.2.1: version "1.3.3" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.3.3.tgz#0c336d3980553d755c39b586ae3b20aa49c82b7f" +regenerator-runtime@^0.10.5: + version "0.10.5" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.10.5.tgz#336c3efc1220adcedda2c9fab67b5a7955a33658" + regenerator-runtime@^0.11.0: version "0.11.1" resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9"