--- loncom/auth/lonracc.pm 2007/03/02 23:17:48 1.21 +++ loncom/auth/lonracc.pm 2007/03/02 23:43:29 1.22 @@ -1,7 +1,7 @@ # The LearningOnline Network # Access Handler for File Transfers # -# $Id: lonracc.pm,v 1.21 2007/03/02 23:17:48 albertel Exp $ +# $Id: lonracc.pm,v 1.22 2007/03/02 23:43:29 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -65,9 +65,8 @@ sub handler { } my $reqhost = $r->get_remote_host(REMOTE_NOLOOKUP); - my %iphost=&Apache::lonnet::get_iphost(); - my $hostids=$iphost{$reqhost}; - if (!$hostids && $reqhost ne '127.0.0.1' ) { + my @hostids= &Apache::lonnet::get_hosts_from_ip($reqhost); + if (!@hostids && $reqhost ne '127.0.0.1' ) { $r->log_reason("Unable to find a host for ". $r->get_remote_host(REMOTE_NOLOOKUP)); return FORBIDDEN; @@ -78,7 +77,7 @@ sub handler { my $return; my @ids; - foreach my $id (@{$hostids}) { + foreach my $id (@hostids) { my $uri =$r->uri; if (($filename=~/\.meta$/) || ($uri=~m|^/raw/uploaded|) ||