From dff1e5f0ec2ec5ce436a2f5e5d9c3ce134835eab Mon Sep 17 00:00:00 2001 From: Guillaume Vincent Date: Sun, 17 Sep 2017 18:47:55 +0200 Subject: [PATCH] Remove version 1 --- dist/lesspass.js | 2012 ++++++++++++++--- dist/lesspass.min.js | 2 +- package-lock.json | 3875 +++++++++++++++++++++++++++++++++ package.json | 3 +- src/hmac.js | 1 - src/lesspass.js | 162 +- src/pbkdf2.js | 1 - src/v1.js | 128 -- src/v2.js | 136 -- test/api.tests.js | 434 +--- test/entropy.tests.js | 89 + test/renderPassword.tests.js | 99 + test/setOfCharacters.tests.js | 78 + test/v1/deriveEncryptedLogin.tests.js | 110 - test/v1/getPasswordTemplate.tests.js | 82 - test/v1/prettyPrint.js | 39 - test/v1/renderPassword.tests.js | 281 --- test/v2/entropy.tests.js | 79 - test/v2/renderPassword.tests.js | 99 - test/v2/setOfCharacters.tests.js | 78 - 20 files changed, 6096 insertions(+), 1692 deletions(-) create mode 100644 package-lock.json delete mode 100644 src/v1.js delete mode 100644 src/v2.js create mode 100644 test/entropy.tests.js create mode 100644 test/renderPassword.tests.js create mode 100644 test/setOfCharacters.tests.js delete mode 100644 test/v1/deriveEncryptedLogin.tests.js delete mode 100644 test/v1/getPasswordTemplate.tests.js delete mode 100644 test/v1/prettyPrint.js delete mode 100644 test/v1/renderPassword.tests.js delete mode 100644 test/v2/entropy.tests.js delete mode 100644 test/v2/renderPassword.tests.js delete mode 100644 test/v2/setOfCharacters.tests.js diff --git a/dist/lesspass.js b/dist/lesspass.js index 14e0c2f..066cccf 100644 --- a/dist/lesspass.js +++ b/dist/lesspass.js @@ -1228,13 +1228,14 @@ if (typeof module !== "undefined" && module.hasOwnProperty("exports")) { } //amd check -if ( typeof define === "function" && define.amd ) { +if ( typeof define === "function" && define.amd ) { define( "big-integer", [], function() { return bigInt; }); } },{}],2:[function(require,module,exports){ +(function (global){ /** * lodash (Custom Build) * Build: `lodash modularize exports="npm" -o ./` @@ -1244,17 +1245,151 @@ if ( typeof define === "function" && define.amd ) { * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ +/** Used as the size to enable large array optimizations. */ +var LARGE_ARRAY_SIZE = 200; + +/** Used to stand-in for `undefined` hash values. */ +var HASH_UNDEFINED = '__lodash_hash_undefined__'; + /** Used as references for various `Number` constants. */ var MAX_SAFE_INTEGER = 9007199254740991; /** `Object#toString` result references. */ var argsTag = '[object Arguments]', + arrayTag = '[object Array]', + boolTag = '[object Boolean]', + dateTag = '[object Date]', + errorTag = '[object Error]', funcTag = '[object Function]', - genTag = '[object GeneratorFunction]'; + genTag = '[object GeneratorFunction]', + mapTag = '[object Map]', + numberTag = '[object Number]', + objectTag = '[object Object]', + promiseTag = '[object Promise]', + regexpTag = '[object RegExp]', + setTag = '[object Set]', + stringTag = '[object String]', + symbolTag = '[object Symbol]', + weakMapTag = '[object WeakMap]'; + +var arrayBufferTag = '[object ArrayBuffer]', + dataViewTag = '[object DataView]', + float32Tag = '[object Float32Array]', + float64Tag = '[object Float64Array]', + int8Tag = '[object Int8Array]', + int16Tag = '[object Int16Array]', + int32Tag = '[object Int32Array]', + uint8Tag = '[object Uint8Array]', + uint8ClampedTag = '[object Uint8ClampedArray]', + uint16Tag = '[object Uint16Array]', + uint32Tag = '[object Uint32Array]'; + +/** + * Used to match `RegExp` + * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns). + */ +var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; + +/** Used to match `RegExp` flags from their coerced string values. */ +var reFlags = /\w*$/; + +/** Used to detect host constructors (Safari). */ +var reIsHostCtor = /^\[object .+?Constructor\]$/; /** Used to detect unsigned integer values. */ var reIsUint = /^(?:0|[1-9]\d*)$/; +/** Used to identify `toStringTag` values of typed arrays. */ +var typedArrayTags = {}; +typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = +typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = +typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = +typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = +typedArrayTags[uint32Tag] = true; +typedArrayTags[argsTag] = typedArrayTags[arrayTag] = +typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = +typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = +typedArrayTags[errorTag] = typedArrayTags[funcTag] = +typedArrayTags[mapTag] = typedArrayTags[numberTag] = +typedArrayTags[objectTag] = typedArrayTags[regexpTag] = +typedArrayTags[setTag] = typedArrayTags[stringTag] = +typedArrayTags[weakMapTag] = false; + +/** Used to identify `toStringTag` values supported by `_.clone`. */ +var cloneableTags = {}; +cloneableTags[argsTag] = cloneableTags[arrayTag] = +cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = +cloneableTags[boolTag] = cloneableTags[dateTag] = +cloneableTags[float32Tag] = cloneableTags[float64Tag] = +cloneableTags[int8Tag] = cloneableTags[int16Tag] = +cloneableTags[int32Tag] = cloneableTags[mapTag] = +cloneableTags[numberTag] = cloneableTags[objectTag] = +cloneableTags[regexpTag] = cloneableTags[setTag] = +cloneableTags[stringTag] = cloneableTags[symbolTag] = +cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = +cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true; +cloneableTags[errorTag] = cloneableTags[funcTag] = +cloneableTags[weakMapTag] = false; + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + +/** Detect free variable `exports`. */ +var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports; + +/** Detect free variable `module`. */ +var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module; + +/** Detect the popular CommonJS extension `module.exports`. */ +var moduleExports = freeModule && freeModule.exports === freeExports; + +/** Detect free variable `process` from Node.js. */ +var freeProcess = moduleExports && freeGlobal.process; + +/** Used to access faster Node.js helpers. */ +var nodeUtil = (function() { + try { + return freeProcess && freeProcess.binding('util'); + } catch (e) {} +}()); + +/* Node.js helper references. */ +var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray; + +/** + * Adds the key-value `pair` to `map`. + * + * @private + * @param {Object} map The map to modify. + * @param {Array} pair The key-value pair to add. + * @returns {Object} Returns `map`. + */ +function addMapEntry(map, pair) { + // Don't return `map.set` because it's not chainable in IE 11. + map.set(pair[0], pair[1]); + return map; +} + +/** + * Adds `value` to `set`. + * + * @private + * @param {Object} set The set to modify. + * @param {*} value The value to add. + * @returns {Object} Returns `set`. + */ +function addSetEntry(set, value) { + // Don't return `set.add` because it's not chainable in IE 11. + set.add(value); + return set; +} + /** * A faster alternative to `Function#apply`, this function invokes `func` * with the `this` binding of `thisArg` and the arguments of `args`. @@ -1276,6 +1411,71 @@ function apply(func, thisArg, args) { } /** + * A specialized version of `_.forEach` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns `array`. + */ +function arrayEach(array, iteratee) { + var index = -1, + length = array ? array.length : 0; + + while (++index < length) { + if (iteratee(array[index], index, array) === false) { + break; + } + } + return array; +} + +/** + * Appends the elements of `values` to `array`. + * + * @private + * @param {Array} array The array to modify. + * @param {Array} values The values to append. + * @returns {Array} Returns `array`. + */ +function arrayPush(array, values) { + var index = -1, + length = values.length, + offset = array.length; + + while (++index < length) { + array[offset + index] = values[index]; + } + return array; +} + +/** + * A specialized version of `_.reduce` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as + * the initial value. + * @returns {*} Returns the accumulated value. + */ +function arrayReduce(array, iteratee, accumulator, initAccum) { + var index = -1, + length = array ? array.length : 0; + + if (initAccum && length) { + accumulator = array[++index]; + } + while (++index < length) { + accumulator = iteratee(accumulator, array[index], index, array); + } + return accumulator; +} + +/** * The base implementation of `_.times` without support for iteratee shorthands * or max array length checks. * @@ -1295,6 +1495,67 @@ function baseTimes(n, iteratee) { } /** + * The base implementation of `_.unary` without support for storing metadata. + * + * @private + * @param {Function} func The function to cap arguments for. + * @returns {Function} Returns the new capped function. + */ +function baseUnary(func) { + return function(value) { + return func(value); + }; +} + +/** + * Gets the value at `key` of `object`. + * + * @private + * @param {Object} [object] The object to query. + * @param {string} key The key of the property to get. + * @returns {*} Returns the property value. + */ +function getValue(object, key) { + return object == null ? undefined : object[key]; +} + +/** + * Checks if `value` is a host object in IE < 9. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a host object, else `false`. + */ +function isHostObject(value) { + // Many host objects are `Object` objects that can coerce to strings + // despite having improperly defined `toString` methods. + var result = false; + if (value != null && typeof value.toString != 'function') { + try { + result = !!(value + ''); + } catch (e) {} + } + return result; +} + +/** + * Converts `map` to its key-value pairs. + * + * @private + * @param {Object} map The map to convert. + * @returns {Array} Returns the key-value pairs. + */ +function mapToArray(map) { + var index = -1, + result = Array(map.size); + + map.forEach(function(value, key) { + result[++index] = [key, value]; + }); + return result; +} + +/** * Creates a unary function that invokes `func` with its argument transformed. * * @private @@ -1308,12 +1569,46 @@ function overArg(func, transform) { }; } +/** + * Converts `set` to an array of its values. + * + * @private + * @param {Object} set The set to convert. + * @returns {Array} Returns the values. + */ +function setToArray(set) { + var index = -1, + result = Array(set.size); + + set.forEach(function(value) { + result[++index] = value; + }); + return result; +} + /** Used for built-in method references. */ -var objectProto = Object.prototype; +var arrayProto = Array.prototype, + funcProto = Function.prototype, + objectProto = Object.prototype; + +/** Used to detect overreaching core-js shims. */ +var coreJsData = root['__core-js_shared__']; + +/** Used to detect methods masquerading as native. */ +var maskSrcKey = (function() { + var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || ''); + return uid ? ('Symbol(src)_1.' + uid) : ''; +}()); + +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; /** Used to check objects for own properties. */ var hasOwnProperty = objectProto.hasOwnProperty; +/** Used to infer the `Object` constructor. */ +var objectCtorString = funcToString.call(Object); + /** * Used to resolve the * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) @@ -1321,15 +1616,441 @@ var hasOwnProperty = objectProto.hasOwnProperty; */ var objectToString = objectProto.toString; +/** Used to detect if a method is native. */ +var reIsNative = RegExp('^' + + funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&') + .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' +); + /** Built-in value references. */ -var propertyIsEnumerable = objectProto.propertyIsEnumerable; +var Buffer = moduleExports ? root.Buffer : undefined, + Symbol = root.Symbol, + Uint8Array = root.Uint8Array, + getPrototype = overArg(Object.getPrototypeOf, Object), + objectCreate = Object.create, + propertyIsEnumerable = objectProto.propertyIsEnumerable, + splice = arrayProto.splice; /* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeKeys = overArg(Object.keys, Object), +var nativeGetSymbols = Object.getOwnPropertySymbols, + nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined, + nativeKeys = overArg(Object.keys, Object), nativeMax = Math.max; -/** Detect if properties shadowing those on `Object.prototype` are non-enumerable. */ -var nonEnumShadows = !propertyIsEnumerable.call({ 'valueOf': 1 }, 'valueOf'); +/* Built-in method references that are verified to be native. */ +var DataView = getNative(root, 'DataView'), + Map = getNative(root, 'Map'), + Promise = getNative(root, 'Promise'), + Set = getNative(root, 'Set'), + WeakMap = getNative(root, 'WeakMap'), + nativeCreate = getNative(Object, 'create'); + +/** Used to detect maps, sets, and weakmaps. */ +var dataViewCtorString = toSource(DataView), + mapCtorString = toSource(Map), + promiseCtorString = toSource(Promise), + setCtorString = toSource(Set), + weakMapCtorString = toSource(WeakMap); + +/** Used to convert symbols to primitives and strings. */ +var symbolProto = Symbol ? Symbol.prototype : undefined, + symbolValueOf = symbolProto ? symbolProto.valueOf : undefined; + +/** + * Creates a hash object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function Hash(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the hash. + * + * @private + * @name clear + * @memberOf Hash + */ +function hashClear() { + this.__data__ = nativeCreate ? nativeCreate(null) : {}; +} + +/** + * Removes `key` and its value from the hash. + * + * @private + * @name delete + * @memberOf Hash + * @param {Object} hash The hash to modify. + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function hashDelete(key) { + return this.has(key) && delete this.__data__[key]; +} + +/** + * Gets the hash value for `key`. + * + * @private + * @name get + * @memberOf Hash + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function hashGet(key) { + var data = this.__data__; + if (nativeCreate) { + var result = data[key]; + return result === HASH_UNDEFINED ? undefined : result; + } + return hasOwnProperty.call(data, key) ? data[key] : undefined; +} + +/** + * Checks if a hash value for `key` exists. + * + * @private + * @name has + * @memberOf Hash + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function hashHas(key) { + var data = this.__data__; + return nativeCreate ? data[key] !== undefined : hasOwnProperty.call(data, key); +} + +/** + * Sets the hash `key` to `value`. + * + * @private + * @name set + * @memberOf Hash + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the hash instance. + */ +function hashSet(key, value) { + var data = this.__data__; + data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value; + return this; +} + +// Add methods to `Hash`. +Hash.prototype.clear = hashClear; +Hash.prototype['delete'] = hashDelete; +Hash.prototype.get = hashGet; +Hash.prototype.has = hashHas; +Hash.prototype.set = hashSet; + +/** + * Creates an list cache object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function ListCache(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the list cache. + * + * @private + * @name clear + * @memberOf ListCache + */ +function listCacheClear() { + this.__data__ = []; +} + +/** + * Removes `key` and its value from the list cache. + * + * @private + * @name delete + * @memberOf ListCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function listCacheDelete(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + return false; + } + var lastIndex = data.length - 1; + if (index == lastIndex) { + data.pop(); + } else { + splice.call(data, index, 1); + } + return true; +} + +/** + * Gets the list cache value for `key`. + * + * @private + * @name get + * @memberOf ListCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function listCacheGet(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + return index < 0 ? undefined : data[index][1]; +} + +/** + * Checks if a list cache value for `key` exists. + * + * @private + * @name has + * @memberOf ListCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function listCacheHas(key) { + return assocIndexOf(this.__data__, key) > -1; +} + +/** + * Sets the list cache `key` to `value`. + * + * @private + * @name set + * @memberOf ListCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the list cache instance. + */ +function listCacheSet(key, value) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + data.push([key, value]); + } else { + data[index][1] = value; + } + return this; +} + +// Add methods to `ListCache`. +ListCache.prototype.clear = listCacheClear; +ListCache.prototype['delete'] = listCacheDelete; +ListCache.prototype.get = listCacheGet; +ListCache.prototype.has = listCacheHas; +ListCache.prototype.set = listCacheSet; + +/** + * Creates a map cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function MapCache(entries) { + var index = -1, + length = entries ? entries.length : 0; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} + +/** + * Removes all key-value entries from the map. + * + * @private + * @name clear + * @memberOf MapCache + */ +function mapCacheClear() { + this.__data__ = { + 'hash': new Hash, + 'map': new (Map || ListCache), + 'string': new Hash + }; +} + +/** + * Removes `key` and its value from the map. + * + * @private + * @name delete + * @memberOf MapCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function mapCacheDelete(key) { + return getMapData(this, key)['delete'](key); +} + +/** + * Gets the map value for `key`. + * + * @private + * @name get + * @memberOf MapCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function mapCacheGet(key) { + return getMapData(this, key).get(key); +} + +/** + * Checks if a map value for `key` exists. + * + * @private + * @name has + * @memberOf MapCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function mapCacheHas(key) { + return getMapData(this, key).has(key); +} + +/** + * Sets the map `key` to `value`. + * + * @private + * @name set + * @memberOf MapCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the map cache instance. + */ +function mapCacheSet(key, value) { + getMapData(this, key).set(key, value); + return this; +} + +// Add methods to `MapCache`. +MapCache.prototype.clear = mapCacheClear; +MapCache.prototype['delete'] = mapCacheDelete; +MapCache.prototype.get = mapCacheGet; +MapCache.prototype.has = mapCacheHas; +MapCache.prototype.set = mapCacheSet; + +/** + * Creates a stack cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function Stack(entries) { + this.__data__ = new ListCache(entries); +} + +/** + * Removes all key-value entries from the stack. + * + * @private + * @name clear + * @memberOf Stack + */ +function stackClear() { + this.__data__ = new ListCache; +} + +/** + * Removes `key` and its value from the stack. + * + * @private + * @name delete + * @memberOf Stack + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ +function stackDelete(key) { + return this.__data__['delete'](key); +} + +/** + * Gets the stack value for `key`. + * + * @private + * @name get + * @memberOf Stack + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ +function stackGet(key) { + return this.__data__.get(key); +} + +/** + * Checks if a stack value for `key` exists. + * + * @private + * @name has + * @memberOf Stack + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function stackHas(key) { + return this.__data__.has(key); +} + +/** + * Sets the stack `key` to `value`. + * + * @private + * @name set + * @memberOf Stack + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the stack cache instance. + */ +function stackSet(key, value) { + var cache = this.__data__; + if (cache instanceof ListCache) { + var pairs = cache.__data__; + if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) { + pairs.push([key, value]); + return this; + } + cache = this.__data__ = new MapCache(pairs); + } + cache.set(key, value); + return this; +} + +// Add methods to `Stack`. +Stack.prototype.clear = stackClear; +Stack.prototype['delete'] = stackDelete; +Stack.prototype.get = stackGet; +Stack.prototype.has = stackHas; +Stack.prototype.set = stackSet; /** * Creates an array of the enumerable property names of the array-like `value`. @@ -1355,25 +2076,214 @@ function arrayLikeKeys(value, inherited) { result.push(key); } } - return result; + return result; +} + +/** + * This function is like `assignValue` except that it doesn't assign + * `undefined` values. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ +function assignMergeValue(object, key, value) { + if ((value !== undefined && !eq(object[key], value)) || + (typeof key == 'number' && value === undefined && !(key in object))) { + object[key] = value; + } +} + +/** + * Assigns `value` to `key` of `object` if the existing value is not equivalent + * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ +function assignValue(object, key, value) { + var objValue = object[key]; + if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || + (value === undefined && !(key in object))) { + object[key] = value; + } +} + +/** + * Gets the index at which the `key` is found in `array` of key-value pairs. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} key The key to search for. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function assocIndexOf(array, key) { + var length = array.length; + while (length--) { + if (eq(array[length][0], key)) { + return length; + } + } + return -1; +} + +/** + * The base implementation of `_.assign` without support for multiple sources + * or `customizer` functions. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @returns {Object} Returns `object`. + */ +function baseAssign(object, source) { + return object && copyObject(source, keys(source), object); +} + +/** + * The base implementation of `_.clone` and `_.cloneDeep` which tracks + * traversed objects. + * + * @private + * @param {*} value The value to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @param {boolean} [isFull] Specify a clone including symbols. + * @param {Function} [customizer] The function to customize cloning. + * @param {string} [key] The key of `value`. + * @param {Object} [object] The parent object of `value`. + * @param {Object} [stack] Tracks traversed objects and their clone counterparts. + * @returns {*} Returns the cloned value. + */ +function baseClone(value, isDeep, isFull, customizer, key, object, stack) { + var result; + if (customizer) { + result = object ? customizer(value, key, object, stack) : customizer(value); + } + if (result !== undefined) { + return result; + } + if (!isObject(value)) { + return value; + } + var isArr = isArray(value); + if (isArr) { + result = initCloneArray(value); + if (!isDeep) { + return copyArray(value, result); + } + } else { + var tag = getTag(value), + isFunc = tag == funcTag || tag == genTag; + + if (isBuffer(value)) { + return cloneBuffer(value, isDeep); + } + if (tag == objectTag || tag == argsTag || (isFunc && !object)) { + if (isHostObject(value)) { + return object ? value : {}; + } + result = initCloneObject(isFunc ? {} : value); + if (!isDeep) { + return copySymbols(value, baseAssign(result, value)); + } + } else { + if (!cloneableTags[tag]) { + return object ? value : {}; + } + result = initCloneByTag(value, tag, baseClone, isDeep); + } + } + // Check for circular references and return its corresponding clone. + stack || (stack = new Stack); + var stacked = stack.get(value); + if (stacked) { + return stacked; + } + stack.set(value, result); + + if (!isArr) { + var props = isFull ? getAllKeys(value) : keys(value); + } + arrayEach(props || value, function(subValue, key) { + if (props) { + key = subValue; + subValue = value[key]; + } + // Recursively populate clone (susceptible to call stack limits). + assignValue(result, key, baseClone(subValue, isDeep, isFull, customizer, key, value, stack)); + }); + return result; +} + +/** + * The base implementation of `_.create` without support for assigning + * properties to the created object. + * + * @private + * @param {Object} prototype The object to inherit from. + * @returns {Object} Returns the new object. + */ +function baseCreate(proto) { + return isObject(proto) ? objectCreate(proto) : {}; +} + +/** + * The base implementation of `getAllKeys` and `getAllKeysIn` which uses + * `keysFunc` and `symbolsFunc` to get the enumerable property names and + * symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Function} keysFunc The function to get the keys of `object`. + * @param {Function} symbolsFunc The function to get the symbols of `object`. + * @returns {Array} Returns the array of property names and symbols. + */ +function baseGetAllKeys(object, keysFunc, symbolsFunc) { + var result = keysFunc(object); + return isArray(object) ? result : arrayPush(result, symbolsFunc(object)); +} + +/** + * The base implementation of `getTag`. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ +function baseGetTag(value) { + return objectToString.call(value); +} + +/** + * The base implementation of `_.isNative` without bad shim checks. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a native function, + * else `false`. + */ +function baseIsNative(value) { + if (!isObject(value) || isMasked(value)) { + return false; + } + var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor; + return pattern.test(toSource(value)); } /** - * Assigns `value` to `key` of `object` if the existing value is not equivalent - * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * for equality comparisons. + * The base implementation of `_.isTypedArray` without Node.js optimizations. * * @private - * @param {Object} object The object to modify. - * @param {string} key The key of the property to assign. - * @param {*} value The value to assign. + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. */ -function assignValue(object, key, value) { - var objValue = object[key]; - if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || - (value === undefined && !(key in object))) { - object[key] = value; - } +function baseIsTypedArray(value) { + return isObjectLike(value) && + isLength(value.length) && !!typedArrayTags[objectToString.call(value)]; } /** @@ -1397,6 +2307,137 @@ function baseKeys(object) { } /** + * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeysIn(object) { + if (!isObject(object)) { + return nativeKeysIn(object); + } + var isProto = isPrototype(object), + result = []; + + for (var key in object) { + if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { + result.push(key); + } + } + return result; +} + +/** + * The base implementation of `_.merge` without support for multiple sources. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. + * @param {Function} [customizer] The function to customize merged values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ +function baseMerge(object, source, srcIndex, customizer, stack) { + if (object === source) { + return; + } + if (!(isArray(source) || isTypedArray(source))) { + var props = baseKeysIn(source); + } + arrayEach(props || source, function(srcValue, key) { + if (props) { + key = srcValue; + srcValue = source[key]; + } + if (isObject(srcValue)) { + stack || (stack = new Stack); + baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack); + } + else { + var newValue = customizer + ? customizer(object[key], srcValue, (key + ''), object, source, stack) + : undefined; + + if (newValue === undefined) { + newValue = srcValue; + } + assignMergeValue(object, key, newValue); + } + }); +} + +/** + * A specialized version of `baseMerge` for arrays and objects which performs + * deep merges and tracks traversed objects enabling objects with circular + * references to be merged. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. + * @param {Function} mergeFunc The function to merge values. + * @param {Function} [customizer] The function to customize assigned values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ +function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) { + var objValue = object[key], + srcValue = source[key], + stacked = stack.get(srcValue); + + if (stacked) { + assignMergeValue(object, key, stacked); + return; + } + var newValue = customizer + ? customizer(objValue, srcValue, (key + ''), object, source, stack) + : undefined; + + var isCommon = newValue === undefined; + + if (isCommon) { + newValue = srcValue; + if (isArray(srcValue) || isTypedArray(srcValue)) { + if (isArray(objValue)) { + newValue = objValue; + } + else if (isArrayLikeObject(objValue)) { + newValue = copyArray(objValue); + } + else { + isCommon = false; + newValue = baseClone(srcValue, true); + } + } + else if (isPlainObject(srcValue) || isArguments(srcValue)) { + if (isArguments(objValue)) { + newValue = toPlainObject(objValue); + } + else if (!isObject(objValue) || (srcIndex && isFunction(objValue))) { + isCommon = false; + newValue = baseClone(srcValue, true); + } + else { + newValue = objValue; + } + } + else { + isCommon = false; + } + } + if (isCommon) { + // Recursively merge objects and arrays (susceptible to call stack limits). + stack.set(srcValue, newValue); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); + stack['delete'](srcValue); + } + assignMergeValue(object, key, newValue); +} + +/** * The base implementation of `_.rest` which doesn't validate or coerce arguments. * * @private @@ -1426,6 +2467,133 @@ function baseRest(func, start) { } /** + * Creates a clone of `buffer`. + * + * @private + * @param {Buffer} buffer The buffer to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Buffer} Returns the cloned buffer. + */ +function cloneBuffer(buffer, isDeep) { + if (isDeep) { + return buffer.slice(); + } + var result = new buffer.constructor(buffer.length); + buffer.copy(result); + return result; +} + +/** + * Creates a clone of `arrayBuffer`. + * + * @private + * @param {ArrayBuffer} arrayBuffer The array buffer to clone. + * @returns {ArrayBuffer} Returns the cloned array buffer. + */ +function cloneArrayBuffer(arrayBuffer) { + var result = new arrayBuffer.constructor(arrayBuffer.byteLength); + new Uint8Array(result).set(new Uint8Array(arrayBuffer)); + return result; +} + +/** + * Creates a clone of `dataView`. + * + * @private + * @param {Object} dataView The data view to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned data view. + */ +function cloneDataView(dataView, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer; + return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength); +} + +/** + * Creates a clone of `map`. + * + * @private + * @param {Object} map The map to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned map. + */ +function cloneMap(map, isDeep, cloneFunc) { + var array = isDeep ? cloneFunc(mapToArray(map), true) : mapToArray(map); + return arrayReduce(array, addMapEntry, new map.constructor); +} + +/** + * Creates a clone of `regexp`. + * + * @private + * @param {Object} regexp The regexp to clone. + * @returns {Object} Returns the cloned regexp. + */ +function cloneRegExp(regexp) { + var result = new regexp.constructor(regexp.source, reFlags.exec(regexp)); + result.lastIndex = regexp.lastIndex; + return result; +} + +/** + * Creates a clone of `set`. + * + * @private + * @param {Object} set The set to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned set. + */ +function cloneSet(set, isDeep, cloneFunc) { + var array = isDeep ? cloneFunc(setToArray(set), true) : setToArray(set); + return arrayReduce(array, addSetEntry, new set.constructor); +} + +/** + * Creates a clone of the `symbol` object. + * + * @private + * @param {Object} symbol The symbol object to clone. + * @returns {Object} Returns the cloned symbol object. + */ +function cloneSymbol(symbol) { + return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {}; +} + +/** + * Creates a clone of `typedArray`. + * + * @private + * @param {Object} typedArray The typed array to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned typed array. + */ +function cloneTypedArray(typedArray, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer; + return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length); +} + +/** + * Copies the values of `source` to `array`. + * + * @private + * @param {Array} source The array to copy values from. + * @param {Array} [array=[]] The array to copy values to. + * @returns {Array} Returns `array`. + */ +function copyArray(source, array) { + var index = -1, + length = source.length; + + array || (array = Array(length)); + while (++index < length) { + array[index] = source[index]; + } + return array; +} + +/** * Copies properties of `source` to `object`. * * @private @@ -1454,6 +2622,18 @@ function copyObject(source, props, object, customizer) { } /** + * Copies own symbol properties of `source` to `object`. + * + * @private + * @param {Object} source The object to copy symbols from. + * @param {Object} [object={}] The object to copy symbols to. + * @returns {Object} Returns `object`. + */ +function copySymbols(source, object) { + return copyObject(source, getSymbols(source), object); +} + +/** * Creates a function like `_.assign`. * * @private @@ -1487,6 +2667,169 @@ function createAssigner(assigner) { } /** + * Creates an array of own enumerable property names and symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names and symbols. + */ +function getAllKeys(object) { + return baseGetAllKeys(object, keys, getSymbols); +} + +/** + * Gets the data for `map`. + * + * @private + * @param {Object} map The map to query. + * @param {string} key The reference key. + * @returns {*} Returns the map data. + */ +function getMapData(map, key) { + var data = map.__data__; + return isKeyable(key) + ? data[typeof key == 'string' ? 'string' : 'hash'] + : data.map; +} + +/** + * Gets the native function at `key` of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {string} key The key of the method to get. + * @returns {*} Returns the function if it's native, else `undefined`. + */ +function getNative(object, key) { + var value = getValue(object, key); + return baseIsNative(value) ? value : undefined; +} + +/** + * Creates an array of the own enumerable symbol properties of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of symbols. + */ +var getSymbols = nativeGetSymbols ? overArg(nativeGetSymbols, Object) : stubArray; + +/** + * Gets the `toStringTag` of `value`. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ +var getTag = baseGetTag; + +// Fallback for data views, maps, sets, and weak maps in IE 11, +// for data views in Edge < 14, and promises in Node.js. +if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) || + (Map && getTag(new Map) != mapTag) || + (Promise && getTag(Promise.resolve()) != promiseTag) || + (Set && getTag(new Set) != setTag) || + (WeakMap && getTag(new WeakMap) != weakMapTag)) { + getTag = function(value) { + var result = objectToString.call(value), + Ctor = result == objectTag ? value.constructor : undefined, + ctorString = Ctor ? toSource(Ctor) : undefined; + + if (ctorString) { + switch (ctorString) { + case dataViewCtorString: return dataViewTag; + case mapCtorString: return mapTag; + case promiseCtorString: return promiseTag; + case setCtorString: return setTag; + case weakMapCtorString: return weakMapTag; + } + } + return result; + }; +} + +/** + * Initializes an array clone. + * + * @private + * @param {Array} array The array to clone. + * @returns {Array} Returns the initialized clone. + */ +function initCloneArray(array) { + var length = array.length, + result = array.constructor(length); + + // Add properties assigned by `RegExp#exec`. + if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) { + result.index = array.index; + result.input = array.input; + } + return result; +} + +/** + * Initializes an object clone. + * + * @private + * @param {Object} object The object to clone. + * @returns {Object} Returns the initialized clone. + */ +function initCloneObject(object) { + return (typeof object.constructor == 'function' && !isPrototype(object)) + ? baseCreate(getPrototype(object)) + : {}; +} + +/** + * Initializes an object clone based on its `toStringTag`. + * + * **Note:** This function only supports cloning values with tags of + * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`. + * + * @private + * @param {Object} object The object to clone. + * @param {string} tag The `toStringTag` of the object to clone. + * @param {Function} cloneFunc The function to clone values. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the initialized clone. + */ +function initCloneByTag(object, tag, cloneFunc, isDeep) { + var Ctor = object.constructor; + switch (tag) { + case arrayBufferTag: + return cloneArrayBuffer(object); + + case boolTag: + case dateTag: + return new Ctor(+object); + + case dataViewTag: + return cloneDataView(object, isDeep); + + case float32Tag: case float64Tag: + case int8Tag: case int16Tag: case int32Tag: + case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag: + return cloneTypedArray(object, isDeep); + + case mapTag: + return cloneMap(object, isDeep, cloneFunc); + + case numberTag: + case stringTag: + return new Ctor(object); + + case regexpTag: + return cloneRegExp(object); + + case setTag: + return cloneSet(object, isDeep, cloneFunc); + + case symbolTag: + return cloneSymbol(object); + } +} + +/** * Checks if `value` is a valid array-like index. * * @private @@ -1526,6 +2869,31 @@ function isIterateeCall(value, index, object) { } /** + * Checks if `value` is suitable for use as unique object key. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is suitable, else `false`. + */ +function isKeyable(value) { + var type = typeof value; + return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean') + ? (value !== '__proto__') + : (value === null); +} + +/** + * Checks if `func` has its source masked. + * + * @private + * @param {Function} func The function to check. + * @returns {boolean} Returns `true` if `func` is masked, else `false`. + */ +function isMasked(func) { + return !!maskSrcKey && (maskSrcKey in func); +} + +/** * Checks if `value` is likely a prototype object. * * @private @@ -1540,6 +2908,44 @@ function isPrototype(value) { } /** + * This function is like + * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * except that it includes inherited enumerable properties. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function nativeKeysIn(object) { + var result = []; + if (object != null) { + for (var key in Object(object)) { + result.push(key); + } + } + return result; +} + +/** + * Converts `func` to its source code. + * + * @private + * @param {Function} func The function to process. + * @returns {string} Returns the source code. + */ +function toSource(func) { + if (func != null) { + try { + return funcToString.call(func); + } catch (e) {} + try { + return (func + ''); + } catch (e) {} + } + return ''; +} + +/** * Performs a * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) * comparison between two values to determine if they are equivalent. @@ -1672,15 +3078,34 @@ function isArrayLike(value) { * _.isArrayLikeObject(document.body.children); * // => true * - * _.isArrayLikeObject('abc'); - * // => false + * _.isArrayLikeObject('abc'); + * // => false + * + * _.isArrayLikeObject(_.noop); + * // => false + */ +function isArrayLikeObject(value) { + return isObjectLike(value) && isArrayLike(value); +} + +/** + * Checks if `value` is a buffer. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a buffer, else `false`. + * @example + * + * _.isBuffer(new Buffer(2)); + * // => true * - * _.isArrayLikeObject(_.noop); + * _.isBuffer(new Uint8Array(2)); * // => false */ -function isArrayLikeObject(value) { - return isObjectLike(value) && isArrayLike(value); -} +var isBuffer = nativeIsBuffer || stubFalse; /** * Checks if `value` is classified as a `Function` object. @@ -1796,48 +3221,93 @@ function isObjectLike(value) { } /** - * Assigns own enumerable string keyed properties of source objects to the - * destination object. Source objects are applied from left to right. - * Subsequent sources overwrite property assignments of previous sources. - * - * **Note:** This method mutates `object` and is loosely based on - * [`Object.assign`](https://mdn.io/Object/assign). + * Checks if `value` is a plain object, that is, an object created by the + * `Object` constructor or one with a `[[Prototype]]` of `null`. * * @static * @memberOf _ - * @since 0.10.0 - * @category Object - * @param {Object} object The destination object. - * @param {...Object} [sources] The source objects. - * @returns {Object} Returns `object`. - * @see _.assignIn + * @since 0.8.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. * @example * * function Foo() { * this.a = 1; * } * - * function Bar() { - * this.c = 3; - * } + * _.isPlainObject(new Foo); + * // => false * - * Foo.prototype.b = 2; - * Bar.prototype.d = 4; + * _.isPlainObject([1, 2, 3]); + * // => false + * + * _.isPlainObject({ 'x': 0, 'y': 0 }); + * // => true * - * _.assign({ 'a': 0 }, new Foo, new Bar); - * // => { 'a': 1, 'c': 3 } + * _.isPlainObject(Object.create(null)); + * // => true */ -var assign = createAssigner(function(object, source) { - if (nonEnumShadows || isPrototype(source) || isArrayLike(source)) { - copyObject(source, keys(source), object); - return; +function isPlainObject(value) { + if (!isObjectLike(value) || + objectToString.call(value) != objectTag || isHostObject(value)) { + return false; } - for (var key in source) { - if (hasOwnProperty.call(source, key)) { - assignValue(object, key, source[key]); - } + var proto = getPrototype(value); + if (proto === null) { + return true; } -}); + var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; + return (typeof Ctor == 'function' && + Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString); +} + +/** + * Checks if `value` is classified as a typed array. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. + * @example + * + * _.isTypedArray(new Uint8Array); + * // => true + * + * _.isTypedArray([]); + * // => false + */ +var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray; + +/** + * Converts `value` to a plain object flattening inherited enumerable string + * keyed properties of `value` to own properties of the plain object. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {Object} Returns the converted plain object. + * @example + * + * function Foo() { + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.assign({ 'a': 1 }, new Foo); + * // => { 'a': 1, 'b': 2 } + * + * _.assign({ 'a': 1 }, _.toPlainObject(new Foo)); + * // => { 'a': 1, 'b': 2, 'c': 3 } + */ +function toPlainObject(value) { + return copyObject(value, keysIn(value)); +} /** * Creates an array of the own enumerable property names of `object`. @@ -1871,8 +3341,110 @@ function keys(object) { return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); } -module.exports = assign; +/** + * Creates an array of the own and inherited enumerable property names of `object`. + * + * **Note:** Non-object values are coerced to objects. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.keysIn(new Foo); + * // => ['a', 'b', 'c'] (iteration order is not guaranteed) + */ +function keysIn(object) { + return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object); +} + +/** + * This method is like `_.assign` except that it recursively merges own and + * inherited enumerable string keyed properties of source objects into the + * destination object. Source properties that resolve to `undefined` are + * skipped if a destination value exists. Array and plain object properties + * are merged recursively. Other objects and value types are overridden by + * assignment. Source objects are applied from left to right. Subsequent + * sources overwrite property assignments of previous sources. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 0.5.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @example + * + * var object = { + * 'a': [{ 'b': 2 }, { 'd': 4 }] + * }; + * + * var other = { + * 'a': [{ 'c': 3 }, { 'e': 5 }] + * }; + * + * _.merge(object, other); + * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] } + */ +var merge = createAssigner(function(object, source, srcIndex) { + baseMerge(object, source, srcIndex); +}); + +/** + * This method returns a new empty array. + * + * @static + * @memberOf _ + * @since 4.13.0 + * @category Util + * @returns {Array} Returns the new empty array. + * @example + * + * var arrays = _.times(2, _.stubArray); + * + * console.log(arrays); + * // => [[], []] + * + * console.log(arrays[0] === arrays[1]); + * // => false + */ +function stubArray() { + return []; +} + +/** + * This method returns `false`. + * + * @static + * @memberOf _ + * @since 4.13.0 + * @category Util + * @returns {boolean} Returns `false`. + * @example + * + * _.times(2, _.stubFalse); + * // => [false, false] + */ +function stubFalse() { + return false; +} + +module.exports = merge; +}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) },{}],3:[function(require,module,exports){ (function () { 'use strict'; @@ -2061,203 +3633,34 @@ module.exports = function(digest, string, salt) { }; },{"unibabel":3,"unibabel/unibabel.hex":4}],6:[function(require,module,exports){ -var v1 = require("./v1"); -var v2 = require("./v2"); var hmac = require("./hmac"); - -module.exports = { - generatePassword: function(site, login, masterPassword, options) { - if (typeof options !== "undefined" && options.version === 1) { - return v1.generatePassword(site, login, masterPassword, options); - } - return v2.generatePassword(site, login, masterPassword, options); +var pbkdf2 = require("./pbkdf2"); +var bigInt = require("big-integer"); +var merge = require("lodash.merge"); + +var defaultProfile = { + site: '', + login: '', + options: { + uppercase: true, + lowercase: true, + digits: true, + symbols: true, + length: 16, + counter: 1 }, - createFingerprint: function(str) { - return hmac("sha256", str); + crypto: { + method: 'pbkdf2', + iterations: 100000, + keylen: 32, + digest: "sha256" } }; -},{"./hmac":5,"./v1":8,"./v2":9}],7:[function(require,module,exports){ -require("unibabel"); -require("unibabel/unibabel.hex"); - -module.exports = function(password, salt, iterations, keylen, digest) { - var algorithms = { - sha1: "SHA-1", - "sha-1": "SHA-1", - sha256: "SHA-256", - "sha-256": "SHA-256", - sha512: "SHA-512", - "sha-512": "SHA-512" - }; - return window.crypto.subtle - .importKey("raw", Unibabel.utf8ToBuffer(password), "PBKDF2", false, [ - "deriveKey" - ]) - .then(function(key) { - var algo = { - name: "PBKDF2", - salt: Unibabel.utf8ToBuffer(salt), - iterations: iterations, - hash: algorithms[digest.toLowerCase()] - }; - return window.crypto.subtle.deriveKey( - algo, - key, - { - name: "AES-CTR", - length: keylen * 8 - }, - true, - ["encrypt", "decrypt"] - ); - }) - .then(function(derivedKey) { - return window.crypto.subtle - .exportKey("raw", derivedKey) - .then(function(keyArray) { - return Unibabel.bufferToHex(new Uint8Array(keyArray)); - }); - }); -}; - -},{"unibabel":3,"unibabel/unibabel.hex":4}],8:[function(require,module,exports){ -var pbkdf2 = require("./pbkdf2"); -var assign = require("lodash.assign"); -var hmac = require("./hmac"); - -module.exports = { - generatePassword: generatePassword, - _renderPassword: renderPassword, - _createHmac: createHmac, - _deriveEncryptedLogin: deriveEncryptedLogin, - _getPasswordTemplate: getPasswordTemplate, - _prettyPrint: prettyPrint, - _string2charCodes: string2charCodes, - _getCharType: getCharType, - _getPasswordChar: getPasswordChar -}; - -var defaultOptions = { - version: 1, - lowercase: true, - numbers: true, - uppercase: true, - symbols: true, - keylen: 32, - digest: "sha256", - length: 12, - counter: 1, - iterations: 8192 -}; - -function generatePassword(site, login, masterPassword, options) { - var _options = assign({}, defaultOptions, options); - return pbkdf2( - masterPassword, - login, - _options.iterations, - _options.keylen, - "sha256" - ).then(function(encryptedLogin) { - return renderPassword(encryptedLogin, site, _options).then(function( - generatedPassword - ) { - return generatedPassword; - }); - }); -} - -function renderPassword(encryptedLogin, site, passwordOptions) { - return deriveEncryptedLogin( - encryptedLogin, - site, - passwordOptions - ).then(function(derivedEncryptedLogin) { - var template = - passwordOptions.template || getPasswordTemplate(passwordOptions); - return prettyPrint(derivedEncryptedLogin, template); - }); -} - -function createHmac(encryptedLogin, salt) { - return new Promise(function(resolve) { - resolve(hmac("sha256", encryptedLogin, salt)); - }); -} - -function deriveEncryptedLogin(encryptedLogin, site, options) { - var _options = options !== undefined ? options : {}; - var length = _options.length || 12; - var counter = _options.counter || 1; - - var salt = site + counter.toString(); - return createHmac(encryptedLogin, salt).then(function(derivedHash) { - return derivedHash.substring(0, length); - }); -} - -function getPasswordTemplate(passwordTypes) { - var templates = { - lowercase: "vc", - uppercase: "VC", - numbers: "n", - symbols: "s" - }; - var returnedTemplate = ""; - Object.keys(templates).forEach(function(template) { - if (passwordTypes.hasOwnProperty(template) && passwordTypes[template]) { - returnedTemplate += templates[template]; - } - }); - return returnedTemplate; -} - -function prettyPrint(hash, template) { - var password = ""; - - string2charCodes(hash).forEach(function(charCode, index) { - var charType = getCharType(template, index); - password += getPasswordChar(charType, charCode); - }); - return password; -} - -function string2charCodes(text) { - var charCodes = []; - for (var i = 0; i < text.length; i++) { - charCodes.push(text.charCodeAt(i)); - } - return charCodes; -} - -function getCharType(template, index) { - return template[index % template.length]; -} - -function getPasswordChar(charType, index) { - var passwordsChars = { - V: "AEIOUY", - C: "BCDFGHJKLMNPQRSTVWXZ", - v: "aeiouy", - c: "bcdfghjklmnpqrstvwxz", - A: "AEIOUYBCDFGHJKLMNPQRSTVWXZ", - a: "AEIOUYaeiouyBCDFGHJKLMNPQRSTVWXZbcdfghjklmnpqrstvwxz", - n: "0123456789", - s: "@&%?,=[]_:-+*$#!'^~;()/.", - x: "AEIOUYaeiouyBCDFGHJKLMNPQRSTVWXZbcdfghjklmnpqrstvwxz0123456789@&%?,=[]_:-+*$#!'^~;()/." - }; - var passwordChar = passwordsChars[charType]; - return passwordChar[index % passwordChar.length]; -} - -},{"./hmac":5,"./pbkdf2":7,"lodash.assign":2}],9:[function(require,module,exports){ -var pbkdf2 = require("./pbkdf2"); -var bigInt = require("big-integer"); -var assign = require("lodash.assign"); - module.exports = { generatePassword: generatePassword, + createFingerprint: createFingerprint, + isSupported: isSupported, _calcEntropy: calcEntropy, _consumeEntropy: consumeEntropy, _getSetOfCharacters: getSetOfCharacters, @@ -2267,43 +3670,46 @@ module.exports = { _renderPassword: renderPassword }; -var defaultOptions = { - version: 2, - lowercase: true, - numbers: true, - uppercase: true, - symbols: true, - keylen: 32, - digest: "sha256", - length: 16, - counter: 1, - iterations: 100000 -}; +function generatePassword(profile, masterPassword) { + var _profile = merge({}, defaultProfile, profile); + return calcEntropy(_profile, masterPassword) + .then(function(entropy) { + return renderPassword(entropy, _profile.options); + }); +} -function generatePassword(site, login, masterPassword, options) { - var _options = assign({}, defaultOptions, options); - return calcEntropy(site, login, masterPassword, _options).then(function( - entropy - ) { - return renderPassword(entropy, _options); - }); +function createFingerprint(str) { + return hmac("sha256", str); +} + +function isSupported() { + try { + var simpleProfile = merge({}, defaultProfile, {crypto: {iterations: 1}}); + return generatePassword(simpleProfile, 'LessPass') + .then(function(generatedPassword) { + return generatedPassword == "n'LTsjPA#3E$e*2'"; + }); + } catch (e) { + console.error(e); + return Promise.resolve(false); + } } -function calcEntropy(site, login, masterPassword, passwordProfile) { - var salt = site + login + passwordProfile.counter.toString(16); +function calcEntropy(profile, masterPassword) { + var salt = profile.site + profile.login + profile.options.counter.toString(16); return pbkdf2( masterPassword, salt, - passwordProfile.iterations, - passwordProfile.keylen, - passwordProfile.digest + profile.crypto.iterations, + profile.crypto.keylen, + profile.crypto.digest ); } var characterSubsets = { lowercase: "abcdefghijklmnopqrstuvwxyz", uppercase: "ABCDEFGHIJKLMNOPQRSTUVWXYZ", - numbers: "0123456789", + digits: "0123456789", symbols: "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~" }; @@ -2312,7 +3718,7 @@ function getSetOfCharacters(rules) { return ( characterSubsets.lowercase + characterSubsets.uppercase + - characterSubsets.numbers + + characterSubsets.digits + characterSubsets.symbols ); } @@ -2323,14 +3729,12 @@ function getSetOfCharacters(rules) { return setOfChars; } -function consumeEntropy( - generatedPassword, - quotient, - setOfCharacters, - maxLength -) { +function consumeEntropy(generatedPassword, + quotient, + setOfCharacters, + maxLength) { if (generatedPassword.length >= maxLength) { - return { value: generatedPassword, entropy: quotient }; + return {value: generatedPassword, entropy: quotient}; } var longDivision = quotient.divmod(setOfCharacters.length); generatedPassword += setOfCharacters[longDivision.remainder]; @@ -2361,13 +3765,11 @@ function getOneCharPerRule(entropy, rules) { oneCharPerRules += password.value; entropy = password.entropy; }); - return { value: oneCharPerRules, entropy: entropy }; + return {value: oneCharPerRules, entropy: entropy}; } function getConfiguredRules(passwordProfile) { - return ["lowercase", "uppercase", "numbers", "symbols"].filter(function( - rule - ) { + return ["lowercase", "uppercase", "digits", "symbols"].filter(function(rule) { return passwordProfile[rule]; }); } @@ -2389,5 +3791,49 @@ function renderPassword(entropy, passwordProfile) { ); } -},{"./pbkdf2":7,"big-integer":1,"lodash.assign":2}]},{},[6])(6) +},{"./hmac":5,"./pbkdf2":7,"big-integer":1,"lodash.merge":2}],7:[function(require,module,exports){ +require("unibabel"); +require("unibabel/unibabel.hex"); + +module.exports = function(password, salt, iterations, keylen, digest) { + var algorithms = { + sha1: "SHA-1", + "sha-1": "SHA-1", + sha256: "SHA-256", + "sha-256": "SHA-256", + sha512: "SHA-512", + "sha-512": "SHA-512" + }; + return window.crypto.subtle + .importKey("raw", Unibabel.utf8ToBuffer(password), "PBKDF2", false, [ + "deriveKey" + ]) + .then(function(key) { + var algo = { + name: "PBKDF2", + salt: Unibabel.utf8ToBuffer(salt), + iterations: iterations, + hash: algorithms[digest.toLowerCase()] + }; + return window.crypto.subtle.deriveKey( + algo, + key, + { + name: "AES-CTR", + length: keylen * 8 + }, + true, + ["encrypt", "decrypt"] + ); + }) + .then(function(derivedKey) { + return window.crypto.subtle + .exportKey("raw", derivedKey) + .then(function(keyArray) { + return Unibabel.bufferToHex(new Uint8Array(keyArray)); + }); + }); +}; + +},{"unibabel":3,"unibabel/unibabel.hex":4}]},{},[6])(6) }); \ No newline at end of file diff --git a/dist/lesspass.min.js b/dist/lesspass.min.js index 94a699b..c633f1a 100644 --- a/dist/lesspass.min.js +++ b/dist/lesspass.min.js @@ -1 +1 @@ -!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).LessPass=t()}}(function(){return function t(r,e,n){function o(u,a){if(!e[u]){if(!r[u]){var s="function"==typeof require&&require;if(!a&&s)return s(u,!0);if(i)return i(u,!0);var f=new Error("Cannot find module '"+u+"'");throw f.code="MODULE_NOT_FOUND",f}var p=e[u]={exports:{}};r[u][0].call(p.exports,function(t){var e=r[u][1][t];return o(e||t)},p,p.exports,t,r,e,n)}return e[u].exports}for(var i="function"==typeof require&&require,u=0;u0?Math.floor(t):Math.ceil(t)}function l(t,r){var e,n,o=t.length,i=r.length,u=new Array(o),a=0,s=K;for(n=0;n=s?1:0,u[n]=e-a*s;for(;n0&&u.push(a),u}function c(t,r){return t.length>=r.length?l(t,r):l(r,t)}function h(t,r){var e,n,o=t.length,i=new Array(o),u=K;for(n=0;n0;)i[n++]=r%u,r=Math.floor(r/u);return i}function v(t,r){var e,n,o=t.length,i=r.length,u=new Array(o),a=0,f=K;for(e=0;e=0?i=v(t,r):(i=v(r,t),n=!n),i=a(i),"number"==typeof i?(n&&(i=-i),new o(i)):new e(i,n)}function g(t,r,n){var i,u,s=t.length,f=new Array(s),p=-r,l=K;for(i=0;i0;)i[n++]=a%u,a=Math.floor(a/u);return i}function m(t,r){for(var e=[];r-- >0;)e.push(0);return e.concat(t)}function w(t,r){var e=Math.max(t.length,r.length);if(e<=30)return d(t,r);e=Math.ceil(e/2);var n=t.slice(e),o=t.slice(0,e),i=r.slice(e),u=r.slice(0,e),a=w(o,u),f=w(n,i),p=c(c(a,m(v(v(w(c(o,n),c(u,i)),a),f),e)),m(f,2*e));return s(p),p}function S(t,r){return-.012*t-.012*r+15e-6*t*r>0}function A(t,r,n){return t=0;n--){for(e=h-1,d[n+c]!==y&&(e=Math.floor((d[n+c]*h+d[n+c-1])/y)),o=0,i=0,s=m.length,u=0;up&&(o=(o+1)*h),e=Math.ceil(o/i);do{if(u=b(r,e),O(u,c)<=0)break;e--}while(e);l.push(e),c=v(c,u)}return l.reverse(),[a(l),a(c)]}function x(t,r){var e,n,o,i,u=t.length,a=f(u),s=K;for(o=0,e=u-1;e>=0;--e)o=(i=o*s+t[e])-(n=p(i/r))*r,a[e]=0|n;return[a,0|o]}function P(t,n){var i,s,f=F(n),l=t.value,c=f.value;if(0===c)throw new Error("Cannot divide by zero");if(t.isSmall)return f.isSmall?[new o(p(l/c)),new o(l%c)]:[r[0],t];if(f.isSmall){if(1===c)return[t,r[0]];if(-1==c)return[t.negate(),r[0]];var h=Math.abs(c);if(hr.length?1:-1;for(var e=t.length-1;e>=0;e--)if(t[e]!==r[e])return t[e]>r[e]?1:-1;return 0}function C(t){var r=t.abs();return!r.isUnit()&&(!!(r.equals(2)||r.equals(3)||r.equals(5))||!(r.isEven()||r.isDivisibleBy(3)||r.isDivisibleBy(5))&&(!!r.lesser(25)||void 0))}function T(t){return("number"==typeof t||"string"==typeof t)&&+Math.abs(t)<=K||t instanceof e&&t.value.length<=1}function U(t,r,e){r=F(r);for(var o=t.isNegative(),i=r.isNegative(),u=o?t.not():t,a=i?r.not():r,s=[],f=[],p=!1,l=!1;!p||!l;)u.isZero()?(p=!0,s.push(o?1:0)):o?s.push(u.isEven()?1:0):s.push(u.isEven()?0:1),a.isZero()?(l=!0,f.push(i?1:0)):i?f.push(a.isEven()?1:0):f.push(a.isEven()?0:1),u=u.over(2),a=a.over(2);for(var c=[],h=0;h=0;f--){var l=s?i.value[f]:K,c=p(Math.random()*l);u.unshift(c),c=0;o--)i=i.add(t[o].times(u)),u=u.times(e);return n?i.negate():i}function Z(t){var r=t.value;return"number"==typeof r&&(r=[r]),1===r.length&&r[0]<=35?"0123456789abcdefghijklmnopqrstuvwxyz".charAt(r[0]):"<"+r+">"}function L(t,r){if((r=n(r)).isZero()){if(t.isZero())return"0";throw new Error("Cannot convert nonzero numbers to base 0.")}if(r.equals(-1))return t.isZero()?"0":t.isNegative()?new Array(1-t).join("10"):"1"+new Array(+t).join("01");var e="";if(t.isNegative()&&r.isPositive()&&(e="-",t=t.abs()),r.equals(1))return t.isZero()?"0":e+new Array(+t+1).join(1);for(var o,i=[],u=t;u.isNegative()||u.compareAbs(r)>=0;){u=(o=u.divmod(r)).quotient;var a=o.remainder;a.isNegative()&&(a=r.minus(a).abs(),u=u.next()),i.push(Z(a))}return i.push(Z(u)),e+i.reverse().join("")}function R(t){if(i(+t)){var r=+t;if(r===p(r))return new o(r);throw"Invalid integer: "+t}var n="-"===t[0];n&&(t=t.slice(1));var u=t.split(/e/i);if(u.length>2)throw new Error("Invalid integer: "+u.join("e"));if(2===u.length){var a=u[1];if("+"===a[0]&&(a=a.slice(1)),(a=+a)!==p(a)||!i(a))throw new Error("Invalid integer: "+a+" is not a valid exponent.");var f=u[0],l=f.indexOf(".");if(l>=0&&(a-=f.length-l-1,f=f.slice(0,l)+f.slice(l+1)),a<0)throw new Error("Cannot include negative exponent part for integers");t=f+=new Array(a+1).join("0")}if(!/^([0-9][0-9]*)$/.test(t))throw new Error("Invalid integer: "+t);for(var c=[],h=t.length,v=z,y=h-v;h>0;)c.push(+t.slice(y,h)),(y-=v)<0&&(y=0),h-=v;return s(c),new e(c,n)}function D(t){if(i(t)){if(t!==p(t))throw new Error(t+" is not an integer.");return new o(t)}return R(t.toString())}function F(t){return"number"==typeof t?D(t):"string"==typeof t?R(t):t}var K=1e7,z=7,J=9007199254740992,V=u(J),G=Math.log(J);e.prototype=Object.create(r.prototype),o.prototype=Object.create(r.prototype),e.prototype.add=function(t){var r=F(t);if(this.sign!==r.sign)return this.subtract(r.negate());var n=this.value,o=r.value;return r.isSmall?new e(h(n,Math.abs(o)),this.sign):new e(c(n,o),this.sign)},e.prototype.plus=e.prototype.add,o.prototype.add=function(t){var r=F(t),n=this.value;if(n<0!==r.sign)return this.subtract(r.negate());var a=r.value;if(r.isSmall){if(i(n+a))return new o(n+a);a=u(Math.abs(a))}return new e(h(a,Math.abs(n)),n<0)},o.prototype.plus=o.prototype.add,e.prototype.subtract=function(t){var r=F(t);if(this.sign!==r.sign)return this.add(r.negate());var e=this.value,n=r.value;return r.isSmall?g(e,Math.abs(n),this.sign):y(e,n,this.sign)},e.prototype.minus=e.prototype.subtract,o.prototype.subtract=function(t){var r=F(t),e=this.value;if(e<0!==r.sign)return this.add(r.negate());var n=r.value;return r.isSmall?new o(e-n):g(n,Math.abs(e),e>=0)},o.prototype.minus=o.prototype.subtract,e.prototype.negate=function(){return new e(this.value,!this.sign)},o.prototype.negate=function(){var t=this.sign,r=new o(-this.value);return r.sign=!t,r},e.prototype.abs=function(){return new e(this.value,!1)},o.prototype.abs=function(){return new o(Math.abs(this.value))},e.prototype.multiply=function(t){var n,o=F(t),i=this.value,a=o.value,s=this.sign!==o.sign;if(o.isSmall){if(0===a)return r[0];if(1===a)return this;if(-1===a)return this.negate();if((n=Math.abs(a))n?1:-1):-1},e.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var r=F(t),e=this.value,n=r.value;return this.sign!==r.sign?r.sign?1:-1:r.isSmall?this.sign?-1:1:O(e,n)*(this.sign?-1:1)},e.prototype.compareTo=e.prototype.compare,o.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var r=F(t),e=this.value,n=r.value;return r.isSmall?e==n?0:e>n?1:-1:e<0!==r.sign?e<0?-1:1:e<0?1:-1},o.prototype.compareTo=o.prototype.compare,e.prototype.equals=function(t){return 0===this.compare(t)},o.prototype.eq=o.prototype.equals=e.prototype.eq=e.prototype.equals,e.prototype.notEquals=function(t){return 0!==this.compare(t)},o.prototype.neq=o.prototype.notEquals=e.prototype.neq=e.prototype.notEquals,e.prototype.greater=function(t){return this.compare(t)>0},o.prototype.gt=o.prototype.greater=e.prototype.gt=e.prototype.greater,e.prototype.lesser=function(t){return this.compare(t)<0},o.prototype.lt=o.prototype.lesser=e.prototype.lt=e.prototype.lesser,e.prototype.greaterOrEquals=function(t){return this.compare(t)>=0},o.prototype.geq=o.prototype.greaterOrEquals=e.prototype.geq=e.prototype.greaterOrEquals,e.prototype.lesserOrEquals=function(t){return this.compare(t)<=0},o.prototype.leq=o.prototype.lesserOrEquals=e.prototype.leq=e.prototype.lesserOrEquals,e.prototype.isEven=function(){return 0==(1&this.value[0])},o.prototype.isEven=function(){return 0==(1&this.value)},e.prototype.isOdd=function(){return 1==(1&this.value[0])},o.prototype.isOdd=function(){return 1==(1&this.value)},e.prototype.isPositive=function(){return!this.sign},o.prototype.isPositive=function(){return this.value>0},e.prototype.isNegative=function(){return this.sign},o.prototype.isNegative=function(){return this.value<0},e.prototype.isUnit=function(){return!1},o.prototype.isUnit=function(){return 1===Math.abs(this.value)},e.prototype.isZero=function(){return!1},o.prototype.isZero=function(){return 0===this.value},e.prototype.isDivisibleBy=function(t){var e=F(t),n=e.value;return 0!==n&&(1===n||(2===n?this.isEven():this.mod(e).equals(r[0])))},o.prototype.isDivisibleBy=e.prototype.isDivisibleBy,e.prototype.isPrime=function(){var t=C(this);if(void 0!==t)return t;for(var e,o,i,u,a=this.abs(),s=a.prev(),f=[2,3,5,7,11,13,17,19],p=s;p.isEven();)p=p.divide(2);for(i=0;i-J?new o(t-1):new e(V,!0)};for(var Q=[1];Q[Q.length-1]<=K;)Q.push(2*Q[Q.length-1]);var W=Q.length,X=Q[W-1];e.prototype.shiftLeft=function(t){if(!T(t))throw new Error(String(t)+" is too large for shifting.");if((t=+t)<0)return this.shiftRight(-t);for(var r=this;t>=W;)r=r.multiply(X),t-=W-1;return r.multiply(Q[t])},o.prototype.shiftLeft=e.prototype.shiftLeft,e.prototype.shiftRight=function(t){var r;if(!T(t))throw new Error(String(t)+" is too large for shifting.");if((t=+t)<0)return this.shiftLeft(-t);for(var e=this;t>=W;){if(e.isZero())return e;e=(r=P(e,X))[1].isNegative()?r[0].prev():r[0],t-=W-1}return r=P(e,Q[t]),r[1].isNegative()?r[0].prev():r[0]},o.prototype.shiftRight=e.prototype.shiftRight,e.prototype.not=function(){return this.negate().prev()},o.prototype.not=e.prototype.not,e.prototype.and=function(t){return U(this,t,function(t,r){return t&r})},o.prototype.and=e.prototype.and,e.prototype.or=function(t){return U(this,t,function(t,r){return t|r})},o.prototype.or=e.prototype.or,e.prototype.xor=function(t){return U(this,t,function(t,r){return t^r})},o.prototype.xor=e.prototype.xor;var Y=1<<30,$=(K&-K)*(K&-K)|Y,tt=function(t,r){var e=t.length;if(2<=r&&r<=36&&e<=G/Math.log(r))return new o(parseInt(t,r));r=F(r);var n,i=[],u="-"===t[0];for(n=u?1:0;n"!==t[n]);i.push(F(t.slice(f+1,n)))}}return k(i,r,u)};e.prototype.toString=function(t){if(void 0===t&&(t=10),10!==t)return L(this,t);for(var r,e=this.value,n=e.length,o=String(e[--n]);--n>=0;)r=String(e[n]),o+="0000000".slice(r.length)+r;return(this.sign?"-":"")+o},o.prototype.toString=function(t){return void 0===t&&(t=10),10!=t?L(this,t):String(this.value)},e.prototype.valueOf=function(){return+this.toString()},e.prototype.toJSNumber=e.prototype.valueOf,o.prototype.valueOf=function(){return this.value},o.prototype.toJSNumber=o.prototype.valueOf;for(var rt=0;rt<1e3;rt++)r[rt]=new o(rt),rt>0&&(r[-rt]=new o(-rt));return r.one=r[1],r.zero=r[0],r.minusOne=r[-1],r.max=j,r.min=H,r.gcd=_,r.lcm=I,r.isInstance=function(t){return t instanceof e||t instanceof o},r.randBetween=N,r.fromArray=function(t,r,e){return k(t.map(F),F(r||10),e)},r}();void 0!==r&&r.hasOwnProperty("exports")&&(r.exports=n)},{}],2:[function(t,r,e){function n(t,r,e){switch(e.length){case 0:return t.call(r);case 1:return t.call(r,e[0]);case 2:return t.call(r,e[0],e[1]);case 3:return t.call(r,e[0],e[1],e[2])}return t.apply(r,e)}function o(t,r){for(var e=-1,n=Array(t);++e-1&&t%1==0&&t-1&&t%1==0&&t<=A}function m(t){var r=typeof t;return!!t&&("object"==r||"function"==r)}function w(t){return!!t&&"object"==typeof t}function S(t){return y(t)?i(t):a(t)}var A=9007199254740991,E="[object Arguments]",q="[object Function]",M="[object GeneratorFunction]",x=/^(?:0|[1-9]\d*)$/,P=Object.prototype,O=P.hasOwnProperty,C=P.toString,T=P.propertyIsEnumerable,U=function(t,r){return function(e){return t(r(e))}}(Object.keys,Object),B=Math.max,j=!T.call({valueOf:1},"valueOf"),H=Array.isArray,_=function(t){return s(function(r,e){var n=-1,o=e.length,i=o>1?e[o-1]:void 0,u=o>2?e[2]:void 0;for(i=t.length>3&&"function"==typeof i?(o--,i):void 0,u&&l(e[0],e[1],u)&&(i=o<3?void 0:i,o=1),r=Object(r);++n=n)return{value:t,entropy:r};var o=r.divmod(e.length);return t+=e[o.remainder],u(t,o.quotient,e,n)}function a(t,r,e){for(var n=0;n?@[\\]^_`{|}~"}},{"./pbkdf2":7,"big-integer":1,"lodash.assign":2}]},{},[6])(6)}); \ No newline at end of file +!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).LessPass=t()}}(function(){return function t(r,e,n){function o(u,a){if(!e[u]){if(!r[u]){var s="function"==typeof require&&require;if(!a&&s)return s(u,!0);if(i)return i(u,!0);var f=new Error("Cannot find module '"+u+"'");throw f.code="MODULE_NOT_FOUND",f}var c=e[u]={exports:{}};r[u][0].call(c.exports,function(t){var e=r[u][1][t];return o(e||t)},c,c.exports,t,r,e,n)}return e[u].exports}for(var i="function"==typeof require&&require,u=0;u0?Math.floor(t):Math.ceil(t)}function p(t,r){var e,n,o=t.length,i=r.length,u=new Array(o),a=0,s=D;for(n=0;n=s?1:0,u[n]=e-a*s;for(;n0&&u.push(a),u}function l(t,r){return t.length>=r.length?p(t,r):p(r,t)}function h(t,r){var e,n,o=t.length,i=new Array(o),u=D;for(n=0;n0;)i[n++]=r%u,r=Math.floor(r/u);return i}function v(t,r){var e,n,o=t.length,i=r.length,u=new Array(o),a=0,f=D;for(e=0;e=0?i=v(t,r):(i=v(r,t),n=!n),"number"==typeof(i=a(i))?(n&&(i=-i),new o(i)):new e(i,n)}function g(t,r,n){var i,u,s=t.length,f=new Array(s),c=-r,p=D;for(i=0;i0;)i[n++]=a%u,a=Math.floor(a/u);return i}function w(t,r){for(var e=[];r-- >0;)e.push(0);return e.concat(t)}function m(t,r){var e=Math.max(t.length,r.length);if(e<=30)return d(t,r);e=Math.ceil(e/2);var n=t.slice(e),o=t.slice(0,e),i=r.slice(e),u=r.slice(0,e),a=m(o,u),f=m(n,i),c=l(l(a,w(v(v(m(l(o,n),l(u,i)),a),f),e)),w(f,2*e));return s(c),c}function _(t,r){return-.012*t-.012*r+15e-6*t*r>0}function A(t,r,n){return t=0;n--){for(e=h-1,d[n+l]!==y&&(e=Math.floor((d[n+l]*h+d[n+l-1])/y)),o=0,i=0,s=w.length,u=0;uc&&(o=(o+1)*h),e=Math.ceil(o/i);do{if(u=b(r,e),q(u,l)<=0)break;e--}while(e);p.push(e),l=v(l,u)}return p.reverse(),[a(p),a(l)]}function O(t,r){var e,n,o,i,u=t.length,a=f(u),s=D;for(o=0,e=u-1;e>=0;--e)o=(i=o*s+t[e])-(n=c(i/r))*r,a[e]=0|n;return[a,0|o]}function M(t,n){var i,s,f=R(n),p=t.value,l=f.value;if(0===l)throw new Error("Cannot divide by zero");if(t.isSmall)return f.isSmall?[new o(c(p/l)),new o(p%l)]:[r[0],t];if(f.isSmall){if(1===l)return[t,r[0]];if(-1==l)return[t.negate(),r[0]];var h=Math.abs(l);if(hr.length?1:-1;for(var e=t.length-1;e>=0;e--)if(t[e]!==r[e])return t[e]>r[e]?1:-1;return 0}function x(t){var r=t.abs();return!r.isUnit()&&(!!(r.equals(2)||r.equals(3)||r.equals(5))||!(r.isEven()||r.isDivisibleBy(3)||r.isDivisibleBy(5))&&(!!r.lesser(25)||void 0))}function P(t){return("number"==typeof t||"string"==typeof t)&&+Math.abs(t)<=D||t instanceof e&&t.value.length<=1}function U(t,r,e){r=R(r);for(var o=t.isNegative(),i=r.isNegative(),u=o?t.not():t,a=i?r.not():r,s=[],f=[],c=!1,p=!1;!c||!p;)u.isZero()?(c=!0,s.push(o?1:0)):o?s.push(u.isEven()?1:0):s.push(u.isEven()?0:1),a.isZero()?(p=!0,f.push(i?1:0)):i?f.push(a.isEven()?1:0):f.push(a.isEven()?0:1),u=u.over(2),a=a.over(2);for(var l=[],h=0;h=0;o--)i=i.add(t[o].times(u)),u=u.times(e);return n?i.negate():i}function N(t){var r=t.value;return"number"==typeof r&&(r=[r]),1===r.length&&r[0]<=35?"0123456789abcdefghijklmnopqrstuvwxyz".charAt(r[0]):"<"+r+">"}function k(t,r){if((r=n(r)).isZero()){if(t.isZero())return"0";throw new Error("Cannot convert nonzero numbers to base 0.")}if(r.equals(-1))return t.isZero()?"0":t.isNegative()?new Array(1-t).join("10"):"1"+new Array(+t).join("01");var e="";if(t.isNegative()&&r.isPositive()&&(e="-",t=t.abs()),r.equals(1))return t.isZero()?"0":e+new Array(+t+1).join(1);for(var o,i=[],u=t;u.isNegative()||u.compareAbs(r)>=0;){u=(o=u.divmod(r)).quotient;var a=o.remainder;a.isNegative()&&(a=r.minus(a).abs(),u=u.next()),i.push(N(a))}return i.push(N(u)),e+i.reverse().join("")}function Z(t){if(i(+t)){var r=+t;if(r===c(r))return new o(r);throw"Invalid integer: "+t}var n="-"===t[0];n&&(t=t.slice(1));var u=t.split(/e/i);if(u.length>2)throw new Error("Invalid integer: "+u.join("e"));if(2===u.length){var a=u[1];if("+"===a[0]&&(a=a.slice(1)),(a=+a)!==c(a)||!i(a))throw new Error("Invalid integer: "+a+" is not a valid exponent.");var f=u[0],p=f.indexOf(".");if(p>=0&&(a-=f.length-p-1,f=f.slice(0,p)+f.slice(p+1)),a<0)throw new Error("Cannot include negative exponent part for integers");t=f+=new Array(a+1).join("0")}if(!/^([0-9][0-9]*)$/.test(t))throw new Error("Invalid integer: "+t);for(var l=[],h=t.length,v=F,y=h-v;h>0;)l.push(+t.slice(y,h)),(y-=v)<0&&(y=0),h-=v;return s(l),new e(l,n)}function L(t){if(i(t)){if(t!==c(t))throw new Error(t+" is not an integer.");return new o(t)}return Z(t.toString())}function R(t){return"number"==typeof t?L(t):"string"==typeof t?Z(t):t}var D=1e7,F=7,$=9007199254740992,z=u($),K=Math.log($);e.prototype=Object.create(r.prototype),o.prototype=Object.create(r.prototype),e.prototype.add=function(t){var r=R(t);if(this.sign!==r.sign)return this.subtract(r.negate());var n=this.value,o=r.value;return r.isSmall?new e(h(n,Math.abs(o)),this.sign):new e(l(n,o),this.sign)},e.prototype.plus=e.prototype.add,o.prototype.add=function(t){var r=R(t),n=this.value;if(n<0!==r.sign)return this.subtract(r.negate());var a=r.value;if(r.isSmall){if(i(n+a))return new o(n+a);a=u(Math.abs(a))}return new e(h(a,Math.abs(n)),n<0)},o.prototype.plus=o.prototype.add,e.prototype.subtract=function(t){var r=R(t);if(this.sign!==r.sign)return this.add(r.negate());var e=this.value,n=r.value;return r.isSmall?g(e,Math.abs(n),this.sign):y(e,n,this.sign)},e.prototype.minus=e.prototype.subtract,o.prototype.subtract=function(t){var r=R(t),e=this.value;if(e<0!==r.sign)return this.add(r.negate());var n=r.value;return r.isSmall?new o(e-n):g(n,Math.abs(e),e>=0)},o.prototype.minus=o.prototype.subtract,e.prototype.negate=function(){return new e(this.value,!this.sign)},o.prototype.negate=function(){var t=this.sign,r=new o(-this.value);return r.sign=!t,r},e.prototype.abs=function(){return new e(this.value,!1)},o.prototype.abs=function(){return new o(Math.abs(this.value))},e.prototype.multiply=function(t){var n,o=R(t),i=this.value,a=o.value,s=this.sign!==o.sign;if(o.isSmall){if(0===a)return r[0];if(1===a)return this;if(-1===a)return this.negate();if((n=Math.abs(a))n?1:-1):-1},e.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var r=R(t),e=this.value,n=r.value;return this.sign!==r.sign?r.sign?1:-1:r.isSmall?this.sign?-1:1:q(e,n)*(this.sign?-1:1)},e.prototype.compareTo=e.prototype.compare,o.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var r=R(t),e=this.value,n=r.value;return r.isSmall?e==n?0:e>n?1:-1:e<0!==r.sign?e<0?-1:1:e<0?1:-1},o.prototype.compareTo=o.prototype.compare,e.prototype.equals=function(t){return 0===this.compare(t)},o.prototype.eq=o.prototype.equals=e.prototype.eq=e.prototype.equals,e.prototype.notEquals=function(t){return 0!==this.compare(t)},o.prototype.neq=o.prototype.notEquals=e.prototype.neq=e.prototype.notEquals,e.prototype.greater=function(t){return this.compare(t)>0},o.prototype.gt=o.prototype.greater=e.prototype.gt=e.prototype.greater,e.prototype.lesser=function(t){return this.compare(t)<0},o.prototype.lt=o.prototype.lesser=e.prototype.lt=e.prototype.lesser,e.prototype.greaterOrEquals=function(t){return this.compare(t)>=0},o.prototype.geq=o.prototype.greaterOrEquals=e.prototype.geq=e.prototype.greaterOrEquals,e.prototype.lesserOrEquals=function(t){return this.compare(t)<=0},o.prototype.leq=o.prototype.lesserOrEquals=e.prototype.leq=e.prototype.lesserOrEquals,e.prototype.isEven=function(){return 0==(1&this.value[0])},o.prototype.isEven=function(){return 0==(1&this.value)},e.prototype.isOdd=function(){return 1==(1&this.value[0])},o.prototype.isOdd=function(){return 1==(1&this.value)},e.prototype.isPositive=function(){return!this.sign},o.prototype.isPositive=function(){return this.value>0},e.prototype.isNegative=function(){return this.sign},o.prototype.isNegative=function(){return this.value<0},e.prototype.isUnit=function(){return!1},o.prototype.isUnit=function(){return 1===Math.abs(this.value)},e.prototype.isZero=function(){return!1},o.prototype.isZero=function(){return 0===this.value},e.prototype.isDivisibleBy=function(t){var e=R(t),n=e.value;return 0!==n&&(1===n||(2===n?this.isEven():this.mod(e).equals(r[0])))},o.prototype.isDivisibleBy=e.prototype.isDivisibleBy,e.prototype.isPrime=function(){var t=x(this);if(void 0!==t)return t;for(var e,o,i,u,a=this.abs(),s=a.prev(),f=[2,3,5,7,11,13,17,19],c=s;c.isEven();)c=c.divide(2);for(i=0;i-$?new o(t-1):new e(z,!0)};for(var J=[1];J[J.length-1]<=D;)J.push(2*J[J.length-1]);var V=J.length,W=J[V-1];e.prototype.shiftLeft=function(t){if(!P(t))throw new Error(String(t)+" is too large for shifting.");if((t=+t)<0)return this.shiftRight(-t);for(var r=this;t>=V;)r=r.multiply(W),t-=V-1;return r.multiply(J[t])},o.prototype.shiftLeft=e.prototype.shiftLeft,e.prototype.shiftRight=function(t){var r;if(!P(t))throw new Error(String(t)+" is too large for shifting.");if((t=+t)<0)return this.shiftLeft(-t);for(var e=this;t>=V;){if(e.isZero())return e;e=(r=M(e,W))[1].isNegative()?r[0].prev():r[0],t-=V-1}return(r=M(e,J[t]))[1].isNegative()?r[0].prev():r[0]},o.prototype.shiftRight=e.prototype.shiftRight,e.prototype.not=function(){return this.negate().prev()},o.prototype.not=e.prototype.not,e.prototype.and=function(t){return U(this,t,function(t,r){return t&r})},o.prototype.and=e.prototype.and,e.prototype.or=function(t){return U(this,t,function(t,r){return t|r})},o.prototype.or=e.prototype.or,e.prototype.xor=function(t){return U(this,t,function(t,r){return t^r})},o.prototype.xor=e.prototype.xor;var G=1<<30,Q=(D&-D)*(D&-D)|G,X=function(t,r){var e=t.length;if(2<=r&&r<=36&&e<=K/Math.log(r))return new o(parseInt(t,r));r=R(r);var n,i=[],u="-"===t[0];for(n=u?1:0;n"!==t[n]);i.push(R(t.slice(f+1,n)))}}return H(i,r,u)};e.prototype.toString=function(t){if(void 0===t&&(t=10),10!==t)return k(this,t);for(var r,e=this.value,n=e.length,o=String(e[--n]);--n>=0;)r=String(e[n]),o+="0000000".slice(r.length)+r;return(this.sign?"-":"")+o},o.prototype.toString=function(t){return void 0===t&&(t=10),10!=t?k(this,t):String(this.value)},e.prototype.valueOf=function(){return+this.toString()},e.prototype.toJSNumber=e.prototype.valueOf,o.prototype.valueOf=function(){return this.value},o.prototype.toJSNumber=o.prototype.valueOf;for(var Y=0;Y<1e3;Y++)r[Y]=new o(Y),Y>0&&(r[-Y]=new o(-Y));return r.one=r[1],r.zero=r[0],r.minusOne=r[-1],r.max=B,r.min=C,r.gcd=I,r.lcm=function(t,r){return t=R(t).abs(),r=R(r).abs(),t.divide(I(t,r)).multiply(r)},r.isInstance=function(t){return t instanceof e||t instanceof o},r.randBetween=function(t,r){var n=C(t=R(t),r=R(r)),i=B(t,r).subtract(n);if(i.isSmall)return n.add(Math.round(Math.random()*i));for(var u=[],s=!0,f=i.value.length-1;f>=0;f--){var p=s?i.value[f]:D,l=c(Math.random()*p);u.unshift(l),l-1&&t%1==0&&t-1&&t%1==0&&t<=dt}function ft(t){var r=typeof t;return!!t&&("object"==r||"function"==r)}function ct(t){return!!t&&"object"==typeof t}function pt(t){if(!ct(t)||pr.call(t)!=Et||p(t))return!1;var r=gr(t);if(null===r)return!0;var e=fr.call(r,"constructor")&&r.constructor;return"function"==typeof e&&e instanceof e&&sr.call(e)==cr}function lt(t){return D(t,vt(t))}function ht(t){return it(t)?w(t):q(t)}function vt(t){return it(t)?w(t,!0):x(t)}var yt=200,gt="__lodash_hash_undefined__",dt=9007199254740991,bt="[object Arguments]",wt="[object Boolean]",mt="[object Date]",_t="[object Function]",At="[object GeneratorFunction]",St="[object Map]",jt="[object Number]",Et="[object Object]",Ot="[object RegExp]",Mt="[object Set]",qt="[object String]",xt="[object Symbol]",Pt="[object WeakMap]",Ut="[object ArrayBuffer]",Tt="[object DataView]",Bt="[object Float32Array]",Ct="[object Float64Array]",It="[object Int8Array]",Ht="[object Int16Array]",Nt="[object Int32Array]",kt="[object Uint8Array]",Zt="[object Uint8ClampedArray]",Lt="[object Uint16Array]",Rt="[object Uint32Array]",Dt=/[\\^$.*+?()[\]{}|]/g,Ft=/\w*$/,$t=/^\[object .+?Constructor\]$/,zt=/^(?:0|[1-9]\d*)$/,Kt={};Kt[Bt]=Kt[Ct]=Kt[It]=Kt[Ht]=Kt[Nt]=Kt[kt]=Kt[Zt]=Kt[Lt]=Kt[Rt]=!0,Kt[bt]=Kt["[object Array]"]=Kt[Ut]=Kt[wt]=Kt[Tt]=Kt[mt]=Kt["[object Error]"]=Kt[_t]=Kt[St]=Kt[jt]=Kt[Et]=Kt[Ot]=Kt[Mt]=Kt[qt]=Kt[Pt]=!1;var Jt={};Jt[bt]=Jt["[object Array]"]=Jt[Ut]=Jt[Tt]=Jt[wt]=Jt[mt]=Jt[Bt]=Jt[Ct]=Jt[It]=Jt[Ht]=Jt[Nt]=Jt[St]=Jt[jt]=Jt[Et]=Jt[Ot]=Jt[Mt]=Jt[qt]=Jt[xt]=Jt[kt]=Jt[Zt]=Jt[Lt]=Jt[Rt]=!0,Jt["[object Error]"]=Jt[_t]=Jt[Pt]=!1;var Vt="object"==typeof t&&t&&t.Object===Object&&t,Wt="object"==typeof self&&self&&self.Object===Object&&self,Gt=Vt||Wt||Function("return this")(),Qt="object"==typeof e&&e&&!e.nodeType&&e,Xt=Qt&&"object"==typeof r&&r&&!r.nodeType&&r,Yt=Xt&&Xt.exports===Qt,tr=Yt&&Vt.process,rr=function(){try{return tr&&tr.binding("util")}catch(t){}}(),er=rr&&rr.isTypedArray,nr=Array.prototype,or=Function.prototype,ir=Object.prototype,ur=Gt["__core-js_shared__"],ar=function(){var t=/[^.]+$/.exec(ur&&ur.keys&&ur.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),sr=or.toString,fr=ir.hasOwnProperty,cr=sr.call(Object),pr=ir.toString,lr=RegExp("^"+sr.call(fr).replace(Dt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),hr=Yt?Gt.Buffer:void 0,vr=Gt.Symbol,yr=Gt.Uint8Array,gr=h(Object.getPrototypeOf,Object),dr=Object.create,br=ir.propertyIsEnumerable,wr=nr.splice,mr=Object.getOwnPropertySymbols,_r=hr?hr.isBuffer:void 0,Ar=h(Object.keys,Object),Sr=Math.max,jr=K(Gt,"DataView"),Er=K(Gt,"Map"),Or=K(Gt,"Promise"),Mr=K(Gt,"Set"),qr=K(Gt,"WeakMap"),xr=K(Object,"create"),Pr=et(jr),Ur=et(Er),Tr=et(Or),Br=et(Mr),Cr=et(qr),Ir=vr?vr.prototype:void 0,Hr=Ir?Ir.valueOf:void 0;y.prototype.clear=function(){this.__data__=xr?xr(null):{}},y.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},y.prototype.get=function(t){var r=this.__data__;if(xr){var e=r[t];return e===gt?void 0:e}return fr.call(r,t)?r[t]:void 0},y.prototype.has=function(t){var r=this.__data__;return xr?void 0!==r[t]:fr.call(r,t)},y.prototype.set=function(t,r){return this.__data__[t]=xr&&void 0===r?gt:r,this},g.prototype.clear=function(){this.__data__=[]},g.prototype.delete=function(t){var r=this.__data__,e=A(r,t);return!(e<0||(e==r.length-1?r.pop():wr.call(r,e,1),0))},g.prototype.get=function(t){var r=this.__data__,e=A(r,t);return e<0?void 0:r[e][1]},g.prototype.has=function(t){return A(this.__data__,t)>-1},g.prototype.set=function(t,r){var e=this.__data__,n=A(e,t);return n<0?e.push([t,r]):e[n][1]=r,this},d.prototype.clear=function(){this.__data__={hash:new y,map:new(Er||g),string:new y}},d.prototype.delete=function(t){return z(this,t).delete(t)},d.prototype.get=function(t){return z(this,t).get(t)},d.prototype.has=function(t){return z(this,t).has(t)},d.prototype.set=function(t,r){return z(this,t).set(t,r),this},b.prototype.clear=function(){this.__data__=new g},b.prototype.delete=function(t){return this.__data__.delete(t)},b.prototype.get=function(t){return this.__data__.get(t)},b.prototype.has=function(t){return this.__data__.has(t)},b.prototype.set=function(t,r){var e=this.__data__;if(e instanceof g){var n=e.__data__;if(!Er||n.length1?e[o-1]:void 0,u=o>2?e[2]:void 0;for(i=t.length>3&&"function"==typeof i?(o--,i):void 0,u&&Q(e[0],e[1],u)&&(i=o<3?void 0:i,o=1),r=Object(r);++n=n)return{value:t,entropy:r};var o=r.divmod(e.length);return t+=e[o.remainder],u(t,o.quotient,e,n)}function a(t,r,e){for(var n=0;n?@[\\]^_`{|}~"}},{"./hmac":5,"./pbkdf2":7,"big-integer":1,"lodash.merge":2}],7:[function(t,r,e){t("unibabel"),t("unibabel/unibabel.hex"),r.exports=function(t,r,e,n,o){var i={sha1:"SHA-1","sha-1":"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha512:"SHA-512","sha-512":"SHA-512"};return window.crypto.subtle.importKey("raw",Unibabel.utf8ToBuffer(t),"PBKDF2",!1,["deriveKey"]).then(function(t){var u={name:"PBKDF2",salt:Unibabel.utf8ToBuffer(r),iterations:e,hash:i[o.toLowerCase()]};return window.crypto.subtle.deriveKey(u,t,{name:"AES-CTR",length:8*n},!0,["encrypt","decrypt"])}).then(function(t){return window.crypto.subtle.exportKey("raw",t).then(function(t){return Unibabel.bufferToHex(new Uint8Array(t))})})}},{unibabel:3,"unibabel/unibabel.hex":4}]},{},[6])(6)}); \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..4e8d916 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,3875 @@ +{ + "name": "lesspass", + "version": "7.0.1", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "JSONStream": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/JSONStream/-/JSONStream-1.3.1.tgz", + "integrity": "sha1-cH92HgHa6eFvG8+TcDt4xwlmV5o=", + "dev": true, + "requires": { + "jsonparse": "1.3.1", + "through": "2.3.8" + } + }, + "accepts": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.3.tgz", + "integrity": "sha1-w8p0NJOGSMPg2cHjKN1otiLChMo=", + "dev": true, + "requires": { + "mime-types": "2.1.15", + "negotiator": "0.6.1" + } + }, + "acorn": { + "version": "4.0.13", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-4.0.13.tgz", + "integrity": "sha1-EFSVrlNh1pe9GVyCUZLhrX8lN4c=", + "dev": true + }, + "after": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/after/-/after-0.8.2.tgz", + "integrity": "sha1-/ts5T58OAqqXaOcCvaI7UF+ufh8=", + "dev": true + }, + "anymatch": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-1.3.0.tgz", + "integrity": "sha1-o+Uvo5FoyCX/V7AkgSbOWo/5VQc=", + "dev": true, + "requires": { + "arrify": "1.0.1", + "micromatch": "2.3.11" + } + }, + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "dev": true, + "requires": { + "arr-flatten": "1.0.3" + } + }, + "arr-flatten": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.0.3.tgz", + "integrity": "sha1-onTthawIhJtr14R8RYB0XcUa37E=", + "dev": true + }, + "array-filter": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/array-filter/-/array-filter-0.0.1.tgz", + "integrity": "sha1-fajPLiZijtcygDWB/SH2fKzS7uw=", + "dev": true + }, + "array-map": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/array-map/-/array-map-0.0.0.tgz", + "integrity": "sha1-iKK6tz0c97zVwbEYoAP2b2ZfpmI=", + "dev": true + }, + "array-reduce": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/array-reduce/-/array-reduce-0.0.0.tgz", + "integrity": "sha1-FziZ0//Rx9k4PkR5Ul2+J4yrXys=", + "dev": true + }, + "array-slice": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/array-slice/-/array-slice-0.2.3.tgz", + "integrity": "sha1-3Tz7gO15c6dRF82sabC5nshhhvU=", + "dev": true + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=", + "dev": true + }, + "arraybuffer.slice": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/arraybuffer.slice/-/arraybuffer.slice-0.0.6.tgz", + "integrity": "sha1-8zshWfBTKj8xB6JywMz70a0peco=", + "dev": true + }, + "arrify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", + "integrity": "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=", + "dev": true + }, + "asn1.js": { + "version": "4.9.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-4.9.1.tgz", + "integrity": "sha1-SLokC0WpKA6UdImQull9IWYX/UA=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "inherits": "2.0.3", + "minimalistic-assert": "1.0.0" + } + }, + "assert": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/assert/-/assert-1.4.1.tgz", + "integrity": "sha1-mZEtWRg2tab1s0XA8H7vwI/GXZE=", + "dev": true, + "requires": { + "util": "0.10.3" + } + }, + "astw": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/astw/-/astw-2.2.0.tgz", + "integrity": "sha1-e9QXhNMkk5h66yOba04cV6hzuRc=", + "dev": true, + "requires": { + "acorn": "4.0.13" + } + }, + "async-each": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.1.tgz", + "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0=", + "dev": true + }, + "backo2": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/backo2/-/backo2-1.0.2.tgz", + "integrity": "sha1-MasayLEpNjRj41s+u2n038+6eUc=", + "dev": true + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", + "dev": true + }, + "base64-arraybuffer": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz", + "integrity": "sha1-c5JncZI7Whl0etZmqlzUv5xunOg=", + "dev": true + }, + "base64-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.2.1.tgz", + "integrity": "sha512-dwVUVIXsBZXwTuwnXI9RK8sBmgq09NDHzyR9SAph9eqk76gKK2JSQmZARC2zRC81JC2QTtxD0ARU5qTS25gIGw==", + "dev": true + }, + "base64id": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/base64id/-/base64id-1.0.0.tgz", + "integrity": "sha1-R2iMuZu2gE8OBtPnY7HDLlfY5rY=", + "dev": true + }, + "better-assert": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/better-assert/-/better-assert-1.0.2.tgz", + "integrity": "sha1-QIZrnhueC1W0gYlDEeaPr/rrxSI=", + "dev": true, + "requires": { + "callsite": "1.0.0" + } + }, + "big-integer": { + "version": "1.6.23", + "resolved": "https://registry.npmjs.org/big-integer/-/big-integer-1.6.23.tgz", + "integrity": "sha1-6F1QgiDHTj9DpM5y7tUfPaTblNE=" + }, + "binary-extensions": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.8.0.tgz", + "integrity": "sha1-SOyNFt9Dd+rl+liEaCSAr02Vx3Q=", + "dev": true + }, + "blob": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/blob/-/blob-0.0.4.tgz", + "integrity": "sha1-vPEwUspURj8w+fx+lbmkdjCpSSE=", + "dev": true + }, + "bluebird": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.0.tgz", + "integrity": "sha1-eRQg1/VR7qKJdFOop3ZT+WYG1nw=", + "dev": true + }, + "bn.js": { + "version": "4.11.7", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.7.tgz", + "integrity": "sha512-LxFiV5mefv0ley0SzqkOPR1bC4EbpPx8LkOz5vMe/Yi15t5hzwgO/G+tc7wOtL4PZTYjwHu8JnEiSLumuSjSfA==", + "dev": true + }, + "body-parser": { + "version": "1.17.2", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.17.2.tgz", + "integrity": "sha1-+IkqvI+eYn1Crtr7yma/WrmRBO4=", + "dev": true, + "requires": { + "bytes": "2.4.0", + "content-type": "1.0.2", + "debug": "2.6.7", + "depd": "1.1.0", + "http-errors": "1.6.1", + "iconv-lite": "0.4.15", + "on-finished": "2.3.0", + "qs": "6.4.0", + "raw-body": "2.2.0", + "type-is": "1.6.15" + } + }, + "brace-expansion": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.8.tgz", + "integrity": "sha1-wHshHHyVLsH479Uad+8NHTmQopI=", + "dev": true, + "requires": { + "balanced-match": "1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "dev": true, + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=", + "dev": true + }, + "browser-pack": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/browser-pack/-/browser-pack-6.0.2.tgz", + "integrity": "sha1-+GzWzvT1MAyOY+B6TVEvZfv/RTE=", + "dev": true, + "requires": { + "JSONStream": "1.3.1", + "combine-source-map": "0.7.2", + "defined": "1.0.0", + "through2": "2.0.3", + "umd": "3.0.1" + } + }, + "browser-resolve": { + "version": "1.11.2", + "resolved": "https://registry.npmjs.org/browser-resolve/-/browser-resolve-1.11.2.tgz", + "integrity": "sha1-j/CbCixCFxihBRwmCzLkj0QpOM4=", + "dev": true, + "requires": { + "resolve": "1.1.7" + }, + "dependencies": { + "resolve": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", + "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=", + "dev": true + } + } + }, + "browser-stdout": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.0.tgz", + "integrity": "sha1-81HTKWnTL6XXpVZxVCY9korjvR8=", + "dev": true + }, + "browserify": { + "version": "14.4.0", + "resolved": "https://registry.npmjs.org/browserify/-/browserify-14.4.0.tgz", + "integrity": "sha1-CJo0Y69Y0OSNjNQHCz90ZU1avKk=", + "dev": true, + "requires": { + "JSONStream": "1.3.1", + "assert": "1.4.1", + "browser-pack": "6.0.2", + "browser-resolve": "1.11.2", + "browserify-zlib": "0.1.4", + "buffer": "5.0.6", + "cached-path-relative": "1.0.1", + "concat-stream": "1.5.2", + "console-browserify": "1.1.0", + "constants-browserify": "1.0.0", + "crypto-browserify": "3.11.0", + "defined": "1.0.0", + "deps-sort": "2.0.0", + "domain-browser": "1.1.7", + "duplexer2": "0.1.4", + "events": "1.1.1", + "glob": "7.1.2", + "has": "1.0.1", + "htmlescape": "1.1.1", + "https-browserify": "1.0.0", + "inherits": "2.0.3", + "insert-module-globals": "7.0.1", + "labeled-stream-splicer": "2.0.0", + "module-deps": "4.1.1", + "os-browserify": "0.1.2", + "parents": "1.0.1", + "path-browserify": "0.0.0", + "process": "0.11.10", + "punycode": "1.4.1", + "querystring-es3": "0.2.1", + "read-only-stream": "2.0.0", + "readable-stream": "2.3.2", + "resolve": "1.3.3", + "shasum": "1.0.2", + "shell-quote": "1.6.1", + "stream-browserify": "2.0.1", + "stream-http": "2.7.2", + "string_decoder": "1.0.3", + "subarg": "1.0.0", + "syntax-error": "1.3.0", + "through2": "2.0.3", + "timers-browserify": "1.4.2", + "tty-browserify": "0.0.0", + "url": "0.11.0", + "util": "0.10.3", + "vm-browserify": "0.0.4", + "xtend": "4.0.1" + } + }, + "browserify-aes": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.0.6.tgz", + "integrity": "sha1-Xncl297x/Vkw1OurSFZ85FHEigo=", + "dev": true, + "requires": { + "buffer-xor": "1.0.3", + "cipher-base": "1.0.3", + "create-hash": "1.1.3", + "evp_bytestokey": "1.0.0", + "inherits": "2.0.3" + } + }, + "browserify-cipher": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/browserify-cipher/-/browserify-cipher-1.0.0.tgz", + "integrity": "sha1-mYgkSHS/XtTijalWZtzWasj8Njo=", + "dev": true, + "requires": { + "browserify-aes": "1.0.6", + "browserify-des": "1.0.0", + "evp_bytestokey": "1.0.0" + } + }, + "browserify-des": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/browserify-des/-/browserify-des-1.0.0.tgz", + "integrity": "sha1-2qJ3cXRwki7S/hhZQRihdUOXId0=", + "dev": true, + "requires": { + "cipher-base": "1.0.3", + "des.js": "1.0.0", + "inherits": "2.0.3" + } + }, + "browserify-rsa": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.0.1.tgz", + "integrity": "sha1-IeCr+vbyApzy+vsTNWenAdQTVSQ=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "randombytes": "2.0.5" + } + }, + "browserify-sign": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/browserify-sign/-/browserify-sign-4.0.4.tgz", + "integrity": "sha1-qk62jl17ZYuqa/alfmMMvXqT0pg=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "browserify-rsa": "4.0.1", + "create-hash": "1.1.3", + "create-hmac": "1.1.6", + "elliptic": "6.4.0", + "inherits": "2.0.3", + "parse-asn1": "5.1.0" + } + }, + "browserify-zlib": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/browserify-zlib/-/browserify-zlib-0.1.4.tgz", + "integrity": "sha1-uzX4pRn2AOD6a4SFJByXnQFB+y0=", + "dev": true, + "requires": { + "pako": "0.2.9" + } + }, + "buffer": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.0.6.tgz", + "integrity": "sha1-LqZp9+7Atu2gWwj4tf9mGyhXNYg=", + "dev": true, + "requires": { + "base64-js": "1.2.1", + "ieee754": "1.1.8" + } + }, + "buffer-xor": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/buffer-xor/-/buffer-xor-1.0.3.tgz", + "integrity": "sha1-JuYe0UIvtw3ULm42cp7VHYVf6Nk=", + "dev": true + }, + "builtin-status-codes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz", + "integrity": "sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug=", + "dev": true + }, + "bytes": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-2.4.0.tgz", + "integrity": "sha1-fZcZb51br39pNeJZhVSe3SpsIzk=", + "dev": true + }, + "cached-path-relative": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/cached-path-relative/-/cached-path-relative-1.0.1.tgz", + "integrity": "sha1-0JxLUoAKpMB44t2BqGmqyQ0uVOc=", + "dev": true + }, + "callsite": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/callsite/-/callsite-1.0.0.tgz", + "integrity": "sha1-KAOY5dZkvXQDi28JBRU+borxvCA=", + "dev": true + }, + "chokidar": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-1.7.0.tgz", + "integrity": "sha1-eY5ol3gVHIB2tLNg5e3SjNortGg=", + "dev": true, + "requires": { + "anymatch": "1.3.0", + "async-each": "1.0.1", + "fsevents": "1.1.2", + "glob-parent": "2.0.0", + "inherits": "2.0.3", + "is-binary-path": "1.0.1", + "is-glob": "2.0.1", + "path-is-absolute": "1.0.1", + "readdirp": "2.1.0" + } + }, + "cipher-base": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/cipher-base/-/cipher-base-1.0.3.tgz", + "integrity": "sha1-7qvxlEGc6QDaMBjCB9IS8qbfCgc=", + "dev": true, + "requires": { + "inherits": "2.0.3" + } + }, + "colors": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/colors/-/colors-1.1.2.tgz", + "integrity": "sha1-FopHAXVran9RoSzgyXv6KMCE7WM=", + "dev": true + }, + "combine-lists": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/combine-lists/-/combine-lists-1.0.1.tgz", + "integrity": "sha1-RYwH4J4NkA/Ci3Cj/sLazR0st/Y=", + "dev": true, + "requires": { + "lodash": "4.17.4" + }, + "dependencies": { + "lodash": { + "version": "4.17.4", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz", + "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=", + "dev": true + } + } + }, + "combine-source-map": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/combine-source-map/-/combine-source-map-0.7.2.tgz", + "integrity": "sha1-CHAxKFazB6h8xKxIbzqaYq7MwJ4=", + "dev": true, + "requires": { + "convert-source-map": "1.1.3", + "inline-source-map": "0.6.2", + "lodash.memoize": "3.0.4", + "source-map": "0.5.6" + } + }, + "component-bind": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/component-bind/-/component-bind-1.0.0.tgz", + "integrity": "sha1-AMYIq33Nk4l8AAllGx06jh5zu9E=", + "dev": true + }, + "component-emitter": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.1.2.tgz", + "integrity": "sha1-KWWU8nU9qmOZbSrwjRWpURbJrsM=", + "dev": true + }, + "component-inherit": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/component-inherit/-/component-inherit-0.0.3.tgz", + "integrity": "sha1-ZF/ErfWLcrZJ1crmUTVhnbJv8UM=", + "dev": true + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "concat-stream": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.5.2.tgz", + "integrity": "sha1-cIl4Yk2FavQaWnQd790mHadSwmY=", + "dev": true, + "requires": { + "inherits": "2.0.3", + "readable-stream": "2.0.6", + "typedarray": "0.0.6" + }, + "dependencies": { + "readable-stream": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.6.tgz", + "integrity": "sha1-j5A0HmilPMySh4jaz80Rs265t44=", + "dev": true, + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "string_decoder": "0.10.31", + "util-deprecate": "1.0.2" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + } + } + }, + "connect": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/connect/-/connect-3.6.2.tgz", + "integrity": "sha1-aU6NIGgb/kkCgsiriGvpjwn0L+c=", + "dev": true, + "requires": { + "debug": "2.6.7", + "finalhandler": "1.0.3", + "parseurl": "1.3.1", + "utils-merge": "1.0.0" + } + }, + "console-browserify": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/console-browserify/-/console-browserify-1.1.0.tgz", + "integrity": "sha1-8CQcRXMKn8YyOyBtvzjtx0HQuxA=", + "dev": true, + "requires": { + "date-now": "0.1.4" + } + }, + "constants-browserify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/constants-browserify/-/constants-browserify-1.0.0.tgz", + "integrity": "sha1-wguW2MYXdIqvHBYCF2DNJ/y4y3U=", + "dev": true + }, + "content-type": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.2.tgz", + "integrity": "sha1-t9ETrueo3Se9IRM8TcJSnfFyHu0=", + "dev": true + }, + "convert-source-map": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.1.3.tgz", + "integrity": "sha1-SCnId+n+SbMWHzvzZziI4gRpmGA=", + "dev": true + }, + "cookie": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.3.1.tgz", + "integrity": "sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s=", + "dev": true + }, + "core-js": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.4.1.tgz", + "integrity": "sha1-TekR5mew6ukSTjQlS1OupvxhjT4=", + "dev": true + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", + "dev": true + }, + "create-ecdh": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/create-ecdh/-/create-ecdh-4.0.0.tgz", + "integrity": "sha1-iIxyNZbN92EvZJgjPuvXo1MBc30=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "elliptic": "6.4.0" + } + }, + "create-hash": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.1.3.tgz", + "integrity": "sha1-YGBCrIuSYnUPSDyt2rD1gZFy2P0=", + "dev": true, + "requires": { + "cipher-base": "1.0.3", + "inherits": "2.0.3", + "ripemd160": "2.0.1", + "sha.js": "2.4.8" + } + }, + "create-hmac": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.6.tgz", + "integrity": "sha1-rLniIaThe9sHbpBlfEK5PjcmzwY=", + "dev": true, + "requires": { + "cipher-base": "1.0.3", + "create-hash": "1.1.3", + "inherits": "2.0.3", + "ripemd160": "2.0.1", + "safe-buffer": "5.1.1", + "sha.js": "2.4.8" + } + }, + "crypto-browserify": { + "version": "3.11.0", + "resolved": "https://registry.npmjs.org/crypto-browserify/-/crypto-browserify-3.11.0.tgz", + "integrity": "sha1-NlKgkGq5sqfgw85mpAjpV6JIVSI=", + "dev": true, + "requires": { + "browserify-cipher": "1.0.0", + "browserify-sign": "4.0.4", + "create-ecdh": "4.0.0", + "create-hash": "1.1.3", + "create-hmac": "1.1.6", + "diffie-hellman": "5.0.2", + "inherits": "2.0.3", + "pbkdf2": "3.0.12", + "public-encrypt": "4.0.0", + "randombytes": "2.0.5" + } + }, + "custom-event": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/custom-event/-/custom-event-1.0.1.tgz", + "integrity": "sha1-XQKkaFCt8bSjF5RqOSj8y1v9BCU=", + "dev": true + }, + "date-now": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/date-now/-/date-now-0.1.4.tgz", + "integrity": "sha1-6vQ5/U1ISK105cx9vvIAZyueNFs=", + "dev": true + }, + "debug": { + "version": "2.6.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.7.tgz", + "integrity": "sha1-krrR9tBbu2u6Isyoi80OyJTChh4=", + "dev": true, + "requires": { + "ms": "2.0.0" + } + }, + "defined": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.0.tgz", + "integrity": "sha1-yY2bzvdWdBiOEQlpFRGZ45sfppM=", + "dev": true + }, + "depd": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.0.tgz", + "integrity": "sha1-4b2Cxqq2ztlluXuIsX7T5SjKGMM=", + "dev": true + }, + "deps-sort": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/deps-sort/-/deps-sort-2.0.0.tgz", + "integrity": "sha1-CRckkC6EZYJg65EHSMzNGvbiH7U=", + "dev": true, + "requires": { + "JSONStream": "1.3.1", + "shasum": "1.0.2", + "subarg": "1.0.0", + "through2": "2.0.3" + } + }, + "des.js": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/des.js/-/des.js-1.0.0.tgz", + "integrity": "sha1-wHTS4qpqipoH29YfmhXCzYPsjsw=", + "dev": true, + "requires": { + "inherits": "2.0.3", + "minimalistic-assert": "1.0.0" + } + }, + "detective": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/detective/-/detective-4.5.0.tgz", + "integrity": "sha1-blqMaybmx6JUsca210kNmOyR7dE=", + "dev": true, + "requires": { + "acorn": "4.0.13", + "defined": "1.0.0" + } + }, + "di": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/di/-/di-0.0.1.tgz", + "integrity": "sha1-gGZJMmzqp8qjMG112YXqJ0i6kTw=", + "dev": true + }, + "diff": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.2.0.tgz", + "integrity": "sha1-yc45Okt8vQsFinJck98pkCeGj/k=", + "dev": true + }, + "diffie-hellman": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.2.tgz", + "integrity": "sha1-tYNXOScM/ias9jIJn97SoH8gnl4=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "miller-rabin": "4.0.0", + "randombytes": "2.0.5" + } + }, + "dom-serialize": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/dom-serialize/-/dom-serialize-2.2.1.tgz", + "integrity": "sha1-ViromZ9Evl6jB29UGdzVnrQ6yVs=", + "dev": true, + "requires": { + "custom-event": "1.0.1", + "ent": "2.2.0", + "extend": "3.0.1", + "void-elements": "2.0.1" + } + }, + "domain-browser": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/domain-browser/-/domain-browser-1.1.7.tgz", + "integrity": "sha1-hnqksJP6oF8d4IwG9NeyH9+GmLw=", + "dev": true + }, + "duplexer2": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", + "integrity": "sha1-ixLauHjA1p4+eJEFFmKjL8a93ME=", + "dev": true, + "requires": { + "readable-stream": "2.3.2" + } + }, + "ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=", + "dev": true + }, + "elliptic": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.4.0.tgz", + "integrity": "sha1-ysmvh2LIWDYYcAPI3+GT5eLq5d8=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "brorand": "1.1.0", + "hash.js": "1.1.1", + "hmac-drbg": "1.0.1", + "inherits": "2.0.3", + "minimalistic-assert": "1.0.0", + "minimalistic-crypto-utils": "1.0.1" + } + }, + "encodeurl": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.1.tgz", + "integrity": "sha1-eePVhlU0aQn+bw9Fpd5oEDspTSA=", + "dev": true + }, + "engine.io": { + "version": "1.8.3", + "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-1.8.3.tgz", + "integrity": "sha1-jef5eJXSDTm4X4ju7nd7K9QrE9Q=", + "dev": true, + "requires": { + "accepts": "1.3.3", + "base64id": "1.0.0", + "cookie": "0.3.1", + "debug": "2.3.3", + "engine.io-parser": "1.3.2", + "ws": "1.1.2" + }, + "dependencies": { + "debug": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.3.3.tgz", + "integrity": "sha1-QMRT5n5uE8kB3ewxeviYbNqe/4w=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + } + } + }, + "engine.io-client": { + "version": "1.8.3", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-1.8.3.tgz", + "integrity": "sha1-F5jtk0USRkU9TG9jXXogH+lA1as=", + "dev": true, + "requires": { + "component-emitter": "1.2.1", + "component-inherit": "0.0.3", + "debug": "2.3.3", + "engine.io-parser": "1.3.2", + "has-cors": "1.1.0", + "indexof": "0.0.1", + "parsejson": "0.0.3", + "parseqs": "0.0.5", + "parseuri": "0.0.5", + "ws": "1.1.2", + "xmlhttprequest-ssl": "1.5.3", + "yeast": "0.1.2" + }, + "dependencies": { + "component-emitter": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", + "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=", + "dev": true + }, + "debug": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.3.3.tgz", + "integrity": "sha1-QMRT5n5uE8kB3ewxeviYbNqe/4w=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + } + } + }, + "engine.io-parser": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-1.3.2.tgz", + "integrity": "sha1-k3sHnwAH0Ik+xW1GyyILjLQ1Igo=", + "dev": true, + "requires": { + "after": "0.8.2", + "arraybuffer.slice": "0.0.6", + "base64-arraybuffer": "0.1.5", + "blob": "0.0.4", + "has-binary": "0.1.7", + "wtf-8": "1.0.0" + } + }, + "ent": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/ent/-/ent-2.2.0.tgz", + "integrity": "sha1-6WQhkyWiHQX0RGai9obtbOX13R0=", + "dev": true + }, + "escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=", + "dev": true + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "dev": true + }, + "eventemitter3": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-1.2.0.tgz", + "integrity": "sha1-HIaZHYFq0eUEdQ5zh0Ik7PO+xQg=", + "dev": true + }, + "events": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/events/-/events-1.1.1.tgz", + "integrity": "sha1-nr23Y1rQmccNzEwqH1AEKI6L2SQ=", + "dev": true + }, + "evp_bytestokey": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/evp_bytestokey/-/evp_bytestokey-1.0.0.tgz", + "integrity": "sha1-SXtmrZ/vZc18CKYYCCS6FHa2blM=", + "dev": true, + "requires": { + "create-hash": "1.1.3" + } + }, + "expand-braces": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/expand-braces/-/expand-braces-0.1.2.tgz", + "integrity": "sha1-SIsdHSRRyz06axks/AMPRMWFX+o=", + "dev": true, + "requires": { + "array-slice": "0.2.3", + "array-unique": "0.2.1", + "braces": "0.1.5" + }, + "dependencies": { + "braces": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-0.1.5.tgz", + "integrity": "sha1-wIVxEIUpHYt1/ddOqw+FlygHEeY=", + "dev": true, + "requires": { + "expand-range": "0.1.1" + } + }, + "expand-range": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/expand-range/-/expand-range-0.1.1.tgz", + "integrity": "sha1-TLjtoJk8pW+k9B/ELzy7TMrf8EQ=", + "dev": true, + "requires": { + "is-number": "0.1.1", + "repeat-string": "0.2.2" + } + }, + "is-number": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-0.1.1.tgz", + "integrity": "sha1-aaevEWlj1HIG7JvZtIoUIW8eOAY=", + "dev": true + }, + "repeat-string": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-0.2.2.tgz", + "integrity": "sha1-x6jTI2BoNiBZp+RlH8aITosftK4=", + "dev": true + } + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "dev": true, + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "expand-range": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz", + "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", + "dev": true, + "requires": { + "fill-range": "2.2.3" + } + }, + "extend": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=", + "dev": true + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + }, + "filename-regex": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.1.tgz", + "integrity": "sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY=", + "dev": true + }, + "fill-range": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.3.tgz", + "integrity": "sha1-ULd9/X5Gm8dJJHCWNpn+eoSFpyM=", + "dev": true, + "requires": { + "is-number": "2.1.0", + "isobject": "2.1.0", + "randomatic": "1.1.7", + "repeat-element": "1.1.2", + "repeat-string": "1.6.1" + } + }, + "finalhandler": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.0.3.tgz", + "integrity": "sha1-70fneVDpmXgOhgIqVg4yF+DQzIk=", + "dev": true, + "requires": { + "debug": "2.6.7", + "encodeurl": "1.0.1", + "escape-html": "1.0.3", + "on-finished": "2.3.0", + "parseurl": "1.3.1", + "statuses": "1.3.1", + "unpipe": "1.0.0" + } + }, + "for-in": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", + "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=", + "dev": true + }, + "for-own": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/for-own/-/for-own-0.1.5.tgz", + "integrity": "sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4=", + "dev": true, + "requires": { + "for-in": "1.0.2" + } + }, + "fs-access": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/fs-access/-/fs-access-1.0.1.tgz", + "integrity": "sha1-1qh/JiJxzv6+wwxVNAf7mV2od3o=", + "dev": true, + "requires": { + "null-check": "1.0.0" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fsevents": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-1.1.2.tgz", + "integrity": "sha512-Sn44E5wQW4bTHXvQmvSHwqbuiXtduD6Rrjm2ZtUEGbyrig+nUH3t/QD4M4/ZXViY556TBpRgZkHLDx3JxPwxiw==", + "dev": true, + "optional": true, + "requires": { + "nan": "2.6.2", + "node-pre-gyp": "0.6.36" + }, + "dependencies": { + "abbrev": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.0.tgz", + "integrity": "sha1-0FVMIlZjbi9W58LlrRg/hZQo2B8=", + "dev": true, + "optional": true + }, + "ajv": { + "version": "4.11.8", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-4.11.8.tgz", + "integrity": "sha1-gv+wKynmYq5TvcIK8VlHcGc5xTY=", + "dev": true, + "optional": true, + "requires": { + "co": "4.6.0", + "json-stable-stringify": "1.0.1" + } + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "dev": true + }, + "aproba": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.1.1.tgz", + "integrity": "sha1-ldNgDwdxCqDpKYxyatXs8urLq6s=", + "dev": true, + "optional": true + }, + "are-we-there-yet": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.4.tgz", + "integrity": "sha1-u13KOCu5TwXhUZQ3PRb9O6HKEQ0=", + "dev": true, + "optional": true, + "requires": { + "delegates": "1.0.0", + "readable-stream": "2.2.9" + } + }, + "asn1": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.3.tgz", + "integrity": "sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y=", + "dev": true, + "optional": true + }, + "assert-plus": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.2.0.tgz", + "integrity": "sha1-104bh+ev/A24qttwIfP+SBAasjQ=", + "dev": true, + "optional": true + }, + "asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", + "dev": true, + "optional": true + }, + "aws-sign2": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.6.0.tgz", + "integrity": "sha1-FDQt0428yU0OW4fXY81jYSwOeU8=", + "dev": true, + "optional": true + }, + "aws4": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.6.0.tgz", + "integrity": "sha1-g+9cqGCysy5KDe7e6MdxudtXRx4=", + "dev": true, + "optional": true + }, + "balanced-match": { + "version": "0.4.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-0.4.2.tgz", + "integrity": "sha1-yz8+PHMtwPAe5wtAPzAuYddwmDg=", + "dev": true + }, + "bcrypt-pbkdf": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz", + "integrity": "sha1-Y7xdy2EzG5K8Bf1SiVPDNGKgb40=", + "dev": true, + "optional": true, + "requires": { + "tweetnacl": "0.14.5" + } + }, + "block-stream": { + "version": "0.0.9", + "resolved": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz", + "integrity": "sha1-E+v+d4oDIFz+A3UUgeu0szAMEmo=", + "dev": true, + "requires": { + "inherits": "2.0.3" + } + }, + "boom": { + "version": "2.10.1", + "resolved": "https://registry.npmjs.org/boom/-/boom-2.10.1.tgz", + "integrity": "sha1-OciRjO/1eZ+D+UkqhI9iWt0Mdm8=", + "dev": true, + "requires": { + "hoek": "2.16.3" + } + }, + "brace-expansion": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.7.tgz", + "integrity": "sha1-Pv/DxQ4ABTH7cg6v+A8K6O8jz1k=", + "dev": true, + "requires": { + "balanced-match": "0.4.2", + "concat-map": "0.0.1" + } + }, + "buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha1-mXjOMXOIxkmth5MCjDR37wRKi1E=", + "dev": true + }, + "caseless": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", + "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", + "dev": true, + "optional": true + }, + "co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=", + "dev": true, + "optional": true + }, + "code-point-at": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", + "dev": true + }, + "combined-stream": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.5.tgz", + "integrity": "sha1-k4NwpXtKUd6ix3wV1cX9+JUWQAk=", + "dev": true, + "requires": { + "delayed-stream": "1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", + "dev": true + }, + "console-control-strings": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", + "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", + "dev": true + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", + "dev": true + }, + "cryptiles": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-2.0.5.tgz", + "integrity": "sha1-O9/s3GCBR8HGcgL6KR59ylnqo7g=", + "dev": true, + "optional": true, + "requires": { + "boom": "2.10.1" + } + }, + "dashdash": { + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", + "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", + "dev": true, + "optional": true + } + } + }, + "debug": { + "version": "2.6.8", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.8.tgz", + "integrity": "sha1-5zFTHKLt4n0YgiJCfaF4IdaP9Pw=", + "dev": true, + "optional": true, + "requires": { + "ms": "2.0.0" + } + }, + "deep-extend": { + "version": "0.4.2", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.4.2.tgz", + "integrity": "sha1-SLaZwn4zS/ifEIkr5DL25MfTSn8=", + "dev": true, + "optional": true + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", + "dev": true + }, + "delegates": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", + "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", + "dev": true, + "optional": true + }, + "ecc-jsbn": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz", + "integrity": "sha1-D8c6ntXw1Tw4GTOYUj735UN3dQU=", + "dev": true, + "optional": true, + "requires": { + "jsbn": "0.1.1" + } + }, + "extend": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=", + "dev": true, + "optional": true + }, + "extsprintf": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.0.2.tgz", + "integrity": "sha1-4QgOBljjALBilJkMxw4VAiNf1VA=", + "dev": true + }, + "forever-agent": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", + "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", + "dev": true, + "optional": true + }, + "form-data": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.1.4.tgz", + "integrity": "sha1-M8GDrPGTJ27KqYFDpp6Uv+4XUNE=", + "dev": true, + "optional": true, + "requires": { + "asynckit": "0.4.0", + "combined-stream": "1.0.5", + "mime-types": "2.1.15" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", + "dev": true + }, + "fstream": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/fstream/-/fstream-1.0.11.tgz", + "integrity": "sha1-XB+x8RdHcRTwYyoOtLcbPLD9MXE=", + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "inherits": "2.0.3", + "mkdirp": "0.5.1", + "rimraf": "2.6.1" + } + }, + "fstream-ignore": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/fstream-ignore/-/fstream-ignore-1.0.5.tgz", + "integrity": "sha1-nDHa40dnAY/h0kmyTa2mfQktoQU=", + "dev": true, + "optional": true, + "requires": { + "fstream": "1.0.11", + "inherits": "2.0.3", + "minimatch": "3.0.4" + } + }, + "gauge": { + "version": "2.7.4", + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", + "dev": true, + "optional": true, + "requires": { + "aproba": "1.1.1", + "console-control-strings": "1.1.0", + "has-unicode": "2.0.1", + "object-assign": "4.1.1", + "signal-exit": "3.0.2", + "string-width": "1.0.2", + "strip-ansi": "3.0.1", + "wide-align": "1.1.2" + } + }, + "getpass": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", + "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", + "dev": true, + "optional": true + } + } + }, + "glob": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", + "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "dev": true, + "requires": { + "fs.realpath": "1.0.0", + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "3.0.4", + "once": "1.4.0", + "path-is-absolute": "1.0.1" + } + }, + "graceful-fs": { + "version": "4.1.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", + "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", + "dev": true + }, + "har-schema": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-1.0.5.tgz", + "integrity": "sha1-0mMTX0MwfALGAq/I/pWXDAFRNp4=", + "dev": true, + "optional": true + }, + "har-validator": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-4.2.1.tgz", + "integrity": "sha1-M0gdDxu/9gDdID11gSpqX7oALio=", + "dev": true, + "optional": true, + "requires": { + "ajv": "4.11.8", + "har-schema": "1.0.5" + } + }, + "has-unicode": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", + "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", + "dev": true, + "optional": true + }, + "hawk": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/hawk/-/hawk-3.1.3.tgz", + "integrity": "sha1-B4REvXwWQLD+VA0sm3PVlnjo4cQ=", + "dev": true, + "optional": true, + "requires": { + "boom": "2.10.1", + "cryptiles": "2.0.5", + "hoek": "2.16.3", + "sntp": "1.0.9" + } + }, + "hoek": { + "version": "2.16.3", + "resolved": "https://registry.npmjs.org/hoek/-/hoek-2.16.3.tgz", + "integrity": "sha1-ILt0A9POo5jpHcRxCo/xuCdKJe0=", + "dev": true + }, + "http-signature": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.1.1.tgz", + "integrity": "sha1-33LiZwZs0Kxn+3at+OE0qPvPkb8=", + "dev": true, + "optional": true, + "requires": { + "assert-plus": "0.2.0", + "jsprim": "1.4.0", + "sshpk": "1.13.0" + } + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "1.4.0", + "wrappy": "1.0.2" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", + "dev": true + }, + "ini": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.4.tgz", + "integrity": "sha1-BTfLedr1m1mhpRff9wbIbsA5Fi4=", + "dev": true, + "optional": true + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "dev": true, + "requires": { + "number-is-nan": "1.0.1" + } + }, + "is-typedarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", + "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", + "dev": true, + "optional": true + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "dev": true + }, + "isstream": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", + "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=", + "dev": true, + "optional": true + }, + "jodid25519": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/jodid25519/-/jodid25519-1.0.2.tgz", + "integrity": "sha1-BtSRIlUJNBlHfUJWM2BuDpB4KWc=", + "dev": true, + "optional": true, + "requires": { + "jsbn": "0.1.1" + } + }, + "jsbn": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", + "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", + "dev": true, + "optional": true + }, + "json-schema": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", + "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", + "dev": true, + "optional": true + }, + "json-stable-stringify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz", + "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=", + "dev": true, + "optional": true, + "requires": { + "jsonify": "0.0.0" + } + }, + "json-stringify-safe": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", + "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", + "dev": true, + "optional": true + }, + "jsonify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz", + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=", + "dev": true, + "optional": true + }, + "jsprim": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.0.tgz", + "integrity": "sha1-o7h+QCmNjDgFUtjMdiigu5WiKRg=", + "dev": true, + "optional": true, + "requires": { + "assert-plus": "1.0.0", + "extsprintf": "1.0.2", + "json-schema": "0.2.3", + "verror": "1.3.6" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", + "dev": true, + "optional": true + } + } + }, + "mime-db": { + "version": "1.27.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.27.0.tgz", + "integrity": "sha1-gg9XIpa70g7CXtVeW13oaeVDbrE=", + "dev": true + }, + "mime-types": { + "version": "2.1.15", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.15.tgz", + "integrity": "sha1-pOv1BkCUVpI3uM9wBGd20J/JKu0=", + "dev": true, + "requires": { + "mime-db": "1.27.0" + } + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "1.1.7" + } + }, + "minimist": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", + "dev": true + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "dev": true, + "requires": { + "minimist": "0.0.8" + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "dev": true, + "optional": true + }, + "node-pre-gyp": { + "version": "0.6.36", + "resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.6.36.tgz", + "integrity": "sha1-22BBEst04NR3VU6bUFsXq936t4Y=", + "dev": true, + "optional": true, + "requires": { + "mkdirp": "0.5.1", + "nopt": "4.0.1", + "npmlog": "4.1.0", + "rc": "1.2.1", + "request": "2.81.0", + "rimraf": "2.6.1", + "semver": "5.3.0", + "tar": "2.2.1", + "tar-pack": "3.4.0" + } + }, + "nopt": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", + "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", + "dev": true, + "optional": true, + "requires": { + "abbrev": "1.1.0", + "osenv": "0.1.4" + } + }, + "npmlog": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.0.tgz", + "integrity": "sha512-ocolIkZYZt8UveuiDS0yAkkIjid1o7lPG8cYm05yNYzBn8ykQtaiPMEGp8fY9tKdDgm8okpdKzkvu1y9hUYugA==", + "dev": true, + "optional": true, + "requires": { + "are-we-there-yet": "1.1.4", + "console-control-strings": "1.1.0", + "gauge": "2.7.4", + "set-blocking": "2.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", + "dev": true + }, + "oauth-sign": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.8.2.tgz", + "integrity": "sha1-Rqarfwrq2N6unsBWV4C31O/rnUM=", + "dev": true, + "optional": true + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", + "dev": true, + "optional": true + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1.0.2" + } + }, + "os-homedir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", + "dev": true, + "optional": true + }, + "os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", + "dev": true, + "optional": true + }, + "osenv": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.4.tgz", + "integrity": "sha1-Qv5tWVPfBsgGS+bxdsPQWqqjRkQ=", + "dev": true, + "optional": true, + "requires": { + "os-homedir": "1.0.2", + "os-tmpdir": "1.0.2" + } + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "performance-now": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-0.2.0.tgz", + "integrity": "sha1-M+8wxcd9TqIcWlOGnZG1bY8lVeU=", + "dev": true, + "optional": true + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M=", + "dev": true + }, + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true, + "optional": true + }, + "qs": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.4.0.tgz", + "integrity": "sha1-E+JtKK1rD/qpExLNO/cI7TUecjM=", + "dev": true, + "optional": true + }, + "rc": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.1.tgz", + "integrity": "sha1-LgPo5C7kULjLPc5lvhv4l04d/ZU=", + "dev": true, + "optional": true, + "requires": { + "deep-extend": "0.4.2", + "ini": "1.3.4", + "minimist": "1.2.0", + "strip-json-comments": "2.0.1" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", + "dev": true, + "optional": true + } + } + }, + "readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha1-z3jsb0ptHrQ9JkiMrJfwQudLf8g=", + "dev": true, + "requires": { + "buffer-shims": "1.0.0", + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "string_decoder": "1.0.1", + "util-deprecate": "1.0.2" + } + }, + "request": { + "version": "2.81.0", + "resolved": "https://registry.npmjs.org/request/-/request-2.81.0.tgz", + "integrity": "sha1-xpKJRqDgbF+Nb4qTM0af/aRimKA=", + "dev": true, + "optional": true, + "requires": { + "aws-sign2": "0.6.0", + "aws4": "1.6.0", + "caseless": "0.12.0", + "combined-stream": "1.0.5", + "extend": "3.0.1", + "forever-agent": "0.6.1", + "form-data": "2.1.4", + "har-validator": "4.2.1", + "hawk": "3.1.3", + "http-signature": "1.1.1", + "is-typedarray": "1.0.0", + "isstream": "0.1.2", + "json-stringify-safe": "5.0.1", + "mime-types": "2.1.15", + "oauth-sign": "0.8.2", + "performance-now": "0.2.0", + "qs": "6.4.0", + "safe-buffer": "5.0.1", + "stringstream": "0.0.5", + "tough-cookie": "2.3.2", + "tunnel-agent": "0.6.0", + "uuid": "3.0.1" + } + }, + "rimraf": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.1.tgz", + "integrity": "sha1-wjOOxkPfeht/5cVPqG9XQopV8z0=", + "dev": true, + "requires": { + "glob": "7.1.2" + } + }, + "safe-buffer": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.0.1.tgz", + "integrity": "sha1-0mPKVGls2KMGtcplUekt5XkY++c=", + "dev": true + }, + "semver": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.3.0.tgz", + "integrity": "sha1-myzl094C0XxgEq0yaqa00M9U+U8=", + "dev": true, + "optional": true + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true, + "optional": true + }, + "signal-exit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", + "dev": true, + "optional": true + }, + "sntp": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/sntp/-/sntp-1.0.9.tgz", + "integrity": "sha1-ZUEYTMkK7qbG57NeJlkIJEPGYZg=", + "dev": true, + "optional": true, + "requires": { + "hoek": "2.16.3" + } + }, + "sshpk": { + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.13.0.tgz", + "integrity": "sha1-/yo+T9BEl1Vf7Zezmg/YL6+zozw=", + "dev": true, + "optional": true, + "requires": { + "asn1": "0.2.3", + "assert-plus": "1.0.0", + "bcrypt-pbkdf": "1.0.1", + "dashdash": "1.14.1", + "ecc-jsbn": "0.1.1", + "getpass": "0.1.7", + "jodid25519": "1.0.2", + "jsbn": "0.1.1", + "tweetnacl": "0.14.5" + }, + "dependencies": { + "assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", + "dev": true, + "optional": true + } + } + }, + "string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "dev": true, + "requires": { + "code-point-at": "1.1.0", + "is-fullwidth-code-point": "1.0.0", + "strip-ansi": "3.0.1" + } + }, + "string_decoder": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.1.tgz", + "integrity": "sha1-YuIA8DmVWmgQ2N8KM//A8BNmLZg=", + "dev": true, + "requires": { + "safe-buffer": "5.0.1" + } + }, + "stringstream": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/stringstream/-/stringstream-0.0.5.tgz", + "integrity": "sha1-TkhM1N5aC7vuGORjB3EKioFiGHg=", + "dev": true, + "optional": true + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "dev": true, + "requires": { + "ansi-regex": "2.1.1" + } + }, + "strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", + "dev": true, + "optional": true + }, + "tar": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/tar/-/tar-2.2.1.tgz", + "integrity": "sha1-jk0qJWwOIYXGsYrWlK7JaLg8sdE=", + "dev": true, + "requires": { + "block-stream": "0.0.9", + "fstream": "1.0.11", + "inherits": "2.0.3" + } + }, + "tar-pack": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/tar-pack/-/tar-pack-3.4.0.tgz", + "integrity": "sha1-I74tf2cagzk3bL2wuP4/3r8xeYQ=", + "dev": true, + "optional": true, + "requires": { + "debug": "2.6.8", + "fstream": "1.0.11", + "fstream-ignore": "1.0.5", + "once": "1.4.0", + "readable-stream": "2.2.9", + "rimraf": "2.6.1", + "tar": "2.2.1", + "uid-number": "0.0.6" + } + }, + "tough-cookie": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.3.2.tgz", + "integrity": "sha1-8IH3bkyFcg5sN6X6ztc3FQ2EByo=", + "dev": true, + "optional": true, + "requires": { + "punycode": "1.4.1" + } + }, + "tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", + "dev": true, + "optional": true, + "requires": { + "safe-buffer": "5.0.1" + } + }, + "tweetnacl": { + "version": "0.14.5", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", + "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", + "dev": true, + "optional": true + }, + "uid-number": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/uid-number/-/uid-number-0.0.6.tgz", + "integrity": "sha1-DqEOgDXo61uOREnwbaHHMGY7qoE=", + "dev": true, + "optional": true + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", + "dev": true + }, + "uuid": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.0.1.tgz", + "integrity": "sha1-ZUS7ot/ajBzxfmKaOjBeK7H+5sE=", + "dev": true, + "optional": true + }, + "verror": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/verror/-/verror-1.3.6.tgz", + "integrity": "sha1-z/XfEpRtKX0rqu+qJoniW+AcAFw=", + "dev": true, + "optional": true, + "requires": { + "extsprintf": "1.0.2" + } + }, + "wide-align": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.2.tgz", + "integrity": "sha512-ijDLlyQ7s6x1JgCLur53osjm/UXUYD9+0PbYKrBsYisYXzCxN+HC3mYDNy/dWdmf3AwqwU3CXwDCvsNgGK1S0w==", + "dev": true, + "optional": true, + "requires": { + "string-width": "1.0.2" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + } + } + }, + "function-bind": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.0.tgz", + "integrity": "sha1-FhdnFMgBeY5Ojyz391KUZ7tKV3E=", + "dev": true + }, + "glob": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", + "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "dev": true, + "requires": { + "fs.realpath": "1.0.0", + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "3.0.4", + "once": "1.4.0", + "path-is-absolute": "1.0.1" + } + }, + "glob-base": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/glob-base/-/glob-base-0.3.0.tgz", + "integrity": "sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q=", + "dev": true, + "requires": { + "glob-parent": "2.0.0", + "is-glob": "2.0.1" + } + }, + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "dev": true, + "requires": { + "is-glob": "2.0.1" + } + }, + "graceful-fs": { + "version": "4.1.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", + "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", + "dev": true + }, + "graceful-readlink": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/graceful-readlink/-/graceful-readlink-1.0.1.tgz", + "integrity": "sha1-TK+tdrxi8C+gObL5Tpo906ORpyU=", + "dev": true + }, + "growl": { + "version": "1.9.2", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.9.2.tgz", + "integrity": "sha1-Dqd0NxXbjY3ixe3hd14bRayFwC8=", + "dev": true + }, + "has": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.1.tgz", + "integrity": "sha1-hGFzP1OLCDfJNh45qauelwTcLyg=", + "dev": true, + "requires": { + "function-bind": "1.1.0" + } + }, + "has-binary": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/has-binary/-/has-binary-0.1.7.tgz", + "integrity": "sha1-aOYesWIQyVRaClzOBqhzkS/h5ow=", + "dev": true, + "requires": { + "isarray": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + } + } + }, + "has-cors": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-cors/-/has-cors-1.1.0.tgz", + "integrity": "sha1-XkdHk/fqmEPRu5nCPu9J/xJv/zk=", + "dev": true + }, + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "dev": true + }, + "hash-base": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hash-base/-/hash-base-2.0.2.tgz", + "integrity": "sha1-ZuodhW206KVHDK32/OI65SRO8uE=", + "dev": true, + "requires": { + "inherits": "2.0.3" + } + }, + "hash.js": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.1.tgz", + "integrity": "sha512-I2TYCUjYQMmqmRMCp6jKMC5bvdXxGIZ/heITRR/0F1u0OP920ImEj/cXt3WgcTKBnNYGn7enxUzdai3db829JA==", + "dev": true, + "requires": { + "inherits": "2.0.3", + "minimalistic-assert": "1.0.0" + } + }, + "hat": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/hat/-/hat-0.0.3.tgz", + "integrity": "sha1-uwFKnmSzeIrtgAWRdBPU/z1QLYo=", + "dev": true + }, + "hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha1-0nRXAQJabHdabFRXk+1QL8DGSaE=", + "dev": true, + "requires": { + "hash.js": "1.1.1", + "minimalistic-assert": "1.0.0", + "minimalistic-crypto-utils": "1.0.1" + } + }, + "htmlescape": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/htmlescape/-/htmlescape-1.1.1.tgz", + "integrity": "sha1-OgPtwiFLyjtmQko+eVk0lQnLA1E=", + "dev": true + }, + "http-errors": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.1.tgz", + "integrity": "sha1-X4uO2YrKVFZWv1cplzh/kEpyIlc=", + "dev": true, + "requires": { + "depd": "1.1.0", + "inherits": "2.0.3", + "setprototypeof": "1.0.3", + "statuses": "1.3.1" + } + }, + "http-proxy": { + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.16.2.tgz", + "integrity": "sha1-Bt/ykpUr9k2+hHH6nfcwZtTzd0I=", + "dev": true, + "requires": { + "eventemitter3": "1.2.0", + "requires-port": "1.0.0" + } + }, + "https-browserify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/https-browserify/-/https-browserify-1.0.0.tgz", + "integrity": "sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM=", + "dev": true + }, + "iconv-lite": { + "version": "0.4.15", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.15.tgz", + "integrity": "sha1-/iZaIYrGpXz+hUkn6dBMGYJe3es=", + "dev": true + }, + "ieee754": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.1.8.tgz", + "integrity": "sha1-vjPUCsEO8ZJnAfbwii2G+/0a0+Q=", + "dev": true + }, + "indexof": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/indexof/-/indexof-0.0.1.tgz", + "integrity": "sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10=", + "dev": true + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "dev": true, + "requires": { + "once": "1.4.0", + "wrappy": "1.0.2" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", + "dev": true + }, + "inline-source-map": { + "version": "0.6.2", + "resolved": "https://registry.npmjs.org/inline-source-map/-/inline-source-map-0.6.2.tgz", + "integrity": "sha1-+Tk0ccGKedFyT4Y/o4tYY3Ct4qU=", + "dev": true, + "requires": { + "source-map": "0.5.6" + } + }, + "insert-module-globals": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/insert-module-globals/-/insert-module-globals-7.0.1.tgz", + "integrity": "sha1-wDv04BywhtW15azorQr+eInWOMM=", + "dev": true, + "requires": { + "JSONStream": "1.3.1", + "combine-source-map": "0.7.2", + "concat-stream": "1.5.2", + "is-buffer": "1.1.5", + "lexical-scope": "1.2.0", + "process": "0.11.10", + "through2": "2.0.3", + "xtend": "4.0.1" + } + }, + "is-binary-path": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-1.0.1.tgz", + "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", + "dev": true, + "requires": { + "binary-extensions": "1.8.0" + } + }, + "is-buffer": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.5.tgz", + "integrity": "sha1-Hzsm72E7IUuIy8ojzGwB2Hlh7sw=", + "dev": true + }, + "is-dotfile": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-dotfile/-/is-dotfile-1.0.3.tgz", + "integrity": "sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE=", + "dev": true + }, + "is-equal-shallow": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/is-equal-shallow/-/is-equal-shallow-0.1.3.tgz", + "integrity": "sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ=", + "dev": true, + "requires": { + "is-primitive": "2.0.0" + } + }, + "is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=", + "dev": true + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=", + "dev": true + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "dev": true, + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-number": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-2.1.0.tgz", + "integrity": "sha1-Afy7s5NGOlSPL0ZszhbezknbkI8=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + } + }, + "is-posix-bracket": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz", + "integrity": "sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q=", + "dev": true + }, + "is-primitive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-primitive/-/is-primitive-2.0.0.tgz", + "integrity": "sha1-IHurkWOEmcB7Kt8kCkGochADRXU=", + "dev": true + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", + "dev": true + }, + "isbinaryfile": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/isbinaryfile/-/isbinaryfile-3.0.2.tgz", + "integrity": "sha1-Sj6XTsDLqQBNP8bN5yCeppNopiE=", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "isobject": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "dev": true, + "requires": { + "isarray": "1.0.0" + } + }, + "js-string-escape": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/js-string-escape/-/js-string-escape-1.0.1.tgz", + "integrity": "sha1-4mJbrbwNZ8dTPp7cEGjFh65BN+8=", + "dev": true + }, + "json-stable-stringify": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-0.0.1.tgz", + "integrity": "sha1-YRwj6BTbN1Un34URk9tZ3Sryf0U=", + "dev": true, + "requires": { + "jsonify": "0.0.0" + } + }, + "json3": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/json3/-/json3-3.3.2.tgz", + "integrity": "sha1-PAQ0dD35Pi9cQq7nsZvLSDV19OE=", + "dev": true + }, + "jsonify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz", + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=", + "dev": true + }, + "jsonparse": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/jsonparse/-/jsonparse-1.3.1.tgz", + "integrity": "sha1-P02uSpH6wxX3EGL4UhzCOfE2YoA=", + "dev": true + }, + "karma": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/karma/-/karma-1.7.0.tgz", + "integrity": "sha1-b3oaQGRG+i4YfslTmGmPTO5HYmk=", + "dev": true, + "requires": { + "bluebird": "3.5.0", + "body-parser": "1.17.2", + "chokidar": "1.7.0", + "colors": "1.1.2", + "combine-lists": "1.0.1", + "connect": "3.6.2", + "core-js": "2.4.1", + "di": "0.0.1", + "dom-serialize": "2.2.1", + "expand-braces": "0.1.2", + "glob": "7.1.2", + "graceful-fs": "4.1.11", + "http-proxy": "1.16.2", + "isbinaryfile": "3.0.2", + "lodash": "3.10.1", + "log4js": "0.6.38", + "mime": "1.3.6", + "minimatch": "3.0.4", + "optimist": "0.6.1", + "qjobs": "1.1.5", + "range-parser": "1.2.0", + "rimraf": "2.6.1", + "safe-buffer": "5.1.1", + "socket.io": "1.7.3", + "source-map": "0.5.6", + "tmp": "0.0.31", + "useragent": "2.1.13" + }, + "dependencies": { + "lodash": { + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", + "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", + "dev": true + } + } + }, + "karma-browserify": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/karma-browserify/-/karma-browserify-5.1.1.tgz", + "integrity": "sha1-9kLXDXdtmrO3NSbFcyq8/qJAAxk=", + "dev": true, + "requires": { + "convert-source-map": "1.1.3", + "hat": "0.0.3", + "js-string-escape": "1.0.1", + "lodash": "3.10.1", + "minimatch": "3.0.4", + "os-shim": "0.1.3" + }, + "dependencies": { + "lodash": { + "version": "3.10.1", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-3.10.1.tgz", + "integrity": "sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y=", + "dev": true + } + } + }, + "karma-chrome-launcher": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/karma-chrome-launcher/-/karma-chrome-launcher-2.2.0.tgz", + "integrity": "sha512-uf/ZVpAabDBPvdPdveyk1EPgbnloPvFFGgmRhYLTDH7gEB4nZdSBk8yTU47w1g/drLSx5uMOkjKk7IWKfWg/+w==", + "dev": true, + "requires": { + "fs-access": "1.0.1", + "which": "1.2.14" + } + }, + "karma-firefox-launcher": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/karma-firefox-launcher/-/karma-firefox-launcher-1.0.1.tgz", + "integrity": "sha1-zlj0fCATqIFW1VpdYTN8CZz1u1E=", + "dev": true + }, + "karma-mocha": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/karma-mocha/-/karma-mocha-1.3.0.tgz", + "integrity": "sha1-7qrH/8DiAetjxGdEDStpx883eL8=", + "dev": true, + "requires": { + "minimist": "1.2.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.5" + } + }, + "labeled-stream-splicer": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/labeled-stream-splicer/-/labeled-stream-splicer-2.0.0.tgz", + "integrity": "sha1-pS4dE4AkwAuGscDJH2d5GLiuClk=", + "dev": true, + "requires": { + "inherits": "2.0.3", + "isarray": "0.0.1", + "stream-splicer": "2.0.0" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + } + } + }, + "lexical-scope": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/lexical-scope/-/lexical-scope-1.2.0.tgz", + "integrity": "sha1-/Ope3HBKSzqHls3KQZw6CvryLfQ=", + "dev": true, + "requires": { + "astw": "2.2.0" + } + }, + "lodash._baseassign": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/lodash._baseassign/-/lodash._baseassign-3.2.0.tgz", + "integrity": "sha1-jDigmVAPIVrQnlnxci/QxSv+Ck4=", + "dev": true, + "requires": { + "lodash._basecopy": "3.0.1", + "lodash.keys": "3.1.2" + } + }, + "lodash._basecopy": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz", + "integrity": "sha1-jaDmqHbPNEwK2KVIghEd08XHyjY=", + "dev": true + }, + "lodash._basecreate": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/lodash._basecreate/-/lodash._basecreate-3.0.3.tgz", + "integrity": "sha1-G8ZhYU2qf8MRt9A78WgGoCE8+CE=", + "dev": true + }, + "lodash._getnative": { + "version": "3.9.1", + "resolved": "https://registry.npmjs.org/lodash._getnative/-/lodash._getnative-3.9.1.tgz", + "integrity": "sha1-VwvH3t5G1hzc3mh9ZdPuy6o6r/U=", + "dev": true + }, + "lodash._isiterateecall": { + "version": "3.0.9", + "resolved": "https://registry.npmjs.org/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz", + "integrity": "sha1-UgOte6Ql+uhCRg5pbbnPPmqsBXw=", + "dev": true + }, + "lodash.create": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/lodash.create/-/lodash.create-3.1.1.tgz", + "integrity": "sha1-1/KEnw29p+BGgruM1yqwIkYd6+c=", + "dev": true, + "requires": { + "lodash._baseassign": "3.2.0", + "lodash._basecreate": "3.0.3", + "lodash._isiterateecall": "3.0.9" + } + }, + "lodash.isarguments": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz", + "integrity": "sha1-L1c9hcaiQon/AGY7SRwdM4/zRYo=", + "dev": true + }, + "lodash.isarray": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/lodash.isarray/-/lodash.isarray-3.0.4.tgz", + "integrity": "sha1-eeTriMNqgSKvhvhEqpvNhRtfu1U=", + "dev": true + }, + "lodash.keys": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/lodash.keys/-/lodash.keys-3.1.2.tgz", + "integrity": "sha1-TbwEcrFWvlCgsoaFXRvQsMZWCYo=", + "dev": true, + "requires": { + "lodash._getnative": "3.9.1", + "lodash.isarguments": "3.1.0", + "lodash.isarray": "3.0.4" + } + }, + "lodash.memoize": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-3.0.4.tgz", + "integrity": "sha1-LcvSwofLwKVcxCMovQxzYVDVPj8=", + "dev": true + }, + "lodash.merge": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.0.tgz", + "integrity": "sha1-aYhLoUSsM/5plzemCG3v+t0PicU=" + }, + "log4js": { + "version": "0.6.38", + "resolved": "https://registry.npmjs.org/log4js/-/log4js-0.6.38.tgz", + "integrity": "sha1-LElBFmldb7JUgJQ9P8hy5mKlIv0=", + "dev": true, + "requires": { + "readable-stream": "1.0.34", + "semver": "4.3.6" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "0.0.1", + "string_decoder": "0.10.31" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + } + } + }, + "lru-cache": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-2.2.4.tgz", + "integrity": "sha1-bGWGGb7PFAMdDQtZSxYELOTcBj0=", + "dev": true + }, + "media-typer": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=", + "dev": true + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "dev": true, + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.3" + }, + "dependencies": { + "normalize-path": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", + "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", + "dev": true, + "requires": { + "remove-trailing-separator": "1.0.2" + } + } + } + }, + "miller-rabin": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/miller-rabin/-/miller-rabin-4.0.0.tgz", + "integrity": "sha1-SmL7HUKTPAVYOYL0xxb2+55sbT0=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "brorand": "1.1.0" + } + }, + "mime": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.3.6.tgz", + "integrity": "sha1-WR2E02U6awtKO5343lqoEI5y5eA=", + "dev": true + }, + "mime-db": { + "version": "1.27.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.27.0.tgz", + "integrity": "sha1-gg9XIpa70g7CXtVeW13oaeVDbrE=", + "dev": true + }, + "mime-types": { + "version": "2.1.15", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.15.tgz", + "integrity": "sha1-pOv1BkCUVpI3uM9wBGd20J/JKu0=", + "dev": true, + "requires": { + "mime-db": "1.27.0" + } + }, + "minimalistic-assert": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.0.tgz", + "integrity": "sha1-cCvi3aazf0g2vLP121ZkG2Sh09M=", + "dev": true + }, + "minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo=", + "dev": true + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "dev": true, + "requires": { + "brace-expansion": "1.1.8" + } + }, + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", + "dev": true + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "dev": true, + "requires": { + "minimist": "0.0.8" + }, + "dependencies": { + "minimist": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", + "dev": true + } + } + }, + "mocha": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-3.4.2.tgz", + "integrity": "sha1-0O9NMyEm2/GNDWQMmzgt1IvpdZQ=", + "dev": true, + "requires": { + "browser-stdout": "1.3.0", + "commander": "2.9.0", + "debug": "2.6.0", + "diff": "3.2.0", + "escape-string-regexp": "1.0.5", + "glob": "7.1.1", + "growl": "1.9.2", + "json3": "3.3.2", + "lodash.create": "3.1.1", + "mkdirp": "0.5.1", + "supports-color": "3.1.2" + }, + "dependencies": { + "commander": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.9.0.tgz", + "integrity": "sha1-nJkJQXbhIkDLItbFFGCYQA/g99Q=", + "dev": true, + "requires": { + "graceful-readlink": "1.0.1" + } + }, + "debug": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.0.tgz", + "integrity": "sha1-vFlryr52F/Edn6FTYe3tVgi4SZs=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "glob": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz", + "integrity": "sha1-gFIR3wT6rxxjo2ADBs31reULLsg=", + "dev": true, + "requires": { + "fs.realpath": "1.0.0", + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "3.0.4", + "once": "1.4.0", + "path-is-absolute": "1.0.1" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + }, + "supports-color": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.1.2.tgz", + "integrity": "sha1-cqJiiU2dQIuVbKBf83su2KbiotU=", + "dev": true, + "requires": { + "has-flag": "1.0.0" + } + } + } + }, + "module-deps": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/module-deps/-/module-deps-4.1.1.tgz", + "integrity": "sha1-IyFYM/HaE/1gbMuAh7RIUty4If0=", + "dev": true, + "requires": { + "JSONStream": "1.3.1", + "browser-resolve": "1.11.2", + "cached-path-relative": "1.0.1", + "concat-stream": "1.5.2", + "defined": "1.0.0", + "detective": "4.5.0", + "duplexer2": "0.1.4", + "inherits": "2.0.3", + "parents": "1.0.1", + "readable-stream": "2.3.2", + "resolve": "1.3.3", + "stream-combiner2": "1.1.1", + "subarg": "1.0.0", + "through2": "2.0.3", + "xtend": "4.0.1" + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "dev": true + }, + "nan": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.6.2.tgz", + "integrity": "sha1-5P805slf37WuzAjeZZb0NgWn20U=", + "dev": true, + "optional": true + }, + "negotiator": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.1.tgz", + "integrity": "sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk=", + "dev": true + }, + "null-check": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/null-check/-/null-check-1.0.0.tgz", + "integrity": "sha1-l33/1xdgErnsMNKjnbXPcqBDnt0=", + "dev": true + }, + "object-assign": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.0.tgz", + "integrity": "sha1-ejs9DpgGPUP0wD8uiubNUahog6A=", + "dev": true + }, + "object-component": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/object-component/-/object-component-0.0.3.tgz", + "integrity": "sha1-8MaapQ78lbhmwYb0AKM3acsvEpE=", + "dev": true + }, + "object.omit": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/object.omit/-/object.omit-2.0.1.tgz", + "integrity": "sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo=", + "dev": true, + "requires": { + "for-own": "0.1.5", + "is-extendable": "0.1.1" + } + }, + "on-finished": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", + "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", + "dev": true, + "requires": { + "ee-first": "1.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1.0.2" + } + }, + "optimist": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", + "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", + "dev": true, + "requires": { + "minimist": "0.0.10", + "wordwrap": "0.0.3" + }, + "dependencies": { + "minimist": { + "version": "0.0.10", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", + "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=", + "dev": true + } + } + }, + "options": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/options/-/options-0.0.6.tgz", + "integrity": "sha1-7CLTEoBrtT5zF3Pnza788cZDEo8=", + "dev": true + }, + "os-browserify": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/os-browserify/-/os-browserify-0.1.2.tgz", + "integrity": "sha1-ScoCk+CxlZCl9d4Qx/JlphfY/lQ=", + "dev": true + }, + "os-shim": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/os-shim/-/os-shim-0.1.3.tgz", + "integrity": "sha1-a2LDeRz3kJ6jXtRuF2WLtBfLORc=", + "dev": true + }, + "os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", + "dev": true + }, + "pako": { + "version": "0.2.9", + "resolved": "https://registry.npmjs.org/pako/-/pako-0.2.9.tgz", + "integrity": "sha1-8/dSL073gjSNqBYbrZ7P1Rv4OnU=", + "dev": true + }, + "parents": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parents/-/parents-1.0.1.tgz", + "integrity": "sha1-/t1NK/GTp3dF/nHjcdc8MwfZx1E=", + "dev": true, + "requires": { + "path-platform": "0.11.15" + } + }, + "parse-asn1": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.0.tgz", + "integrity": "sha1-N8T5t+06tlx0gXtfJICTf7+XxxI=", + "dev": true, + "requires": { + "asn1.js": "4.9.1", + "browserify-aes": "1.0.6", + "create-hash": "1.1.3", + "evp_bytestokey": "1.0.0", + "pbkdf2": "3.0.12" + } + }, + "parse-glob": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/parse-glob/-/parse-glob-3.0.4.tgz", + "integrity": "sha1-ssN2z7EfNVE7rdFz7wu246OIORw=", + "dev": true, + "requires": { + "glob-base": "0.3.0", + "is-dotfile": "1.0.3", + "is-extglob": "1.0.0", + "is-glob": "2.0.1" + } + }, + "parsejson": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/parsejson/-/parsejson-0.0.3.tgz", + "integrity": "sha1-q343WfIJ7OmUN5c/fQ8fZK4OZKs=", + "dev": true, + "requires": { + "better-assert": "1.0.2" + } + }, + "parseqs": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/parseqs/-/parseqs-0.0.5.tgz", + "integrity": "sha1-1SCKNzjkZ2bikbouoXNoSSGouJ0=", + "dev": true, + "requires": { + "better-assert": "1.0.2" + } + }, + "parseuri": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/parseuri/-/parseuri-0.0.5.tgz", + "integrity": "sha1-gCBKUNTbt3m/3G6+J3jZDkvOMgo=", + "dev": true, + "requires": { + "better-assert": "1.0.2" + } + }, + "parseurl": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.1.tgz", + "integrity": "sha1-yKuMkiO6NIiKpkopeyiFO+wY2lY=", + "dev": true + }, + "path-browserify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-0.0.0.tgz", + "integrity": "sha1-oLhwcpquIUAFt9UDLsLLuw+0RRo=", + "dev": true + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", + "dev": true + }, + "path-parse": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.5.tgz", + "integrity": "sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME=", + "dev": true + }, + "path-platform": { + "version": "0.11.15", + "resolved": "https://registry.npmjs.org/path-platform/-/path-platform-0.11.15.tgz", + "integrity": "sha1-6GQhf3TDaFDwhSt43Hv31KVyG/I=", + "dev": true + }, + "pbkdf2": { + "version": "3.0.12", + "resolved": "https://registry.npmjs.org/pbkdf2/-/pbkdf2-3.0.12.tgz", + "integrity": "sha1-vjZ4XFBn6kjYBv+SMojF91C2uKI=", + "dev": true, + "requires": { + "create-hash": "1.1.3", + "create-hmac": "1.1.6", + "ripemd160": "2.0.1", + "safe-buffer": "5.1.1", + "sha.js": "2.4.8" + } + }, + "preserve": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/preserve/-/preserve-0.2.0.tgz", + "integrity": "sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks=", + "dev": true + }, + "prettier": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-1.4.4.tgz", + "integrity": "sha512-GuuPazIvjW1DG26yLQgO+nagmRF/h9M4RaCtZWqu/eFW7csdZkQEwPJUeXX10d+LzmCnR9DuIZndqIOn3p2YoA==", + "dev": true + }, + "process": { + "version": "0.11.10", + "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", + "integrity": "sha1-czIwDoQBYb2j5podHZGn1LwW8YI=", + "dev": true + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M=", + "dev": true + }, + "public-encrypt": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.0.tgz", + "integrity": "sha1-OfaZ86RlYN1eusvKaTyvfGXBjMY=", + "dev": true, + "requires": { + "bn.js": "4.11.7", + "browserify-rsa": "4.0.1", + "create-hash": "1.1.3", + "parse-asn1": "5.1.0", + "randombytes": "2.0.5" + } + }, + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=", + "dev": true + }, + "qjobs": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/qjobs/-/qjobs-1.1.5.tgz", + "integrity": "sha1-ZZ3p8s+NzCehSBJ28gU3cnI4LnM=", + "dev": true + }, + "qs": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.4.0.tgz", + "integrity": "sha1-E+JtKK1rD/qpExLNO/cI7TUecjM=", + "dev": true + }, + "querystring": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/querystring/-/querystring-0.2.0.tgz", + "integrity": "sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA=", + "dev": true + }, + "querystring-es3": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/querystring-es3/-/querystring-es3-0.2.1.tgz", + "integrity": "sha1-nsYfeQSYdXB9aUFFlv2Qek1xHnM=", + "dev": true + }, + "randomatic": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/randomatic/-/randomatic-1.1.7.tgz", + "integrity": "sha512-D5JUjPyJbaJDkuAazpVnSfVkLlpeO3wDlPROTMLGKG1zMFNFRgrciKo1ltz/AzNTkqE0HzDx655QOL51N06how==", + "dev": true, + "requires": { + "is-number": "3.0.0", + "kind-of": "4.0.0" + }, + "dependencies": { + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "dev": true, + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "dev": true, + "requires": { + "is-buffer": "1.1.5" + } + } + } + }, + "kind-of": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", + "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", + "dev": true, + "requires": { + "is-buffer": "1.1.5" + } + } + } + }, + "randombytes": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.0.5.tgz", + "integrity": "sha512-8T7Zn1AhMsQ/HI1SjcCfT/t4ii3eAqco3yOcSzS4mozsOz69lHLsoMXmF9nZgnFanYscnSlUSgs8uZyKzpE6kg==", + "dev": true, + "requires": { + "safe-buffer": "5.1.1" + } + }, + "range-parser": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.0.tgz", + "integrity": "sha1-9JvmtIeJTdxA3MlKMi9hEJLgDV4=", + "dev": true + }, + "raw-body": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.2.0.tgz", + "integrity": "sha1-mUl2z2pQlqQRYoQEkvC9xdbn+5Y=", + "dev": true, + "requires": { + "bytes": "2.4.0", + "iconv-lite": "0.4.15", + "unpipe": "1.0.0" + } + }, + "read-only-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/read-only-stream/-/read-only-stream-2.0.0.tgz", + "integrity": "sha1-JyT9aoET1zdkrCiNQ4YnDB2/F/A=", + "dev": true, + "requires": { + "readable-stream": "2.3.2" + } + }, + "readable-stream": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.2.tgz", + "integrity": "sha1-WgTfBeT1f+Pw3Gj90R3FyXx+b00=", + "dev": true, + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "safe-buffer": "5.1.1", + "string_decoder": "1.0.3", + "util-deprecate": "1.0.2" + } + }, + "readdirp": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.1.0.tgz", + "integrity": "sha1-TtCtBg3zBzMAxIRANz9y0cxkLXg=", + "dev": true, + "requires": { + "graceful-fs": "4.1.11", + "minimatch": "3.0.4", + "readable-stream": "2.3.2", + "set-immediate-shim": "1.0.1" + } + }, + "regex-cache": { + "version": "0.4.3", + "resolved": "https://registry.npmjs.org/regex-cache/-/regex-cache-0.4.3.tgz", + "integrity": "sha1-mxpsNdTQ3871cRrmUejp09cRQUU=", + "dev": true, + "requires": { + "is-equal-shallow": "0.1.3", + "is-primitive": "2.0.0" + } + }, + "remove-trailing-separator": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.0.2.tgz", + "integrity": "sha1-abBi2XhyetFNxrVrpKt3L9jXBRE=", + "dev": true + }, + "repeat-element": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.2.tgz", + "integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo=", + "dev": true + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", + "dev": true + }, + "requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=", + "dev": true + }, + "resolve": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.3.3.tgz", + "integrity": "sha1-ZVkHw0aahoDcLeOidaj91paR8OU=", + "dev": true, + "requires": { + "path-parse": "1.0.5" + } + }, + "rimraf": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.1.tgz", + "integrity": "sha1-wjOOxkPfeht/5cVPqG9XQopV8z0=", + "dev": true, + "requires": { + "glob": "7.1.2" + } + }, + "ripemd160": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/ripemd160/-/ripemd160-2.0.1.tgz", + "integrity": "sha1-D0WEKVxTo2KK9+bXmsohzlfRxuc=", + "dev": true, + "requires": { + "hash-base": "2.0.2", + "inherits": "2.0.3" + } + }, + "safe-buffer": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", + "integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==", + "dev": true + }, + "semver": { + "version": "4.3.6", + "resolved": "https://registry.npmjs.org/semver/-/semver-4.3.6.tgz", + "integrity": "sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto=", + "dev": true + }, + "set-immediate-shim": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz", + "integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=", + "dev": true + }, + "setprototypeof": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.0.3.tgz", + "integrity": "sha1-ZlZ+NwQ+608E2RvWWMDL77VbjgQ=", + "dev": true + }, + "sha.js": { + "version": "2.4.8", + "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.8.tgz", + "integrity": "sha1-NwaMLEdra69ALRSknGf1l5IfY08=", + "dev": true, + "requires": { + "inherits": "2.0.3" + } + }, + "shasum": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/shasum/-/shasum-1.0.2.tgz", + "integrity": "sha1-5wEjENj0F/TetXEhUOVni4euVl8=", + "dev": true, + "requires": { + "json-stable-stringify": "0.0.1", + "sha.js": "2.4.8" + } + }, + "shell-quote": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/shell-quote/-/shell-quote-1.6.1.tgz", + "integrity": "sha1-9HgZSczkAmlxJ0MOo7PFR29IF2c=", + "dev": true, + "requires": { + "array-filter": "0.0.1", + "array-map": "0.0.0", + "array-reduce": "0.0.0", + "jsonify": "0.0.0" + } + }, + "socket.io": { + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-1.7.3.tgz", + "integrity": "sha1-uK+cq6AJSeVo42nxMn6pvp6iRhs=", + "dev": true, + "requires": { + "debug": "2.3.3", + "engine.io": "1.8.3", + "has-binary": "0.1.7", + "object-assign": "4.1.0", + "socket.io-adapter": "0.5.0", + "socket.io-client": "1.7.3", + "socket.io-parser": "2.3.1" + }, + "dependencies": { + "debug": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.3.3.tgz", + "integrity": "sha1-QMRT5n5uE8kB3ewxeviYbNqe/4w=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + } + } + }, + "socket.io-adapter": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-0.5.0.tgz", + "integrity": "sha1-y21LuL7IHhB4uZZ3+c7QBGBmu4s=", + "dev": true, + "requires": { + "debug": "2.3.3", + "socket.io-parser": "2.3.1" + }, + "dependencies": { + "debug": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.3.3.tgz", + "integrity": "sha1-QMRT5n5uE8kB3ewxeviYbNqe/4w=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + } + } + }, + "socket.io-client": { + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-1.7.3.tgz", + "integrity": "sha1-sw6GqhDV7zVGYBwJzeR2Xjgdo3c=", + "dev": true, + "requires": { + "backo2": "1.0.2", + "component-bind": "1.0.0", + "component-emitter": "1.2.1", + "debug": "2.3.3", + "engine.io-client": "1.8.3", + "has-binary": "0.1.7", + "indexof": "0.0.1", + "object-component": "0.0.3", + "parseuri": "0.0.5", + "socket.io-parser": "2.3.1", + "to-array": "0.1.4" + }, + "dependencies": { + "component-emitter": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", + "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=", + "dev": true + }, + "debug": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.3.3.tgz", + "integrity": "sha1-QMRT5n5uE8kB3ewxeviYbNqe/4w=", + "dev": true, + "requires": { + "ms": "0.7.2" + } + }, + "ms": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz", + "integrity": "sha1-riXPJRKziFodldfwN4aNhDESR2U=", + "dev": true + } + } + }, + "socket.io-parser": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-2.3.1.tgz", + "integrity": "sha1-3VMgJRA85Clpcya+/WQAX8/ltKA=", + "dev": true, + "requires": { + "component-emitter": "1.1.2", + "debug": "2.2.0", + "isarray": "0.0.1", + "json3": "3.3.2" + }, + "dependencies": { + "debug": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz", + "integrity": "sha1-+HBX6ZWxofauaklgZkE3vFbwOdo=", + "dev": true, + "requires": { + "ms": "0.7.1" + } + }, + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "ms": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz", + "integrity": "sha1-nNE8A62/8ltl7/3nzoZO6VIBcJg=", + "dev": true + } + } + }, + "source-map": { + "version": "0.5.6", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.6.tgz", + "integrity": "sha1-dc449SvwczxafwwRjYEzSiu19BI=", + "dev": true + }, + "statuses": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.3.1.tgz", + "integrity": "sha1-+vUbnrdKrvOzrPStX2Gr8ky3uT4=", + "dev": true + }, + "stream-browserify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.1.tgz", + "integrity": "sha1-ZiZu5fm9uZQKTkUUyvtDu3Hlyds=", + "dev": true, + "requires": { + "inherits": "2.0.3", + "readable-stream": "2.3.2" + } + }, + "stream-combiner2": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/stream-combiner2/-/stream-combiner2-1.1.1.tgz", + "integrity": "sha1-+02KFCDqNidk4hrUeAOXvry0HL4=", + "dev": true, + "requires": { + "duplexer2": "0.1.4", + "readable-stream": "2.3.2" + } + }, + "stream-http": { + "version": "2.7.2", + "resolved": "https://registry.npmjs.org/stream-http/-/stream-http-2.7.2.tgz", + "integrity": "sha512-c0yTD2rbQzXtSsFSVhtpvY/vS6u066PcXOX9kBB3mSO76RiUQzL340uJkGBWnlBg4/HZzqiUXtaVA7wcRcJgEw==", + "dev": true, + "requires": { + "builtin-status-codes": "3.0.0", + "inherits": "2.0.3", + "readable-stream": "2.3.2", + "to-arraybuffer": "1.0.1", + "xtend": "4.0.1" + } + }, + "stream-splicer": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/stream-splicer/-/stream-splicer-2.0.0.tgz", + "integrity": "sha1-G2O+Q4oTPktnHMGTUZdgAXWRDYM=", + "dev": true, + "requires": { + "inherits": "2.0.3", + "readable-stream": "2.3.2" + } + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "dev": true, + "requires": { + "safe-buffer": "5.1.1" + } + }, + "subarg": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/subarg/-/subarg-1.0.0.tgz", + "integrity": "sha1-9izxdYHplrSPyWVpn1TAauJouNI=", + "dev": true, + "requires": { + "minimist": "1.2.0" + } + }, + "syntax-error": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/syntax-error/-/syntax-error-1.3.0.tgz", + "integrity": "sha1-HtkmbE1AvnXcVb+bsct3Biu5bKE=", + "dev": true, + "requires": { + "acorn": "4.0.13" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=", + "dev": true + }, + "through2": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.3.tgz", + "integrity": "sha1-AARWmzfHx0ujnEPzzteNGtlBQL4=", + "dev": true, + "requires": { + "readable-stream": "2.3.2", + "xtend": "4.0.1" + } + }, + "timers-browserify": { + "version": "1.4.2", + "resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-1.4.2.tgz", + "integrity": "sha1-ycWLV1voQHN1y14kYtrO50NZ9B0=", + "dev": true, + "requires": { + "process": "0.11.10" + } + }, + "tmp": { + "version": "0.0.31", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.31.tgz", + "integrity": "sha1-jzirlDjhcxXl29izZX6L+yd65Kc=", + "dev": true, + "requires": { + "os-tmpdir": "1.0.2" + } + }, + "to-array": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/to-array/-/to-array-0.1.4.tgz", + "integrity": "sha1-F+bBH3PdTz10zaek/zI46a2b+JA=", + "dev": true + }, + "to-arraybuffer": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz", + "integrity": "sha1-fSKbH8xjfkZsoIEYCDanqr/4P0M=", + "dev": true + }, + "tty-browserify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/tty-browserify/-/tty-browserify-0.0.0.tgz", + "integrity": "sha1-oVe6QC2iTpv5V/mqadUk7tQpAaY=", + "dev": true + }, + "type-is": { + "version": "1.6.15", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.15.tgz", + "integrity": "sha1-yrEPtJCeRByChC6v4a1kbIGARBA=", + "dev": true, + "requires": { + "media-typer": "0.3.0", + "mime-types": "2.1.15" + } + }, + "typedarray": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz", + "integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=", + "dev": true + }, + "uglify-js": { + "version": "3.0.20", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.0.20.tgz", + "integrity": "sha512-O/c2/N97k1Ms+23VRx6gIAfGdijuW53SlASmXy0FVapK63rQrduHyE+5X6hUtqNiSLLao9Uv6ijotpNe8t991Q==", + "dev": true, + "requires": { + "commander": "2.9.0", + "source-map": "0.5.6" + }, + "dependencies": { + "commander": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.9.0.tgz", + "integrity": "sha1-nJkJQXbhIkDLItbFFGCYQA/g99Q=", + "dev": true, + "requires": { + "graceful-readlink": "1.0.1" + } + } + } + }, + "ultron": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/ultron/-/ultron-1.0.2.tgz", + "integrity": "sha1-rOEWq1V80Zc4ak6I9GhTeMiy5Po=", + "dev": true + }, + "umd": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/umd/-/umd-3.0.1.tgz", + "integrity": "sha1-iuVW4RAR9jwllnCKiDclnwGz1g4=", + "dev": true + }, + "unibabel": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/unibabel/-/unibabel-2.1.4.tgz", + "integrity": "sha1-f1fU+Hn4dq6smzEtnrE7TRVdbK8=" + }, + "unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=", + "dev": true + }, + "url": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/url/-/url-0.11.0.tgz", + "integrity": "sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE=", + "dev": true, + "requires": { + "punycode": "1.3.2", + "querystring": "0.2.0" + }, + "dependencies": { + "punycode": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz", + "integrity": "sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0=", + "dev": true + } + } + }, + "useragent": { + "version": "2.1.13", + "resolved": "https://registry.npmjs.org/useragent/-/useragent-2.1.13.tgz", + "integrity": "sha1-u6Q+iqJNXOuDwpN0c+EC4h33TBA=", + "dev": true, + "requires": { + "lru-cache": "2.2.4", + "tmp": "0.0.31" + } + }, + "util": { + "version": "0.10.3", + "resolved": "https://registry.npmjs.org/util/-/util-0.10.3.tgz", + "integrity": "sha1-evsa/lCAUkZInj23/g7TeTNqwPk=", + "dev": true, + "requires": { + "inherits": "2.0.1" + }, + "dependencies": { + "inherits": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz", + "integrity": "sha1-sX0I0ya0Qj5Wjv9xn5GwscvfafE=", + "dev": true + } + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", + "dev": true + }, + "utils-merge": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz", + "integrity": "sha1-ApT7kiu5N1FTVBxPcJYjHyh8ivg=", + "dev": true + }, + "vm-browserify": { + "version": "0.0.4", + "resolved": "https://registry.npmjs.org/vm-browserify/-/vm-browserify-0.0.4.tgz", + "integrity": "sha1-XX6kW7755Kb/ZflUOOCofDV9WnM=", + "dev": true, + "requires": { + "indexof": "0.0.1" + } + }, + "void-elements": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/void-elements/-/void-elements-2.0.1.tgz", + "integrity": "sha1-wGavtYK7HLQSjWDqkjkulNXp2+w=", + "dev": true + }, + "which": { + "version": "1.2.14", + "resolved": "https://registry.npmjs.org/which/-/which-1.2.14.tgz", + "integrity": "sha1-mofEN48D6CfOyvGs31bHNsAcFOU=", + "dev": true, + "requires": { + "isexe": "2.0.0" + } + }, + "wordwrap": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", + "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=", + "dev": true + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "ws": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/ws/-/ws-1.1.2.tgz", + "integrity": "sha1-iiRPoFJAHgjJiGz0SoUYnh/UBn8=", + "dev": true, + "requires": { + "options": "0.0.6", + "ultron": "1.0.2" + } + }, + "wtf-8": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wtf-8/-/wtf-8-1.0.0.tgz", + "integrity": "sha1-OS2LotDxw00e4tYw8V0O+2jhBIo=", + "dev": true + }, + "xmlhttprequest-ssl": { + "version": "1.5.3", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-1.5.3.tgz", + "integrity": "sha1-GFqIjATspGw+QHDZn3tJ3jUomS0=", + "dev": true + }, + "xtend": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.1.tgz", + "integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=", + "dev": true + }, + "yeast": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/yeast/-/yeast-0.1.2.tgz", + "integrity": "sha1-AI4G2AlDIMNy28L47XagymyKxBk=", + "dev": true + } + } +} diff --git a/package.json b/package.json index 5f64d55..6e45e38 100644 --- a/package.json +++ b/package.json @@ -32,8 +32,7 @@ }, "dependencies": { "big-integer": "^1.6.22", - "es6-promise": "^4.1.0", - "lodash.assign": "^4.2.0", + "lodash.merge": "^4.6.0", "unibabel": "^2.1.4" }, "devDependencies": { diff --git a/src/hmac.js b/src/hmac.js index 1a3f25e..0bd4101 100644 --- a/src/hmac.js +++ b/src/hmac.js @@ -1,5 +1,4 @@ var crypto = require("crypto"); -var Promise = require("es6-promise").Promise; module.exports = function(digest, string, salt) { return new Promise(function(resolve) { diff --git a/src/lesspass.js b/src/lesspass.js index 1b0adb6..f50b0e1 100644 --- a/src/lesspass.js +++ b/src/lesspass.js @@ -1,15 +1,157 @@ -var v1 = require("./v1"); -var v2 = require("./v2"); var hmac = require("./hmac"); +var pbkdf2 = require("./pbkdf2"); +var bigInt = require("big-integer"); +var merge = require("lodash.merge"); -module.exports = { - generatePassword: function(site, login, masterPassword, options) { - if (typeof options !== "undefined" && options.version === 1) { - return v1.generatePassword(site, login, masterPassword, options); - } - return v2.generatePassword(site, login, masterPassword, options); +var defaultProfile = { + site: '', + login: '', + options: { + uppercase: true, + lowercase: true, + digits: true, + symbols: true, + length: 16, + counter: 1 }, - createFingerprint: function(str) { - return hmac("sha256", str); + crypto: { + method: 'pbkdf2', + iterations: 100000, + keylen: 32, + digest: "sha256" + } +}; + +module.exports = { + generatePassword: generatePassword, + createFingerprint: createFingerprint, + isSupported: isSupported, + _calcEntropy: calcEntropy, + _consumeEntropy: consumeEntropy, + _getSetOfCharacters: getSetOfCharacters, + _getConfiguredRules: getConfiguredRules, + _insertStringPseudoRandomly: insertStringPseudoRandomly, + _getOneCharPerRule: getOneCharPerRule, + _renderPassword: renderPassword +}; + +function generatePassword(profile, masterPassword) { + var _profile = merge({}, defaultProfile, profile); + return calcEntropy(_profile, masterPassword) + .then(function(entropy) { + return renderPassword(entropy, _profile.options); + }); +} + +function createFingerprint(str) { + return hmac("sha256", str); +} + +function isSupported() { + try { + var simpleProfile = merge({}, defaultProfile, {crypto: {iterations: 1}}); + return generatePassword(simpleProfile, 'LessPass') + .then(function(generatedPassword) { + return generatedPassword == "n'LTsjPA#3E$e*2'"; + }); + } catch (e) { + console.error(e); + return Promise.resolve(false); } +} + +function calcEntropy(profile, masterPassword) { + var salt = profile.site + profile.login + profile.options.counter.toString(16); + return pbkdf2( + masterPassword, + salt, + profile.crypto.iterations, + profile.crypto.keylen, + profile.crypto.digest + ); +} + +var characterSubsets = { + lowercase: "abcdefghijklmnopqrstuvwxyz", + uppercase: "ABCDEFGHIJKLMNOPQRSTUVWXYZ", + digits: "0123456789", + symbols: "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~" }; + +function getSetOfCharacters(rules) { + if (typeof rules === "undefined") { + return ( + characterSubsets.lowercase + + characterSubsets.uppercase + + characterSubsets.digits + + characterSubsets.symbols + ); + } + var setOfChars = ""; + rules.forEach(function(rule) { + setOfChars += characterSubsets[rule]; + }); + return setOfChars; +} + +function consumeEntropy(generatedPassword, + quotient, + setOfCharacters, + maxLength) { + if (generatedPassword.length >= maxLength) { + return {value: generatedPassword, entropy: quotient}; + } + var longDivision = quotient.divmod(setOfCharacters.length); + generatedPassword += setOfCharacters[longDivision.remainder]; + return consumeEntropy( + generatedPassword, + longDivision.quotient, + setOfCharacters, + maxLength + ); +} + +function insertStringPseudoRandomly(generatedPassword, entropy, string) { + for (var i = 0; i < string.length; i++) { + var longDivision = entropy.divmod(generatedPassword.length); + generatedPassword = + generatedPassword.slice(0, longDivision.remainder) + + string[i] + + generatedPassword.slice(longDivision.remainder); + entropy = longDivision.quotient; + } + return generatedPassword; +} + +function getOneCharPerRule(entropy, rules) { + var oneCharPerRules = ""; + rules.forEach(function(rule) { + var password = consumeEntropy("", entropy, characterSubsets[rule], 1); + oneCharPerRules += password.value; + entropy = password.entropy; + }); + return {value: oneCharPerRules, entropy: entropy}; +} + +function getConfiguredRules(passwordProfile) { + return ["lowercase", "uppercase", "digits", "symbols"].filter(function(rule) { + return passwordProfile[rule]; + }); +} + +function renderPassword(entropy, passwordProfile) { + var rules = getConfiguredRules(passwordProfile); + var setOfCharacters = getSetOfCharacters(rules); + var password = consumeEntropy( + "", + bigInt(entropy, 16), + setOfCharacters, + passwordProfile.length - rules.length + ); + var charactersToAdd = getOneCharPerRule(password.entropy, rules); + return insertStringPseudoRandomly( + password.value, + charactersToAdd.entropy, + charactersToAdd.value + ); +} diff --git a/src/pbkdf2.js b/src/pbkdf2.js index 4e2b1cc..90d70bf 100644 --- a/src/pbkdf2.js +++ b/src/pbkdf2.js @@ -1,5 +1,4 @@ const crypto = require("crypto"); -var Promise = require("es6-promise").Promise; module.exports = function(password, salt, iterations, keylen, digest) { return new Promise(function(resolve, reject) { diff --git a/src/v1.js b/src/v1.js deleted file mode 100644 index 443ef3b..0000000 --- a/src/v1.js +++ /dev/null @@ -1,128 +0,0 @@ -var pbkdf2 = require("./pbkdf2"); -var assign = require("lodash.assign"); -var hmac = require("./hmac"); - -module.exports = { - generatePassword: generatePassword, - _renderPassword: renderPassword, - _createHmac: createHmac, - _deriveEncryptedLogin: deriveEncryptedLogin, - _getPasswordTemplate: getPasswordTemplate, - _prettyPrint: prettyPrint, - _string2charCodes: string2charCodes, - _getCharType: getCharType, - _getPasswordChar: getPasswordChar -}; - -var defaultOptions = { - version: 1, - lowercase: true, - numbers: true, - uppercase: true, - symbols: true, - keylen: 32, - digest: "sha256", - length: 12, - counter: 1, - iterations: 8192 -}; - -function generatePassword(site, login, masterPassword, options) { - var _options = assign({}, defaultOptions, options); - return pbkdf2( - masterPassword, - login, - _options.iterations, - _options.keylen, - "sha256" - ).then(function(encryptedLogin) { - return renderPassword(encryptedLogin, site, _options).then(function( - generatedPassword - ) { - return generatedPassword; - }); - }); -} - -function renderPassword(encryptedLogin, site, passwordOptions) { - return deriveEncryptedLogin( - encryptedLogin, - site, - passwordOptions - ).then(function(derivedEncryptedLogin) { - var template = - passwordOptions.template || getPasswordTemplate(passwordOptions); - return prettyPrint(derivedEncryptedLogin, template); - }); -} - -function createHmac(encryptedLogin, salt) { - return new Promise(function(resolve) { - resolve(hmac("sha256", encryptedLogin, salt)); - }); -} - -function deriveEncryptedLogin(encryptedLogin, site, options) { - var _options = options !== undefined ? options : {}; - var length = _options.length || 12; - var counter = _options.counter || 1; - - var salt = site + counter.toString(); - return createHmac(encryptedLogin, salt).then(function(derivedHash) { - return derivedHash.substring(0, length); - }); -} - -function getPasswordTemplate(passwordTypes) { - var templates = { - lowercase: "vc", - uppercase: "VC", - numbers: "n", - symbols: "s" - }; - var returnedTemplate = ""; - Object.keys(templates).forEach(function(template) { - if (passwordTypes.hasOwnProperty(template) && passwordTypes[template]) { - returnedTemplate += templates[template]; - } - }); - return returnedTemplate; -} - -function prettyPrint(hash, template) { - var password = ""; - - string2charCodes(hash).forEach(function(charCode, index) { - var charType = getCharType(template, index); - password += getPasswordChar(charType, charCode); - }); - return password; -} - -function string2charCodes(text) { - var charCodes = []; - for (var i = 0; i < text.length; i++) { - charCodes.push(text.charCodeAt(i)); - } - return charCodes; -} - -function getCharType(template, index) { - return template[index % template.length]; -} - -function getPasswordChar(charType, index) { - var passwordsChars = { - V: "AEIOUY", - C: "BCDFGHJKLMNPQRSTVWXZ", - v: "aeiouy", - c: "bcdfghjklmnpqrstvwxz", - A: "AEIOUYBCDFGHJKLMNPQRSTVWXZ", - a: "AEIOUYaeiouyBCDFGHJKLMNPQRSTVWXZbcdfghjklmnpqrstvwxz", - n: "0123456789", - s: "@&%?,=[]_:-+*$#!'^~;()/.", - x: "AEIOUYaeiouyBCDFGHJKLMNPQRSTVWXZbcdfghjklmnpqrstvwxz0123456789@&%?,=[]_:-+*$#!'^~;()/." - }; - var passwordChar = passwordsChars[charType]; - return passwordChar[index % passwordChar.length]; -} diff --git a/src/v2.js b/src/v2.js deleted file mode 100644 index 63c6665..0000000 --- a/src/v2.js +++ /dev/null @@ -1,136 +0,0 @@ -var pbkdf2 = require("./pbkdf2"); -var bigInt = require("big-integer"); -var assign = require("lodash.assign"); - -module.exports = { - generatePassword: generatePassword, - _calcEntropy: calcEntropy, - _consumeEntropy: consumeEntropy, - _getSetOfCharacters: getSetOfCharacters, - _getConfiguredRules: getConfiguredRules, - _insertStringPseudoRandomly: insertStringPseudoRandomly, - _getOneCharPerRule: getOneCharPerRule, - _renderPassword: renderPassword -}; - -var defaultOptions = { - version: 2, - lowercase: true, - numbers: true, - uppercase: true, - symbols: true, - keylen: 32, - digest: "sha256", - length: 16, - counter: 1, - iterations: 100000 -}; - -function generatePassword(site, login, masterPassword, options) { - var _options = assign({}, defaultOptions, options); - return calcEntropy(site, login, masterPassword, _options).then(function( - entropy - ) { - return renderPassword(entropy, _options); - }); -} - -function calcEntropy(site, login, masterPassword, passwordProfile) { - var salt = site + login + passwordProfile.counter.toString(16); - return pbkdf2( - masterPassword, - salt, - passwordProfile.iterations, - passwordProfile.keylen, - passwordProfile.digest - ); -} - -var characterSubsets = { - lowercase: "abcdefghijklmnopqrstuvwxyz", - uppercase: "ABCDEFGHIJKLMNOPQRSTUVWXYZ", - numbers: "0123456789", - symbols: "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~" -}; - -function getSetOfCharacters(rules) { - if (typeof rules === "undefined") { - return ( - characterSubsets.lowercase + - characterSubsets.uppercase + - characterSubsets.numbers + - characterSubsets.symbols - ); - } - var setOfChars = ""; - rules.forEach(function(rule) { - setOfChars += characterSubsets[rule]; - }); - return setOfChars; -} - -function consumeEntropy( - generatedPassword, - quotient, - setOfCharacters, - maxLength -) { - if (generatedPassword.length >= maxLength) { - return { value: generatedPassword, entropy: quotient }; - } - var longDivision = quotient.divmod(setOfCharacters.length); - generatedPassword += setOfCharacters[longDivision.remainder]; - return consumeEntropy( - generatedPassword, - longDivision.quotient, - setOfCharacters, - maxLength - ); -} - -function insertStringPseudoRandomly(generatedPassword, entropy, string) { - for (var i = 0; i < string.length; i++) { - var longDivision = entropy.divmod(generatedPassword.length); - generatedPassword = - generatedPassword.slice(0, longDivision.remainder) + - string[i] + - generatedPassword.slice(longDivision.remainder); - entropy = longDivision.quotient; - } - return generatedPassword; -} - -function getOneCharPerRule(entropy, rules) { - var oneCharPerRules = ""; - rules.forEach(function(rule) { - var password = consumeEntropy("", entropy, characterSubsets[rule], 1); - oneCharPerRules += password.value; - entropy = password.entropy; - }); - return { value: oneCharPerRules, entropy: entropy }; -} - -function getConfiguredRules(passwordProfile) { - return ["lowercase", "uppercase", "numbers", "symbols"].filter(function( - rule - ) { - return passwordProfile[rule]; - }); -} - -function renderPassword(entropy, passwordProfile) { - var rules = getConfiguredRules(passwordProfile); - var setOfCharacters = getSetOfCharacters(rules); - var password = consumeEntropy( - "", - bigInt(entropy, 16), - setOfCharacters, - passwordProfile.length - rules.length - ); - var charactersToAdd = getOneCharPerRule(password.entropy, rules); - return insertStringPseudoRandomly( - password.value, - charactersToAdd.entropy, - charactersToAdd.value - ); -} diff --git a/test/api.tests.js b/test/api.tests.js index cab8e1c..66173f4 100644 --- a/test/api.tests.js +++ b/test/api.tests.js @@ -1,388 +1,98 @@ var assert = require("assert"); var LessPass = require("../src/lesspass"); -describe("api", function() { - describe("v1", function() { - it("generatedPassword", function() { - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var options = { +describe("api", () => { + it("generatePassword", () => { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { lowercase: true, uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("izIS5@ozYM2?", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("azYS7,olOL2]", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - length: 14, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("azYS7,olOL2]iz", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: false, - numbers: false, - symbols: false, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("azyseqololat", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: false, - uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("AZ3[EQ7@OL2]", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: false, - uppercase: false, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("4?3[7,7@7@2]", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: false, - uppercase: false, - numbers: false, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("[?=[&,:@:@[]", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: false, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("azYS7uwAW8at", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: false, - symbols: false, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("azYSeqOLolAT", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 2, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("obYT2=olOV9=", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "lesspass"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("erOC1%imIW3,", generatedPassword); - }); - }); - it("generatedPassword", function() { - var site = "lesspass.com"; - var login = "contact@lesspass.com"; - var masterPassword = "password2"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - length: 12, - counter: 1, - version: 1 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("uvUM5_ucUP5=", generatedPassword); - }); - }); - }); - describe("v2", function() { - it("generatedPassword", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: true, + digits: true, symbols: true, length: 16, - counter: 1, - version: 2 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { + counter: 1 + } + }; + const masterPassword = "password"; + return LessPass + .generatePassword(profile, masterPassword) + .then(generatedPassword => { assert.equal("WHLpUL)e00[iHR+w", generatedPassword); }); + }); + it("generatePassword default options", () => { + const profile = { + site: "example.org", + login: "contact@example.org" + }; + const masterPassword = "password"; + return LessPass.generatePassword(profile, masterPassword).then(generatedPassword => { + assert.equal("WHLpUL)e00[iHR+w", generatedPassword); }); - it("generatedPassword", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var options = { + }); + it("generatedPassword different options", () => { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { lowercase: true, uppercase: true, - numbers: true, + digits: true, symbols: false, length: 14, - counter: 2, - version: 2 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("MBAsB7b1Prt8Sl", generatedPassword); - }); + counter: 2 + } + }; + const masterPassword = "password"; + return LessPass.generatePassword(profile, masterPassword).then(generatedPassword => { + assert.equal("MBAsB7b1Prt8Sl", generatedPassword); + assert.equal(14, generatedPassword.length); }); - it("generatedPassword", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var options = { + }); + it("generatedPassword only digits", () => { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { lowercase: false, uppercase: false, - numbers: true, + digits: true, symbols: false, length: 6, - counter: 3, - version: 2 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("117843", generatedPassword); - }); + counter: 3 + } + }; + const masterPassword = "password"; + return LessPass.generatePassword(profile, masterPassword).then(generatedPassword => { + assert.equal("117843", generatedPassword); }); - it("generatedPassword", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var options = { - lowercase: true, - uppercase: true, - numbers: false, - symbols: true, - length: 14, - counter: 1, - version: 2 - }; - return LessPass.generatePassword( - site, - login, - masterPassword, - options - ).then(function(generatedPassword) { - assert.equal("sB>{qF}wN%/-fm", generatedPassword); - }); + }); + it("generatedPassword no digit", () => { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { + digits: false + } + }; + const masterPassword = "password"; + return LessPass.generatePassword(profile, masterPassword).then(generatedPassword => { + assert.equal("s>{F}RwkN/-fmM.X", generatedPassword); }); - it("generatedPassword", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - return LessPass.generatePassword( - site, - login, - masterPassword - ).then(function(generatedPassword) { - assert.equal("WHLpUL)e00[iHR+w", generatedPassword); - }); + }); + it("createFingerprint", () => { + return LessPass.createFingerprint("password").then(function(fingerprint) { + assert.equal( + "e56a207acd1e6714735487c199c6f095844b7cc8e5971d86c003a7b6f36ef51e", + fingerprint + ); }); }); - describe("fingerprint", function() { - it("createFingerprint", function() { - return LessPass.createFingerprint("password").then(function(fingerprint) { - assert.equal( - "e56a207acd1e6714735487c199c6f095844b7cc8e5971d86c003a7b6f36ef51e", - fingerprint - ); - }); + it("isSupported", () => { + return LessPass.isSupported("password").then(function(isSupported) { + assert(isSupported); }); }); }); diff --git a/test/entropy.tests.js b/test/entropy.tests.js new file mode 100644 index 0000000..be7d3f6 --- /dev/null +++ b/test/entropy.tests.js @@ -0,0 +1,89 @@ +var assert = require("assert"); +var LessPass = require("../src/lesspass"); +var bigInt = require("big-integer"); + +describe("entropy", function() { + it("calc entropy pbkdf2 with default params (100000 iterations, 32 bytes length, sha256 digest)", function() { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { + counter: 1 + }, + crypto: { + method: 'pbkdf2', + iterations: 100000, + keylen: 32, + digest: "sha256" + } + }; + const masterPassword = "password"; + return LessPass._calcEntropy(profile, masterPassword) + .then(function(entropy) { + assert.equal( + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e", + entropy + ); + }); + }); + it("calc entropy with different options (8192 iterations, 16 bytes length, sha512 digest)", function() { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { + counter: 1 + }, + crypto: { + method: 'pbkdf2', + iterations: 8192, + keylen: 16, + digest: "sha512" + } + }; + const masterPassword = "password"; + return LessPass._calcEntropy(profile, masterPassword) + .then(function(entropy) { + assert.equal("fff211c16a4e776b3574c6a5c91fd252", entropy); + }); + }); + it("calc entropy different if counter different 1", function() { + const profile = { + site: "example.org", + login: "contact@example.org", + options: { + counter: 1 + }, + crypto: { + method: 'pbkdf2', + iterations: 100000, + keylen: 32, + digest: "sha256" + } + }; + const profile2 = { + site: "example.org", + login: "contact@example.org", + options: { + counter: 2 + }, + crypto: { + method: 'pbkdf2', + iterations: 100000, + keylen: 32, + digest: "sha256" + } + }; + const promises = [ + LessPass._calcEntropy(profile, "password"), + LessPass._calcEntropy(profile2, "password"), + ]; + Promise.all(promises).then(values => { + assert.notEqual(values[0], values[1]); + }); + }); + it("consume entropy", function() { + var password = LessPass._consumeEntropy("", bigInt(4 * 4 + 2), "abcd", 2); + assert.equal("ca", password.value); + assert.equal(1, password.entropy); + }); +}); diff --git a/test/renderPassword.tests.js b/test/renderPassword.tests.js new file mode 100644 index 0000000..499875a --- /dev/null +++ b/test/renderPassword.tests.js @@ -0,0 +1,99 @@ +const assert = require("assert"); +const LessPass = require("../src/lesspass"); +const bigInt = require("big-integer"); + +describe("LessPass LessPass", function() { + const defaultPasswordProfile = { + length: 16, + lowercase: true, + uppercase: true, + digits: true, + symbols: true + }; + it("render password use remainder of long division beetween entropy and set of chars length as an index", function() { + const entropy = + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; + assert.equal("W", LessPass._renderPassword(entropy, defaultPasswordProfile)[0]); + }); + it("render password use quotient as second entropy recursively", function() { + const entropy = + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; + assert.equal("H", LessPass._renderPassword(entropy, defaultPasswordProfile)[1]); + }); + it("render password has default length of 16", function() { + const entropy = + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; + assert.equal( + 16, + LessPass._renderPassword(entropy, defaultPasswordProfile).length + ); + }); + it("render password can specify length", function() { + const entropy = + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; + const passwordProfile = { + length: 20, + lowercase: true, + uppercase: true, + digits: true, + symbols: true + }; + assert.equal(20, LessPass._renderPassword(entropy, passwordProfile).length); + }); + it("include one char per set of characters", function() { + const password = LessPass._insertStringPseudoRandomly( + "123456", + bigInt(7 * 6 + 2), + "uT" + ); + assert.equal("T12u3456", password); + }); + it("render password return at least one char in every characters set", function() { + const entropy = + "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; + const passwordProfile = { + length: 6, + lowercase: true, + uppercase: true, + digits: true, + symbols: true + }; + const generatedPassword = LessPass._renderPassword(entropy, passwordProfile); + let passwordLength = generatedPassword.length; + let lowercaseOk = false; + let uppercaseOk = false; + let digitsOk = false; + let symbolsOk = false; + while (passwordLength--) { + if ( + "abcdefghijklmnopqrstuvwxyz".indexOf( + generatedPassword[passwordLength] + ) !== -1 + ) { + lowercaseOk = true; + } + if ( + "ABCDEFGHIJKLMNOPQRSTUVWXYZ".indexOf( + generatedPassword[passwordLength] + ) !== -1 + ) { + uppercaseOk = true; + } + if ("0123456789".indexOf(generatedPassword[passwordLength]) !== -1) { + digitsOk = true; + } + if ( + "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~".indexOf( + generatedPassword[passwordLength] + ) !== -1 + ) { + symbolsOk = true; + } + } + assert.equal(6, generatedPassword.length); + assert( + lowercaseOk && uppercaseOk && digitsOk && symbolsOk, + "there is no at least one char in every characters set" + ); + }); +}); diff --git a/test/setOfCharacters.tests.js b/test/setOfCharacters.tests.js new file mode 100644 index 0000000..e1597f3 --- /dev/null +++ b/test/setOfCharacters.tests.js @@ -0,0 +1,78 @@ +var assert = require("assert"); +var LessPass = require("../src/lesspass"); +var bigInt = require("big-integer"); + +describe("set of characters", function() { + it("get default set of characters", function() { + var setOfCharacters = LessPass._getSetOfCharacters(); + assert.equal( + "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~", + setOfCharacters + ); + assert.equal(26 * 2 + 10 + 32, setOfCharacters.length); + }); + it("get default set of characters concat rules in order", function() { + var setOfCharacters = LessPass._getSetOfCharacters([ + "lowercase", + "uppercase", + "digits" + ]); + assert.equal( + "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", + setOfCharacters + ); + assert.equal(26 * 2 + 10, setOfCharacters.length); + }); + it("get set of characters only lowercase", function() { + var setOfCharacters = LessPass._getSetOfCharacters(["lowercase"]); + assert.equal("abcdefghijklmnopqrstuvwxyz", setOfCharacters); + assert.equal(26, setOfCharacters.length); + }); + it("get set of characters only uppercase", function() { + var setOfCharacters = LessPass._getSetOfCharacters(["uppercase"]); + assert.equal("ABCDEFGHIJKLMNOPQRSTUVWXYZ", setOfCharacters); + assert.equal(26, setOfCharacters.length); + }); + it("get set of characters only digits", function() { + var setOfCharacters = LessPass._getSetOfCharacters(["digits"]); + assert.equal("0123456789", setOfCharacters); + assert.equal(10, setOfCharacters.length); + }); + it("get set of characters only symbols", function() { + var setOfCharacters = LessPass._getSetOfCharacters(["symbols"]); + assert.equal("!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~", setOfCharacters); + assert.equal(32, setOfCharacters.length); + }); + it("generate one char per rules", function() { + var oneCharPerSetOfCharacters = LessPass._getOneCharPerRule(bigInt(26 * 26), [ + "lowercase", + "uppercase" + ]); + assert.equal("aA", oneCharPerSetOfCharacters.value); + assert.equal(2, oneCharPerSetOfCharacters.value.length); + assert.equal(1, oneCharPerSetOfCharacters.entropy); + }); + it("configured rules", function() { + assert.deepEqual( + ["uppercase"], + LessPass._getConfiguredRules({ uppercase: true }) + ); + assert.deepEqual( + ["lowercase", "uppercase"], + LessPass._getConfiguredRules({ uppercase: true, lowercase: true }) + ); + assert.deepEqual( + ["lowercase"], + LessPass._getConfiguredRules({ lowercase: true, symbols: false }) + ); + assert.deepEqual( + ["lowercase", "uppercase", "digits", "symbols"], + LessPass._getConfiguredRules({ + lowercase: true, + uppercase: true, + symbols: true, + digits: true + }) + ); + }); +}); diff --git a/test/v1/deriveEncryptedLogin.tests.js b/test/v1/deriveEncryptedLogin.tests.js deleted file mode 100644 index 79904e3..0000000 --- a/test/v1/deriveEncryptedLogin.tests.js +++ /dev/null @@ -1,110 +0,0 @@ -var assert = require("assert"); -var v1 = require("../../src/v1"); - -describe("deriveEncryptedLogin", function() { - it("should createHmac", function() { - var encryptedLogin = - "9f505f3a95fe0485da3242cb81c9fe25c2f400d8399737655a8dad2b52778d88"; - var salt = "lesspass.com1"; - return v1._createHmac(encryptedLogin, salt).then(function(hmac) { - assert.equal( - "be00f942fc8aa67d8e76fc2456862b9d66d166ebfdd3dc2f0116e278209532ed", - hmac - ); - }); - }); - it("should derive encrypted login with default options 1", function() { - const encryptedLogin = - "90cff82b8847525370a8f29a59ecf45db62c719a535788ad0df58d32304e925d"; - const site = "lesspass.com"; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site) - .then(function(generatedPassword) { - assert.equal("ecd16aefc7e5", generatedPassword); - }); - }); - it("should derive encrypted login with default options 2", function() { - const encryptedLogin = - "90cff82b8847525370a8f29a59ecf45db62c719a535788ad0df58d32304e925d"; - const site = "lesspass.com"; - const option = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site, option) - .then(function(generatedPassword) { - assert.equal("ecd16aefc7e5", generatedPassword); - }); - }); - it("should derive encrypted login with defined length", function() { - var encryptedLogin = - "d79d8482f708122288af7b259393a58fe05840f4555cc935cdd3f062b9aa75ed"; - var site = "lesspass.com"; - var option = { - counter: 1, - length: 10 - }; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site, option) - .then(function(generatedPassword) { - assert.equal(10, generatedPassword.length); - }); - }); - it("should return two different passwords if site different 1", function() { - const encryptedLogin = - "f4fd3885fb70085f2285c3382e2d9adb4c2553285fc45dd896791aa5e79070a9"; - const site = "google.com"; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site) - .then(function(derivedEncryptedLogin) { - assert.equal("a957c3a459ec", derivedEncryptedLogin); - }); - }); - it("should return two different passwords if site different 2", function() { - const encryptedLogin = - "f4fd3885fb70085f2285c3382e2d9adb4c2553285fc45dd896791aa5e79070a9"; - const site = "facebook.com"; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site) - .then(function(derivedEncryptedLogin) { - assert.equal("d9f3a918c34b", derivedEncryptedLogin); - }); - }); - it("should return two different passwords if counter different 1", function() { - const encryptedLogin = - "dfba06278c9aa24d992bc2d390a53efef482788859455875f72015335d085fcd"; - const site = "lesspass.com"; - const option = { counter: 1 }; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site, option) - .then(function(derivedEncryptedLogins) { - assert.equal("bb2e0b34036d", derivedEncryptedLogins); - }); - }); - it("should return two different passwords if counter different 2", function() { - const encryptedLogin = - "dfba06278c9aa24d992bc2d390a53efef482788859455875f72015335d085fcd"; - const site = "lesspass.com"; - const option2 = { counter: 2 }; - return v1 - ._deriveEncryptedLogin(encryptedLogin, site, option2) - .then(function(derivedEncryptedLogins) { - assert.equal("67fe8c05a248", derivedEncryptedLogins); - }); - }); - it("should derive encrypted login with sha 256", function() { - const encryptedLogin = - "9f505f3a95fe0485da3242cb81c9fe25c2f400d8399737655a8dad2b52778d88"; - const site = "lesspass.com"; - v1 - ._deriveEncryptedLogin(encryptedLogin, site) - .then(function(encryptedLogin) { - assert.equal("be00f942fc8a", encryptedLogin); - }); - }); -}); diff --git a/test/v1/getPasswordTemplate.tests.js b/test/v1/getPasswordTemplate.tests.js deleted file mode 100644 index 0fc43f2..0000000 --- a/test/v1/getPasswordTemplate.tests.js +++ /dev/null @@ -1,82 +0,0 @@ -var assert = require("assert"); -var v1 = require("../../src/v1"); - -describe("getPasswordTemplate", function() { - it("should get default template", function() { - assert.equal( - "vcVCns", - v1._getPasswordTemplate({ - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }) - ); - }); - it("should get lowercase template", function() { - assert.equal( - "vc", - v1._getPasswordTemplate({ - lowercase: true, - uppercase: false, - numbers: false, - symbols: false - }) - ); - }); - it("should get uppercase template", function() { - assert.equal( - "VC", - v1._getPasswordTemplate({ - lowercase: false, - uppercase: true, - numbers: false, - symbols: false - }) - ); - }); - it("should get numbers template", function() { - assert.equal( - "n", - v1._getPasswordTemplate({ - lowercase: false, - uppercase: false, - numbers: true, - symbols: false - }) - ); - }); - it("should get symbols template", function() { - assert.equal( - "s", - v1._getPasswordTemplate({ - lowercase: false, - uppercase: false, - numbers: false, - symbols: true - }) - ); - }); - it("should concatenate template if two password settings", function() { - assert.equal( - "vcVC", - v1._getPasswordTemplate({ - lowercase: true, - uppercase: true, - numbers: false, - symbols: false - }) - ); - assert.equal( - "vcns", - v1._getPasswordTemplate({ - lowercase: true, - uppercase: false, - numbers: true, - symbols: true - }) - ); - }); -}); diff --git a/test/v1/prettyPrint.js b/test/v1/prettyPrint.js deleted file mode 100644 index 43b484f..0000000 --- a/test/v1/prettyPrint.js +++ /dev/null @@ -1,39 +0,0 @@ -var assert = require("assert"); -var v1 = require("../../src/v1"); - -describe("prettyPrint", function() { - it("should print different password if templates different", function() { - var encryptedLogin = - "78ae5892055ab59fdd54489ae30928d322841a27590b65cf875fcfdd083f7c32"; - assert.notEqual( - v1._prettyPrint(encryptedLogin, "cv"), - v1._prettyPrint(encryptedLogin, "vc") - ); - }); - it("must return a string of the same length as the input", function() { - var hash = - "f5785e569ab5d38b02e2248c798ac17df90f57a85f34a9d5382408c2f0d9532d"; - assert.equal(hash.length, v1._prettyPrint(hash, "cv").length); - }); - it("should return char inside a string based on modulo of the index", function() { - var template = "cv"; - assert.equal("c", v1._getCharType(template, 0)); - assert.equal("v", v1._getCharType(template, 1)); - assert.equal("c", v1._getCharType(template, 10)); - }); - it("should convert a string into an array of char code", function() { - var charCodes = v1._string2charCodes("ab40f6ee71"); - assert.equal(97, charCodes[0]); - assert.equal(98, charCodes[1]); - assert.equal(10, charCodes.length); - }); - it("should get password char based on its type and index", function() { - var typeVowel = "V"; - assert.equal("A", v1._getPasswordChar(typeVowel, 0)); - }); - it("should modulo if overflow", function() { - var typeVowel = "V"; - assert.equal("E", v1._getPasswordChar(typeVowel, 1)); - assert.equal("E", v1._getPasswordChar(typeVowel, 7)); - }); -}); diff --git a/test/v1/renderPassword.tests.js b/test/v1/renderPassword.tests.js deleted file mode 100644 index c897de6..0000000 --- a/test/v1/renderPassword.tests.js +++ /dev/null @@ -1,281 +0,0 @@ -var assert = require("assert"); -var v1 = require("../../src/v1"); - -describe("renderPassword", function() { - it("renderPassword", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azYS7,olOL2]", generatedPassword); - }); - }); - it("renderPassword with a custom template", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - template: "n" - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - var i = generatedPassword.length; - while (i--) { - assert("0123456789".indexOf(generatedPassword[i]) !== -1); - } - }); - }); - it("renderPassword with a custom template too short", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - template: "CvcnCVsn" - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("Sor4WU:8Wad5", generatedPassword); - }); - }); - it("renderPassword with a custom template too long", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 6, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true, - template: "CvcnCVsn" - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("Sor4WU", generatedPassword); - }); - }); - it("renderPassword auto generated 0", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azYS7,olOL2]", generatedPassword); - }); - }); - it("renderPassword auto generated 1", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 14, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azYS7,olOL2]iz", generatedPassword); - }); - }); - it("renderPassword auto generated 2", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: false, - numbers: false, - symbols: false - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azyseqololat", generatedPassword); - }); - }); - it("renderPassword auto generated 3", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: false, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("AZ3[EQ7@OL2]", generatedPassword); - }); - }); - it("renderPassword auto generated 4", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: false, - uppercase: false, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("4?3[7,7@7@2]", generatedPassword); - }); - }); - it("renderPassword auto generated 5", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: false, - uppercase: false, - numbers: false, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("[?=[&,:@:@[]", generatedPassword); - }); - }); - it("renderPassword auto generated 6", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: false - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azYS7uwAW8at", generatedPassword); - }); - }); - it("renderPassword auto generated 7", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: false, - symbols: false - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("azYSeqOLolAT", generatedPassword); - }); - }); - it("renderPassword auto generated 8", function() { - var site = "lesspass.com"; - var encryptedLogin = - "63d850713d0b2f7f2c4396fe93f4ac0c6bc7485f9e7473c4b8c4a33ec12199c0"; - var passwordOptions = { - counter: 2, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("obYT2=olOV9=", generatedPassword); - }); - }); - it("renderPassword auto generated 9", function() { - var site = "lesspass.com"; - var encryptedLogin = - "7d05ee25597dcc3ac16d082aa910e7707f75be620ed8db5bef7245e2a8579116"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("erOC1%imIW3,", generatedPassword); - }); - }); - it("renderPassword auto generated 10", function() { - var site = "lesspass.com"; - var encryptedLogin = - "ce853092fc54fe88c281e38df97bd5826d64e6bee315dc94939cbba8930df0e4"; - var passwordOptions = { - counter: 1, - length: 12, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - return v1 - ._renderPassword(encryptedLogin, site, passwordOptions) - .then(function(generatedPassword) { - assert.equal("uvUM5_ucUP5=", generatedPassword); - }); - }); -}); diff --git a/test/v2/entropy.tests.js b/test/v2/entropy.tests.js deleted file mode 100644 index 7b2551c..0000000 --- a/test/v2/entropy.tests.js +++ /dev/null @@ -1,79 +0,0 @@ -var assert = require("assert"); -var v2 = require("../../src/v2"); -var bigInt = require("big-integer"); - -describe("entropy", function() { - it("calc entropy pbkdf2 with default params (100000 iterations, 32 bytes length, sha256 digest)", function() { - this.timeout(10000); - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var passwordProfile = { - iterations: 100000, - keylen: 32, - digest: "sha256", - counter: 1 - }; - return v2 - ._calcEntropy(site, login, masterPassword, passwordProfile) - .then(function(entropy) { - assert.equal( - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e", - entropy - ); - }); - }); - it("calc entropy with different options (8192 iterations, 16 bytes length, sha512 digest)", function() { - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var passwordProfile = { - iterations: 8192, - keylen: 16, - digest: "sha512", - counter: 1 - }; - return v2 - ._calcEntropy(site, login, masterPassword, passwordProfile) - .then(function(entropy) { - assert.equal("fff211c16a4e776b3574c6a5c91fd252", entropy); - }); - }); - it("calc entropy different if counter different 1", function() { - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var passwordProfile1 = { - iterations: 1, - keylen: 16, - digest: "sha256", - counter: 1 - }; - return v2 - ._calcEntropy(site, login, masterPassword, passwordProfile1) - .then(function(entropy) { - assert.equal("d3ec1e988dd0b3640c7491cd2c2a88b5", entropy); - }); - }); - it("calc entropy different if counter different 2", function() { - var site = "example.org"; - var login = "contact@example.org"; - var masterPassword = "password"; - var passwordProfile2 = { - iterations: 1, - keylen: 16, - digest: "sha256", - counter: 2 - }; - return v2 - ._calcEntropy(site, login, masterPassword, passwordProfile2) - .then(function(entropy) { - assert.equal("ddfb1136260f930c21f6d72f6eddbd40", entropy); - }); - }); - it("consume entropy", function() { - var password = v2._consumeEntropy("", bigInt(4 * 4 + 2), "abcd", 2); - assert.equal("ca", password.value); - assert.equal(1, password.entropy); - }); -}); diff --git a/test/v2/renderPassword.tests.js b/test/v2/renderPassword.tests.js deleted file mode 100644 index 3bc1ca9..0000000 --- a/test/v2/renderPassword.tests.js +++ /dev/null @@ -1,99 +0,0 @@ -var assert = require("assert"); -var v2 = require("../../src/v2"); -var bigInt = require("big-integer"); - -describe("LessPass v2", function() { - var defaultPasswordProfile = { - length: 16, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - it("render password use remainder of long division beetween entropy and set of chars length as an index", function() { - var entropy = - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; - assert.equal("W", v2._renderPassword(entropy, defaultPasswordProfile)[0]); - }); - it("render password use quotient as second entropy recursively", function() { - var entropy = - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; - assert.equal("H", v2._renderPassword(entropy, defaultPasswordProfile)[1]); - }); - it("render password has default length of 16", function() { - var entropy = - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; - assert.equal( - 16, - v2._renderPassword(entropy, defaultPasswordProfile).length - ); - }); - it("render password can specify length", function() { - var entropy = - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; - var passwordProfile = { - length: 20, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - assert.equal(20, v2._renderPassword(entropy, passwordProfile).length); - }); - it("include one char per set of characters", function() { - var password = v2._insertStringPseudoRandomly( - "123456", - bigInt(7 * 6 + 2), - "uT" - ); - assert.equal("T12u3456", password); - }); - it("render password return at least one char in every characters set", function() { - var entropy = - "dc33d431bce2b01182c613382483ccdb0e2f66482cbba5e9d07dab34acc7eb1e"; - var passwordProfile = { - length: 6, - lowercase: true, - uppercase: true, - numbers: true, - symbols: true - }; - var generatedPassword = v2._renderPassword(entropy, passwordProfile); - var passwordLength = generatedPassword.length; - var lowercaseOk = false; - var uppercaseOk = false; - var numbersOk = false; - var symbolsOk = false; - while (passwordLength--) { - if ( - "abcdefghijklmnopqrstuvwxyz".indexOf( - generatedPassword[passwordLength] - ) !== -1 - ) { - lowercaseOk = true; - } - if ( - "ABCDEFGHIJKLMNOPQRSTUVWXYZ".indexOf( - generatedPassword[passwordLength] - ) !== -1 - ) { - uppercaseOk = true; - } - if ("0123456789".indexOf(generatedPassword[passwordLength]) !== -1) { - numbersOk = true; - } - if ( - "!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~".indexOf( - generatedPassword[passwordLength] - ) !== -1 - ) { - symbolsOk = true; - } - } - assert.equal(6, generatedPassword.length); - assert( - lowercaseOk && uppercaseOk && numbersOk && symbolsOk, - "there is no at least one char in every characters set" - ); - }); -}); diff --git a/test/v2/setOfCharacters.tests.js b/test/v2/setOfCharacters.tests.js deleted file mode 100644 index cf1c7ec..0000000 --- a/test/v2/setOfCharacters.tests.js +++ /dev/null @@ -1,78 +0,0 @@ -var assert = require("assert"); -var v2 = require("../../src/v2"); -var bigInt = require("big-integer"); - -describe("set of characters", function() { - it("get default set of characters", function() { - var setOfCharacters = v2._getSetOfCharacters(); - assert.equal( - "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~", - setOfCharacters - ); - assert.equal(26 * 2 + 10 + 32, setOfCharacters.length); - }); - it("get default set of characters concat rules in order", function() { - var setOfCharacters = v2._getSetOfCharacters([ - "lowercase", - "uppercase", - "numbers" - ]); - assert.equal( - "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", - setOfCharacters - ); - assert.equal(26 * 2 + 10, setOfCharacters.length); - }); - it("get set of characters only lowercase", function() { - var setOfCharacters = v2._getSetOfCharacters(["lowercase"]); - assert.equal("abcdefghijklmnopqrstuvwxyz", setOfCharacters); - assert.equal(26, setOfCharacters.length); - }); - it("get set of characters only uppercase", function() { - var setOfCharacters = v2._getSetOfCharacters(["uppercase"]); - assert.equal("ABCDEFGHIJKLMNOPQRSTUVWXYZ", setOfCharacters); - assert.equal(26, setOfCharacters.length); - }); - it("get set of characters only numbers", function() { - var setOfCharacters = v2._getSetOfCharacters(["numbers"]); - assert.equal("0123456789", setOfCharacters); - assert.equal(10, setOfCharacters.length); - }); - it("get set of characters only symbols", function() { - var setOfCharacters = v2._getSetOfCharacters(["symbols"]); - assert.equal("!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~", setOfCharacters); - assert.equal(32, setOfCharacters.length); - }); - it("generate one char per rules", function() { - var oneCharPerSetOfCharacters = v2._getOneCharPerRule(bigInt(26 * 26), [ - "lowercase", - "uppercase" - ]); - assert.equal("aA", oneCharPerSetOfCharacters.value); - assert.equal(2, oneCharPerSetOfCharacters.value.length); - assert.equal(1, oneCharPerSetOfCharacters.entropy); - }); - it("configured rules", function() { - assert.deepEqual( - ["uppercase"], - v2._getConfiguredRules({ uppercase: true }) - ); - assert.deepEqual( - ["lowercase", "uppercase"], - v2._getConfiguredRules({ uppercase: true, lowercase: true }) - ); - assert.deepEqual( - ["lowercase"], - v2._getConfiguredRules({ lowercase: true, symbols: false }) - ); - assert.deepEqual( - ["lowercase", "uppercase", "numbers", "symbols"], - v2._getConfiguredRules({ - lowercase: true, - uppercase: true, - symbols: true, - numbers: true - }) - ); - }); -});