summaryrefslogtreecommitdiffstats
path: root/ax25
Commit message (Collapse)AuthorAgeFilesLines
* Substitute proper paths in ax25d.conf.Ralf Baechle2015-05-264-7/+69
| | | | | | | | | | | | | Depending on the prefix configured, the default ax25d.conf file may contain incorrects paths. Generate config file using the correct sbin dir. Assume node which is not part of ax25-tools to be installed with the same prefix. Don't probe - chances are the sysadmin of a node system is going to install it after ax25-tools so we'd likely have to guess which never is a good thing. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* axwrapper: Indent with tabs instead of spaces.Ralf Baechle2015-05-251-2/+2
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Add Tomi Manninen OH2BNS's axwrapper program.Ralf Baechle2015-05-256-1/+256
| | | | | | | | | | | | | Axwrapper first creates a pipe and then forks and execs the program <server-program> with arguments given at the axwrapper command line. The argv[0] argument is mandatory; further arguments are optional. The parent process then sits and waits for any I/O to and from the user and converts any carriage return characters from the user to line feeds and any line feeds from the program to carriage returns. This is useful when starting non-AX.25-aware programs from ax25d. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* axparms: Fix harmless -Werror=format-security build error.Ralf Baechle2015-05-181-1/+1
| | | | | | | | | | | | | | | | | | | gcc -DHAVE_CONFIG_H -I. -I.. -DAX25_SYSCONFDIR=\""/usr/local/etc/ax25/"\" -DAX25_LOCALSTATEDIR=\""/usr/local/var/ax25/"\" -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -MT axparms.o -MD -MP -MF .deps/axparms.Tpo -c -o axparms.o axparms.c axparms.c: In function ‘routes’: axparms.c:142:4: error: format not a string literal and no format arguments [-Werror=format-security] printf(routebuf); ^ axparms.c: In function ‘associate’: axparms.c:189:3: warning: ignoring return value of ‘fgets’, declared with attribute warn_unused_result [-Wunused-result] fgets(buffer, 80, fp); ^ cc1: some warnings being treated as errors Makefile:570: recipe for target 'axparms.o' failed make[3]: *** [axparms.o] Error 1 Note that routebuf has been read from /procfs so should be safe. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* automake: Replace use of deprecated automake macro INCLUDES.Ralf Baechle2015-05-171-2/+2
| | | | | | | | | | | | | | | | | This fixes the automake warnings: 6pack/Makefile.am:10: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') Makefile.am:9: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') ax25/Makefile.am:26: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') hdlcutil/Makefile.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') kiss/Makefile.am:11: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') netrom/Makefile.am:28: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') rose/Makefile.am:15: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') tcpip/Makefile.am:27: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS') INCLUDES has been deprecated since automake 1.5. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* axspawn: Remove unused variable command.Ralf Baechle2015-05-071-1/+0
| | | | | | | | | | | | | gcc -DHAVE_CONFIG_H -I. -I.. -DAX25_SYSCONFDIR=\""/usr/local/etc/ax25/"\" -DAX25 _LOCALSTATEDIR=\""/usr/local/var/ax25/"\" -g -O2 -Wall -MT axspawn.o -MD -MP -MF .deps/axspawn.Tpo -c -o axspawn.o axspawn.c [...] axspawn.c:1049:7: warning: unused variable ‘command’ [-Wunused-variable] char command[1024]; ^ [...] Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Merge branch 'master' of git://git.linux-ax25.org/pub/scm/ralf/ax25-toolsRalf Baechle2015-05-0222-2214/+2206
|\ | | | | | | | | Conflicts: ax25/axspawn.c
| * axgetput: Use shifts instead of a silly table to compute bitmask.Ralf Baechle2013-06-171-3/+1
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * axgetput: Simplify do_crc() a bit.Ralf Baechle2013-06-171-2/+1
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * axgetput: Use calc_crc() to simplify CRC calculations.Ralf Baechle2013-06-171-11/+4
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * axgetput: Provide calc_crc() function to iterate over memory area.Ralf Baechle2013-06-171-0/+8
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * axgetput: Get rid of unused length argument of do_crc().Ralf Baechle2013-06-171-4/+4
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Insert space between `)' and a following `{'.Ralf Baechle2013-06-171-1/+1
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Reformat consistently. Strictly whitespace changes only.Ralf Baechle2013-06-1714-1801/+1801
| | | | | | | | | | | | | | Indentation by tabs only. Move case labels in switches are on the same level as the switch keyword. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Always have a space between if, for, switch, while and the following `('.Ralf Baechle2013-06-174-7/+7
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Remove parenthesis around arguments of return statements.Ralf Baechle2013-06-175-17/+17
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Use tabs for indentation, not spaces.Ralf Baechle2013-06-178-259/+259
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Remove useless initializations to 0 or NULL.Ralf Baechle2013-06-174-21/+21
| | | | | | | | | | | | | | They only inflate the .data section of the binary. Initializations to FALSE are still left to do. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Nuke trailing whitespace.Ralf Baechle2013-06-1719-171/+171
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Nuke trailing blank lines.Ralf Baechle2013-06-175-5/+0
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
| * Use dist_ prefix in Makefile.am rather than EXTRA_DIST where possible.Ralf Baechle2013-06-172-4/+3
| | | | | | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* | Fix typo SIOCAX25CTLCON in perror()Thomas Osterried2015-05-011-1/+1
| | | | | | | | Signed-off-by: Thomas Osterried <thomas@osterried.de>
* | Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>Thomas Osterried2015-05-011-1/+1
| | | | | | | | | | | | | | | | | | Security patch submitted by Jaroslav Skarvada <jskarvad@redhat.com> Netrom and ROSE Addresses are copied to Node. Room was enough for Netrom, but rose addresses returned by rose_ntoa() are one byte longer (a 10 bytes string plus null-termination) which lead to an buffer overflow.
* | Provide defaults for user_shell if unset.Thomas Osterried2015-05-012-2/+8
| | | | | | | | | | | | | | | | | | The user_shell config variable is optional. If not specified, /bin/bash is used. Except: if create_with_useradd is configured and there's a config file /etc/default/useradd, then it's not passed to useradd in order to let the user choose. Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>
* | Found debian wheezy useradd bug: useradd did terminates and eats 100%Thomas Osterried2015-05-011-10/+78
|/ | | | | | | | | | | | | | | | | | | cpu power, if it was called from axspawn. This could be prevented if SIGCHLD is masked. To increase security, no longer call useradd via system() but fork() and execve(). Fixed a bug when useradd failed then the login process continued anyway. Empty lines in axspawn.conf are now valid. The user_shell config variable is optional. If not specified, /bin/bash is used. Except: if create_with_useradd is configured and there's a config file /etc/default/useradd, then it's not passed to useradd in order to let him choose. Signed-off-by: Thomas Osterried <ax25@x-berg.in-berlin.de>
* Weed out all use of RCS strings.Ralf Baechle2013-06-069-42/+5
| | | | | | | Their value has always been dubious and git doesn't support them so let's get rid of the clutter. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* Convert .cvsignore files to .gitignoreRalf Baechle2013-06-042-1/+1
| | | | Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
* call setsid() only if we are not already the process group leaderThomas Osterried2011-08-181-2/+6
|
* Removed check for return value of setsid(). If it's alreadyThomas Osterried2011-08-181-3/+2
| | | | process group leader, setsid() fails.
* Fix for CVE-2011-2910: check return status of setuid(), ..Thomas Osterried2011-08-182-8/+13
|
* Consistently spell digipeater.Ralf Baechle2011-07-141-1/+1
|
* Christoph Rueckert <dk2crn> had an issue with OpenSuse 11.2.Thomas Osterried2010-03-311-3/+3
| | | | | | | | | | login -f -h <protocol> <as_user> did not work. login -h <protocol> -f <as_user> did work. Imho, OpenSUSE meessed up login's getopt()... On the other hand, we have no problems to switch the position of arguments - as long as there's not another linux demanding another position ;)
* Fix parallel installation bugs.Ralf Baechle2009-09-231-1/+1
| | | | | | | | install-exec-local hooks may be run in parallel. This may result in the attempted installation of files into directories before they have been created. Fixed by using install-exec-hook instead. Reported and axgetput-only patch by Thomas Beierlein <tb@forth-ev.de>.
* Convert spelling of Joerg Reuter's name from umlaut to oe.Ralf Baechle2009-06-271-2/+2
| | | | | In a world that is caught between ISO 8859-1, ISO 8859-15 and UTF-8 non-ASCII characters are a guaranteed mess, still.
* axgetput: Delete homegrown declarations of optarg and optind.Ralf Baechle2009-06-231-4/+1
| | | | These should be declared by unistd.h only.
* axgetput: Remove homegrown 'extern int errno' declaration.Ralf Baechle2009-06-231-2/+1
| | | | <errno.h> is the way to go.
* Remove use of backwards compatibility header name.Ralf Baechle2009-06-218-70/+2
| | | | | | Glibc as old as 2.2 provides working headers under the right name and if not libax25 would install headers under the right name so this has become redundant and ugly.
* Ignore a few more generated files.Ralf Baechle2009-06-192-0/+2
|
* Remove all generated files.Ralf Baechle2009-06-192-1303/+0
| | | | | | | | | | | | | | Keeping generated files in CVS doesn't only tend to produce large and cluttered files it also may result in build problems due to timestamps in the wrong order. So dump everything, update .cvsignore to ignore these files and resolve all warnings generated by autoreconf. From now on users of a CVS checkout should run the command autoreconf --install --force after having done a CVS checkout. For this to succeed automake, autoconf and libtool will have to be installed.
* Fix type of length argument to sockset syscalls.Ralf Baechle2009-06-144-9/+12
| | | | | | | | Various socket syscalls receive a length argument that should be a socklen_t rsp. a ptr to a socklen_t but instead int rsp. ptr to int were being passed. While in theory this was a bug it's harmless as dangerously large values would not be used but the issue manifested itself in a significant number of compilation warnings.
* Fix utmp time codeRalf Baechle2009-06-141-4/+10
| | | | | | | | | | | | | | | | | | | Thanks to using the antiquated time(2) call the microsecond field of the struct utmp being manipulated was never initialized resulting in random values. On some 64-bit systems this also manifested itself in below warnings. axspawn.c: In function ‘cleanup’: axspawn.c:1017: warning: passing argument 1 of ‘time’ from incompatible pointer type /usr/include/time.h:186: note: expected ‘time_t *’ but argument is of type ‘int32_t *’ [...] axspawn.c: In function ‘main’: [...] axspawn.c:1693: warning: passing argument 1 of ‘time’ from incompatible pointer type /usr/include/time.h:186: note: expected ‘time_t *’ but argument is of type ‘int32_t *’ Fixed by changing it to the recommended initialization sequenze based on gettimeofday().
* Convert K&R-style function definitions to function prototypes.Ralf Baechle2009-06-142-7/+7
|
* fixThomas Osterried2009-02-121-1/+1
|
* escape fixThomas Osterried2009-02-121-1/+1
|
* time_t for file_timeThomas Osterried2009-01-221-3/+3
|
* made proto_bin compatible to call(1) ~a upload.Thomas Osterried2009-01-221-15/+25
|
* completed docuThomas Osterried2008-11-211-1/+2
|
* important security fix:Thomas Osterried2008-11-211-9/+18
| | | | char addr[20] was static and strcpy(addr,.argv[n]) of variable length..
* bugfix: write_ax25(line, ..) segfaultet if line is static char[].Thomas Osterried2008-11-081-6/+14
|
* fix: strncpy(ut.ut_id, tty + 3, sizeof(ut.ut_id)); // was ↵Thomas Osterried2008-10-221-2/+2
| | | | sizeof(ut.ut_line) with size = 12, wheras ut_id is 4.