fix: update DNS record type validation
This commit is contained in:
+2
-2
@@ -33,8 +33,8 @@ export async function scanDnsZones(
|
||||
for await (const record of client.recordSets.listAllByDnsZone(rg, zone.name)) {
|
||||
if (!record.name) continue;
|
||||
if (!isAcmeTagged(record.metadata)) continue;
|
||||
if (record.type !== 'Microsoft.Network/dnszones/A' &&
|
||||
record.type !== 'Microsoft.Network/dnszones/CNAME') continue;
|
||||
const recordType = record.type?.split('/').pop();
|
||||
if (recordType !== 'A' && recordType !== 'AAAA' && recordType !== 'CNAME') continue;
|
||||
|
||||
const fqdn = record.name === '@' ? zone.name : `${record.name}.${zone.name}`;
|
||||
addDomain(results, seen, fqdn, rg, false);
|
||||
|
||||
Reference in New Issue
Block a user