Kim Alvefur
43351d2b54
Spelling: Fix various spelling mistakes (thanks timeless)
...
Words, sometimes I wonder how they even work
Maybe I missed something.
4 years ago
Kim Alvefur
869581384d
net: Prefix module imports with prosody namespace
3 years ago
Kim Alvefur
93830ecf40
various: Update IETF RFC URLs for tools.ietf.org transition
...
See https://www.ietf.org/blog/finalizing-ietf-tools-transition/
Already done in various other places.
3 years ago
Matthew Wild
fb5059547f
net.dns: Disable jitter for default resolver (used by blocking dns.lookup() calls)
...
This fixes 'prosodyctl check dns' being slow.
6 years ago
Matthew Wild
6daae1f629
net.dns: Reduce default timeout to 5s
...
Most healthy queries will return well within this time, and the
new retry logic should help spread the cost of additional retries.
6 years ago
Matthew Wild
5e744740f3
net.dns: Increase backoff delays
...
Not entirely happy with the overall logic here.
6 years ago
Matthew Wild
d080fee323
net.dns: Add jitter to spread queries and reduce failures due to congestion
6 years ago
Matthew Wild
3ff48b8386
net.dns: Fix timeout retry logic
...
On timeout the query would be resent twice - once within
servfail(), and again inside the timeout callback.
This commit moves all retry logic to servfail().
6 years ago
Matthew Wild
5f4fcad112
net.dns: Add some debug logging
6 years ago
Kim Alvefur
522e9778ea
net.dns: Handle being loaded outside of Prosody
...
`if timer ...` suggests that this was intended, but it did not work
because net.timer depends on net.server which refuses to be loaded
outside of Prosody.
6 years ago
Kim Alvefur
94880142e9
net.dns: Close resolv.conf handle when done ( fixes #1342 )
7 years ago
Kim Alvefur
054cdafd57
net.dns: Lazily generate unknown RR type names
8 years ago
Kim Alvefur
28e486f3df
Backed out changeset eae606b9266c: Used a lot of memory
8 years ago
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
8 years ago
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
8 years ago
Kim Alvefur
73a7fa134d
net.dns: Also cache records from the 'additional' section
...
Could be getting A/AAAA records here when asking for SRV
8 years ago
Kim Alvefur
ad268c9db3
net.dns: Cache all records from the 'answer' section ( fixes #487 )
...
This should preserve CNAME records included here
8 years ago
Kim Alvefur
d3fafd4a69
net.dns: Prevent answers from immediately expiring even if TTL=0 (see #919 )
9 years ago
Kim Alvefur
1b616a9320
net.dns: Simplify expiry calculation ( fixes #919 )
9 years ago
Kim Alvefur
066b90ccff
net.dns: Don't compress a single zero group in IPv6 addresses to match behaviour of inet_ntop
8 years ago
Kim Alvefur
11402a46bb
net.dns: Correctly apply lower bound of RTT (thanks Ge0rG)
8 years ago
Kim Alvefur
f4edab7047
net.dns: Expand table of known RR types from IANA registry
8 years ago
Kim Alvefur
43b814a83b
vairious: Add annotation when an empty environment is set [luacheck]
8 years ago
Kim Alvefur
c8323e953d
net.dns: Use inet_ntop from util.net if available
8 years ago
Anton Shestakov
6d713ae288
net.dns: remove unused variable unpack [luacheck]
10 years ago
Anton Shestakov
fdff628291
net.dns: remove unused one-letter loop variables [luacheck]
10 years ago
Anton Shestakov
8320418d38
net.dns: don't use "for s,s in pairs..." (unused loop variable s) [luacheck]
10 years ago
Anton Shestakov
4da595c2cf
net.dns: remove unused one-letter loop variables [luacheck]
10 years ago
Kim Alvefur
ecf5de4a4d
net.dns: Remember query only after it was sent, in case it was not ( fixes #598 )
10 years ago
Matthew Wild
76de073eea
Backout 88d54bec26b7 prior to release, as it certainly requires more testing
10 years ago
Kim Alvefur
58885565fe
net.dns: Allow a zone id in resolv.conf (eg like %eth0)
10 years ago
Kim Alvefur
86200054b7
net.dns: Use new IPv4-specific socket factory if available (fixes dns on libevent with latest development version of luasocket)
10 years ago
Matthew Wild
ff7b482c6d
net.dns: Remove resolver:new(), as it needlessly and incorrectly duplicates dns.resolver()
11 years ago
Matthew Wild
df0b6a6e97
net.dns: Unconditionally cache records found in answers
11 years ago
Kim Alvefur
38a580bfeb
net.dns: Make sure argument to math.randomseed does not overflow a 32 bit *signed* int (blame Lua). Closes #439
11 years ago
Kim Alvefur
7dff400ed5
net.dns, mod_s2s: Add chasing of CNAMEs to net.dns and remove it from mod_s2s
11 years ago
Kim Alvefur
69652ea24b
net.*: Remove use of module() function
11 years ago
Kim Alvefur
fd043915e0
net.dns: Import unpack() in forward-compatible way (Fixes compat with Lua5.2+)
10 years ago
Kim Alvefur
c68bed48e9
net.dns: Try next server if peer name can not be set (thanks wirehack7)
11 years ago
Kim Alvefur
450ee96e48
net.dns: Return new socket from servfail
11 years ago
Florian Zeitz
2b53ced362
net.dns: Avoid duplicate cache entries
11 years ago
Matthew Wild
7ff1520d7d
net.dns: Remove unused obsolete code
12 years ago
Matthew Wild
4ed07e7947
net.dns: Ensure all pending requests get notified of a timeout when looking up a record (fix for d122420542fb)
12 years ago
Kim Alvefur
7ef57da047
net.dns: Fix duplicated cache insertions by limiting outstanding queries per name to one
12 years ago
Florian Zeitz
1d833bb807
Remove all trailing whitespace
13 years ago
Kim Alvefur
5b13d561ee
net.dns, net.adns: Make sure errors from net.server are propagated (thanks asterix)
13 years ago
Florian Zeitz
4f709973f8
net.dns: Support IPv6 addresses in resolv.conf [Backported from 0.10]
13 years ago
Florian Zeitz
15c9e030d7
net.dns: Support IPv6 addresses in resolv.conf
13 years ago
Kim Alvefur
694d42d322
net.dns: Add nicer API to cached records
13 years ago
Kim Alvefur
cd8da4a60d
net.dns: Make sure argument to math.randomseed does not overflow a 32 bit unsigned int. Closes #320
13 years ago