&pipethrough_prep &pipethrough_run
&pipethrough_run_along &pipethrough_run_finish
&pipethrough_run_gzip
- &cgipostform &yarrgpostform);
+ &cgipostform &yarrgpostform &cgi_get_caller);
%EXPORT_TAGS = ( );
@EXPORT_OK = qw();
chomp($version);
$aref->{"${prefix}version"}= $version;
return $aref;
+ # clientname "ypp-sc-tools"
+ # clientversion 2.1-g2e06a26 [from git-describe --tags HEAD]
+ # clientfixes "lastpage" [space separated list]
}
sub pipethrough_prep () {
return @v;
}
+sub cgi_get_caller () {
+ my $caller= $ENV{'REMOTE_ADDR'};
+ $caller= 'LOCAL' unless defined $caller;
+
+ my $fwdf= $ENV{'HTTP_X_FORWARDED_FOR'};
+ if (defined $fwdf) {
+ $fwdf =~ s/\s//g;
+ $fwdf =~ s/[^0-9.,]/?/g;
+ $caller= "$fwdf";
+ }
+ return $caller;
+}
+
1;