@plotdb/express-session 1.17.3
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/HISTORY.md +442 -0
- package/LICENSE +24 -0
- package/README.md +994 -0
- package/index.js +693 -0
- package/package.json +47 -0
- package/session/cookie.js +150 -0
- package/session/memory.js +187 -0
- package/session/session.js +143 -0
- package/session/store.js +102 -0
package/HISTORY.md
ADDED
|
@@ -0,0 +1,442 @@
|
|
|
1
|
+
1.17.3 / 2022-05-11
|
|
2
|
+
===================
|
|
3
|
+
|
|
4
|
+
* Fix resaving already-saved new session at end of request
|
|
5
|
+
* deps: cookie@0.4.2
|
|
6
|
+
|
|
7
|
+
1.17.2 / 2021-05-19
|
|
8
|
+
===================
|
|
9
|
+
|
|
10
|
+
* Fix `res.end` patch to always commit headers
|
|
11
|
+
* deps: cookie@0.4.1
|
|
12
|
+
* deps: safe-buffer@5.2.1
|
|
13
|
+
|
|
14
|
+
1.17.1 / 2020-04-16
|
|
15
|
+
===================
|
|
16
|
+
|
|
17
|
+
* Fix internal method wrapping error on failed reloads
|
|
18
|
+
|
|
19
|
+
1.17.0 / 2019-10-10
|
|
20
|
+
===================
|
|
21
|
+
|
|
22
|
+
* deps: cookie@0.4.0
|
|
23
|
+
- Add `SameSite=None` support
|
|
24
|
+
* deps: safe-buffer@5.2.0
|
|
25
|
+
|
|
26
|
+
1.16.2 / 2019-06-12
|
|
27
|
+
===================
|
|
28
|
+
|
|
29
|
+
* Fix restoring `cookie.originalMaxAge` when store returns `Date`
|
|
30
|
+
* deps: parseurl@~1.3.3
|
|
31
|
+
|
|
32
|
+
1.16.1 / 2019-04-11
|
|
33
|
+
===================
|
|
34
|
+
|
|
35
|
+
* Fix error passing `data` option to `Cookie` constructor
|
|
36
|
+
* Fix uncaught error from bad session data
|
|
37
|
+
|
|
38
|
+
1.16.0 / 2019-04-10
|
|
39
|
+
===================
|
|
40
|
+
|
|
41
|
+
* Catch invalid `cookie.maxAge` value earlier
|
|
42
|
+
* Deprecate setting `cookie.maxAge` to a `Date` object
|
|
43
|
+
* Fix issue where `resave: false` may not save altered sessions
|
|
44
|
+
* Remove `utils-merge` dependency
|
|
45
|
+
* Use `safe-buffer` for improved Buffer API
|
|
46
|
+
* Use `Set-Cookie` as cookie header name for compatibility
|
|
47
|
+
* deps: depd@~2.0.0
|
|
48
|
+
- Replace internal `eval` usage with `Function` constructor
|
|
49
|
+
- Use instance methods on `process` to check for listeners
|
|
50
|
+
- perf: remove argument reassignment
|
|
51
|
+
* deps: on-headers@~1.0.2
|
|
52
|
+
- Fix `res.writeHead` patch missing return value
|
|
53
|
+
|
|
54
|
+
1.15.6 / 2017-09-26
|
|
55
|
+
===================
|
|
56
|
+
|
|
57
|
+
* deps: debug@2.6.9
|
|
58
|
+
* deps: parseurl@~1.3.2
|
|
59
|
+
- perf: reduce overhead for full URLs
|
|
60
|
+
- perf: unroll the "fast-path" `RegExp`
|
|
61
|
+
* deps: uid-safe@~2.1.5
|
|
62
|
+
- perf: remove only trailing `=`
|
|
63
|
+
* deps: utils-merge@1.0.1
|
|
64
|
+
|
|
65
|
+
1.15.5 / 2017-08-02
|
|
66
|
+
===================
|
|
67
|
+
|
|
68
|
+
* Fix `TypeError` when `req.url` is an empty string
|
|
69
|
+
* deps: depd@~1.1.1
|
|
70
|
+
- Remove unnecessary `Buffer` loading
|
|
71
|
+
|
|
72
|
+
1.15.4 / 2017-07-18
|
|
73
|
+
===================
|
|
74
|
+
|
|
75
|
+
* deps: debug@2.6.8
|
|
76
|
+
|
|
77
|
+
1.15.3 / 2017-05-17
|
|
78
|
+
===================
|
|
79
|
+
|
|
80
|
+
* deps: debug@2.6.7
|
|
81
|
+
- deps: ms@2.0.0
|
|
82
|
+
|
|
83
|
+
1.15.2 / 2017-03-26
|
|
84
|
+
===================
|
|
85
|
+
|
|
86
|
+
* deps: debug@2.6.3
|
|
87
|
+
- Fix `DEBUG_MAX_ARRAY_LENGTH`
|
|
88
|
+
* deps: uid-safe@~2.1.4
|
|
89
|
+
- Remove `base64-url` dependency
|
|
90
|
+
|
|
91
|
+
1.15.1 / 2017-02-10
|
|
92
|
+
===================
|
|
93
|
+
|
|
94
|
+
* deps: debug@2.6.1
|
|
95
|
+
- Fix deprecation messages in WebStorm and other editors
|
|
96
|
+
- Undeprecate `DEBUG_FD` set to `1` or `2`
|
|
97
|
+
|
|
98
|
+
1.15.0 / 2017-01-22
|
|
99
|
+
===================
|
|
100
|
+
|
|
101
|
+
* Fix detecting modified session when session contains "cookie" property
|
|
102
|
+
* Fix resaving already-saved reloaded session at end of request
|
|
103
|
+
* deps: crc@3.4.4
|
|
104
|
+
- perf: use `Buffer.from` when available
|
|
105
|
+
* deps: debug@2.6.0
|
|
106
|
+
- Allow colors in workers
|
|
107
|
+
- Deprecated `DEBUG_FD` environment variable
|
|
108
|
+
- Use same color for same namespace
|
|
109
|
+
- Fix error when running under React Native
|
|
110
|
+
- deps: ms@0.7.2
|
|
111
|
+
* perf: remove unreachable branch in set-cookie method
|
|
112
|
+
|
|
113
|
+
1.14.2 / 2016-10-30
|
|
114
|
+
===================
|
|
115
|
+
|
|
116
|
+
* deps: crc@3.4.1
|
|
117
|
+
- Fix deprecation warning in Node.js 7.x
|
|
118
|
+
* deps: uid-safe@~2.1.3
|
|
119
|
+
- deps: base64-url@1.3.3
|
|
120
|
+
|
|
121
|
+
1.14.1 / 2016-08-24
|
|
122
|
+
===================
|
|
123
|
+
|
|
124
|
+
* Fix not always resetting session max age before session save
|
|
125
|
+
* Fix the cookie `sameSite` option to actually alter the `Set-Cookie`
|
|
126
|
+
* deps: uid-safe@~2.1.2
|
|
127
|
+
- deps: base64-url@1.3.2
|
|
128
|
+
|
|
129
|
+
1.14.0 / 2016-07-01
|
|
130
|
+
===================
|
|
131
|
+
|
|
132
|
+
* Correctly inherit from `EventEmitter` class in `Store` base class
|
|
133
|
+
* Fix issue where `Set-Cookie` `Expires` was not always updated
|
|
134
|
+
* Methods are no longer enumerable on `req.session` object
|
|
135
|
+
* deps: cookie@0.3.1
|
|
136
|
+
- Add `sameSite` option
|
|
137
|
+
- Improve error message when `encode` is not a function
|
|
138
|
+
- Improve error message when `expires` is not a `Date`
|
|
139
|
+
- perf: enable strict mode
|
|
140
|
+
- perf: use for loop in parse
|
|
141
|
+
- perf: use string concatination for serialization
|
|
142
|
+
* deps: parseurl@~1.3.1
|
|
143
|
+
- perf: enable strict mode
|
|
144
|
+
* deps: uid-safe@~2.1.1
|
|
145
|
+
- Use `random-bytes` for byte source
|
|
146
|
+
- deps: base64-url@1.2.2
|
|
147
|
+
* perf: enable strict mode
|
|
148
|
+
* perf: remove argument reassignment
|
|
149
|
+
|
|
150
|
+
1.13.0 / 2016-01-10
|
|
151
|
+
===================
|
|
152
|
+
|
|
153
|
+
* Fix `rolling: true` to not set cookie when no session exists
|
|
154
|
+
- Better `saveUninitialized: false` + `rolling: true` behavior
|
|
155
|
+
* deps: crc@3.4.0
|
|
156
|
+
|
|
157
|
+
1.12.1 / 2015-10-29
|
|
158
|
+
===================
|
|
159
|
+
|
|
160
|
+
* deps: cookie@0.2.3
|
|
161
|
+
- Fix cookie `Max-Age` to never be a floating point number
|
|
162
|
+
|
|
163
|
+
1.12.0 / 2015-10-25
|
|
164
|
+
===================
|
|
165
|
+
|
|
166
|
+
* Support the value `'auto'` in the `cookie.secure` option
|
|
167
|
+
* deps: cookie@0.2.2
|
|
168
|
+
- Throw on invalid values provided to `serialize`
|
|
169
|
+
* deps: depd@~1.1.0
|
|
170
|
+
- Enable strict mode in more places
|
|
171
|
+
- Support web browser loading
|
|
172
|
+
* deps: on-headers@~1.0.1
|
|
173
|
+
- perf: enable strict mode
|
|
174
|
+
|
|
175
|
+
1.11.3 / 2015-05-22
|
|
176
|
+
===================
|
|
177
|
+
|
|
178
|
+
* deps: cookie@0.1.3
|
|
179
|
+
- Slight optimizations
|
|
180
|
+
* deps: crc@3.3.0
|
|
181
|
+
|
|
182
|
+
1.11.2 / 2015-05-10
|
|
183
|
+
===================
|
|
184
|
+
|
|
185
|
+
* deps: debug@~2.2.0
|
|
186
|
+
- deps: ms@0.7.1
|
|
187
|
+
* deps: uid-safe@~2.0.0
|
|
188
|
+
|
|
189
|
+
1.11.1 / 2015-04-08
|
|
190
|
+
===================
|
|
191
|
+
|
|
192
|
+
* Fix mutating `options.secret` value
|
|
193
|
+
|
|
194
|
+
1.11.0 / 2015-04-07
|
|
195
|
+
===================
|
|
196
|
+
|
|
197
|
+
* Support an array in `secret` option for key rotation
|
|
198
|
+
* deps: depd@~1.0.1
|
|
199
|
+
|
|
200
|
+
1.10.4 / 2015-03-15
|
|
201
|
+
===================
|
|
202
|
+
|
|
203
|
+
* deps: debug@~2.1.3
|
|
204
|
+
- Fix high intensity foreground color for bold
|
|
205
|
+
- deps: ms@0.7.0
|
|
206
|
+
|
|
207
|
+
1.10.3 / 2015-02-16
|
|
208
|
+
===================
|
|
209
|
+
|
|
210
|
+
* deps: cookie-signature@1.0.6
|
|
211
|
+
* deps: uid-safe@1.1.0
|
|
212
|
+
- Use `crypto.randomBytes`, if available
|
|
213
|
+
- deps: base64-url@1.2.1
|
|
214
|
+
|
|
215
|
+
1.10.2 / 2015-01-31
|
|
216
|
+
===================
|
|
217
|
+
|
|
218
|
+
* deps: uid-safe@1.0.3
|
|
219
|
+
- Fix error branch that would throw
|
|
220
|
+
- deps: base64-url@1.2.0
|
|
221
|
+
|
|
222
|
+
1.10.1 / 2015-01-08
|
|
223
|
+
===================
|
|
224
|
+
|
|
225
|
+
* deps: uid-safe@1.0.2
|
|
226
|
+
- Remove dependency on `mz`
|
|
227
|
+
|
|
228
|
+
1.10.0 / 2015-01-05
|
|
229
|
+
===================
|
|
230
|
+
|
|
231
|
+
* Add `store.touch` interface for session stores
|
|
232
|
+
* Fix `MemoryStore` expiration with `resave: false`
|
|
233
|
+
* deps: debug@~2.1.1
|
|
234
|
+
|
|
235
|
+
1.9.3 / 2014-12-02
|
|
236
|
+
==================
|
|
237
|
+
|
|
238
|
+
* Fix error when `req.sessionID` contains a non-string value
|
|
239
|
+
|
|
240
|
+
1.9.2 / 2014-11-22
|
|
241
|
+
==================
|
|
242
|
+
|
|
243
|
+
* deps: crc@3.2.1
|
|
244
|
+
- Minor fixes
|
|
245
|
+
|
|
246
|
+
1.9.1 / 2014-10-22
|
|
247
|
+
==================
|
|
248
|
+
|
|
249
|
+
* Remove unnecessary empty write call
|
|
250
|
+
- Fixes Node.js 0.11.14 behavior change
|
|
251
|
+
- Helps work-around Node.js 0.10.1 zlib bug
|
|
252
|
+
|
|
253
|
+
1.9.0 / 2014-09-16
|
|
254
|
+
==================
|
|
255
|
+
|
|
256
|
+
* deps: debug@~2.1.0
|
|
257
|
+
- Implement `DEBUG_FD` env variable support
|
|
258
|
+
* deps: depd@~1.0.0
|
|
259
|
+
|
|
260
|
+
1.8.2 / 2014-09-15
|
|
261
|
+
==================
|
|
262
|
+
|
|
263
|
+
* Use `crc` instead of `buffer-crc32` for speed
|
|
264
|
+
* deps: depd@0.4.5
|
|
265
|
+
|
|
266
|
+
1.8.1 / 2014-09-08
|
|
267
|
+
==================
|
|
268
|
+
|
|
269
|
+
* Keep `req.session.save` non-enumerable
|
|
270
|
+
* Prevent session prototype methods from being overwritten
|
|
271
|
+
|
|
272
|
+
1.8.0 / 2014-09-07
|
|
273
|
+
==================
|
|
274
|
+
|
|
275
|
+
* Do not resave already-saved session at end of request
|
|
276
|
+
* deps: cookie-signature@1.0.5
|
|
277
|
+
* deps: debug@~2.0.0
|
|
278
|
+
|
|
279
|
+
1.7.6 / 2014-08-18
|
|
280
|
+
==================
|
|
281
|
+
|
|
282
|
+
* Fix exception on `res.end(null)` calls
|
|
283
|
+
|
|
284
|
+
1.7.5 / 2014-08-10
|
|
285
|
+
==================
|
|
286
|
+
|
|
287
|
+
* Fix parsing original URL
|
|
288
|
+
* deps: on-headers@~1.0.0
|
|
289
|
+
* deps: parseurl@~1.3.0
|
|
290
|
+
|
|
291
|
+
1.7.4 / 2014-08-05
|
|
292
|
+
==================
|
|
293
|
+
|
|
294
|
+
* Fix response end delay for non-chunked responses
|
|
295
|
+
|
|
296
|
+
1.7.3 / 2014-08-05
|
|
297
|
+
==================
|
|
298
|
+
|
|
299
|
+
* Fix `res.end` patch to call correct upstream `res.write`
|
|
300
|
+
|
|
301
|
+
1.7.2 / 2014-07-27
|
|
302
|
+
==================
|
|
303
|
+
|
|
304
|
+
* deps: depd@0.4.4
|
|
305
|
+
- Work-around v8 generating empty stack traces
|
|
306
|
+
|
|
307
|
+
1.7.1 / 2014-07-26
|
|
308
|
+
==================
|
|
309
|
+
|
|
310
|
+
* deps: depd@0.4.3
|
|
311
|
+
- Fix exception when global `Error.stackTraceLimit` is too low
|
|
312
|
+
|
|
313
|
+
1.7.0 / 2014-07-22
|
|
314
|
+
==================
|
|
315
|
+
|
|
316
|
+
* Improve session-ending error handling
|
|
317
|
+
- Errors are passed to `next(err)` instead of `console.error`
|
|
318
|
+
* deps: debug@1.0.4
|
|
319
|
+
* deps: depd@0.4.2
|
|
320
|
+
- Add `TRACE_DEPRECATION` environment variable
|
|
321
|
+
- Remove non-standard grey color from color output
|
|
322
|
+
- Support `--no-deprecation` argument
|
|
323
|
+
- Support `--trace-deprecation` argument
|
|
324
|
+
|
|
325
|
+
1.6.5 / 2014-07-11
|
|
326
|
+
==================
|
|
327
|
+
|
|
328
|
+
* Do not require `req.originalUrl`
|
|
329
|
+
* deps: debug@1.0.3
|
|
330
|
+
- Add support for multiple wildcards in namespaces
|
|
331
|
+
|
|
332
|
+
1.6.4 / 2014-07-07
|
|
333
|
+
==================
|
|
334
|
+
|
|
335
|
+
* Fix blank responses for stores with synchronous operations
|
|
336
|
+
|
|
337
|
+
1.6.3 / 2014-07-04
|
|
338
|
+
==================
|
|
339
|
+
|
|
340
|
+
* Fix resave deprecation message
|
|
341
|
+
|
|
342
|
+
1.6.2 / 2014-07-04
|
|
343
|
+
==================
|
|
344
|
+
|
|
345
|
+
* Fix confusing option deprecation messages
|
|
346
|
+
|
|
347
|
+
1.6.1 / 2014-06-28
|
|
348
|
+
==================
|
|
349
|
+
|
|
350
|
+
* Fix saveUninitialized deprecation message
|
|
351
|
+
|
|
352
|
+
1.6.0 / 2014-06-28
|
|
353
|
+
==================
|
|
354
|
+
|
|
355
|
+
* Add deprecation message to undefined `resave` option
|
|
356
|
+
* Add deprecation message to undefined `saveUninitialized` option
|
|
357
|
+
* Fix `res.end` patch to return correct value
|
|
358
|
+
* Fix `res.end` patch to handle multiple `res.end` calls
|
|
359
|
+
* Reject cookies with missing signatures
|
|
360
|
+
|
|
361
|
+
1.5.2 / 2014-06-26
|
|
362
|
+
==================
|
|
363
|
+
|
|
364
|
+
* deps: cookie-signature@1.0.4
|
|
365
|
+
- fix for timing attacks
|
|
366
|
+
|
|
367
|
+
1.5.1 / 2014-06-21
|
|
368
|
+
==================
|
|
369
|
+
|
|
370
|
+
* Move hard-to-track-down `req.secret` deprecation message
|
|
371
|
+
|
|
372
|
+
1.5.0 / 2014-06-19
|
|
373
|
+
==================
|
|
374
|
+
|
|
375
|
+
* Debug name is now "express-session"
|
|
376
|
+
* Deprecate integration with `cookie-parser` middleware
|
|
377
|
+
* Deprecate looking for secret in `req.secret`
|
|
378
|
+
* Directly read cookies; `cookie-parser` no longer required
|
|
379
|
+
* Directly set cookies; `res.cookie` no longer required
|
|
380
|
+
* Generate session IDs with `uid-safe`, faster and even less collisions
|
|
381
|
+
|
|
382
|
+
1.4.0 / 2014-06-17
|
|
383
|
+
==================
|
|
384
|
+
|
|
385
|
+
* Add `genid` option to generate custom session IDs
|
|
386
|
+
* Add `saveUninitialized` option to control saving uninitialized sessions
|
|
387
|
+
* Add `unset` option to control unsetting `req.session`
|
|
388
|
+
* Generate session IDs with `rand-token` by default; reduce collisions
|
|
389
|
+
* deps: buffer-crc32@0.2.3
|
|
390
|
+
|
|
391
|
+
1.3.1 / 2014-06-14
|
|
392
|
+
==================
|
|
393
|
+
|
|
394
|
+
* Add description in package for npmjs.org listing
|
|
395
|
+
|
|
396
|
+
1.3.0 / 2014-06-14
|
|
397
|
+
==================
|
|
398
|
+
|
|
399
|
+
* Integrate with express "trust proxy" by default
|
|
400
|
+
* deps: debug@1.0.2
|
|
401
|
+
|
|
402
|
+
1.2.1 / 2014-05-27
|
|
403
|
+
==================
|
|
404
|
+
|
|
405
|
+
* Fix `resave` such that `resave: true` works
|
|
406
|
+
|
|
407
|
+
1.2.0 / 2014-05-19
|
|
408
|
+
==================
|
|
409
|
+
|
|
410
|
+
* Add `resave` option to control saving unmodified sessions
|
|
411
|
+
|
|
412
|
+
1.1.0 / 2014-05-12
|
|
413
|
+
==================
|
|
414
|
+
|
|
415
|
+
* Add `name` option; replacement for `key` option
|
|
416
|
+
* Use `setImmediate` in MemoryStore for node.js >= 0.10
|
|
417
|
+
|
|
418
|
+
1.0.4 / 2014-04-27
|
|
419
|
+
==================
|
|
420
|
+
|
|
421
|
+
* deps: debug@0.8.1
|
|
422
|
+
|
|
423
|
+
1.0.3 / 2014-04-19
|
|
424
|
+
==================
|
|
425
|
+
|
|
426
|
+
* Use `res.cookie()` instead of `res.setHeader()`
|
|
427
|
+
* deps: cookie@0.1.2
|
|
428
|
+
|
|
429
|
+
1.0.2 / 2014-02-23
|
|
430
|
+
==================
|
|
431
|
+
|
|
432
|
+
* Add missing dependency to `package.json`
|
|
433
|
+
|
|
434
|
+
1.0.1 / 2014-02-15
|
|
435
|
+
==================
|
|
436
|
+
|
|
437
|
+
* Add missing dependencies to `package.json`
|
|
438
|
+
|
|
439
|
+
1.0.0 / 2014-02-15
|
|
440
|
+
==================
|
|
441
|
+
|
|
442
|
+
* Genesis from `connect`
|
package/LICENSE
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
(The MIT License)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2010 Sencha Inc.
|
|
4
|
+
Copyright (c) 2011 TJ Holowaychuk <tj@vision-media.ca>
|
|
5
|
+
Copyright (c) 2014-2015 Douglas Christopher Wilson <doug@somethingdoug.com>
|
|
6
|
+
|
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
8
|
+
a copy of this software and associated documentation files (the
|
|
9
|
+
'Software'), to deal in the Software without restriction, including
|
|
10
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
11
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
12
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
13
|
+
the following conditions:
|
|
14
|
+
|
|
15
|
+
The above copyright notice and this permission notice shall be
|
|
16
|
+
included in all copies or substantial portions of the Software.
|
|
17
|
+
|
|
18
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
|
19
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
20
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
21
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
|
22
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
23
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
|
24
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|