Changeset 1281
- Timestamp:
- 24/08/07 09:09:32 (4 years ago)
- Files:
-
- trunk/Makefile (modified) (1 diff)
- trunk/Makefile.config-dist (modified) (1 diff)
- trunk/Makefile.config-maint (modified) (1 diff)
- trunk/node/munin-node.in (modified) (2 diffs)
- trunk/node/munin-run.in (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/Makefile
r1205 r1281 245 245 -e 's|@@GOODSH@@|$(GOODSH)|g' \ 246 246 -e 's|@@BASH@@|$(BASH)|g' \ 247 -e 's|@@HASSETR@@|$(HASSETR)|g' \ 247 248 $$file > build/$$destname; \ 248 249 done trunk/Makefile.config-dist
r1194 r1281 100 100 CHMOD = chmod 101 101 CHGRP = chgrp 102 103 # Check whether setruid functionality can be used 104 HASSETR = $(shell perl -e 'use Config; my @vars=("d_setruid", "d_setreuid", "d_setresuid"); foreach my $$var (@vars) { if ($$Config{$$var} eq "define") { print "1\n"; exit 0; } } print "0\n"; exit 0;' ) 105 trunk/Makefile.config-maint
r1194 r1281 94 94 CHMOD = chmod 95 95 CHGRP = chgrp 96 97 # Check whether setruid functionality can be used 98 HASSETR = $(shell perl -e 'use Config; my @vars=("d_setruid", "d_setreuid", "d_setresuid"); foreach my $$var (@vars) { if ($$Config{$$var} eq "define") { print "1\n"; exit 0; } } print "0\n"; exit 0;' ) trunk/node/munin-node.in
r1198 r1281 28 28 use Getopt::Long; 29 29 use Net::Server::Fork; # any personality will do 30 31 # Variable is set at build, with values detected by the makefiles 32 my $HAS_SETR = @@HASSETR@@; 30 33 31 34 my $tls; … … 459 462 # net_write ("# Want to run as euid/egid $u/$g\n") if $DEBUG; 460 463 461 $( = $g unless $g == 0; 464 if ($HAS_SETR) 465 { 466 $( = $g unless $g == 0; 467 $< = $u unless $u == 0; 468 } 462 469 $) = $gs unless $g == 0; 463 $< = $u unless $u == 0;464 470 $> = $u unless $u == 0; 465 471 trunk/node/munin-run.in
r1198 r1281 24 24 use vars qw(@ISA); 25 25 use Getopt::Long; 26 27 # Variable is set at build, with values detected by the makefiles 28 my $HAS_SETR = @@HASSETR@@; 26 29 27 30 # "Clean" environment to disable taint-checking on the environment. We _know_ … … 355 358 print "# Want to run as euid/egid $u/$g\n" if $DEBUG; 356 359 357 $( = $g unless $g == 0; 360 if ($HAS_SETR) 361 { 362 $( = $g unless $g == 0; 363 $< = $u unless $u == 0; 364 } 358 365 $) = $gs unless $g == 0; 359 $< = $u unless $u == 0;360 366 $> = $u unless $u == 0; 361 367
