publickey-auth-feathers issueshttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues2018-02-01T10:21:20Zhttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/23Error on http://localhost:30302018-02-01T10:21:20ZAral BalkanError on http://localhost:30301. I run npm install
2. I run Gulp
3. I run npm start
4. I hit http://localhost:3030
Error:
```
> publickey-auth-feathers@0.0.0 start /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers
> node server/
info: Fe...1. I run npm install
2. I run Gulp
3. I run npm start
4. I hit http://localhost:3030
Error:
```
> publickey-auth-feathers@0.0.0 start /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers
> node server/
info: Feathers application started on http://localhost:3030
error: NotFound: Page not found
at new NotFound (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/errors/lib/index.js:114:17)
at /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/errors/lib/not-found-handler.js:5:10
at Layer.handle [as handle_request] (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:317:13)
at /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:284:7
at Function.process_params (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:335:12)
at next (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:275:10)
at exposeHeaders (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/authentication/lib/express/expose-headers.js:10:5)
at Layer.handle [as handle_request] (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:317:13)
error: NotFound: Page not found
at new NotFound (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/errors/lib/index.js:114:17)
at /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/errors/lib/not-found-handler.js:5:10
at Layer.handle [as handle_request] (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:317:13)
at /Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:284:7
at Function.process_params (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:335:12)
at next (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:275:10)
at exposeHeaders (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/@feathersjs/authentication/lib/express/expose-headers.js:10:5)
at Layer.handle [as handle_request] (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/Users/aral/ind.ie/products/indienet/spikes/security/publickey-auth-feathers/node_modules/express/lib/router/index.js:317:13)
```https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/22Document gulp requirement and add to npm start script2018-01-31T14:17:30ZAral BalkanDocument gulp requirement and add to npm start scripthttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/21test: Access public route: access allowed regardless of authentication state2018-01-30T11:34:23ZFrauketest: Access public route: access allowed regardless of authentication statehttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/20test: Access private route when authenticated: access allowed2018-01-30T11:34:24ZFrauketest: Access private route when authenticated: access allowedhttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/19test: Access private route when unauthenticated: access denied2018-01-30T11:34:26ZFrauketest: Access private route when unauthenticated: access deniedhttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/18When logging out destroy the JWT & the private unencrypted key on the client.2018-01-30T11:34:25Zwim-vantommeWhen logging out destroy the JWT & the private unencrypted key on the client.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/17Create succesfull login page with log-out button.2018-01-30T11:34:25Zwim-vantommeCreate succesfull login page with log-out button.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/16Save the JWT on the client inside the IndexedDB2018-01-24T14:10:50Zwim-vantommeSave the JWT on the client inside the IndexedDBMight be that we need a cookie in this fase until we build a real one page application based on vue.js and nuxt.Might be that we need a cookie in this fase until we build a real one page application based on vue.js and nuxt.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/15Verify the nonce on the server and if valid return a JWT.2018-01-24T14:10:47Zwim-vantommeVerify the nonce on the server and if valid return a JWT.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/14Transfer the nonce to the server2018-01-24T14:10:42Zwim-vantommeTransfer the nonce to the serverhttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/13Sign the nonce in the client with the sign private key.2018-01-24T14:10:40Zwim-vantommeSign the nonce in the client with the sign private key.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/12Receive a nonce from the server for authentication.2018-01-24T14:10:36Zwim-vantommeReceive a nonce from the server for authentication.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/11Save the unencrypted private key to IndexedDB2018-01-30T11:34:25Zwim-vantommeSave the unencrypted private key to IndexedDBhttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/10Generate sign key for authentication2018-01-31T06:56:25Zwim-vantommeGenerate sign key for authentication2 separate keys are recommended.
We could use the following technique:
https://download.libsodium.org/doc/advanced/ed25519-curve25519.html
but even the creators mention:
> If you can afford it, using distinct keys for signing and for enc...2 separate keys are recommended.
We could use the following technique:
https://download.libsodium.org/doc/advanced/ed25519-curve25519.html
but even the creators mention:
> If you can afford it, using distinct keys for signing and for encryption is still highly recommended.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/9Get encrypted privatekey and decrypt the key.2018-01-24T14:10:47Zwim-vantommeGet encrypted privatekey and decrypt the key.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/8Create a sign-in page2018-01-30T11:34:24Zwim-vantommeCreate a sign-in pagehttps://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/7Create an api feathers enc-point to access the encryptedPrivateKey on the ser...2018-01-24T09:10:56Zwim-vantommeCreate an api feathers enc-point to access the encryptedPrivateKey on the server.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/6Create an api end-point with feathers to access the publicKey.2018-01-24T09:10:49Zwim-vantommeCreate an api end-point with feathers to access the publicKey.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/5Transfer publicKey and encryptedPrivateKey to the server through feathersjs s...2018-01-24T09:10:45Zwim-vantommeTransfer publicKey and encryptedPrivateKey to the server through feathersjs serviceWe will have to create a feathers service and api endpoint to process the private key.
For now we will use https://www.npmjs.com/package/feathers-fs to create this service and store the key on the server.We will have to create a feathers service and api endpoint to process the private key.
For now we will use https://www.npmjs.com/package/feathers-fs to create this service and store the key on the server.https://source.small-tech.org/indienet/spikes/security/publickey-auth-feathers/-/issues/4Encrypt the unencryptedPrivateKey with libsodium.2018-01-24T07:33:35Zwim-vantommeEncrypt the unencryptedPrivateKey with libsodium.