Drop nonfunctional default ipdata key

This commit is contained in:
Rory&
2025-12-13 23:41:48 +01:00
parent 0be92b274a
commit 4bb3ff1aae
2 changed files with 15 additions and 1 deletions

View File

@@ -36,7 +36,7 @@ export class SecurityConfiguration {
// https://docs.abuseipdb.com/#api-daily-rate-limits
abuseipdbBlacklistRatelimit: number = 5;
abuseipdbConfidenceScoreTreshold: number = 50;
ipdataApiKey: string | null = "eca677b284b3bac29eb72f5e496aa9047f26543605efe99ff2ce35c9"; // isnt even valid anymore it seems?
ipdataApiKey: string | null = null;
mfaBackupCodeCount: number = 10;
statsWorldReadable: boolean = true;
defaultRegistrationTokenExpiration: number = 1000 * 60 * 60 * 24 * 7; //1 week

View File

@@ -0,0 +1,14 @@
import { MigrationInterface, QueryRunner } from "typeorm";
export class DropDefaultIPDataKey1765665440000 implements MigrationInterface {
name = 'DropDefaultIPDataKey1765665440000'
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`UPDATE "config" SET "value" = NULL WHERE "key" = 'security_ipdataApiKey' AND "value" = '"eca677b284b3bac29eb72f5e496aa9047f26543605efe99ff2ce35c9"'`);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`UPDATE "config" SET "value" = '"eca677b284b3bac29eb72f5e496aa9047f26543605efe99ff2ce35c9"' WHERE "key" = 'security_ipdataApiKey' AND "value" IS NULL`);
}
}