From 6f7ce2bc77d18b6932a1af39f46f3f1c0e902b94 Mon Sep 17 00:00:00 2001 From: Zert3x <81202811+Zert3x@users.noreply.github.com> Date: Sun, 28 May 2023 21:27:01 -0400 Subject: forwaded -> forwarded --- src/util/config/types/SecurityConfiguration.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/util/config/types/SecurityConfiguration.ts b/src/util/config/types/SecurityConfiguration.ts index 5e971cfe..35776642 100644 --- a/src/util/config/types/SecurityConfiguration.ts +++ b/src/util/config/types/SecurityConfiguration.ts @@ -28,7 +28,7 @@ export class SecurityConfiguration { // header to get the real user ip address // X-Forwarded-For for nginx/reverse proxies // CF-Connecting-IP for cloudflare - forwadedFor: string | null = null; + forwardedFor: string | null = null; ipdataApiKey: string | null = "eca677b284b3bac29eb72f5e496aa9047f26543605efe99ff2ce35c9"; mfaBackupCodeCount: number = 10; -- cgit 1.4.1 From 6306c5e725b104dca8d0f01f55f88f3e1264e31e Mon Sep 17 00:00:00 2001 From: Zert3x <81202811+Zert3x@users.noreply.github.com> Date: Sun, 28 May 2023 21:39:50 -0400 Subject: Update ipAddress.ts --- src/api/util/utility/ipAddress.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/api/util/utility/ipAddress.ts b/src/api/util/utility/ipAddress.ts index 172e9604..c51daf6c 100644 --- a/src/api/util/utility/ipAddress.ts +++ b/src/api/util/utility/ipAddress.ts @@ -102,7 +102,7 @@ export function getIpAdress(req: Request): string { return ( // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-ignore - req.headers[Config.get().security.forwadedFor] || + req.headers[Config.get().security.forwardedFor] || req.socket.remoteAddress ); } -- cgit 1.4.1 From 09b163f8de0392fcf577ac31e0f1f900d182467f Mon Sep 17 00:00:00 2001 From: Zert3x <81202811+Zert3x@users.noreply.github.com> Date: Sun, 28 May 2023 21:40:21 -0400 Subject: Update Connection.ts --- src/gateway/events/Connection.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/gateway/events/Connection.ts b/src/gateway/events/Connection.ts index 68273ace..1991ebbe 100644 --- a/src/gateway/events/Connection.ts +++ b/src/gateway/events/Connection.ts @@ -45,7 +45,7 @@ export async function Connection( socket: WebSocket, request: IncomingMessage, ) { - const forwardedFor = Config.get().security.forwadedFor; + const forwardedFor = Config.get().security.forwardedFor; const ipAddress = forwardedFor ? (request.headers[forwardedFor] as string) : request.socket.remoteAddress; -- cgit 1.4.1