Commit graph

259 commits

Author SHA1 Message Date
H. Peter Anvin
920b99dfee Update version for release 0.49 2008-10-20 15:08:31 -07:00
H. Peter Anvin
4f715da294 Update CHANGES 2008-10-20 15:07:59 -07:00
Роман Донченко
ac5f0ab996 Compilation of tftp-hpa's Git HEAD with no IPv6, and misc
This patch does two things:
a) makes tftp-hpa to compile on systems with no IPv6 support (there were
some IPv6 macros used unconditionally);
b) removes a stray binary character, which was annoying.
2008-10-20 15:06:24 -07:00
H. Peter Anvin
a1dfd6baf8 Support editline instead of readline
Support editline as an alternative to readline.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-08-09 21:14:45 -07:00
Sridhar Samudrala
740871b0f5 Fix numeric IPv6 address handling
The following patch sets additional hints to restrict the addresses
returned by getaddrinfo() to specify preferred socket type, protocol
and a flag to return only v4/v6 addresses based on the configured
addresses.

Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-08-09 20:58:19 -07:00
Karsten Keil
544abd789e Add error messages if address types mismatch
If a user does supply a IPv4 or IPv6 address
but force the other type with -4 or -6, give an error.
The patch also fix the special [::ffff:127.0.1]
address handling, it work now if you bind to this
address but only if you not force IPv6 only, it seems
that the kernel does not signal connections to a
IPv6 socket listen on [::ffff:127.0.0.1], if it was bound
IPv6 only.
I think we can live with it and do not need a special test
for this address.

Signed-off-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-08-01 08:24:16 -07:00
Karsten Keil
18fd18bd5c Improve address type error handling
This patch detects numeric address types to avoid unnecessary
warnings/errors.  It also cleans up error printing to not print error
messages on stderr in the deamon case.

Signed-off-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-31 11:48:18 -07:00
H. Peter Anvin
bdb90cf176 Add .gitignore file
Add .gitignore file so "git status" is actually useful.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 17:18:17 -07:00
H. Peter Anvin
e4d3083006 tftpd: switch to getopt_long()
Switch to using getopt_long(); include a version in case the platform
lacks it.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 17:16:00 -07:00
H. Peter Anvin
77fbfeebee Implement is_numeric_ipv6() as a state machine
Implement is_numeric_ipv6() as a state machine, so we can avoid
in-place modification.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 16:34:44 -07:00
H. Peter Anvin
0c6f7f86d3 tftpd: mark symbols static
Mark symbols not accessed from other files static.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 16:17:02 -07:00
H. Peter Anvin
7670c83e5a release.sh: remove Cogito
Remove Cogito use in favour of plain git; make sure the index is
clean.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 15:36:46 -07:00
Karsten Keil
cfb85d4dec Fix numeric IPv6 address handling
This patch fix a issue with numeric IPv6 addresses in the
tftpd -a address[:port] option.

Since IPv6 addresses use colon ':' in differnt counts itself, we cannot detect,
if the last colon is a seperator, so it is needed to put the IPv6 address into
square brackets, e.g. [2001:db8::1], so a optional port assignment is
unambiguous.
The patch also allows to specify numeric IPv6 addresses in other places enclosed
in [], but in these cases it accept these also without [].

Signed-off-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-30 15:20:31 -07:00
H. Peter Anvin
c3a5c712e2 Allow the -4 option even in an IPv4-only configuration
Allow the -4 option even if IPv6 isn't compiled in.
2008-07-23 14:36:18 -04:00
H. Peter Anvin
4bdac0b536 Document changes for 0.49 2008-07-23 14:31:48 -04:00
Karsten Keil
28f22b6591 Add support for IPv6 in the server and client.
Add support for IPv6 in the server and client.
You can force the use of IPv4 or IPv6 only with new
-4 and -6 commandline options, if IPv6 support was compiled in.

Signed-off-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-23 14:29:41 -04:00
Karsten Keil
7fe0fb941c IPv6 infrastructure support
Add autoconf rules to detect IPv6 availability and some of the neeeded
support functions. Add stubs for getaddrinfo and inet_ntop.
You can disable IPv6 at compile time with
./configure --without-ipv6

Signed-off-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-23 14:24:19 -04:00
H. Peter Anvin
57ca281980 Remove more obsolete $Id$ tags
Additional $Id$ tags from the CVS era...
2008-07-22 15:07:24 -04:00
H. Peter Anvin
40e20cc4a5 Remove workaround for autoconf 2.52
Remove obsolete workaround for autoconf 2.52 -- we don't support that
version of autoconf anymore.
2008-07-22 14:53:30 -04:00
H. Peter Anvin
3e7043c50f Define DATAROOTDIR in MCONFIG.in to shut up autoconf
Shut up autoconf warning by defining DATAROOTDIR in MCONFIG.in.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2008-07-22 14:44:40 -04:00
H. Peter Anvin
50f22a7ad2 Remove long since obsolete ID tags 2008-07-08 17:30:27 -04:00
H. Peter Anvin
9f83475779 Formatting cleanup 2008-07-08 17:26:18 -04:00
H. Peter Anvin
cd22c6ea31 Formatting cleanup
Clean up line break
2008-07-08 17:24:11 -04:00
H. Peter Anvin
22accddda0 Reformat the source code
The source code was a mix of different styles; normalize on NASM
style; basically K&R style with 4 space indentation.
2008-07-08 17:14:44 -04:00
H. Peter Anvin
62533e7441 AC_USE_SYSTEM_EXTENSIONS is a 2.61 feature, not 2.59 2007-12-10 17:37:52 -08:00
H. Peter Anvin
bbb17208a9 Use autoconf features to deal with feature-test macros. 2007-10-03 17:41:38 -07:00
H. Peter Anvin
80f86e5a04 Get rid of $Id$ tags and update copyright dates 2007-01-30 16:01:24 -08:00
H. Peter Anvin
1f57b0edd5 Update version for release 2007-01-30 15:51:04 -08:00
H. Peter Anvin
0eacf8823f Document fixing -l -s. 2007-01-30 15:51:00 -08:00
H. Peter Anvin
c7ecc59f86 When running in secure mode (-s), we must not chdir while daemonizing
When running in secure mode (-s), we must not chdir while daemonizing.
Thanks to Adrian Urquhart for spotting this bug.
2007-01-30 15:38:04 -08:00
H. Peter Anvin
077eac1fd6 Update version for release 2007-01-27 11:11:27 -08:00
H. Peter Anvin
ecf79bc97f Document user-visible changes 2007-01-27 11:11:22 -08:00
H. Peter Anvin
d15a61abe6 Prototype cleanup; use "config.h" where appropriate 2007-01-15 01:20:41 -08:00
H. Peter Anvin
d9938a7d83 Add -L option to not daemonize process 2007-01-15 01:12:52 -08:00
H. Peter Anvin
059de7ce20 Use replacement library functions to daemonize, rather than #ifdef hell 2007-01-15 01:11:26 -08:00
Mike Frysinger
6124dcbe2d [patch] fix parallel building of tftp-hpa
if you try to build tftp-hpa in parallel, it may fail as the tftp and tftpd
subdirs may try to link before the libcommon.a has a chance to be generated
in the common subdir

trivial patch attached to address this
-mike
2007-01-13 10:24:27 -08:00
H. Peter Anvin
0db17eedd3 Update version for release 2007-01-08 16:54:29 -08:00
H. Peter Anvin
625002c097 Document changes 2007-01-08 16:54:17 -08:00
H. Peter Anvin
2b36598746 When specifying includes, need to specify ALL includes
It seems that overriding the default includes overrides ALL includes;
so we need to specify them all.  Sigh.
2007-01-08 16:53:19 -08:00
H. Peter Anvin
4d02d827fb Make sure we include <sys/socket.h> when checking for socklen_t
socklen_t is often only defined when <sys/socket.h> is included, but this
is not autoconf default; make sure we include it first.
2007-01-08 16:48:46 -08:00
H. Peter Anvin
982c1f2697 printf() and htonl() type matching issue
On older systems, htonl() returns unsigned long, on newer systems it
returns uint32_t.  Cast to unsigned long and use %08lX for the format,
that seems to be the easiest solution.
2007-01-08 16:30:10 -08:00
H. Peter Anvin
ab12c128ff Update version for release 2006-12-12 14:38:27 -08:00
H. Peter Anvin
df877df452 Documentation updates. 2006-12-12 14:37:27 -08:00
Craig Johnston
899b7d500b Add option to TFTP client to ignore ':' in file name
I have encountered a situation where I would like to use tftp-hpa to
retrieve a file that resides within an absolute path containing a ':'
character.  Ala, "tftp foobar -c get C:2/tftpdir/myfile".  Since the
tftp client automatically converts the host:file syntax, I get an
error "tftp: C: Unknown host".

I made a chage to the tftp client code to add a literal mode (-l),
that prevents the special treatment of the ':' character.  I've
attached a patch set for main.c and tftp.1.in for your consideration.
I'm not sure how many folks run into this, but it may be somewhat
common for VxWorks and perhaps MSDOS users.

Thanks,
Craig Johnston
2006-12-12 14:31:51 -08:00
H. Peter Anvin
e031e3bc9a Update version for release 2006-12-05 14:39:40 -08:00
H. Peter Anvin
7390c7ceca Update list of changes for 0.44. 2006-12-05 14:39:28 -08:00
Dyks, Axel (XL)
1cb44ce918 tftp-hpa does not reload the remap file when receiving SIGHUP
... because the signal handling code is enclosed in "#ifdef HAVE_REGEX"
instead of "#ifdef WITH_REGEX"

The following patch against head of "network/tftp/tftp-hap.git" on "kernel.org"
fixes this issues (you are using blanks for indention and not tabs. right?).

Cheers
Axel
2006-12-05 14:36:32 -08:00
H. Peter Anvin
ad475989a5 Document changes 2006-11-13 20:54:07 -08:00
Zack Bartel
ec5973ac5f Moved pick_port_bind() to the libcommon common code so both client and server can use it. Client can now specify a range of ephemeral ports (transaction id) 2006-11-13 17:33:29 -08:00
H. Peter Anvin
5f64014add Document 0.43 changes 2006-10-05 14:22:35 -07:00