nofax 0.2.0 → 0.2.1
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/LICENSE +21 -21
- package/README.md +349 -351
- package/SECURITY.md +144 -144
- package/bin/nofax.mjs +4 -4
- package/package.json +56 -56
- package/src/adapters/claude.mjs +47 -47
- package/src/adapters/codex.mjs +47 -47
- package/src/adapters/gemini.mjs +57 -57
- package/src/cli.mjs +191 -191
- package/src/config.mjs +91 -91
- package/src/index.mjs +8 -8
- package/src/mcp-server.mjs +141 -141
- package/src/mcp-tools.mjs +240 -240
- package/src/ntfy.mjs +259 -259
- package/src/protocol.mjs +108 -108
- package/src/requests.mjs +120 -120
package/README.md
CHANGED
|
@@ -1,351 +1,349 @@
|
|
|
1
|
-
# Nofax
|
|
2
|
-
|
|
3
|
-
[](https://github.com/AKzar1el/nofax/actions/workflows/ci.yml)
|
|
4
|
-
[](LICENSE)
|
|
5
|
-
[](package.json)
|
|
6
|
-
[](https://modelcontextprotocol.io/)
|
|
7
|
-
|
|
8
|
-
**Human-in-the-loop approvals and notifications for AI coding agents, without running a Nofax SaaS.**
|
|
9
|
-
|
|
10
|
-
Nofax is a small open-source bridge between an agent and a human. Local mode can pause an AI workflow, notify your phone, and return an explicit decision. An optional self-deployed Cloudflare Worker exposes a deliberately narrower remote MCP surface for one-way notifications and safe request inspection.
|
|
11
|
-
|
|
12
|
-
No Nofax account. No paid model API. No inbound port on your machine. MIT licensed.
|
|
13
|
-
|
|
14
|
-
> **Current status:** local Nofax is `0.2.
|
|
15
|
-
|
|
16
|
-
## Why Nofax
|
|
17
|
-
|
|
18
|
-
Agent workflows increasingly need a clean answer to one question: **when automation reaches a human decision boundary, how does it ask without pretending that silence means approval?**
|
|
19
|
-
|
|
20
|
-
Nofax keeps that boundary explicit:
|
|
21
|
-
|
|
22
|
-
- pending is never approval;
|
|
23
|
-
- timeout and transport failure fail closed;
|
|
24
|
-
- the first accepted terminal response wins;
|
|
25
|
-
- agent-specific hook schemas stay isolated in adapters;
|
|
26
|
-
- remote access is intentionally narrower than local access;
|
|
27
|
-
- Nofax does not grant authority the calling agent did not already have.
|
|
28
|
-
|
|
29
|
-
## Two operating modes
|
|
30
|
-
|
|
31
|
-
| Capability | Local Nofax `0.2` | Remote Worker `0.3` |
|
|
32
|
-
| --- | --- | --- |
|
|
33
|
-
| Transport | stdio / CLI hooks | MCP Streamable HTTP |
|
|
34
|
-
| One-way notification | Yes | Yes |
|
|
35
|
-
| Allow / Deny | Yes | No |
|
|
36
|
-
| Explicit choices | Yes | No |
|
|
37
|
-
| Free-text refinement | Yes | No |
|
|
38
|
-
| Wait for human response | Yes | No |
|
|
39
|
-
| Read request metadata | Yes | Yes |
|
|
40
|
-
| Durable state | Local files | Existing SQLite Durable Object rows |
|
|
41
|
-
| Hosted by Nofax | No | No — self-deployed Worker |
|
|
42
|
-
| Remote authentication | Local process boundary | Private bearer key |
|
|
43
|
-
|
|
44
|
-
The remote Worker is **not** a hosted remote-approval service. It can send an informational notification and inspect existing request state, but it has no approval callback, choice, refinement, wait, webhook, or arbitrary remote-write endpoint.
|
|
45
|
-
|
|
46
|
-
## Quick start
|
|
47
|
-
|
|
48
|
-
### 1. Install
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
```
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
nofax
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
```
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
- `
|
|
105
|
-
- `
|
|
106
|
-
- `
|
|
107
|
-
- `
|
|
108
|
-
- `
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
"
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
"
|
|
176
|
-
"
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
"
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
|
214
|
-
+-->
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
- `
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
npx wrangler
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
```
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
-
|
|
269
|
-
-
|
|
270
|
-
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
-
|
|
277
|
-
-
|
|
278
|
-
- remote
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
"
|
|
291
|
-
"
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
```
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
```
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
npm
|
|
315
|
-
npm run
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
- [`
|
|
333
|
-
- [`
|
|
334
|
-
- [`
|
|
335
|
-
|
|
336
|
-
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
-
|
|
343
|
-
-
|
|
344
|
-
-
|
|
345
|
-
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
MIT © Tomi Šeregi. See [`LICENSE`](LICENSE).
|
|
1
|
+
# Nofax
|
|
2
|
+
|
|
3
|
+
[](https://github.com/AKzar1el/nofax/actions/workflows/ci.yml)
|
|
4
|
+
[](LICENSE)
|
|
5
|
+
[](package.json)
|
|
6
|
+
[](https://modelcontextprotocol.io/)
|
|
7
|
+
|
|
8
|
+
**Human-in-the-loop approvals and notifications for AI coding agents, without running a Nofax SaaS.**
|
|
9
|
+
|
|
10
|
+
Nofax is a small open-source bridge between an agent and a human. Local mode can pause an AI workflow, notify your phone, and return an explicit decision. An optional self-deployed Cloudflare Worker exposes a deliberately narrower remote MCP surface for one-way notifications and safe request inspection.
|
|
11
|
+
|
|
12
|
+
No Nofax account. No paid model API. No inbound port on your machine. MIT licensed.
|
|
13
|
+
|
|
14
|
+
> **Current status:** local Nofax is `0.2.1`. The optional Cloudflare Worker is the upcoming `0.3.0` remote surface and is developed alongside the local package.
|
|
15
|
+
|
|
16
|
+
## Why Nofax
|
|
17
|
+
|
|
18
|
+
Agent workflows increasingly need a clean answer to one question: **when automation reaches a human decision boundary, how does it ask without pretending that silence means approval?**
|
|
19
|
+
|
|
20
|
+
Nofax keeps that boundary explicit:
|
|
21
|
+
|
|
22
|
+
- pending is never approval;
|
|
23
|
+
- timeout and transport failure fail closed;
|
|
24
|
+
- the first accepted terminal response wins;
|
|
25
|
+
- agent-specific hook schemas stay isolated in adapters;
|
|
26
|
+
- remote access is intentionally narrower than local access;
|
|
27
|
+
- Nofax does not grant authority the calling agent did not already have.
|
|
28
|
+
|
|
29
|
+
## Two operating modes
|
|
30
|
+
|
|
31
|
+
| Capability | Local Nofax `0.2` | Remote Worker `0.3` |
|
|
32
|
+
| --- | --- | --- |
|
|
33
|
+
| Transport | stdio / CLI hooks | MCP Streamable HTTP |
|
|
34
|
+
| One-way notification | Yes | Yes |
|
|
35
|
+
| Allow / Deny | Yes | No |
|
|
36
|
+
| Explicit choices | Yes | No |
|
|
37
|
+
| Free-text refinement | Yes | No |
|
|
38
|
+
| Wait for human response | Yes | No |
|
|
39
|
+
| Read request metadata | Yes | Yes |
|
|
40
|
+
| Durable state | Local files | Existing SQLite Durable Object rows |
|
|
41
|
+
| Hosted by Nofax | No | No — self-deployed Worker |
|
|
42
|
+
| Remote authentication | Local process boundary | Private bearer key |
|
|
43
|
+
|
|
44
|
+
The remote Worker is **not** a hosted remote-approval service. It can send an informational notification and inspect existing request state, but it has no approval callback, choice, refinement, wait, webhook, or arbitrary remote-write endpoint.
|
|
45
|
+
|
|
46
|
+
## Quick start
|
|
47
|
+
|
|
48
|
+
### 1. Install
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
npm install -g nofax
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Requires Node.js 20 or newer.
|
|
55
|
+
|
|
56
|
+
### 2. Initialize
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
nofax init
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Nofax creates `~/.nofax/config.json` and generates a high-entropy notification topic. With the default transport, subscribe to the displayed topic in the ntfy mobile app.
|
|
63
|
+
|
|
64
|
+
### 3. Test
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
nofax test
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### 4. Use it
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
nofax notify --title "Build finished" "All tests passed"
|
|
74
|
+
nofax approve --title "Deploy?" "Release 1.4.0 is ready"
|
|
75
|
+
nofax refine --title "Refine draft" "Tell me what to change"
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
An approval resolves to stable terminal JSON:
|
|
79
|
+
|
|
80
|
+
```json
|
|
81
|
+
{"decision":"allow"}
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
or:
|
|
85
|
+
|
|
86
|
+
```json
|
|
87
|
+
{"decision":"deny"}
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
If the request is still pending, times out, disconnects, or hits a transport error, Nofax never converts that condition into approval.
|
|
91
|
+
|
|
92
|
+
## MCP
|
|
93
|
+
|
|
94
|
+
Start the local stdio MCP server:
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
nofax mcp
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Local MCP exposes:
|
|
101
|
+
|
|
102
|
+
- `nofax_notify`
|
|
103
|
+
- `nofax_request_approval`
|
|
104
|
+
- `nofax_request_choice`
|
|
105
|
+
- `nofax_request_refinement`
|
|
106
|
+
- `nofax_wait_for_response`
|
|
107
|
+
- `nofax_get_request`
|
|
108
|
+
- `nofax_list_pending`
|
|
109
|
+
|
|
110
|
+
Interactive requests return a durable request ID. `nofax_wait_for_response` performs a bounded wait; callers must repeat the wait while the request remains pending rather than infer approval.
|
|
111
|
+
|
|
112
|
+
## Agent integrations
|
|
113
|
+
|
|
114
|
+
### Claude Code
|
|
115
|
+
|
|
116
|
+
Use Nofax as a local `PermissionRequest` hook in `~/.claude/settings.json`:
|
|
117
|
+
|
|
118
|
+
```json
|
|
119
|
+
{
|
|
120
|
+
"hooks": {
|
|
121
|
+
"PermissionRequest": [
|
|
122
|
+
{
|
|
123
|
+
"matcher": ".*",
|
|
124
|
+
"hooks": [
|
|
125
|
+
{
|
|
126
|
+
"type": "command",
|
|
127
|
+
"command": "nofax hook claude"
|
|
128
|
+
}
|
|
129
|
+
]
|
|
130
|
+
}
|
|
131
|
+
]
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### Codex
|
|
137
|
+
|
|
138
|
+
Codex hooks are enabled by default. Configure `~/.codex/hooks.json`:
|
|
139
|
+
|
|
140
|
+
```json
|
|
141
|
+
{
|
|
142
|
+
"hooks": {
|
|
143
|
+
"PermissionRequest": [
|
|
144
|
+
{
|
|
145
|
+
"matcher": ".*",
|
|
146
|
+
"hooks": [
|
|
147
|
+
{
|
|
148
|
+
"type": "command",
|
|
149
|
+
"command": "nofax hook codex",
|
|
150
|
+
"statusMessage": "Waiting for Nofax approval"
|
|
151
|
+
}
|
|
152
|
+
]
|
|
153
|
+
}
|
|
154
|
+
]
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
Restart Codex, run `/hooks`, and review/trust the exact Nofax hook definition before relying on it. Codex skips non-managed hooks until they are trusted, and a changed hook definition must be reviewed again. If an administrator or local policy has explicitly disabled hooks, re-enable them with `[features] hooks = true` in `~/.codex/config.toml`.
|
|
160
|
+
|
|
161
|
+
### Gemini CLI
|
|
162
|
+
|
|
163
|
+
Current Gemini CLI builds expose a synchronous `BeforeTool` hook that can allow or deny a tool call. Route selected tools through Nofax in `~/.gemini/settings.json`:
|
|
164
|
+
|
|
165
|
+
```json
|
|
166
|
+
{
|
|
167
|
+
"hooks": {
|
|
168
|
+
"BeforeTool": [
|
|
169
|
+
{
|
|
170
|
+
"matcher": "run_shell_command|write_file|replace",
|
|
171
|
+
"hooks": [
|
|
172
|
+
{
|
|
173
|
+
"name": "nofax-approval",
|
|
174
|
+
"type": "command",
|
|
175
|
+
"command": "nofax hook gemini",
|
|
176
|
+
"timeout": 305000
|
|
177
|
+
}
|
|
178
|
+
]
|
|
179
|
+
}
|
|
180
|
+
],
|
|
181
|
+
"Notification": [
|
|
182
|
+
{
|
|
183
|
+
"matcher": "ToolPermission",
|
|
184
|
+
"hooks": [
|
|
185
|
+
{
|
|
186
|
+
"name": "nofax-notification",
|
|
187
|
+
"type": "command",
|
|
188
|
+
"command": "nofax hook gemini"
|
|
189
|
+
}
|
|
190
|
+
]
|
|
191
|
+
}
|
|
192
|
+
]
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
`BeforeTool` waits for an explicit Nofax Allow/Deny result. A Nofax timeout or transport failure emits valid no-decision JSON and leaves Gemini CLI's own policy/confirmation flow in control rather than converting failure into approval. The `Notification` hook remains advisory and is forwarded only as a phone notification.
|
|
198
|
+
|
|
199
|
+
Adjust the matcher to the tools you want Nofax to gate. Keep the hook timeout longer than Nofax's configured approval timeout (`timeoutSeconds`, 300 seconds by default).
|
|
200
|
+
|
|
201
|
+
## Optional remote Cloudflare Worker
|
|
202
|
+
|
|
203
|
+
The `worker/` package provides a private, self-deployed MCP endpoint:
|
|
204
|
+
|
|
205
|
+
```text
|
|
206
|
+
remote MCP client
|
|
207
|
+
|
|
|
208
|
+
| authenticated Streamable HTTP
|
|
209
|
+
v
|
|
210
|
+
Cloudflare Worker
|
|
211
|
+
|
|
|
212
|
+
+--> nofax_notify ------> ntfy ------> phone
|
|
213
|
+
|
|
|
214
|
+
+--> SQLite Durable Object
|
|
215
|
+
|
|
|
216
|
+
+--> get request metadata
|
|
217
|
+
+--> list pending requests
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
It exposes exactly three tools:
|
|
221
|
+
|
|
222
|
+
- `nofax_notify` — one-way notification only;
|
|
223
|
+
- `nofax_get_request` — read one safe request projection;
|
|
224
|
+
- `nofax_list_pending` — read unresolved, unexpired request projections.
|
|
225
|
+
|
|
226
|
+
Deploy from `worker/`:
|
|
227
|
+
|
|
228
|
+
```bash
|
|
229
|
+
npm ci
|
|
230
|
+
npx wrangler login
|
|
231
|
+
npx wrangler secret put NOFAX_REMOTE_KEY
|
|
232
|
+
npx wrangler secret put NTFY_TOPIC
|
|
233
|
+
npm run check
|
|
234
|
+
npm run deploy
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
Preferred MCP connection:
|
|
238
|
+
|
|
239
|
+
```text
|
|
240
|
+
https://<worker>.workers.dev/mcp
|
|
241
|
+
Authorization: Bearer <NOFAX_REMOTE_KEY>
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
Clients that cannot attach a static authorization header can use the compatibility capability path:
|
|
245
|
+
|
|
246
|
+
```text
|
|
247
|
+
https://<worker>.workers.dev/mcp/<NOFAX_REMOTE_KEY>
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
Treat the complete capability URL like a password.
|
|
251
|
+
|
|
252
|
+
See [`docs/remote-mcp.md`](docs/remote-mcp.md) for deployment, threat boundaries, and qualification details.
|
|
253
|
+
|
|
254
|
+
### Important: public ntfy + serverless egress
|
|
255
|
+
|
|
256
|
+
The default public `ntfy.sh` service applies publisher quotas. Serverless platforms such as Cloudflare Workers may use shared outbound IP space, so a Worker can receive an ntfy `42908` daily-quota response even when that individual Worker has sent very little traffic. That limit is imposed by ntfy, not by the Cloudflare Workers request quota.
|
|
257
|
+
|
|
258
|
+
For reliability-sensitive deployments, use a notification provider whose quota is tied to your own authenticated account/identity, or operate a trusted self-hosted transport. Do not build a critical workflow around anonymous public-topic quota assumptions.
|
|
259
|
+
|
|
260
|
+
## Security model
|
|
261
|
+
|
|
262
|
+
Nofax is a transport and human-interaction component, **not an authorization policy engine**.
|
|
263
|
+
|
|
264
|
+
Local mode:
|
|
265
|
+
|
|
266
|
+
- pending, timeout, disconnect, malformed state, and network failure never mean approval;
|
|
267
|
+
- the first valid terminal response wins;
|
|
268
|
+
- notification topics and one-time response topics are capabilities;
|
|
269
|
+
- public ntfy is not end-to-end encrypted from the provider;
|
|
270
|
+
- redaction is best-effort and cannot reliably identify secrets embedded in arbitrary free-form text.
|
|
271
|
+
|
|
272
|
+
Remote mode:
|
|
273
|
+
|
|
274
|
+
- only explicit `nofax_notify` performs an external messaging side effect;
|
|
275
|
+
- request-inspection operations are read-only and do not perform hidden cleanup writes;
|
|
276
|
+
- remote approval, callback, webhook, refinement, choice, and wait surfaces are absent;
|
|
277
|
+
- `NOFAX_REMOTE_KEY` is a bearer credential;
|
|
278
|
+
- remote projections omit callback capabilities, prompt/message text, and internal allowed-decision lists.
|
|
279
|
+
|
|
280
|
+
Read [`SECURITY.md`](SECURITY.md) before using Nofax with sensitive information.
|
|
281
|
+
|
|
282
|
+
## Configuration
|
|
283
|
+
|
|
284
|
+
Default local config lives at `~/.nofax/config.json`:
|
|
285
|
+
|
|
286
|
+
```json
|
|
287
|
+
{
|
|
288
|
+
"version": 1,
|
|
289
|
+
"server": "https://ntfy.sh",
|
|
290
|
+
"topic": "nofax_<random>",
|
|
291
|
+
"timeoutSeconds": 300
|
|
292
|
+
}
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
Override the home directory with `NOFAX_HOME`:
|
|
296
|
+
|
|
297
|
+
```bash
|
|
298
|
+
NOFAX_HOME=/path/to/nofax-home nofax config
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
Use another ntfy-compatible server with:
|
|
302
|
+
|
|
303
|
+
```bash
|
|
304
|
+
nofax init --server https://ntfy.example.com --force
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
## Development
|
|
308
|
+
|
|
309
|
+
Local package:
|
|
310
|
+
|
|
311
|
+
```bash
|
|
312
|
+
npm ci
|
|
313
|
+
npm run check
|
|
314
|
+
npm test
|
|
315
|
+
npm pack --dry-run
|
|
316
|
+
```
|
|
317
|
+
|
|
318
|
+
Remote Worker:
|
|
319
|
+
|
|
320
|
+
```bash
|
|
321
|
+
cd worker
|
|
322
|
+
npm ci
|
|
323
|
+
npm run check
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
CI qualifies Node.js 20, 22, and 24 for the local package. The Worker gate runs TypeScript, Vitest, a production-dependency audit, and a Wrangler deployment dry-run.
|
|
327
|
+
|
|
328
|
+
## Project docs
|
|
329
|
+
|
|
330
|
+
- [`docs/architecture.md`](docs/architecture.md) — trust boundaries and data flow
|
|
331
|
+
- [`docs/remote-mcp.md`](docs/remote-mcp.md) — remote Worker deployment and qualification
|
|
332
|
+
- [`SECURITY.md`](SECURITY.md) — security assumptions and vulnerability reporting
|
|
333
|
+
- [`CONTRIBUTING.md`](CONTRIBUTING.md) — contribution and test expectations
|
|
334
|
+
- [`CHANGELOG.md`](CHANGELOG.md) — release history
|
|
335
|
+
|
|
336
|
+
## Non-goals
|
|
337
|
+
|
|
338
|
+
Nofax deliberately does not provide:
|
|
339
|
+
|
|
340
|
+
- a Nofax-operated approval SaaS;
|
|
341
|
+
- a paid model API dependency;
|
|
342
|
+
- persistent `always approve` policy;
|
|
343
|
+
- an arbitrary remote shell endpoint;
|
|
344
|
+
- a public multi-user Worker behind one shared deployment key;
|
|
345
|
+
- a claim that MCP annotations themselves are a security boundary.
|
|
346
|
+
|
|
347
|
+
## License
|
|
348
|
+
|
|
349
|
+
MIT © Tomi Šeregi. See [`LICENSE`](LICENSE).
|