Skip to content

Commit 1e58f11

Browse files
committed
chore(deps): combine dependabot version bumps
1 parent 03dc203 commit 1e58f11

9 files changed

Lines changed: 202 additions & 198 deletions

File tree

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24.14.1
1+
v24.15.0

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ Configure scheduler intervals, SSH timeouts, password settings, and other applic
110110
111111
### Prerequisites
112112

113-
- Node.js 24.14.1 installed
113+
- Node.js 24.15.0 installed
114114
- pnpm 10.33.0 available via Corepack or a global install
115115
- SSH access to at least one Linux server
116116

docker/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM node:24.14.1-trixie-slim AS base
1+
FROM node:24.15.0-trixie-slim AS base
22
WORKDIR /app
33
RUN apt-get update \
44
&& apt-get install -y --no-install-recommends --only-upgrade libc6 libc-bin \

package.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"type": "module",
55
"packageManager": "pnpm@10.33.0",
66
"engines": {
7-
"node": "24.14.1"
7+
"node": "24.15.0"
88
},
99
"scripts": {
1010
"dev": "APP_VERSION=dev-$(date -u +'%Y%m%d%H%M'); VITE_APP_VERSION=\"$APP_VERSION\" LUDASH_APP_VERSION=\"$APP_VERSION\" pnpm run dev:server & VITE_APP_VERSION=\"$APP_VERSION\" LUDASH_APP_VERSION=\"$APP_VERSION\" pnpm run dev:client",
@@ -16,8 +16,7 @@
1616
"check": "tsc --noEmit"
1717
},
1818
"dependencies": {
19-
"@hono/node-server": "1.19.14",
20-
"@hono/node-ws": "1.3.0",
19+
"@hono/node-server": "2.0.0",
2120
"@simplewebauthn/server": "^13.3.0",
2221
"@types/sortablejs": "^1.15.9",
2322
"bcryptjs": "3.0.3",
@@ -31,7 +30,8 @@
3130
"nodemailer": "^8.0.2",
3231
"openid-client": "^6.3.0",
3332
"sortablejs": "^1.15.7",
34-
"ssh2": "^1.16.0"
33+
"ssh2": "^1.16.0",
34+
"ws": "^8.20.0"
3535
},
3636
"devDependencies": {
3737
"@tailwindcss/vite": "^4.2.2",
@@ -42,6 +42,7 @@
4242
"@types/react": "^19.0.0",
4343
"@types/react-dom": "^19.0.0",
4444
"@types/ssh2": "^1.15.0",
45+
"@types/ws": "^8.18.1",
4546
"@vitejs/plugin-react": "^6.0.1",
4647
"react": "^19.0.0",
4748
"react-dom": "^19.0.0",
@@ -50,7 +51,7 @@
5051
"tsup": "8.5.1",
5152
"tsx": "4.21.0",
5253
"typescript": "^6.0.2",
53-
"vite": "8.0.8",
54-
"vitest": "4.1.4"
54+
"vite": "8.0.10",
55+
"vitest": "4.1.5"
5556
}
5657
}

pnpm-lock.yaml

Lines changed: 178 additions & 182 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

run.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ fi
157157
# Check for Node.js and pnpm
158158
if ! command -v node &> /dev/null; then
159159
log "Error: 'node' is not installed."
160-
log "Please install Node.js 24.14.1 to run this application locally."
160+
log "Please install Node.js 24.15.0 to run this application locally."
161161
log "Alternatively, use Docker to run the containerized application."
162162
exit 1
163163
fi

server/app.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { Hono } from "hono";
22
import { cors } from "hono/cors";
33
import { serveStatic } from "@hono/node-server/serve-static";
4-
import { createNodeWebSocket } from "@hono/node-ws";
4+
import { upgradeWebSocket } from "@hono/node-server";
55
import { authMiddleware } from "./middleware/auth";
66
import { csrfMiddleware } from "./middleware/csrf";
77
import { getTrustedPublicOrigin, rememberTrustedPublicOrigin } from "./request-security";
@@ -19,7 +19,6 @@ import credentialsRoutes from "./routes/credentials";
1919

2020
export function createApp() {
2121
const app = new Hono();
22-
const { injectWebSocket, upgradeWebSocket } = createNodeWebSocket({ app });
2322

2423
// Security headers
2524
app.use("*", async (c, next) => {
@@ -111,5 +110,5 @@ export function createApp() {
111110
app.get("*", serveStatic({ root: "./dist/client", path: "index.html" }));
112111
}
113112

114-
return { app, injectWebSocket };
113+
return app;
115114
}

server/index.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { mkdirSync, chmodSync } from "fs";
22
import { dirname } from "path";
33
import { serve } from "@hono/node-server";
4+
import { WebSocketServer } from "ws";
45
import { eq } from "drizzle-orm";
56
import { config, getEncryptionSalt, hasConfiguredBaseUrl } from "./config";
67
import { initDatabase, closeDatabase, getDb } from "./db";
@@ -69,7 +70,8 @@ logger.info("Starting update scheduler");
6970
scheduler.start();
7071

7172
// Create and start Hono app
72-
const { app, injectWebSocket } = createApp();
73+
const app = createApp();
74+
const wss = new WebSocketServer({ noServer: true });
7375

7476
logger.info("Server starting", {
7577
host: config.host,
@@ -81,8 +83,10 @@ const server = serve({
8183
fetch: app.fetch,
8284
hostname: config.host,
8385
port: config.port,
86+
websocket: {
87+
server: wss,
88+
},
8489
});
85-
injectWebSocket(server);
8690

8791
logger.info("Starting notification runtimes");
8892
notificationRuntime.start().catch((error) => {

tests/server/security.test.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
/// <reference types="node" />
2+
13
import { describe, test, expect } from "vitest";
24
import { CredentialEncryptor, isPassphraseKey } from "../../server/security";
35
import { createCipheriv, randomBytes } from "crypto";
@@ -23,7 +25,9 @@ describe("CredentialEncryptor", () => {
2325
test("tampered ciphertext fails", () => {
2426
const enc = new CredentialEncryptor(testKey);
2527
const ciphertext = enc.encrypt("test");
26-
const tampered = "X" + ciphertext.slice(1);
28+
const tamperedBytes = Buffer.from(ciphertext, "base64");
29+
tamperedBytes[tamperedBytes.length - 1] ^= 0xff;
30+
const tampered = tamperedBytes.toString("base64");
2731
expect(() => enc.decrypt(tampered)).toThrow();
2832
});
2933

0 commit comments

Comments
 (0)