Bug#763500: nslint: Accept _ in TXT entries?
- To: 763500@bugs.debian.org
- Subject: Bug#763500: nslint: Accept _ in TXT entries?
- From: Petter Reinholdtsen <pere@hungry.com>
- Date: Mon, 20 May 2024 22:20:36 +0200
- Message-id: <[🔎] ZkuwlOoj08XZ3B8H@hjemme.reinholdtsen.name>
- Reply-to: Petter Reinholdtsen <pere@hungry.com>, 763500@bugs.debian.org
- In-reply-to: <20170625090110.GA1003@diskless.uio.no>
- References: <20140930134031.GG10128@ulrik.uio.no> <9065a738ba4c16d30668bba9a0b134e4.squirrel@mail.incase.de> <20141011055120.GU10128@ulrik.uio.no> <20141011065838.GV10128@ulrik.uio.no> <20170625090110.GA1003@diskless.uio.no> <20140930134031.GG10128@ulrik.uio.no>
Control: tags -1 + patch
I suspect a patch similar to this might solve it, by allowing _ at the
start for both TXT and SRV records.
diff --git a/nslint.c b/nslint.c
index f298ad1..ef1c9d1 100644
--- a/nslint.c
+++ b/nslint.c
@@ -2762,6 +2762,11 @@ rfc1034host(const char *host, int recs)
++underok;
break;
}
+ /* Allow _ first in SRV and TXT records for Kerberos */
+ if (REC_SRV == recs || REC_TXT == recs)
+ ++underok;
+
+ //fprintf(stderr, "host=%s recs=%x\n", host, recs);
cp = host;
if (!(isalpha(*cp) || isdigit(*cp) || (*cp == '_' && underok))) {
Is it enough to allow it in TXT?
--
Happy hacking
Petter Reinholdtsen
Reply to: