1# Changelog
2
3## 1.5.0 (2021-03-05)
4
5*   Feature: Improve error reporting when query fails, include domain and query type and DNS server address where applicable.
6    (#174 by @clue)
7
8*   Feature: Improve error handling when sending data to DNS server fails (macOS).
9    (#171 and #172 by @clue)
10
11*   Fix: Improve DNS response parser to limit recursion for compressed labels.
12    (#169 by @clue)
13
14*   Improve test suite, use GitHub actions for continuous integration (CI).
15    (#170 by @SimonFrings)
16
17## 1.4.0 (2020-09-18)
18
19*   Feature: Support upcoming PHP 8.
20    (#168 by @clue)
21
22*   Improve test suite and update to PHPUnit 9.3.
23    (#164 by @clue, #165 and #166 by @SimonFrings and #167 by @WyriHaximus)
24
25## 1.3.0 (2020-07-10)
26
27*   Feature: Forward compatibility with react/promise v3.
28    (#153 by @WyriHaximus)
29
30*   Feature: Support parsing `OPT` records (EDNS0).
31    (#157 by @clue)
32
33*   Fix: Avoid PHP warnings due to lack of args in exception trace on PHP 7.4.
34    (#160 by @clue)
35
36*   Improve test suite and add `.gitattributes` to exclude dev files from exports.
37    Run tests on PHPUnit 9 and PHP 7.4 and clean up test suite.
38    (#154 by @reedy, #156 by @clue and #163 by @SimonFrings)
39
40## 1.2.0 (2019-08-15)
41
42*   Feature: Add `TcpTransportExecutor` to send DNS queries over TCP/IP connection,
43    add `SelectiveTransportExecutor` to retry with TCP if UDP is truncated and
44    automatically select transport protocol when no explicit `udp://` or `tcp://` scheme is given in `Factory`.
45    (#145, #146, #147 and #148 by @clue)
46
47*   Feature: Support escaping literal dots and special characters in domain names.
48    (#144 by @clue)
49
50## 1.1.0 (2019-07-18)
51
52*   Feature: Support parsing `CAA` and `SSHFP` records.
53    (#141 and #142 by @clue)
54
55*   Feature: Add `ResolverInterface` as common interface for `Resolver` class.
56    (#139 by @clue)
57
58*   Fix: Add missing private property definitions and
59    remove unneeded dependency on `react/stream`.
60    (#140 and #143 by @clue)
61
62## 1.0.0 (2019-07-11)
63
64*   First stable LTS release, now following [SemVer](https://semver.org/).
65    We'd like to emphasize that this component is production ready and battle-tested.
66    We plan to support all long-term support (LTS) releases for at least 24 months,
67    so you have a rock-solid foundation to build on top of.
68
69This update involves a number of BC breaks due to dropped support for
70deprecated functionality and some internal API cleanup. We've tried hard to
71avoid BC breaks where possible and minimize impact otherwise. We expect that
72most consumers of this package will actually not be affected by any BC
73breaks, see below for more details:
74
75*   BC break: Delete all deprecated APIs, use `Query` objects for `Message` questions
76    instead of nested arrays and increase code coverage to 100%.
77    (#130 by @clue)
78
79*   BC break: Move `$nameserver` from `ExecutorInterface` to `UdpTransportExecutor`,
80    remove advanced/internal `UdpTransportExecutor` args for `Parser`/`BinaryDumper` and
81    add API documentation for `ExecutorInterface`.
82    (#135, #137 and #138 by @clue)
83
84*   BC break: Replace `HeaderBag` attributes with simple `Message` properties.
85    (#132 by @clue)
86
87*   BC break: Mark all `Record` attributes as required, add documentation vs `Query`.
88    (#136 by @clue)
89
90*   BC break: Mark all classes as final to discourage inheritance
91    (#134 by @WyriHaximus)
92
93## 0.4.19 (2019-07-10)
94
95*   Feature: Avoid garbage references when DNS resolution rejects on legacy PHP <= 5.6.
96    (#133 by @clue)
97
98## 0.4.18 (2019-09-07)
99
100*   Feature / Fix: Implement `CachingExecutor` using cache TTL, deprecate old `CachedExecutor`,
101    respect TTL from response records when caching and do not cache truncated responses.
102    (#129 by @clue)
103
104*   Feature: Limit cache size to 256 last responses by default.
105    (#127 by @clue)
106
107*   Feature: Cooperatively resolve hosts to avoid running same query concurrently.
108    (#125 by @clue)
109
110## 0.4.17 (2019-04-01)
111
112*   Feature: Support parsing `authority` and `additional` records from DNS response.
113    (#123 by @clue)
114
115*   Feature: Support dumping records as part of outgoing binary DNS message.
116    (#124 by @clue)
117
118*   Feature: Forward compatibility with upcoming Cache v0.6 and Cache v1.0
119    (#121 by @clue)
120
121*   Improve test suite to add forward compatibility with PHPUnit 7,
122    test against PHP 7.3 and use legacy PHPUnit 5 on legacy HHVM.
123    (#122 by @clue)
124
125## 0.4.16 (2018-11-11)
126
127*   Feature: Improve promise cancellation for DNS lookup retries and clean up any garbage references.
128    (#118 by @clue)
129
130*   Fix: Reject parsing malformed DNS response messages such as incomplete DNS response messages,
131    malformed record data or malformed compressed domain name labels.
132    (#115 and #117 by @clue)
133
134*   Fix: Fix interpretation of TTL as UINT32 with most significant bit unset.
135    (#116 by @clue)
136
137*   Fix: Fix caching advanced MX/SRV/TXT/SOA structures.
138    (#112 by @clue)
139
140## 0.4.15 (2018-07-02)
141
142*   Feature: Add `resolveAll()` method to support custom query types in `Resolver`.
143    (#110 by @clue and @WyriHaximus)
144
145    ```php
146    $resolver->resolveAll('reactphp.org', Message::TYPE_AAAA)->then(function ($ips) {
147        echo 'IPv6 addresses for reactphp.org ' . implode(', ', $ips) . PHP_EOL;
148    });
149    ```
150
151*   Feature: Support parsing `NS`, `TXT`, `MX`, `SOA` and `SRV` records.
152    (#104, #105, #106, #107 and #108 by @clue)
153
154*   Feature: Add support for `Message::TYPE_ANY` and parse unknown types as binary data.
155    (#104 by @clue)
156
157*   Feature: Improve error messages for failed queries and improve documentation.
158    (#109 by @clue)
159
160*   Feature: Add reverse DNS lookup example.
161    (#111 by @clue)
162
163## 0.4.14 (2018-06-26)
164
165*   Feature: Add `UdpTransportExecutor`, validate incoming DNS response messages
166    to avoid cache poisoning attacks and deprecate legacy `Executor`.
167    (#101 and #103 by @clue)
168
169*   Feature: Forward compatibility with Cache 0.5
170    (#102 by @clue)
171
172*   Deprecate legacy `Query::$currentTime` and binary parser data attributes to clean up and simplify API.
173    (#99 by @clue)
174
175## 0.4.13 (2018-02-27)
176
177*   Add `Config::loadSystemConfigBlocking()` to load default system config
178    and support parsing DNS config on all supported platforms
179    (`/etc/resolv.conf` on Unix/Linux/Mac and WMIC on Windows)
180    (#92, #93, #94 and #95 by @clue)
181
182    ```php
183    $config = Config::loadSystemConfigBlocking();
184    $server = $config->nameservers ? reset($config->nameservers) : '8.8.8.8';
185    ```
186
187*   Remove unneeded cyclic dependency on react/socket
188    (#96 by @clue)
189
190## 0.4.12 (2018-01-14)
191
192*   Improve test suite by adding forward compatibility with PHPUnit 6,
193    test against PHP 7.2, fix forward compatibility with upcoming EventLoop releases,
194    add test group to skip integration tests relying on internet connection
195    and add minor documentation improvements.
196    (#85 and #87 by @carusogabriel, #88 and #89 by @clue and #83 by @jsor)
197
198## 0.4.11 (2017-08-25)
199
200*   Feature: Support resolving from default hosts file
201    (#75, #76 and #77 by @clue)
202
203    This means that resolving hosts such as `localhost` will now work as
204    expected across all platforms with no changes required:
205
206    ```php
207    $resolver->resolve('localhost')->then(function ($ip) {
208        echo 'IP: ' . $ip;
209    });
210    ```
211
212    The new `HostsExecutor` exists for advanced usage and is otherwise used
213    internally for this feature.
214
215## 0.4.10 (2017-08-10)
216
217* Feature: Forward compatibility with EventLoop v1.0 and v0.5 and
218  lock minimum dependencies and work around circular dependency for tests
219  (#70 and #71 by @clue)
220
221* Fix: Work around DNS timeout issues for Windows users
222  (#74 by @clue)
223
224* Documentation and examples for advanced usage
225  (#66 by @WyriHaximus)
226
227* Remove broken TCP code, do not retry with invalid TCP query
228  (#73 by @clue)
229
230* Improve test suite by fixing HHVM build for now again and ignore future HHVM build errors and
231  lock Travis distro so new defaults will not break the build and
232  fix failing tests for PHP 7.1
233  (#68 by @WyriHaximus and #69 and #72 by @clue)
234
235## 0.4.9 (2017-05-01)
236
237* Feature: Forward compatibility with upcoming Socket v1.0 and v0.8
238  (#61 by @clue)
239
240## 0.4.8 (2017-04-16)
241
242* Feature: Add support for the AAAA record type to the protocol parser
243  (#58 by @othillo)
244
245* Feature: Add support for the PTR record type to the protocol parser
246  (#59 by @othillo)
247
248## 0.4.7 (2017-03-31)
249
250* Feature: Forward compatibility with upcoming Socket v0.6 and v0.7 component
251  (#57 by @clue)
252
253## 0.4.6 (2017-03-11)
254
255* Fix: Fix DNS timeout issues for Windows users and add forward compatibility
256  with Stream v0.5 and upcoming v0.6
257  (#53 by @clue)
258
259* Improve test suite by adding PHPUnit to `require-dev`
260  (#54 by @clue)
261
262## 0.4.5 (2017-03-02)
263
264* Fix: Ensure we ignore the case of the answer
265  (#51 by @WyriHaximus)
266
267* Feature: Add `TimeoutExecutor` and simplify internal APIs to allow internal
268  code re-use for upcoming versions.
269  (#48 and #49 by @clue)
270
271## 0.4.4 (2017-02-13)
272
273* Fix: Fix handling connection and stream errors
274  (#45 by @clue)
275
276* Feature: Add examples and forward compatibility with upcoming Socket v0.5 component
277  (#46 and #47 by @clue)
278
279## 0.4.3 (2016-07-31)
280
281* Feature: Allow for cache adapter injection (#38 by @WyriHaximus)
282
283  ```php
284  $factory = new React\Dns\Resolver\Factory();
285
286  $cache = new MyCustomCacheInstance();
287  $resolver = $factory->createCached('8.8.8.8', $loop, $cache);
288  ```
289
290* Feature: Support Promise cancellation (#35 by @clue)
291
292  ```php
293  $promise = $resolver->resolve('reactphp.org');
294
295  $promise->cancel();
296  ```
297
298## 0.4.2 (2016-02-24)
299
300* Repository maintenance, split off from main repo, improve test suite and documentation
301* First class support for PHP7 and HHVM (#34 by @clue)
302* Adjust compatibility to 5.3 (#30 by @clue)
303
304## 0.4.1 (2014-04-13)
305
306* Bug fix: Fixed PSR-4 autoload path (@marcj/WyriHaximus)
307
308## 0.4.0 (2014-02-02)
309
310* BC break: Bump minimum PHP version to PHP 5.4, remove 5.3 specific hacks
311* BC break: Update to React/Promise 2.0
312* Bug fix: Properly resolve CNAME aliases
313* Dependency: Autoloading and filesystem structure now PSR-4 instead of PSR-0
314* Bump React dependencies to v0.4
315
316## 0.3.2 (2013-05-10)
317
318* Feature: Support default port for IPv6 addresses (@clue)
319
320## 0.3.0 (2013-04-14)
321
322* Bump React dependencies to v0.3
323
324## 0.2.6 (2012-12-26)
325
326* Feature: New cache component, used by DNS
327
328## 0.2.5 (2012-11-26)
329
330* Version bump
331
332## 0.2.4 (2012-11-18)
333
334* Feature: Change to promise-based API (@jsor)
335
336## 0.2.3 (2012-11-14)
337
338* Version bump
339
340## 0.2.2 (2012-10-28)
341
342* Feature: DNS executor timeout handling (@arnaud-lb)
343* Feature: DNS retry executor (@arnaud-lb)
344
345## 0.2.1 (2012-10-14)
346
347* Minor adjustments to DNS parser
348
349## 0.2.0 (2012-09-10)
350
351* Feature: DNS resolver
352