summaryrefslogtreecommitdiffstats
path: root/libexec/tftp-proxy/tftp-proxy.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* remove libexec/tftp-proxy now we have usr.sbin/tftp-proxydlg2012-08-301-335/+0
| | | | ok deraadt@
* tweak tftp-proxy to:dlg2011-09-281-62/+57
| | | | | | | | | | | | | | | | | | | | | | | 1. use a BINDANY socket to connect from the proxy to the server using the clients address. 2. fork a child to do the work so inetd doesnt keep trying to send more packets to the proxy, as per doco in the inetd manpage for dgram wait sockets. because of 1 you now have to add a pass out divert-reply for the proxy to server packet to your pf ruleset. this allows a series of rapid tftp connections from the same host to a server in my environment. without this diff there's several minutes of waiting in between requests because of issues with the rules from previous requests stealing packets but not forwarding them combined with inetd giving too many packets to tftp-proxy that only expects to handle one. this is going in so i can hack on PFRULE_ONCE support. ok mikeb@ sthen@
* Switch tftp-proxy over to using divert-to. Based on a diff from oga@sthen2011-05-051-76/+21
| | | | | | | | | | | | with lots of help from claudio@. Earlier version was ok mikeb@ and looks good to markus@. Note: tftp-proxy rdr-to rules must be changed to use divert-to and must specify the address family. pass in quick on internal proto udp to port tftp rdr-to 127.0.0.1 port 6969 -changes to- pass in quick on internal inet proto udp to port tftp divert-to 127.0.0.1 port 6969
* Use arc4random_buf() when requesting more than a single word of outputdjm2008-04-131-3/+3
| | | | | | | Use arc4random_uniform() when the desired random number upper bound is not a power of two ok deraadt@ millert@
* msg_controllen has to be CMSG_SPACE so that the kernel can account forderaadt2008-03-241-2/+2
| | | | | | | each cmsg_len (ie. msg_controllen = sum of CMSG_ALIGN(cmsg_len). This works now that kernel fd passing has been fixed to accept a bit of sloppiness because of this ABI repair. lots of discussion with kettenis
* Repair more msg_controllen dealing with structures or arrays ofderaadt2008-03-151-2/+2
| | | | descriptors; ok hshoexer, also looked at by kettenis and henning
* Correct CMSG_SPACE and CMSG_LEN usage everywhere in the tree. Due toderaadt2008-03-131-5/+7
| | | | an extensive discussion with otto, kettenis, millert, and hshoexer
* add an additional rule to the filter anchor that allows traffic out fromjoel2006-12-201-1/+8
| | | | | | | the server to the client. this is necessary in case the server is not otherwise allowed to talk to the client. ok jcs@
* import tftp-proxy 1.6, a tftp helper for pfjcs2005-12-281-0/+386
ok jolan@, msf@, millert@ man page help from jmc@