From 7196bd2b7b1bd6970d18e675a4e545c79d76e025 Mon Sep 17 00:00:00 2001 From: Justin Brooks Date: Thu, 14 Nov 2024 18:18:03 -0500 Subject: [PATCH] remove rate limit --- apps/pty-proxy/package.json | 1 - apps/pty-proxy/src/server.ts | 11 ------- pnpm-lock.yaml | 59 +----------------------------------- 3 files changed, 1 insertion(+), 70 deletions(-) diff --git a/apps/pty-proxy/package.json b/apps/pty-proxy/package.json index 942a9f0c..0bcb67be 100644 --- a/apps/pty-proxy/package.json +++ b/apps/pty-proxy/package.json @@ -20,7 +20,6 @@ "cors": "^2.8.5", "dotenv": "^16.4.5", "express": "^4.19.2", - "express-rate-limit": "^7.3.0", "helmet": "^7.1.0", "ms": "^2.1.3", "next-auth": "catalog:", diff --git a/apps/pty-proxy/src/server.ts b/apps/pty-proxy/src/server.ts index 695e1578..e14d739f 100644 --- a/apps/pty-proxy/src/server.ts +++ b/apps/pty-proxy/src/server.ts @@ -1,9 +1,7 @@ import cookieParser from "cookie-parser"; import cors from "cors"; import express from "express"; -import { rateLimit } from "express-rate-limit"; import helmet from "helmet"; -import ms from "ms"; const app = express(); @@ -14,15 +12,6 @@ app.set("trust proxy", true); app.use(cors({ credentials: true })); app.use(helmet()); -app.use( - rateLimit({ - windowMs: ms("1h"), - limit: 100, - standardHeaders: "draft-7", - legacyHeaders: false, - }), -); - app.use(express.urlencoded({ extended: true })); app.use(express.json()); app.use(cookieParser()); diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index c0868c8f..a753f20f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,51 +6,24 @@ settings: catalogs: default: - '@next/eslint-plugin-next': - specifier: ^14.2.6 - version: 14.2.13 - '@octokit/rest': - specifier: ^20.1.1 - version: 20.1.1 '@t3-oss/env-core': specifier: ^0.11.1 version: 0.11.1 - '@t3-oss/env-nextjs': - specifier: ^0.11.1 - version: 0.11.1 - bullmq: - specifier: ^5.15.0 - version: 5.15.0 - date-fns: - specifier: ^3.6.0 - version: 3.6.0 eslint: specifier: ^9.11.1 version: 9.14.0 - eslint-plugin-vitest: - specifier: ^0.5.4 - version: 0.5.4 - next: - specifier: ^14.2.17 - version: 14.2.17 next-auth: specifier: 5.0.0-beta.22 version: 5.0.0-beta.22 prettier: specifier: ^3.3.3 version: 3.3.3 - tailwindcss: - specifier: ^3.4.11 - version: 3.4.13 tsx: specifier: ^4.19.1 version: 4.19.1 typescript: specifier: ^5.6.3 version: 5.6.3 - typescript-eslint: - specifier: ^8.13.0 - version: 8.13.0 zod: specifier: ^3.23.8 version: 3.23.8 @@ -58,23 +31,6 @@ catalogs: '@types/node': specifier: ^20.12.0 version: 20.16.10 - node22: - '@types/node': - specifier: ^22.5.5 - version: 22.7.4 - react18: - '@types/react': - specifier: ^18.3.5 - version: 18.3.10 - '@types/react-dom': - specifier: ^18.3.0 - version: 18.3.0 - react: - specifier: 18.3.1 - version: 18.3.1 - react-dom: - specifier: 18.3.1 - version: 18.3.1 importers: @@ -374,9 +330,6 @@ importers: express: specifier: ^4.19.2 version: 4.21.1 - express-rate-limit: - specifier: ^7.3.0 - version: 7.4.1(express@4.21.1) helmet: specifier: ^7.1.0 version: 7.2.0 @@ -7767,12 +7720,6 @@ packages: resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==} engines: {node: '>=6'} - express-rate-limit@7.4.1: - resolution: {integrity: sha512-KS3efpnpIDVIXopMc65EMbWbUht7qvTCdtCR2dD/IZmi9MIkopYESwyRqLgv8Pfu589+KqDqOdzJWW7AHoACeg==} - engines: {node: '>= 16'} - peerDependencies: - express: 4 || 5 || ^5.0.0-beta.1 - express@4.21.1: resolution: {integrity: sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==} engines: {node: '>= 0.10.0'} @@ -17038,7 +16985,7 @@ snapshots: '@swc/helpers@0.5.13': dependencies: - tslib: 2.7.0 + tslib: 2.8.0 '@swc/helpers@0.5.5': dependencies: @@ -19871,10 +19818,6 @@ snapshots: expand-template@2.0.3: optional: true - express-rate-limit@7.4.1(express@4.21.1): - dependencies: - express: 4.21.1 - express@4.21.1: dependencies: accepts: 1.3.8