]>
git.neil.brown.name Git - portmap.git/log
summary |
shortlog | log |
commit |
commitdiff |
tree
first ⋅ prev ⋅ next
Neil Brown [Fri, 20 Apr 2007 02:42:49 +0000 (12:42 +1000)]
Store mapping table in a file.
Thus we can restore it if killed and restarted.
Neil Brown [Fri, 20 Apr 2007 02:42:48 +0000 (12:42 +1000)]
Improve protection against unapproved service deletion.
If a privilege port was used to register a service, then a privileged
port must be used to unregister it.
This allows system services (statd/lockd/mountd) to safely register
non-privileged ports.
This is good because they don't really need privileged ports, and
using privileged ports when not needed is a waste of scarce recourses.
Neil Brown [Fri, 20 Apr 2007 02:42:46 +0000 (12:42 +1000)]
Remove setsid references.
They aren't used so....
Neil Brown [Fri, 20 Apr 2007 02:42:45 +0000 (12:42 +1000)]
Remove all 'register' variable attributes.
Neil Brown [Fri, 20 Apr 2007 02:42:36 +0000 (12:42 +1000)]
Simple 'install' Makefile target
Copies from Debian (but without /usr/share/doc/portmap stuff).
Neil Brown [Fri, 20 Apr 2007 02:42:35 +0000 (12:42 +1000)]
Man page updates.
Document -l option from Fedora, and general cosmetic improvements.
Neil Brown [Fri, 20 Apr 2007 02:42:34 +0000 (12:42 +1000)]
Add man pages from Debian
Neil Brown [Fri, 20 Apr 2007 02:42:33 +0000 (12:42 +1000)]
Add -f option
diff --git a/portmap.c b/portmap.c
index
a5008c5 ..
e6ee5f6 100644
Neil Brown [Fri, 20 Apr 2007 02:42:33 +0000 (12:42 +1000)]
Add -i/-l option to bind to a local address.
e.g. to bind to 127.0.0.1
-i address is from Debian
-l is from Fedora and means "-i 127.0.0.1"
Neil Brown [Fri, 20 Apr 2007 02:42:32 +0000 (12:42 +1000)]
Add -t option for chroot.
From debian.
Neil Brown [Fri, 20 Apr 2007 02:42:31 +0000 (12:42 +1000)]
Default to -O2
And make it easy to override the optimisation level e.g.
RPM_OPT_FLAGS=-Os make
Neil Brown [Fri, 20 Apr 2007 02:42:30 +0000 (12:42 +1000)]
Compile portmap with -pie
This is from SuSE/Fedora. I think it makes address space
randomisation work.
I don't know what 'visibility "hidden"' is all about..
Neil Brown [Fri, 20 Apr 2007 02:42:29 +0000 (12:42 +1000)]
Remove get_myaddress
Just use INADDR_LOOPBACK for pmap_dump.
glibc already uses the loopback interface for pmap_set, pmap_unset.
Neil Brown [Fri, 20 Apr 2007 02:42:29 +0000 (12:42 +1000)]
drop priv groups as well as uid.
This isn't really needed as no file access is done,
but Debian does it so...
Neil Brown [Fri, 20 Apr 2007 02:42:20 +0000 (12:42 +1000)]
sscanf safety.
Don't scanf unlimited strings: set a limit of 255 chars.
Neil Brown [Fri, 20 Apr 2007 02:42:08 +0000 (12:42 +1000)]
Signal handling fixes.
Ignore sigchld and sigpipe.
And as reap is now not used, don't compile it.
Neil Brown [Fri, 20 Apr 2007 02:42:07 +0000 (12:42 +1000)]
syslog fixes
Use LOG_DAEMON rather than LOG_MAIL, and add LOG_NDELAY.
Fedora Likes LOG_AUTH
SuSE Likes LOG_AUTH
Debian Likes LOG_DAEMON
I prefer LOG_DAEMON.
Alexander Achenbach [Fri, 20 Apr 2007 02:42:06 +0000 (12:42 +1000)]
Protect errno inside signal handler.
From: Alexander Achenbach <xela@slit.de>
If a signal handler modifies errno at random times,
other code can be badly confused. So in 'reap', save
and restore it.
(From debian)
Neil Brown [Fri, 20 Apr 2007 02:42:05 +0000 (12:42 +1000)]
Correct typo in error message: udp -> tcp
Neil Brown [Fri, 20 Apr 2007 02:42:03 +0000 (12:42 +1000)]
Clean up more warnings.
Add -Wall -Wstrict-prototypes and clean up associated
warnings.
Neil Brown [Fri, 20 Apr 2007 02:41:38 +0000 (12:41 +1000)]
Makefile fixes for clean compile.
Remove old stuff from Makefile, and remove daemon.c and strerror.c
as they really aren't needed.
Now get a clean compile.
Neil Brown [Fri, 20 Apr 2007 02:41:38 +0000 (12:41 +1000)]
Add some missing #includes
to remove more compile warning.
Neil Brown [Fri, 20 Apr 2007 02:41:37 +0000 (12:41 +1000)]
Add lots of needed type-casts.
This removes a lot of noisy warnings so that real bugs might become visible.
Neil Brown [Fri, 20 Apr 2007 02:41:29 +0000 (12:41 +1000)]
Remove #define of perror.
Original code defined a new perror to send error messages via
syslog so that perror calls in the rpc library would be redefined as well,
and the had -Dperror=xperror in the Makefile to override this.
Debian and Fedora just removed the "-Dperror=.."
SuSE fixed up problems by adding some more "#undef perror".
I have taken the Debian/Fedora approach and tidied up related bits of code.
Neil Brown [Fri, 20 Apr 2007 00:35:59 +0000 (10:35 +1000)]
Initial checkin of portmap_beta5
Both the current Debian and SuSE distros have identical .tar.gz
containing these files.