Changeset 1011 for branches


Ignore:
Timestamp:
01/30/26 13:15:47 (2 days ago)
Author:
Kris Deugau
Message:

/branches/cname-collision

Exclude another domain from the "is this a test DB?" checklist
Revise record check to exclude a pattern of domain names

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/cname-collision/t/DNSTest.pm

    r999 r1011  
    55##
    66# $Id$
    7 # Copyright 2025 Kris Deugau <kdeugau@deepnet.cx>
     7# Copyright 2025,2026 Kris Deugau <kdeugau@deepnet.cx>
    88#
    99#    This program is free software: you can redistribute it and/or modify
     
    6464
    6565  my ($dcount) = $dbh->selectrow_array("SELECT count(*) FROM domains WHERE NOT domain IN ".
    66         "('example.com','example.net','example.org','expiry1.test','expiry2.test')");
     66        "('example.com','example.net','example.org','expiry1.test','expiry2.test','expiry3.test')");
    6767  BAIL_OUT("# DB looks like it may not be a test DB, found $dcount > 0 non-test domains!\n")
    6868        if $dcount > 0;
     
    7171  my ($rcount) = $dbh->selectrow_array(qq{SELECT count(*) FROM records WHERE NOT (
    7272        host like '%example.com' or host like '%example.net' or host like '%example.org' or
    73         host like '%expiry1.test' or host like '%expiry2.test' or inetlazy(val) << '192.168.2.0/27'
     73        host like '%expiry_.test' or inetlazy(val) << '192.168.2.0/27'
    7474        )});
    7575  my $maxrecs = 0;
Note: See TracChangeset for help on using the changeset viewer.