On Sat, 30 Jan 2021, Noel Duffy via fpc-pascal wrote:
On 30/01/21 9:45 pm, Michael Van Canneyt via fpc-pascal wrote:
On Sat, 30 Jan 2021, Noel Duffy via fpc-pascal wrote:
I've added patches to resolve issue #37906, DNS over TCP, to the bug
tracker:
https://bugs.freepascal.org/view.php?id=37906
I've broken the changes into three patches:
1. netdb.patch, which updates packages/fcl-net/src/netdb.pp, adding
support for DNS over TCP
2. netdb-example.patch, which adds an example program to
packages/fcl-net/examples and adds it to
packages/fcl-net/examples/Makefile.fpc
3. netdb-tests.patch, which adds unit tests to packages/fcl-net/tests and
updates tests/Makefile.fpc to add the new tests to the build system
I've created separate patches to simplify applying them. If there's a
problem with one, the others should still be OK.
In addition to new code for DNS over TCP, this latest set of patches adds
checks for writes beyond buffer boundaries and other potential security
issues. Since the last update I've also added support for SRV records, as
defined in RFC 2782.
Very nice indeed !! I checked your patches, they're all applied.
Great stuff! Thanks Michael. As always, I wonder if you ever sleep! :-D
Less and less with age ;-)
Thank you very much for this contribution !
Happy to do so.
With regard to documentation, I've not written anything yet, and it seems I'm
as well placed as anyone to do it. That said, I'm completely unfamiliar with
generating documentation from source in FPC. But there's just one way to
learn, I suppose!
Lastly, a minor point: in the source for netdb.pp there's a comment warning
of stringfromlabel's lack of checks. Since it now has a good few checks, I
think this warning is superfluous. But I didn't want to remove it without
checking, in case there's more to it than meets the eye.
I also noticed this, but decided to leave it for the moment.
if you feel it can be removed, I'll trust your judgment on that.
Michael.
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal