]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r330719:
authorasomers <asomers@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 3 Aug 2018 14:19:09 +0000 (14:19 +0000)
committerasomers <asomers@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 3 Aug 2018 14:19:09 +0000 (14:19 +0000)
commit799edf0ad8af9f553b3d9ff319459f310e97bd35
tree4550c2c2c6823add0d6e6b81effb7f6adee3f57e
parent456a9f9905482a27479a30e2fe48b7447402ff43
MFC r330719:

tftpd: Abort on an WRQ access violation

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

git-svn-id: svn://svn.freebsd.org/base/stable/10@337249 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
libexec/tftpd/tests/functional.c
libexec/tftpd/tftpd.c