summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* cache statisticsBob Halley2020-07-191-0/+35
|
* Add dns.edns.register_type().Brian Wellington2020-07-171-0/+37
| | | | This allows an application to register a custom EDNS option type.
* Use the selectors module.Brian Wellington2020-07-172-23/+9
| | | | | | Previously, there was code to either use select.select or select.poll, depending on OS. This changes it to use the selectors module, using either SelectSelector or PollSelector, but sharing code otherwise.
* Add coverage for TCP/TLS async getsockname.Brian Wellington2020-07-081-0/+4
|
* Add support for receiving UDP queries.Brian Wellington2020-07-082-0/+31
| | | | | | | | | | | | | | The existing receive_udp() methods are only usable for receiving responses, as they require an expected destination and check that the message is from that destination. This change makes the expected destination (and hence the check) optional, and returns the address that the message was received from (in the sync case, this is only done if no destination is provided, for backwards compatibility). New tests are added, which required adding generic getsockname() support to the async backends.
* Don't read resolv.conf in tests that don't use it.Brian Wellington2020-07-084-9/+10
|
* Remove debugging print.Brian Wellington2020-07-081-1/+0
|
* Merge pull request #531 from bwelling/tsig2Bob Halley2020-07-071-8/+10
|\ | | | | Split TSIG sign and validate.
| * Split TSIG sign and validate.Brian Wellington2020-07-071-8/+10
| |
* | TSIG code now uses dns.rcode.Rcode enum values for the TSIG error field.Bob Halley2020-07-072-4/+21
| |
* | Fix Message.want_dnssec().Brian Wellington2020-07-071-0/+1
|/ | | | | It was incorrectly calling Message._make_opt() in the case where the message was not currently using EDNS.
* Give up on socket.getfqdn() testing with CDN-hosted resources as it has too ↵Bob Halley2020-07-061-7/+16
| | | | much magic.
* improve name coverageBob Halley2020-07-031-0/+4
|
* more coverage for wireBob Halley2020-07-021-1/+33
|
* Consolidate NSEC/NSEC3/CSYNC bitmap handling.Brian Wellington2020-07-021-0/+10
| | | | | | | This also fixes several bugs; the NSEC3 code would properly avoid empty windows, but the NSEC and CSYNC code did not. Also, none of the wire parsing routines properly checked to see that the window number was monotonically increasing.
* Rework wire format processing.Bob Halley2020-07-024-162/+78
| | | | | | Wire format data is now done via a dns.wire.Parser, which does all of the bookkeeping and also provides convenience routines (e.g. get_uint16() or get_name()).
* Merge pull request #527 from bwelling/tsigkeyBob Halley2020-07-012-6/+38
|\ | | | | Add dns.tsig.Key class.
| * Better deal with backwards compatibility.Brian Wellington2020-07-012-12/+19
| | | | | | | | | | | | | | | | If dns.tsigkeyring.from_text() creates dns.tsig.Key objects with the default algorithm, that causes problems for code that specifies a different algorithm. There's no good way to handle this, so change dns.tsigkeyring.from_text() to not create dns.tsig.Key objects unless it knows the algorithm.
| * Add dns.tsig.Key class.Brian Wellington2020-07-012-5/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This creates a new class to represent a TSIG key, containing name, secret, and algorithm. The keyring format is changed to be {name : key}, and the methods in dns.tsigkeyring are updated to deal with old and new formats. The Message class is updated to use dns.tsig.Key, although (to avoid breaking existing code), it stores them in the keyring field. Message.use_tsig() can accept either explicit keys, or keyrings; it will extract and/or create a key. dns.message.from_wire() can accept either a key or a keyring in the keyring parameter. If passed a key, it will now raise if the TSIG record in the message was signed with a different key. If passed a keyring containing keys (as opposed to bare secrets), it will check that the TSIG record's algorithm matches that of the key.
* | Merge remote-tracking branch 'upstream/master' into amtrelayBrian Wellington2020-07-012-0/+118
|\ \ | |/
| * increase resolver coverageBob Halley2020-07-011-0/+58
| |
| * avoid low-level wait tests on WindowsBob Halley2020-07-011-0/+3
| |
| * more query coverageBob Halley2020-06-301-0/+57
| |
* | Add support for the AMTRELAY type.Brian Wellington2020-07-014-0/+20
|/
* One more dnssec test.Brian Wellington2020-06-301-0/+4
|
* Add more dnssec coverage testing.Brian Wellington2020-06-301-0/+44
|
* Merge pull request #525 from bwelling/tsigBob Halley2020-06-302-6/+50
|\ | | | | Adds support for a TSIG record class.
| * Test (and fix) renderer.add_multi_tsig().Brian Wellington2020-06-301-0/+29
| |
| * Store a TSIG rrset on the message object.Brian Wellington2020-06-302-6/+21
| |
* | increase name test coverageBob Halley2020-06-301-0/+66
| |
* | increase test coverageBob Halley2020-06-301-0/+24
| |
* | increase update test coverageBob Halley2020-06-301-0/+109
|/
* fix indentation of test_bogus_family()Bob Halley2020-06-291-5/+5
|
* more coverage improvementsBob Halley2020-06-294-0/+115
|
* add basic renderer testingBob Halley2020-06-291-0/+46
|
* increase namedict coverageBob Halley2020-06-281-0/+37
|
* increase coverageBob Halley2020-06-283-0/+72
|
* remove debugging printsBob Halley2020-06-282-2/+0
|
* add serial number arithmetic helperBob Halley2020-06-271-0/+115
|
* test update section validationBob Halley2020-06-271-16/+112
|
* test class factory and update from_wire()Bob Halley2020-06-262-0/+11
|
* Use `configure=False` in tests to skip reading /etc/resolv.confLumir Balhar2020-06-251-5/+5
|
* lint nanonameserverBob Halley2020-06-241-1/+1
|
* Fix cut-and-paste error.Brian Wellington2020-06-241-1/+1
|
* Close extra UDP sockets more quickly.Brian Wellington2020-06-241-23/+30
| | | | | If any UDP sockets are left open due to the corresponding TCP ports being in use, close them.
* Remove unused code.Brian Wellington2020-06-241-16/+0
|
* Add more functionality to nanonameserver.Brian Wellington2020-06-233-29/+85
| | | | | | | | | | | - When no port is specified, pick the same port for UDP and TCP, so that TCP fallback can be tested. - Change handlers to get a single Request object instead of individual parameters. The Request object contains the message, peer, and connection_type previously passed, and also adds the local address and wire format message. Additionally, it provides convenient properties for accessing the question.
* make read_resolv_conf() tests work on win32 tooBob Halley2020-06-231-2/+4
|
* merge mostly redundant resolv.conf test into existing testBob Halley2020-06-231-35/+15
|
* test resolv.conf settingsBob Halley2020-06-231-0/+20
|