<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/libexec/tftpd, branch releng/12.2</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=releng%2F12.2</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=releng%2F12.2'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2019-12-19T04:58:11Z</updated>
<entry>
<title>Add Makefile.depend.options</title>
<updated>2019-12-19T04:58:11Z</updated>
<author>
<name>Simon J. Gerraty</name>
<email>sjg@FreeBSD.org</email>
</author>
<published>2019-12-19T04:58:11Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=387f2740cab1168555efc6076159d2a66f018a58'/>
<id>urn:sha1:387f2740cab1168555efc6076159d2a66f018a58</id>
<content type='text'>
Leaf directories that have dependencies impacted
by options need a Makefile.depend.options file
to avoid churn in Makefile.depend

DIRDEPS for cases such as OPENSSL, TCP_WRAPPERS etc
can be set in local.dirdeps-options.mk
which can add to those set in Makefile.depend.options

See share/mk/dirdeps-options.mk

Also update affected Makefile.depend files.

MFC of r355616 and r355617

Reviewed by:	 bdrewery
Sponsored by:   Juniper Networks
Differential Revision:  https://reviews.freebsd.org/D22469
</content>
</entry>
<entry>
<title>MFC r345034:</title>
<updated>2019-05-31T16:20:00Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2019-05-31T16:20:00Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=3f0dcb331e116f3f172a74554c5f913ea022683d'/>
<id>urn:sha1:3f0dcb331e116f3f172a74554c5f913ea022683d</id>
<content type='text'>
Drop "All rights reserved" from the files I own

Also, add SPDX tags where needed.
</content>
</entry>
<entry>
<title>tftpd: Fix data corruption bug with netascii</title>
<updated>2018-08-22T23:31:27Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-08-22T23:31:27Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=76e8e459e49f02d7423a25472b9a5694394d35b9'/>
<id>urn:sha1:76e8e459e49f02d7423a25472b9a5694394d35b9</id>
<content type='text'>
Transferring files in netascii format requires, among other things,
translating all CR characters to a CR,NUL pair. tftpd does this correctly
except when the CR occurs as the last octet of a packet. In that case, it
erroneously drops the NUL which should be part of the following packet. The
bug was caused by using 0 as a sentinel value in a variable that could
legitimately hold 0. Fix it by switching the sentinel value to -1.

PR:		178055
Reported by:	Richard &lt;rsitze@gmail.com&gt;
Reviewed by:	cem
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D16853
</content>
</entry>
<entry>
<title>Fix several Coverity warnings in tftp</title>
<updated>2018-07-22T17:10:12Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-07-22T17:10:12Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ca2d3691c3430908847f44f1b2198b5c5298fac5'/>
<id>urn:sha1:ca2d3691c3430908847f44f1b2198b5c5298fac5</id>
<content type='text'>
Some of the changes are in the libexec/tftpd directory, but to functions that
are only used by tftp(1) (they share some code).

* strcpy =&gt; strlcpy (1006793, 1006794, 1006796, 1006741)
* Unchecked return value and TOCTTOU (1009314)
* NULL pointer dereference (1018035, 1018036)

Reported by:	Coverity
CID:		1006793, 1006794, 1006796, 1006741, 1009314, 1018035
CID:		1018036
MFC after:	2 weeks
</content>
</entry>
<entry>
<title>Fix multiple Coverity warnings in tftpd(8)</title>
<updated>2018-07-22T16:14:30Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-07-22T16:14:30Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=3c0fa265346ec04fc8277fba9c3fe28d1e26068a'/>
<id>urn:sha1:3c0fa265346ec04fc8277fba9c3fe28d1e26068a</id>
<content type='text'>
* Initialize uninitialized variable (CID 1006502)
* strcpy =&gt; strlcpy (CID 1006792, 1006791, 1006790)
* Check function return values (CID 1009442, 1009441, 1009440)
* Delete dead code in receive_packet (not reported by Coverity)
* Remove redundant alarm(3) in receive_packet (not reported by Coverity)

Reported by:	Coverity
CID: 1006502, 1006792, 1006791, 1006790, 1009442, 1009441, 1009440
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D11287
</content>
</entry>
<entry>
<title>tftpd(8): when completing an WRQ, flush the file before acknowleding receipt</title>
<updated>2018-07-21T19:48:31Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-07-21T19:48:31Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7378015b694df3fbbc8cf51fe5ed352701f20e01'/>
<id>urn:sha1:7378015b694df3fbbc8cf51fe5ed352701f20e01</id>
<content type='text'>
tftpd(8) should flush a newly written file to disk before ACKing the final DATA
packet.  Otherwise there is a narrow race window when a subsequent read may not
see the file.  This is somewhat related to r330710, but the race window is much
smaller.  Hopefully this will fix the intermittent tests in Jenkins.

Reported by:	Jenkins
MFC after:	2 weeks
</content>
</entry>
<entry>
<title>tftpd: misc Coverity cleanup in the tests</title>
<updated>2018-03-22T14:51:05Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-03-22T14:51:05Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ad5c8bd63ad4d1afc3238adbefd94253b9111da9'/>
<id>urn:sha1:ad5c8bd63ad4d1afc3238adbefd94253b9111da9</id>
<content type='text'>
A bunch of unchecked return values from open(2) and read(2)

Reported by:	Coverity
CID:		1386900, 1386911, 1386926, 1386928, 1386932, 1386942
CID:		1386961, 1386979
MFC after:	8 days
X-MFC-With:	330696
</content>
</entry>
<entry>
<title>tftpd: fix the build of tests on i386 after 330696</title>
<updated>2018-03-10T18:07:31Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-03-10T18:07:31Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=f270fabc2ba3bd482d025c2e549704a97101a09e'/>
<id>urn:sha1:f270fabc2ba3bd482d025c2e549704a97101a09e</id>
<content type='text'>
It's those darn printf format specifiers again

Reported by:	cy, kibab
MFC after:	20 days
X-MFC-With:	330696
</content>
</entry>
<entry>
<title>tftpd: reject unknown opcodes</title>
<updated>2018-03-10T01:50:43Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-03-10T01:50:43Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=6301d64774c9c58ec727f2386e0f49d0c676305a'/>
<id>urn:sha1:6301d64774c9c58ec727f2386e0f49d0c676305a</id>
<content type='text'>
If tftpd receives a command with an unknown opcode, it simply exits 1.  It
doesn't send an ERROR packet, and the client will hang waiting for one.  Fix
it.

PR:		226005
MFC after:	3 weeks
</content>
</entry>
<entry>
<title>tftpd: Abort on an WRQ access violation</title>
<updated>2018-03-10T01:43:55Z</updated>
<author>
<name>Alan Somers</name>
<email>asomers@FreeBSD.org</email>
</author>
<published>2018-03-10T01:43:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=b7da179e961d961c70c64f799a29486e39fbb695'/>
<id>urn:sha1:b7da179e961d961c70c64f799a29486e39fbb695</id>
<content type='text'>
On a WRQ (write request) tftpd checks whether the client has access
permission for the file in question.  If not, then the write is prevented.
However, tftpd doesn't reply with an ERROR packet, nor does it abort.
Instead, it tries to receive the packet anyway.

The symptom is slightly different depending on the nature of the error.  If
the target file is nonexistent and tftpd lacks permission to create it, then
tftpd will willingly receive the file, but not write it anywhere.  If the
file exists but is not writable, then tftpd will fail to ACK to WRQ.

PR:		225996
MFC after:	3 weeks
</content>
</entry>
</feed>
