@feathersjs/authentication 5.0.5 → 5.0.7

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/CHANGELOG.md CHANGED
@@ -3,6 +3,20 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [5.0.7](https://github.com/feathersjs/feathers/compare/v5.0.6...v5.0.7) (2023-07-14)
7
+
8
+ **Note:** Version bump only for package @feathersjs/authentication
9
+
10
+
11
+
12
+
13
+
14
+ ## [5.0.6](https://github.com/feathersjs/feathers/compare/v5.0.5...v5.0.6) (2023-06-15)
15
+
16
+ ### Bug Fixes
17
+
18
+ - **authentication:** Export JwtVerifyOptions ([#3214](https://github.com/feathersjs/feathers/issues/3214)) ([d59896e](https://github.com/feathersjs/feathers/commit/d59896eb0229f1490c712f19cf84eb2bcf123698))
19
+
6
20
  ## [5.0.5](https://github.com/feathersjs/feathers/compare/v5.0.4...v5.0.5) (2023-04-28)
7
21
 
8
22
  **Note:** Version bump only for package @feathersjs/authentication
package/lib/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export * as hooks from './hooks';
2
2
  export { authenticate } from './hooks';
3
- export { AuthenticationBase, AuthenticationRequest, AuthenticationResult, AuthenticationStrategy, AuthenticationParams, ConnectionEvent } from './core';
3
+ export { AuthenticationBase, AuthenticationRequest, AuthenticationResult, AuthenticationStrategy, AuthenticationParams, ConnectionEvent, JwtVerifyOptions } from './core';
4
4
  export { AuthenticationBaseStrategy } from './strategy';
5
5
  export { AuthenticationService } from './service';
6
6
  export { JWTStrategy } from './jwt';
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iDAAgC;AAChC,iCAAsC;AAA7B,qGAAA,YAAY,OAAA;AACrB,+BAOe;AANb,0GAAA,kBAAkB,OAAA;AAOpB,uCAAuD;AAA9C,sHAAA,0BAA0B,OAAA;AACnC,qCAAiD;AAAxC,gHAAA,qBAAqB,OAAA;AAC9B,6BAAmC;AAA1B,kGAAA,WAAW,OAAA;AACpB,qCAAqF;AAA5E,uHAAA,4BAA4B,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iDAAgC;AAChC,iCAAsC;AAA7B,qGAAA,YAAY,OAAA;AACrB,+BAQe;AAPb,0GAAA,kBAAkB,OAAA;AAQpB,uCAAuD;AAA9C,sHAAA,0BAA0B,OAAA;AACnC,qCAAiD;AAAxC,gHAAA,qBAAqB,OAAA;AAC9B,6BAAmC;AAA1B,kGAAA,WAAW,OAAA;AACpB,qCAAqF;AAA5E,uHAAA,4BAA4B,OAAA"}
package/lib/service.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import '@feathersjs/transport-commons';
2
- import { ServiceMethods, ServiceAddons } from '@feathersjs/feathers';
2
+ import { ServiceMethods } from '@feathersjs/feathers';
3
3
  import { AuthenticationBase, AuthenticationResult, AuthenticationRequest, AuthenticationParams } from './core';
4
4
  declare module '@feathersjs/feathers/lib/declarations' {
5
5
  interface FeathersApplication<Services, Settings> {
@@ -16,8 +16,6 @@ declare module '@feathersjs/feathers/lib/declarations' {
16
16
  authentication?: AuthenticationRequest;
17
17
  }
18
18
  }
19
- export interface AuthenticationService extends ServiceAddons<AuthenticationResult, AuthenticationResult> {
20
- }
21
19
  export declare class AuthenticationService extends AuthenticationBase implements Partial<ServiceMethods<AuthenticationResult, AuthenticationRequest, AuthenticationParams>> {
22
20
  constructor(app: any, configKey?: string, options?: {});
23
21
  /**
package/lib/service.js CHANGED
@@ -138,8 +138,9 @@ class AuthenticationService extends core_1.AuthenticationBase {
138
138
  throw new Error(`The '${service}' service does not have an 'id' property and no 'entityId' option is set.`);
139
139
  }
140
140
  }
141
- if (typeof this.publish === 'function') {
142
- this.publish(() => null);
141
+ const publishable = this;
142
+ if (typeof publishable.publish === 'function') {
143
+ publishable.publish(() => null);
143
144
  }
144
145
  }
145
146
  }
@@ -1 +1 @@
1
- {"version":3,"file":"service.js","sourceRoot":"","sources":["../src/service.ts"],"names":[],"mappings":";;;;;;AAAA,yDAAgC;AAChC,+CAAqD;AACrD,yCAAsC;AACtC,iDAAiD;AAEjD,+CAAoD;AACpD,gEAAuC;AACvC,6CAAyC;AAEzC,iCAA8G;AAC9G,mCAA2C;AAE3C,MAAM,KAAK,GAAG,IAAA,qBAAW,EAAC,oCAAoC,CAAC,CAAA;AAwB/D,MAAa,qBACX,SAAQ,yBAAkB;IAG1B,YAAY,GAAQ,EAAE,SAAS,GAAG,gBAAgB,EAAE,OAAO,GAAG,EAAE;QAC9D,KAAK,CAAC,GAAG,EAAE,SAAS,EAAE,OAAO,CAAC,CAAA;QAE9B,IAAA,aAAK,EAAC,IAAI,EAAE;YACV,MAAM,EAAE,CAAC,IAAA,wBAAe,GAAE,EAAE,IAAA,aAAK,EAAC,OAAO,CAAC,EAAE,IAAA,kBAAU,EAAC,OAAO,CAAC,CAAC;YAChE,MAAM,EAAE,CAAC,IAAA,wBAAe,GAAE,EAAE,IAAA,aAAK,EAAC,QAAQ,CAAC,EAAE,IAAA,kBAAU,EAAC,QAAQ,CAAC,CAAC;SACnE,CAAC,CAAA;QAEF,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,YAAY,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE;YAC7C,MAAM,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,UAAU,CAAC,CAAA;QACvD,CAAC,CAAC,CAAA;QAEF,IAAI,OAAO,GAAG,CAAC,qBAAqB,KAAK,UAAU,EAAE;YACnD,GAAG,CAAC,qBAAqB,GAAG,UAAU,QAAiB;gBACrD,MAAM,SAAS,GAAG,GAAG,CAAC,GAAG,CAAC,uBAAuB,CAAC,CAAA;gBAClD,MA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ersjs/authentication",
3
3
  "description": "Add Authentication to your FeathersJS app.",
4
- "version": "5.0.5",
4
+ "version": "5.0.7",
5
5
  "homepage": "https://feathersjs.com",
6
6
  "main": "lib/",
7
7
  "types": "lib/",
@@ -53,28 +53,28 @@
53
53
  "access": "public"
54
54
  },
55
55
  "dependencies": {
56
- "@feathersjs/commons": "^5.0.5",
57
- "@feathersjs/errors": "^5.0.5",
58
- "@feathersjs/feathers": "^5.0.5",
56
+ "@feathersjs/commons": "^5.0.7",
57
+ "@feathersjs/errors": "^5.0.7",
58
+ "@feathersjs/feathers": "^5.0.7",
59
59
  "@feathersjs/hooks": "^0.8.1",
60
- "@feathersjs/schema": "^5.0.5",
61
- "@feathersjs/transport-commons": "^5.0.5",
62
- "@types/jsonwebtoken": "^9.0.1",
63
- "jsonwebtoken": "^9.0.0",
60
+ "@feathersjs/schema": "^5.0.7",
61
+ "@feathersjs/transport-commons": "^5.0.7",
62
+ "@types/jsonwebtoken": "^9.0.2",
63
+ "jsonwebtoken": "^9.0.1",
64
64
  "lodash": "^4.17.21",
65
65
  "long-timeout": "^0.1.1",
66
66
  "uuid": "^9.0.0"
67
67
  },
68
68
  "devDependencies": {
69
- "@feathersjs/memory": "^5.0.5",
70
- "@types/lodash": "^4.14.192",
69
+ "@feathersjs/memory": "^5.0.7",
70
+ "@types/lodash": "^4.14.195",
71
71
  "@types/mocha": "^10.0.1",
72
- "@types/node": "^18.15.11",
73
- "@types/uuid": "^9.0.1",
72
+ "@types/node": "^20.4.2",
73
+ "@types/uuid": "^9.0.2",
74
74
  "mocha": "^10.2.0",
75
75
  "shx": "^0.3.4",
76
76
  "ts-node": "^10.9.1",
77
- "typescript": "^5.0.3"
77
+ "typescript": "^5.1.6"
78
78
  },
79
- "gitHead": "42bd5e40ec73b10939b9a008ae8e49c39a191009"
79
+ "gitHead": "1ab855487d2dfacb114339c634621357bce3a56a"
80
80
  }
package/src/index.ts CHANGED
@@ -6,7 +6,8 @@ export {
6
6
  AuthenticationResult,
7
7
  AuthenticationStrategy,
8
8
  AuthenticationParams,
9
- ConnectionEvent
9
+ ConnectionEvent,
10
+ JwtVerifyOptions
10
11
  } from './core'
11
12
  export { AuthenticationBaseStrategy } from './strategy'
12
13
  export { AuthenticationService } from './service'
package/src/service.ts CHANGED
@@ -2,13 +2,14 @@ import merge from 'lodash/merge'
2
2
  import { NotAuthenticated } from '@feathersjs/errors'
3
3
  import '@feathersjs/transport-commons'
4
4
  import { createDebug } from '@feathersjs/commons'
5
- import { ServiceMethods, ServiceAddons } from '@feathersjs/feathers'
5
+ import { ServiceMethods } from '@feathersjs/feathers'
6
6
  import { resolveDispatch } from '@feathersjs/schema'
7
7
  import jsonwebtoken from 'jsonwebtoken'
8
8
  import { hooks } from '@feathersjs/hooks'
9
9
 
10
10
  import { AuthenticationBase, AuthenticationResult, AuthenticationRequest, AuthenticationParams } from './core'
11
11
  import { connection, event } from './hooks'
12
+ import { RealTimeConnection } from '@feathersjs/feathers'
12
13
 
13
14
  const debug = createDebug('@feathersjs/authentication/service')
14
15
 
@@ -31,9 +32,6 @@ declare module '@feathersjs/feathers/lib/declarations' {
31
32
  }
32
33
  }
33
34
 
34
- // eslint-disable-next-line @typescript-eslint/no-empty-interface
35
- export interface AuthenticationService extends ServiceAddons<AuthenticationResult, AuthenticationResult> {}
36
-
37
35
  export class AuthenticationService
38
36
  extends AuthenticationBase
39
37
  implements Partial<ServiceMethods<AuthenticationResult, AuthenticationRequest, AuthenticationParams>>
@@ -46,7 +44,7 @@ export class AuthenticationService
46
44
  remove: [resolveDispatch(), event('logout'), connection('logout')]
47
45
  })
48
46
 
49
- this.app.on('disconnect', async (connection) => {
47
+ this.app.on('disconnect', async (connection: RealTimeConnection) => {
50
48
  await this.handleConnection('disconnect', connection)
51
49
  })
52
50
 
@@ -196,8 +194,10 @@ export class AuthenticationService
196
194
  }
197
195
  }
198
196
 
199
- if (typeof this.publish === 'function') {
200
- this.publish(() => null)
197
+ const publishable = this as any
198
+
199
+ if (typeof publishable.publish === 'function') {
200
+ publishable.publish((): any => null)
201
201
  }
202
202
  }
203
203
  }