@wenex/sdk 1.0.6 → 1.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.
@@ -8,5 +8,5 @@ exports.MAXIMUM_ACCESS_TTL = 3600; // 1 hour in seconds
8
8
  exports.DEFAULT_REFRESH_TTL = 24 * 60 * 60; // 24 hours in seconds
9
9
  exports.MINIMUM_REFRESH_TTL = 0; // 0 second
10
10
  exports.MAXIMUM_REFRESH_TTL = 45 * 24 * 60 * 60; // 45 days in seconds
11
- exports.SENSITIVE_PHRASES = [RegExp(/pwd/), RegExp(/^pass/), RegExp(/secret/), RegExp(/private/)];
11
+ exports.SENSITIVE_PHRASES = [RegExp(/^pwd/), RegExp(/^pass/), RegExp(/secret/), RegExp(/^private/), RegExp(/authorization/)];
12
12
  //# sourceMappingURL=security.constant.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"security.constant.js","sourceRoot":"","sources":["../../../src/common/core/constants/security.constant.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,EAAE,CAAC,CAAC,cAAc;AAElC,QAAA,kBAAkB,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,wBAAwB;AACtD,QAAA,kBAAkB,GAAG,CAAC,CAAC,CAAC,WAAW;AACnC,QAAA,kBAAkB,GAAG,IAAI,CAAC,CAAC,oBAAoB;AAE/C,QAAA,mBAAmB,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,sBAAsB;AAC1D,QAAA,mBAAmB,GAAG,CAAC,CAAC,CAAC,WAAW;AACpC,QAAA,mBAAmB,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,qBAAqB;AAE9D,QAAA,iBAAiB,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"security.constant.js","sourceRoot":"","sources":["../../../src/common/core/constants/security.constant.ts"],"names":[],"mappings":";;;AAAa,QAAA,aAAa,GAAG,EAAE,CAAC,CAAC,cAAc;AAElC,QAAA,kBAAkB,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,wBAAwB;AACtD,QAAA,kBAAkB,GAAG,CAAC,CAAC,CAAC,WAAW;AACnC,QAAA,kBAAkB,GAAG,IAAI,CAAC,CAAC,oBAAoB;AAE/C,QAAA,mBAAmB,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,sBAAsB;AAC1D,QAAA,mBAAmB,GAAG,CAAC,CAAC,CAAC,WAAW;AACpC,QAAA,mBAAmB,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC,qBAAqB;AAE9D,QAAA,iBAAiB,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const constants_1 = require("../constants");
4
+ const logger_util_1 = require("./logger.util");
5
+ describe('libs/common/src/core/utils/logger.util.ts', () => {
6
+ it('mask', () => {
7
+ expect((0, logger_util_1.mask)(['pd'])).toEqual(['**']);
8
+ expect((0, logger_util_1.mask)(['password'])).toEqual(['p******d']);
9
+ expect((0, logger_util_1.mask)(['password', 123])).toEqual(['p******d', '1*3']);
10
+ expect((0, logger_util_1.mask)([{ password: 'password' }])).toEqual([{ password: 'p******d' }]);
11
+ expect((0, logger_util_1.mask)([{ password: 'password' }, 'sensitive'])).toEqual([{ password: 'p******d' }, 's*******e']);
12
+ expect((0, logger_util_1.mask)([{ password: 'password' }, 'not sensitive'], constants_1.SENSITIVE_PHRASES)).toEqual([
13
+ { password: 'p******d' },
14
+ 'not sensitive',
15
+ ]);
16
+ });
17
+ });
18
+ //# sourceMappingURL=logger.spec.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logger.spec.js","sourceRoot":"","sources":["../../../src/common/core/utils/logger.spec.ts"],"names":[],"mappings":";;AAAA,4CAAiD;AACjD,+CAAqC;AAErC,QAAQ,CAAC,2CAA2C,EAAE,GAAG,EAAE;IACzD,EAAE,CAAC,MAAM,EAAE,GAAG,EAAE;QACd,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;QACrC,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;QACjD,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,UAAU,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,UAAU,EAAE,KAAK,CAAC,CAAC,CAAC;QAC7D,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,CAAC,CAAC,CAAC;QAC7E,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,WAAW,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,WAAW,CAAC,CAAC,CAAC;QACvG,MAAM,CAAC,IAAA,kBAAI,EAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,EAAE,eAAe,CAAC,EAAE,6BAAiB,CAAC,CAAC,CAAC,OAAO,CAAC;YACnF,EAAE,QAAQ,EAAE,UAAU,EAAE;YACxB,eAAe;SAChB,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,4 +1,22 @@
1
1
  import log from 'debug';
2
+ /**
3
+ * The `mask` function takes an array of values and masks sensitive information by replacing characters
4
+ * with asterisks, while optionally allowing specific phrases to be excluded from masking.
5
+ *
6
+ * @param {any[]} args - The `args` parameter in the `mask` function is an array of values that you
7
+ * want to mask. These values can be of various types such as strings, numbers, or objects. The
8
+ * function will mask these values based on certain conditions and return an array of masked values.
9
+ *
10
+ * @param {RegExp[] | null} [phrases=null] - The `phrases` parameter in the `mask` function is an
11
+ * optional parameter that accepts an array of regular expressions. These regular expressions are used
12
+ * to determine which keys in an object should be masked.
13
+ *
14
+ * @returns The `mask` function returns an array of masked values based on the input arguments. The
15
+ * function masks strings by replacing characters with asterisks, leaving the first and last characters
16
+ * unchanged. For numbers, it converts them to strings and then masks them. For objects, it recursively
17
+ * masks the values based on the provided phrases (if any) that match the object keys.
18
+ */
19
+ export declare function mask(args: any[], phrases?: RegExp[] | null): any[];
2
20
  /**
3
21
  * The `logger` function in TypeScript creates a logging instance with a specified namespace and
4
22
  * prefix.
@@ -1,8 +1,60 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.logger = void 0;
4
+ exports.mask = mask;
4
5
  const naming_conventions_modeler_1 = require("naming-conventions-modeler");
5
6
  const debug_1 = require("debug");
7
+ const constants_1 = require("../constants");
8
+ /**
9
+ * The `mask` function takes an array of values and masks sensitive information by replacing characters
10
+ * with asterisks, while optionally allowing specific phrases to be excluded from masking.
11
+ *
12
+ * @param {any[]} args - The `args` parameter in the `mask` function is an array of values that you
13
+ * want to mask. These values can be of various types such as strings, numbers, or objects. The
14
+ * function will mask these values based on certain conditions and return an array of masked values.
15
+ *
16
+ * @param {RegExp[] | null} [phrases=null] - The `phrases` parameter in the `mask` function is an
17
+ * optional parameter that accepts an array of regular expressions. These regular expressions are used
18
+ * to determine which keys in an object should be masked.
19
+ *
20
+ * @returns The `mask` function returns an array of masked values based on the input arguments. The
21
+ * function masks strings by replacing characters with asterisks, leaving the first and last characters
22
+ * unchanged. For numbers, it converts them to strings and then masks them. For objects, it recursively
23
+ * masks the values based on the provided phrases (if any) that match the object keys.
24
+ */
25
+ function mask(args, phrases = null) {
26
+ if (!Array.isArray(args))
27
+ return [];
28
+ const fn = (value) => {
29
+ if (value.length <= 2)
30
+ return value.replace(/./g, '*');
31
+ return value[0] + value.slice(1, -1).replace(/./g, '*') + value[value.length - 1];
32
+ };
33
+ const result = [];
34
+ for (const arg of args) {
35
+ if (typeof arg === 'string' && !phrases)
36
+ result.push(fn(arg));
37
+ else if (typeof arg === 'number' && !phrases)
38
+ result.push(fn(String(arg)));
39
+ else if (typeof arg === 'object') {
40
+ if (Array.isArray(arg))
41
+ result.push(mask(arg, phrases));
42
+ else {
43
+ const obj = {};
44
+ for (const key in arg) {
45
+ if (phrases?.some((p) => p.test(key)))
46
+ obj[key] = mask([arg[key]])[0];
47
+ else
48
+ obj[key] = mask([arg[key]], phrases)[0];
49
+ }
50
+ result.push(obj);
51
+ }
52
+ }
53
+ else
54
+ result.push(arg);
55
+ }
56
+ return result;
57
+ }
6
58
  /**
7
59
  * The `logger` function in TypeScript creates a logging instance with a specified namespace and
8
60
  * prefix.
@@ -18,14 +70,17 @@ const debug_1 = require("debug");
18
70
  * Proxy to intercept property access on the `baseLogger` object and modify the behavior for functions,
19
71
  * specifically handling the 'extend' function differently.
20
72
  */
21
- const logger = (namespace, prefix = 'clt') => {
73
+ const logger = (namespace, prefix = process.env.DEBUG_NAMESPACE || process.env.NAMESPACE || 'clt') => {
22
74
  const baseLogger = (0, debug_1.default)([prefix, (0, naming_conventions_modeler_1.toKebabCase)(namespace)].join(':'));
75
+ function apply(target, thisArg, args) {
76
+ return target(args[0], ...mask(args.slice(1), [...constants_1.SENSITIVE_PHRASES, /(token|key)$/]));
77
+ }
23
78
  function get(target, prop, receiver) {
24
79
  const original = target[prop];
25
80
  if (typeof original === 'function') {
26
81
  return (...args) => {
27
82
  if (prop === 'extend') {
28
- return new Proxy(original.call(target, (0, naming_conventions_modeler_1.toKebabCase)(args[0])), { get });
83
+ return new Proxy(original.call(target, (0, naming_conventions_modeler_1.toKebabCase)(args[0])), { get, apply });
29
84
  }
30
85
  else
31
86
  return original.call(target, ...args);
@@ -34,7 +89,7 @@ const logger = (namespace, prefix = 'clt') => {
34
89
  // Default behavior for non-function properties
35
90
  return Reflect.get(target, prop, receiver);
36
91
  }
37
- return new Proxy(baseLogger, { get });
92
+ return new Proxy(baseLogger, { get, apply });
38
93
  };
39
94
  exports.logger = logger;
40
95
  //# sourceMappingURL=logger.util.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"logger.util.js","sourceRoot":"","sources":["../../../src/common/core/utils/logger.util.ts"],"names":[],"mappings":";;;AAAA,2EAAyD;AACzD,iCAAwB;AAExB;;;;;;;;;;;;;;GAcG;AACI,MAAM,MAAM,GAAG,CAAC,SAAiB,EAAE,MAAM,GAAG,KAAK,EAAgB,EAAE;IACxE,MAAM,UAAU,GAAG,IAAA,eAAG,EAAC,CAAC,MAAM,EAAE,IAAA,wCAAW,EAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;IAEnE,SAAS,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,QAAQ;QACjC,MAAM,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC;QAE9B,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE,CAAC;YACnC,OAAO,CAAC,GAAG,IAAW,EAAE,EAAE;gBACxB,IAAI,IAAI,KAAK,QAAQ,EAAE,CAAC;oBACtB,OAAO,IAAI,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,IAAA,wCAAW,EAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE,GAAG,EAAE,CAAC,CAAC;gBACzE,CAAC;;oBAAM,OAA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AAC;IAEnE,SAAS,KAAK,CAAC,MAAoB,EAAE,OAAY,EAAE,IAAW;QAC5D,OAAO,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,6BAAiB,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;IACzF,CAAC;IAED,SAAS,GAAG,CAAC,MAAoB,EAAE,IAAqB,EAAE,QAAa;QACrE,MAAM,QAAQ,GAAQ,MAAM,CAAC,IAAI,CAAC,CAAC;QAEnC,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE,CAAC;YACnC,OAAO,CAAC,GAAG,IAAW,EAAO,EAAE;gBAC7B,IAAI,IAAI,KAAK,QAAQ,EAAE,CAAC;oBACtB,OAAO,IAAI,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,IAAA,wCAAW,EAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC;gBAChF,CAAC;;oBAAM,OAAO,QAAQ,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC,CAAC;YAC/C,CAAC,CAAC;QACJ,CAAC;QAED,+CAA+C;QAC/C,OAAO,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,IAAI,EAAE,QAAQ,CAAC,CAAC;IAC7C,CAAC;IAED,OAAO,IAAI,KAAK,CAAC,UAAU,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC;AAC/C,CAAC,CAAC;AAvBW,QAAA,MAAM,UAuBjB"}
@@ -18,7 +18,7 @@ const transform_util_1 = require("./transform.util");
18
18
  * @returns The `get` function returns a value of type `T` or `undefined`.
19
19
  */
20
20
  const get = (key, meta, defaultValue) => {
21
- if (!meta || Array.isArray(meta))
21
+ if (meta === null || Array.isArray(meta) || typeof meta !== 'object')
22
22
  return defaultValue;
23
23
  else {
24
24
  const value = key.startsWith('x-') ? (0, transform_util_1.toJSON)(meta[key] || meta[key.replace(/^x-/, '')]) : (0, transform_util_1.toJSON)(meta[key] || meta['x-' + key]);
@@ -1 +1 @@
1
- {"version":3,"file":"meta.util.js","sourceRoot":"","sources":["../../../src/common/core/utils/meta.util.ts"],"names":[],"mappings":";;;AAAA,qDAAoD;AAGpD;;;;;;;;;;;;;;GAcG;AACI,MAAM,GAAG,GAAG,CAAU,GAAY,EAAE,IAAe,EAAE,YAAgB,EAAK,EAAE;IACjF,IAAI,CAAC,IAAI,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;QAAE,OAAO,YAAiB,CAAC;SACtD,CAAC;QACJ,MAAM,KAAK,GAAG,GAAG,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAA,uBAAM,EAAC,IAAI,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAA,uBAAM,EAAC,IAAI,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC,CAAC,CAAC;QAC/H,OAAO,KAAK,IAAI,YAAY,CAAC;IAC/B,CAAC;AACH,CAAC,CAAC;AANW,QAAA,GAAG,OAMd;AAEF;;;;;;;;;;;;;GAaG;AACI,MAAM,GAAG,GAAG,CAAU,IAAc,EAAE,GAAY,EAAE,GAAM,EAAY,EAAE;IAC7E,IAAI,GAAG,CAAC,UAAU,CAAC,IAAI,CAAC;QAAE,IAAI,CAAC,GAAG,CAAC,GAAG,OAAO,GAAG,KAAK,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAA,yBAAQ,EAAC,GAAG,CAAC,CAAC;;QAC/E,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC,GAAG,OAAO,GAAG,KAAK,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC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,CAAC,GAAG,CAAC,CAAC,CAAC,IAAA,yBAAQ,EAAC,GAAG,CAAC,CAAC;IACtE,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AAJW,QAAA,GAAG,OAId"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wenex/sdk",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "Wenex SDK",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -20,11 +20,11 @@
20
20
  },
21
21
  "homepage": "https://github.com/wenex-org/platform-sdk#readme",
22
22
  "scripts": {
23
- "build": "npm run clean && tsc",
23
+ "build": "tsc -p ./tsconfig.json",
24
+ "prebuild": "rimraf tsconfig.tsbuildinfo index.* common services",
24
25
  "preinstall": "husky",
25
26
  "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
26
27
  "lint": "eslint \"{src,test}/**/*.ts\" --quiet --fix",
27
- "clean": "rimraf tsconfig.tsbuildinfo index.* common services",
28
28
  "test": "jest",
29
29
  "test:cov": "jest --coverage && npm run make-coverage-badge",
30
30
  "doc": "npx typedoc --entryPointStrategy expand --out docs src/",