@icoretech/warden-mcp 0.2.68 → 0.2.70

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.
Files changed (38) hide show
  1. package/node_modules/encodeurl/README.md +14 -0
  2. package/node_modules/encodeurl/index.js +5 -10
  3. package/node_modules/encodeurl/package.json +10 -6
  4. package/node_modules/qs/.editorconfig +1 -1
  5. package/node_modules/qs/CHANGELOG.md +87 -22
  6. package/node_modules/qs/README.md +63 -10
  7. package/node_modules/qs/dist/qs.js +17 -17
  8. package/node_modules/qs/eslint.config.mjs +61 -50
  9. package/node_modules/qs/lib/formats.js +7 -2
  10. package/node_modules/qs/lib/parse.js +29 -10
  11. package/node_modules/qs/lib/stringify.js +5 -3
  12. package/node_modules/qs/lib/utils.js +28 -9
  13. package/node_modules/qs/package.json +6 -6
  14. package/node_modules/qs/test/parse.js +335 -2
  15. package/node_modules/qs/test/stringify.js +222 -0
  16. package/node_modules/qs/test/utils.js +61 -3
  17. package/node_modules/tldts-core/dist/cjs/index.js +1 -1
  18. package/node_modules/tldts-core/dist/cjs/index.js.map +1 -1
  19. package/node_modules/tldts-core/dist/cjs/src/is-ip.js +1 -1
  20. package/node_modules/tldts-core/dist/cjs/src/is-ip.js.map +1 -1
  21. package/node_modules/tldts-core/dist/cjs/tsconfig.tsbuildinfo +1 -1
  22. package/node_modules/tldts-core/dist/es6/src/is-ip.js +1 -1
  23. package/node_modules/tldts-core/dist/es6/src/is-ip.js.map +1 -1
  24. package/node_modules/tldts-core/dist/es6/tsconfig.bundle.tsbuildinfo +1 -1
  25. package/node_modules/tldts-core/package.json +2 -2
  26. package/node_modules/tldts-core/src/is-ip.ts +1 -1
  27. package/node_modules/tslib/README.md +3 -8
  28. package/node_modules/tslib/package.json +1 -1
  29. package/node_modules/tslib/tslib.d.ts +4 -2
  30. package/node_modules/tslib/tslib.es6.js +10 -1
  31. package/node_modules/tslib/tslib.es6.mjs +10 -1
  32. package/node_modules/tslib/tslib.js +10 -1
  33. package/node_modules/ws/README.md +21 -29
  34. package/node_modules/ws/lib/buffer-util.js +13 -2
  35. package/node_modules/ws/lib/sender.js +4 -1
  36. package/node_modules/ws/lib/websocket.js +8 -3
  37. package/node_modules/ws/package.json +1 -1
  38. package/package.json +1 -1
@@ -357,8 +357,17 @@ export function __disposeResources(env) {
357
357
  return next();
358
358
  }
359
359
 
360
- export function __rewriteRelativeImportExtension(path, preserveJsx) {
360
+ export function __rewriteRelativeImportExtension(path, preserveJsx, extraExtensions, ignoreCase) {
361
361
  if (typeof path === "string" && /^\.\.?\//.test(path)) {
362
+ if (extraExtensions) {
363
+ for (var extension in extraExtensions) {
364
+ var suffix = path.slice(-extension.length);
365
+ if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
366
+ var output = extraExtensions[extension];
367
+ return output === extension ? path : path.slice(0, -extension.length) + output;
368
+ }
369
+ }
370
+ }
362
371
  return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
363
372
  return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
364
373
  });
@@ -356,8 +356,17 @@ export function __disposeResources(env) {
356
356
  return next();
357
357
  }
358
358
 
359
- export function __rewriteRelativeImportExtension(path, preserveJsx) {
359
+ export function __rewriteRelativeImportExtension(path, preserveJsx, extraExtensions, ignoreCase) {
360
360
  if (typeof path === "string" && /^\.\.?\//.test(path)) {
361
+ if (extraExtensions) {
362
+ for (var extension in extraExtensions) {
363
+ var suffix = path.slice(-extension.length);
364
+ if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
365
+ var output = extraExtensions[extension];
366
+ return output === extension ? path : path.slice(0, -extension.length) + output;
367
+ }
368
+ }
369
+ }
361
370
  return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
362
371
  return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
363
372
  });
@@ -405,8 +405,17 @@ var __rewriteRelativeImportExtension;
405
405
  return next();
406
406
  };
407
407
 
408
- __rewriteRelativeImportExtension = function (path, preserveJsx) {
408
+ __rewriteRelativeImportExtension = function (path, preserveJsx, extraExtensions, ignoreCase) {
409
409
  if (typeof path === "string" && /^\.\.?\//.test(path)) {
410
+ if (extraExtensions) {
411
+ for (var extension in extraExtensions) {
412
+ var suffix = path.slice(-extension.length);
413
+ if (suffix === extension || ignoreCase && suffix.toLowerCase() === extension.toLowerCase()) {
414
+ var output = extraExtensions[extension];
415
+ return output === extension ? path : path.slice(0, -extension.length) + output;
416
+ }
417
+ }
418
+ }
410
419
  return path.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function (m, tsx, d, ext, cm) {
411
420
  return tsx ? preserveJsx ? ".jsx" : ".js" : d && (!ext || !cm) ? m : (d + ext + "." + cm.toLowerCase() + "js");
412
421
  });
@@ -56,39 +56,27 @@ can use one of the many wrappers available on npm, like
56
56
  npm install ws
57
57
  ```
58
58
 
59
- ### Opt-in for performance
59
+ ### Legacy opt-in for performance
60
60
 
61
- [bufferutil][] is an optional module that can be installed alongside the ws
62
- module:
61
+ On older Node.js versions, ws can leverage optional binary modules to optimize
62
+ performance.
63
63
 
64
- ```
65
- npm install --save-optional bufferutil
66
- ```
67
-
68
- This is a binary addon that improves the performance of certain operations such
69
- as masking and unmasking the data payload of the WebSocket frames. Prebuilt
70
- binaries are available for the most popular platforms, so you don't necessarily
71
- need to have a C++ compiler installed on your machine.
72
-
73
- To force ws to not use bufferutil, use the
74
- [`WS_NO_BUFFER_UTIL`](./doc/ws.md#ws_no_buffer_util) environment variable. This
75
- can be useful to enhance security in systems where a user can put a package in
76
- the package search path of an application of another user, due to how the
77
- Node.js resolver algorithm works.
78
-
79
- #### Legacy opt-in for performance
80
-
81
- If you are running on an old version of Node.js (prior to v18.14.0), ws also
82
- supports the [utf-8-validate][] module:
83
-
84
- ```
85
- npm install --save-optional utf-8-validate
86
- ```
64
+ - `npm install --save-optional bufferutil`: Provides binary polyfills for
65
+ [`http.websocketMask()`][] and [`http.websocketUnmask()`][].
66
+ - `npm install --save-optional utf-8-validate`: Provides a binary polyfill for
67
+ [`buffer.isUtf8()`][].
87
68
 
88
- This contains a binary polyfill for [`buffer.isUtf8()`][].
69
+ On newer Node.js versions (v27.0.0-alpha.0.0.0 or later for bufferutil, and
70
+ v18.14.0 or later for utf-8-validate) that feature built-in alternatives, these
71
+ modules are not loaded even if installed.
89
72
 
90
- To force ws not to use utf-8-validate, use the
91
- [`WS_NO_UTF_8_VALIDATE`](./doc/ws.md#ws_no_utf_8_validate) environment variable.
73
+ To force ws not to use [bufferutil][] or [utf-8-validate][] on the older Node.js
74
+ versions where they would otherwise be loaded, set the
75
+ [`WS_NO_BUFFER_UTIL`](./doc/ws.md#ws_no_buffer_util) and
76
+ [`WS_NO_UTF_8_VALIDATE`](./doc/ws.md#ws_no_utf_8_validate) environment
77
+ variables. This can be useful to enhance security in systems where a user can
78
+ put a package in the package search path of an application of another user, due
79
+ to how the Node.js resolver algorithm works.
92
80
 
93
81
  ## API docs
94
82
 
@@ -533,6 +521,10 @@ We're using the GitHub [releases][changelog] for changelog entries.
533
521
  [MIT](LICENSE)
534
522
 
535
523
  [`buffer.isutf8()`]: https://nodejs.org/api/buffer.html#bufferisutf8input
524
+ [`http.websocketMask()`]:
525
+ https://nodejs.org/api/http.html#httpwebsocketmasksource-mask-output-offset-length
526
+ [`http.websocketUnmask()`]:
527
+ https://nodejs.org/api/http.html#httpwebsocketunmaskbuffer-mask
536
528
  [bufferutil]: https://github.com/websockets/bufferutil
537
529
  [changelog]: https://github.com/websockets/ws/releases
538
530
  [client-report]: http://websockets.github.io/ws/autobahn/clients/
@@ -1,5 +1,7 @@
1
1
  'use strict';
2
2
 
3
+ const { websocketMask, websocketUnmask } = require('http');
4
+
3
5
  const { EMPTY_BUFFER } = require('./constants');
4
6
 
5
7
  const FastBuffer = Buffer[Symbol.species];
@@ -111,8 +113,17 @@ module.exports = {
111
113
  unmask: _unmask
112
114
  };
113
115
 
114
- /* istanbul ignore else */
115
- if (!process.env.WS_NO_BUFFER_UTIL) {
116
+ if (websocketMask) {
117
+ module.exports.mask = function (source, mask, output, offset, length) {
118
+ if (length < 24) _mask(source, mask, output, offset, length);
119
+ else websocketMask(source, mask, output, offset, length);
120
+ };
121
+
122
+ module.exports.unmask = function (buffer, mask) {
123
+ if (buffer.length < 24) _unmask(buffer, mask);
124
+ else websocketUnmask(buffer, mask);
125
+ };
126
+ } /* istanbul ignore else */ else if (!process.env.WS_NO_BUFFER_UTIL) {
116
127
  try {
117
128
  const bufferUtil = require('bufferutil');
118
129
 
@@ -153,7 +153,9 @@ class Sender {
153
153
  target.writeUIntBE(dataLength, 4, 6);
154
154
  }
155
155
 
156
- if (!options.mask) return [target, data];
156
+ if (!options.mask) {
157
+ return dataLength ? [target, data] : [target];
158
+ }
157
159
 
158
160
  target[1] |= 0x80;
159
161
  target[offset - 4] = mask[0];
@@ -161,6 +163,7 @@ class Sender {
161
163
  target[offset - 2] = mask[2];
162
164
  target[offset - 1] = mask[3];
163
165
 
166
+ if (!dataLength) return [target];
164
167
  if (skipMasking) return [target, data];
165
168
 
166
169
  if (merge) {
@@ -819,10 +819,15 @@ function initAsClient(websocket, address, protocols, options) {
819
819
  }
820
820
 
821
821
  if (isIpcUrl) {
822
- const parts = opts.path.split(':');
822
+ const i = opts.path.indexOf(':');
823
823
 
824
- opts.socketPath = parts[0];
825
- opts.path = parts[1];
824
+ if (i === -1) {
825
+ opts.socketPath = opts.path;
826
+ opts.path = '';
827
+ } else {
828
+ opts.socketPath = opts.path.slice(0, i);
829
+ opts.path = opts.path.slice(i + 1);
830
+ }
826
831
  }
827
832
 
828
833
  let req;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ws",
3
- "version": "8.22.0",
3
+ "version": "8.22.1",
4
4
  "peerDependencies": {
5
5
  "bufferutil": "^4.0.1",
6
6
  "utf-8-validate": ">=5.0.2"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@icoretech/warden-mcp",
3
- "version": "0.2.68",
3
+ "version": "0.2.70",
4
4
  "dependencies": {
5
5
  "@bitwarden/cli": "2026.10.1",
6
6
  "@modelcontextprotocol/sdk": "^1.32.2",