@secrez/core 1.0.4 → 1.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -28,18 +28,18 @@ API documentation
28
28
  ## Test coverage
29
29
 
30
30
  ```
31
- 60 passing (1s)
31
+ 60 passing (2s)
32
32
 
33
33
  -----------------|---------|----------|---------|---------|-------------------
34
34
  File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s
35
35
  -----------------|---------|----------|---------|---------|-------------------
36
36
  All files | 99.75 | 94.31 | 100 | 99.75 |
37
- src | 100 | 96.07 | 100 | 100 |
37
+ src | 100 | 96.06 | 100 | 100 |
38
38
  Entry.js | 100 | 95.65 | 100 | 100 | 39
39
- Secrez.js | 100 | 96.95 | 100 | 100 | 154,319,442
40
- _Secrez.js | 100 | 91.67 | 100 | 100 | 14,226
41
- src/config | 98.57 | 84.85 | 100 | 98.57 |
42
- ConfigUtils.js | 98.48 | 84.85 | 100 | 98.48 | 137
39
+ Secrez.js | 100 | 96.94 | 100 | 100 | 154,319,442
40
+ _Secrez.js | 100 | 91.66 | 100 | 100 | 14,226
41
+ src/config | 98.57 | 84.84 | 100 | 98.57 |
42
+ ConfigUtils.js | 98.48 | 84.84 | 100 | 98.48 | 137
43
43
  booleans.js | 100 | 100 | 100 | 100 |
44
44
  index.js | 100 | 100 | 100 | 100 |
45
45
  -----------------|---------|----------|---------|---------|-------------------
package/coverage.report CHANGED
@@ -1,5 +1,5 @@
1
1
 
2
- > @secrez/core@1.0.4 test /Users/francescosullo/Projects/Personal/secrez/packages/core
2
+ > @secrez/core@1.0.5 test /Users/francescosullo/Projects/Secrez/secrez/packages/core
3
3
  > cross-env NODE_ENV=test nyc --reporter=lcov --reporter=text mocha test/*.test.js test/**/*.test.js --exit
4
4
 
5
5
 
@@ -26,22 +26,22 @@
26
26
  derivePassword
27
27
  ✓ should derive a password and obtain a predeterminded hash
28
28
  signup and signin
29
- ✓ should signup the user and signin without saving the iterations (71ms)
30
- ✓ should signup in two instances without conflicts (41ms)
31
- ✓ should signup the user and signin saved the iterations (38ms)
32
- ✓ should signup with version one, and signin and upgrade to version two (68ms)
33
- ✓ should signup the user, change password and signin (56ms)
34
- ✓ should signup the user, change iterations and signin (49ms)
35
- ✓ should signup the user, change password and iterations and signin (67ms)
29
+ ✓ should signup the user and signin without saving the iterations (73ms)
30
+ ✓ should signup in two instances without conflicts (50ms)
31
+ ✓ should signup the user and signin saved the iterations (45ms)
32
+ ✓ should signup with version one, and signin and upgrade to version two (66ms)
33
+ ✓ should signup the user, change password and signin (63ms)
34
+ ✓ should signup the user, change iterations and signin (63ms)
35
+ ✓ should signup the user, change password and iterations and signin (81ms)
36
36
  should throw an error
37
37
  ✓ trying to signup if Secrez has not been initiated
38
38
  ✓ trying to signin if Secrez has not been initiated
39
39
  ✓ trying to signup if account already exists
40
40
  ✓ trying to signin if account is not set yet
41
41
  ✓ trying to signin with missed iterations
42
- ✓ trying to signin with the wrong password
43
- ✓ trying to signin with the right password but wrong number of iterations
44
- ✓ trying to signin with the right password but using a wrong hash on file
42
+ ✓ trying to signin with the wrong password (40ms)
43
+ ✓ trying to signin with the right password but wrong number of iterations (41ms)
44
+ ✓ trying to signin with the right password but using a wrong hash on file (41ms)
45
45
  ✓ trying to sign out if never signed-in
46
46
  encryptEntry and decryptEntry
47
47
  ✓ should encrypt a name and decrypt it
@@ -62,22 +62,22 @@
62
62
  ✓ should encrypt some data with the derivedPassword and decrypt it
63
63
  ✓ should throw trying to get the master key
64
64
  generateSharedSecrets && recoverSharedSecrets
65
- ✓ should set up a second factor (57ms)
66
- ✓ should set up a second factor and then upgrade from derivationVersion 1 to 2
67
- ✓ should set up a second factor and a recovery code and remove them (58ms)
68
- ✓ should set up a second factor and a recovery code and remove the recovery code (58ms)
69
- ✓ should throw if wrong secret
70
- ✓ should throw if wrong authenticator
65
+ ✓ should set up a second factor (72ms)
66
+ ✓ should set up a second factor and then upgrade from derivationVersion 1 to 2 (46ms)
67
+ ✓ should set up a second factor and a recovery code and remove them (70ms)
68
+ ✓ should set up a second factor and a recovery code and remove the recovery code (69ms)
69
+ ✓ should throw if wrong secret (42ms)
70
+ ✓ should throw if wrong authenticator (43ms)
71
71
  #readConf
72
72
  ✓ should encrypt some data with the derivedPassword and decrypt it
73
73
  ✓ should throw trying to get the master key
74
74
  ✓ should throw trying to get the master key
75
75
  #signMessage
76
- ✓ should sign a message and verify it (40ms)
76
+ ✓ should sign a message and verify it (47ms)
77
77
  #getPublicKey
78
- ✓ should sign a message and verify it
78
+ ✓ should sign a message and verify it (44ms)
79
79
  #encrypt and decrypt shared data
80
- ✓ should get a shared ket (50ms)
80
+ ✓ should get a shared ket (52ms)
81
81
 
82
82
  #config
83
83
  ✓ all field should be correctly configured
@@ -91,18 +91,22 @@
91
91
  ✓ #getEnv should return the environment
92
92
 
93
93
 
94
- 60 passing (1s)
94
+ 60 passing (2s)
95
95
 
96
96
  -----------------|---------|----------|---------|---------|-------------------
97
97
  File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s
98
98
  -----------------|---------|----------|---------|---------|-------------------
99
99
  All files | 99.75 | 94.31 | 100 | 99.75 |
100
- src | 100 | 96.07 | 100 | 100 |
100
+ src | 100 | 96.06 | 100 | 100 |
101
101
  Entry.js | 100 | 95.65 | 100 | 100 | 39
102
- Secrez.js | 100 | 96.95 | 100 | 100 | 154,319,442
103
- _Secrez.js | 100 | 91.67 | 100 | 100 | 14,226
104
- src/config | 98.57 | 84.85 | 100 | 98.57 |
105
- ConfigUtils.js | 98.48 | 84.85 | 100 | 98.48 | 137
102
+ Secrez.js | 100 | 96.94 | 100 | 100 | 154,319,442
103
+ _Secrez.js | 100 | 91.66 | 100 | 100 | 14,226
104
+ src/config | 98.57 | 84.84 | 100 | 98.57 |
105
+ ConfigUtils.js | 98.48 | 84.84 | 100 | 98.48 | 137
106
106
  booleans.js | 100 | 100 | 100 | 100 |
107
107
  index.js | 100 | 100 | 100 | 100 |
108
108
  -----------------|---------|----------|---------|---------|-------------------
109
+
110
+ > @secrez/core@1.0.5 posttest /Users/francescosullo/Projects/Secrez/secrez/packages/core
111
+ > nyc check-coverage --statements 99 --branches 94 --functions 99 --lines 99
112
+
package/package.json CHANGED
@@ -1,22 +1,22 @@
1
1
  {
2
2
  "name": "@secrez/core",
3
- "version": "1.0.4",
3
+ "version": "1.0.5",
4
4
  "license": "MIT",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
8
8
  "dependencies": {
9
- "@secrez/crypto": "~1.0.3",
10
- "@secrez/utils": "~1.0.3",
9
+ "@secrez/crypto": "~1.0.4",
10
+ "@secrez/utils": "~1.0.4",
11
11
  "fs-extra": "^9.1.0",
12
12
  "homedir": "^0.6.0",
13
- "lodash": "^4.17.15"
13
+ "lodash": "^4.17.21"
14
14
  },
15
15
  "devDependencies": {
16
- "@secrez/test-helpers": "~2.0.0",
17
- "chai": "^4.2.0",
18
- "cross-env": "^7.0.2",
19
- "mocha": "^7.1.2",
16
+ "@secrez/test-helpers": "~2.0.1",
17
+ "chai": "^4.5.0",
18
+ "cross-env": "^7.0.3",
19
+ "mocha": "^7.2.0",
20
20
  "nyc": "^15.1.0"
21
21
  },
22
22
  "description": "The Secrez core library.",