Update hivegrid-cloud reference to latest main

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
davidandClaude Fable 5 committed 2026-07-08 16:15:37 +02:00
1 parent e98d38e716
commit 7b21524c86
3781 files changed
+373484 -225607

No files matched your search

@@ -1,8 +1,9 @@
import { formatTenantApiUsagePlanTitle, SUBSCRIPTION_FEATURE_LIMIT } from "@toolctrl/db/usage.server";
import { formatTenantApiUsagePlanTitle, SUBSCRIPTION_FEATURE_LIMIT } from "@hivegrid/db/usage.server";
import type { Context } from "hono";
import { extractApiKeyFromRequest } from "../auth.js";
import { getApiRuntimeConfig } from "../config.js";
import { getTrustedClientIp } from "../trusted-client-ip.js";
import { apiError, type ApiErrorEnv } from "../middleware/error-envelope.js";
import type { ApiAppDependencies } from "../app.js";
@@ -102,7 +103,8 @@ async function createApiUsageErrorLog(
}
function getClientIpAddress(request: Request) {
return request.headers.get("x-forwarded-for")?.split(",")[0]?.trim() || request.headers.get("x-real-ip") || "";
// Trusted proxy-set header only; leftmost X-Forwarded-For is client-spoofable.
return getTrustedClientIp(request);
}
function serializeRequestSearchParams(request: Request) {