nofax 0.2.25 → 0.2.26
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 +11 -0
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.26' },
|
|
78
78
|
{ instructions: SERVER_INSTRUCTIONS }
|
|
79
79
|
);
|
|
80
80
|
|
package/src/protocol.mjs
CHANGED
|
@@ -79,6 +79,16 @@ function redactSecretText(value) {
|
|
|
79
79
|
'$1$2$3$4[REDACTED]'
|
|
80
80
|
);
|
|
81
81
|
|
|
82
|
+
redacted = redacted.replace(
|
|
83
|
+
/(^|[\r\n]|[({\[,:;])([ \t]*)(["'])((?:proxy[-_])?authorization)\3(\s*[:=]\s*)[^}\])\r\n]*(?=[}\])]|$)/gim,
|
|
84
|
+
'$1$2$3$4$3$5[REDACTED]'
|
|
85
|
+
);
|
|
86
|
+
|
|
87
|
+
redacted = redacted.replace(
|
|
88
|
+
/([({\[,:;][ \t]*)((?:proxy[-_])?authorization)(\s*[:=]\s*)(?!\[REDACTED\]|(?:bearer|basic)\b)[^}\])\r\n]*(?=[}\])]|$)/gi,
|
|
89
|
+
'$1$2$3[REDACTED]'
|
|
90
|
+
);
|
|
91
|
+
|
|
82
92
|
redacted = redacted.replace(
|
|
83
93
|
/([^ \t\r\n=][ \t]+|=)((?:proxy[-_])?authorization)(\s*[:=]\s*)(?!\[REDACTED\]|(?:bearer|basic)\b)[^\r\n]*/gi,
|
|
84
94
|
'$1$2$3[REDACTED]'
|
|
@@ -119,6 +129,7 @@ function redactSecretText(value) {
|
|
|
119
129
|
/([A-Za-z][A-Za-z0-9_-]{0,63})(\s*[:=]\s*)([^\s"'`,;&]+)/g,
|
|
120
130
|
(match, key, separator, rawValue) => {
|
|
121
131
|
if (!isSecretKey(key)) return match;
|
|
132
|
+
if (/^\[REDACTED\][}\])]*$/.test(rawValue)) return match;
|
|
122
133
|
if (/authorization$/i.test(normalizeSecretKeyName(key)) && /^(?:bearer|basic)$/i.test(rawValue)) return match;
|
|
123
134
|
return `${key}${separator}[REDACTED]`;
|
|
124
135
|
}
|