for (keys %ENV) { print "$_ = $ENV{$_}\n"; } # eg - for remote IP, use $ENV{'REMOTE_ADDR'}