nofax 0.2.11 → 0.2.13
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/package.json +1 -1
- package/src/mcp-server.mjs +1 -1
- package/src/protocol.mjs +9 -1
package/package.json
CHANGED
package/src/mcp-server.mjs
CHANGED
|
@@ -74,7 +74,7 @@ const LIST_PENDING_OUTPUT_SCHEMA = z.object({
|
|
|
74
74
|
|
|
75
75
|
export function buildMcpServer({ handlers = createMcpToolHandlers() } = {}) {
|
|
76
76
|
const server = new McpServer(
|
|
77
|
-
{ name: 'nofax', version: '0.2.
|
|
77
|
+
{ name: 'nofax', version: '0.2.13' },
|
|
78
78
|
{ instructions: SERVER_INSTRUCTIONS }
|
|
79
79
|
);
|
|
80
80
|
|
package/src/protocol.mjs
CHANGED
|
@@ -33,7 +33,12 @@ function redactSecretText(value) {
|
|
|
33
33
|
);
|
|
34
34
|
|
|
35
35
|
redacted = redacted.replace(
|
|
36
|
-
/(
|
|
36
|
+
/(["'])((?:proxy[-_])?authorization)(?!\s*[:=]\s*(?:bearer|basic)\b)(\s*[:=]\s*)((?:\\.|(?!\1).)*)\1/gi,
|
|
37
|
+
'$1$2$3[REDACTED]$1'
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
redacted = redacted.replace(
|
|
41
|
+
/(^|[\r\n])([ \t]*)((?:proxy[-_])?authorization)(\s*[:=]\s*)[^\r\n]*/gim,
|
|
37
42
|
'$1$2$3$4[REDACTED]'
|
|
38
43
|
);
|
|
39
44
|
|
|
@@ -125,6 +130,9 @@ export function redactAndBound(value, options = {}) {
|
|
|
125
130
|
seen.add(value);
|
|
126
131
|
|
|
127
132
|
if (Array.isArray(value)) {
|
|
133
|
+
if (value.length === 2 && typeof value[0] === 'string' && isSecretKey(value[0])) {
|
|
134
|
+
return [boundString(value[0]), '[REDACTED]'];
|
|
135
|
+
}
|
|
128
136
|
return value.slice(0, MAX_ARRAY).map((item) => redactAndBound(item, { seen, depth: depth + 1 }));
|
|
129
137
|
}
|
|
130
138
|
|