Commit graph

117 commits

Author SHA1 Message Date
Kim Alvefur
f4edab7047 net.dns: Expand table of known RR types from IANA registry 2018-06-09 15:30:26 +02:00
Kim Alvefur
10dd453989 Merge 0.10->trunk 2018-06-09 15:47:59 +02:00
Kim Alvefur
5ae35f54cc net.dns: Syntesize type names for the full range
Otherwise unknown records are identified as A records. This also fixes
various tracebacks unearthed by previous commits and mis-identified
records.

Related to #1056 #976 #819
2018-06-09 15:34:00 +02:00
Kim Alvefur
fb63de9331 net.dns: Don't attempt to cache unparsed data (fixes #1056)
rr[qtype:lower()] can be nil. I think this happens if the type does not
have a parser.

Also see #819 #976
2018-06-09 15:35:03 +02:00
Kim Alvefur
73a7fa134d net.dns: Also cache records from the 'additional' section
Could be getting A/AAAA records here when asking for SRV
2018-06-03 00:40:42 +02:00
Kim Alvefur
ad268c9db3 net.dns: Cache all records from the 'answer' section (fixes #487)
This should preserve CNAME records included here
2018-06-09 00:02:06 +02:00
Kim Alvefur
43b814a83b vairious: Add annotation when an empty environment is set [luacheck] 2018-02-28 20:06:26 +01:00
Kim Alvefur
f31e73eb48 Merge 0.10->trunk 2017-12-01 04:54:23 +01:00
Kim Alvefur
066b90ccff net.dns: Don't compress a single zero group in IPv6 addresses to match behaviour of inet_ntop 2017-12-01 04:50:20 +01:00
Kim Alvefur
c8323e953d net.dns: Use inet_ntop from util.net if available 2017-11-29 08:02:14 +01:00
Kim Alvefur
11402a46bb net.dns: Correctly apply lower bound of RTT (thanks Ge0rG) 2017-09-24 01:04:56 +02:00
Kim Alvefur
146583f09a Merge 0.9->0.10 2017-06-13 16:38:52 +02:00
Kim Alvefur
d3fafd4a69 net.dns: Prevent answers from immediately expiring even if TTL=0 (see #919) 2017-06-13 16:36:47 +02:00
Kim Alvefur
2de6a3c394 Merge 0.9->0.10 2017-05-27 16:42:50 +02:00
Kim Alvefur
1b616a9320 net.dns: Simplify expiry calculation (fixes #919) 2017-05-22 05:32:11 +02:00
Kim Alvefur
ecf5de4a4d net.dns: Remember query only after it was sent, in case it was not (fixes #598) 2016-01-21 22:26:46 +01:00
Matthew Wild
76de073eea Backout 88d54bec26b7 prior to release, as it certainly requires more testing 2016-01-08 13:01:27 +00:00
Kim Alvefur
58885565fe net.dns: Allow a zone id in resolv.conf (eg like %eth0) 2016-01-04 15:46:06 +01:00
Anton Shestakov
6d713ae288 net.dns: remove unused variable unpack [luacheck] 2016-07-28 15:39:48 +08:00
Anton Shestakov
fdff628291 net.dns: remove unused one-letter loop variables [luacheck] 2016-07-14 18:43:17 +08:00
Anton Shestakov
8320418d38 net.dns: don't use "for s,s in pairs..." (unused loop variable s) [luacheck] 2016-07-09 10:26:18 +08:00
Anton Shestakov
4da595c2cf net.dns: remove unused one-letter loop variables [luacheck] 2016-07-09 00:45:59 +08:00
Kim Alvefur
fd043915e0 net.dns: Import unpack() in forward-compatible way (Fixes compat with Lua5.2+) 2016-03-28 19:56:12 +02:00
Kim Alvefur
6116ba8cfb Merge 0.9->0.10 2016-01-22 14:49:05 +01:00
Kim Alvefur
ebdebb946d Merge 0.9->0.10 2016-01-08 16:16:08 +01:00
Matthew Wild
99fd12af8f Merge 0.9->0.10 2015-09-25 16:51:42 +01:00
Kim Alvefur
86200054b7 net.dns: Use new IPv4-specific socket factory if available (fixes dns on libevent with latest development version of luasocket) 2015-09-25 17:32:13 +02:00
Matthew Wild
df0b6a6e97 net.dns: Unconditionally cache records found in answers 2015-05-25 23:16:11 +01:00
Kim Alvefur
38a580bfeb net.dns: Make sure argument to math.randomseed does not overflow a 32 bit *signed* int (blame Lua). Closes #439 2015-04-26 19:50:24 +02:00
Kim Alvefur
7dff400ed5 net.dns, mod_s2s: Add chasing of CNAMEs to net.dns and remove it from mod_s2s 2015-04-24 14:14:01 +02:00
Kim Alvefur
c68bed48e9 net.dns: Try next server if peer name can not be set (thanks wirehack7) 2014-10-30 12:28:07 +01:00
Kim Alvefur
450ee96e48 net.dns: Return new socket from servfail 2014-10-30 12:10:15 +01:00
Florian Zeitz
2b53ced362 net.dns: Avoid duplicate cache entries 2014-10-05 14:28:40 +02:00
Matthew Wild
7ff1520d7d net.dns: Remove unused obsolete code 2014-07-25 12:54:31 +01:00
Matthew Wild
4ed07e7947 net.dns: Ensure all pending requests get notified of a timeout when looking up a record (fix for d122420542fb) 2014-07-25 12:08:07 +01:00
Kim Alvefur
7ef57da047 net.dns: Fix duplicated cache insertions by limiting outstanding queries per name to one 2014-06-30 12:45:53 +02:00
Kim Alvefur
69652ea24b net.*: Remove use of module() function 2015-02-21 10:45:24 +01:00
Matthew Wild
ff7b482c6d net.dns: Remove resolver:new(), as it needlessly and incorrectly duplicates dns.resolver() 2015-07-06 19:11:39 +01:00
Kim Alvefur
a7606f77d9 Merge 0.9->0.10 2015-05-03 18:38:39 +02:00
Kim Alvefur
3e6b35b5d4 Merge 0.9->0.10 2015-04-26 00:06:44 +02:00
Kim Alvefur
486335f3db Merge 0.9 -> 0.10 2014-11-09 20:30:04 +01:00
Kim Alvefur
e4a6b7e39a Merge 0.9->0.10 2014-10-05 15:37:21 +02:00
Matthew Wild
999a5a0cb3 Merge 0.9->0.10 2014-07-25 13:01:57 +01:00
Kim Alvefur
75c19f9f6c Merge 0.9->0.10 2014-06-30 13:11:01 +02:00
Florian Zeitz
1d833bb807 Remove all trailing whitespace 2013-08-09 17:48:21 +02:00
Kim Alvefur
7cbbf991bc Merge 0.9->trunk 2013-07-10 07:47:54 +02:00
Kim Alvefur
5b13d561ee net.dns, net.adns: Make sure errors from net.server are propagated (thanks asterix) 2013-07-10 07:45:10 +02:00
Florian Zeitz
4f709973f8 net.dns: Support IPv6 addresses in resolv.conf [Backported from 0.10] 2013-06-18 23:02:20 +02:00
Florian Zeitz
15c9e030d7 net.dns: Support IPv6 addresses in resolv.conf 2013-06-18 23:02:20 +02:00
Kim Alvefur
694d42d322 net.dns: Add nicer API to cached records 2013-05-07 16:51:25 +02:00