@bitkyc08/opencodex 2.1.11 → 2.5.0

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/README.ko.md CHANGED
@@ -171,7 +171,11 @@ npm uninstall -g @bitkyc08/opencodex # 또는: bun remove -g @bitkyc08/opencod
171
171
 
172
172
  ## 설정
173
173
 
174
- 설정 파일은 `~/.opencodex/config.json`에 저장됩니다. 최소 설정 예시:
174
+ 설정 파일은 `~/.opencodex/config.json`에 저장됩니다. 파일이 깨진 경우(잘못된 JSON 등)
175
+ opencodex는 `config.json.invalid-<timestamp>`로 백업하고 경고를 출력한 뒤 기본값으로 시작합니다.
176
+ 원본 파일이 조용히 사라지는 일은 없습니다.
177
+
178
+ 최소 설정 예시:
175
179
 
176
180
  ```json
177
181
  {
@@ -209,6 +213,25 @@ npm uninstall -g @bitkyc08/opencodex # 또는: bun remove -g @bitkyc08/opencod
209
213
 
210
214
  WebSocket 전송은 기본적으로 꺼져 있습니다. Codex가 HTTP/SSE 대신 Responses WebSocket 경로를 사용하게 하려면 `"websockets": true`를 설정하세요.
211
215
 
216
+ ### 원격 접근
217
+
218
+ 기본적으로 opencodex는 `127.0.0.1`(루프백)에 바인딩되며 별도 인증이 필요 없습니다.
219
+ `"hostname": "0.0.0.0"`으로 LAN에 노출할 경우, opencodex는 관리 API(`/api/*`)와 데이터 플레인(`/v1/responses`) 모두에 bearer 토큰을 요구합니다:
220
+
221
+ ```bash
222
+ export OPENCODEX_API_AUTH_TOKEN="your-secret-token"
223
+ ocx start
224
+ ```
225
+
226
+ 비루프백 바인딩 시 이 환경 변수가 없으면 프록시 시작이 거부됩니다.
227
+ 클라이언트(스크립트, 원격 머신)는 모든 요청에 토큰을 포함해야 합니다:
228
+
229
+ ```
230
+ x-opencodex-api-key: your-secret-token
231
+ ```
232
+
233
+ 토큰은 타이밍 공격 방지를 위해 상수 시간으로 비교됩니다.
234
+
212
235
  모든 필드에 대한 자세한 내용은 **[설정 레퍼런스](https://lidge-jun.github.io/opencodex/ko/reference/configuration/)** 를 참고하세요.
213
236
 
214
237
  ## 문서
package/README.md CHANGED
@@ -232,7 +232,11 @@ native Codex config/catalog/history, and deletes `~/.opencodex`.
232
232
 
233
233
  ## Configuration
234
234
 
235
- Config lives at `~/.opencodex/config.json`. Here's a typical multi-provider setup:
235
+ Config lives at `~/.opencodex/config.json`. If the file cannot be parsed (e.g. truncated or
236
+ manually broken JSON), opencodex backs it up to `config.json.invalid-<timestamp>`, prints a warning,
237
+ and falls back to defaults — so your original file is never silently lost.
238
+
239
+ Here's a typical multi-provider setup:
236
240
 
237
241
  ```json
238
242
  {
@@ -288,6 +292,26 @@ Local models work too. Point opencodex at any OpenAI-compatible server running o
288
292
 
289
293
  WebSocket transport is off by default. Set `"websockets": true` only if you want Codex to advertise and use the Responses WebSocket path instead of HTTP/SSE.
290
294
 
295
+ ### Remote access
296
+
297
+ By default opencodex binds to `127.0.0.1` (loopback) and requires no extra authentication.
298
+ If you set `"hostname": "0.0.0.0"` to expose the proxy on the LAN, opencodex requires a bearer token
299
+ to protect both the management API (`/api/*`) and the data-plane (`/v1/responses`):
300
+
301
+ ```bash
302
+ export OPENCODEX_API_AUTH_TOKEN="your-secret-token"
303
+ ocx start
304
+ ```
305
+
306
+ The proxy refuses to start without this variable when binding beyond loopback.
307
+ Clients (scripts, remote machines) must include the token in every request:
308
+
309
+ ```
310
+ x-opencodex-api-key: your-secret-token
311
+ ```
312
+
313
+ The token is compared in constant time to prevent timing attacks.
314
+
291
315
  opencodex leaves existing Codex resume history untouched by default. This avoids changing Codex's
292
316
  local thread index just because the proxy started, but Codex App may hide old OpenAI-backed project
293
317
  threads and opencodex-created `exec` threads while `opencodex` is the active provider. If you want