Welcome Guest | Login

500 Error - IP Spoofing attack?!

I just deployed the app.  It is working fine from my computer and at least one computer off-site.  However, one person is getting 500 error.  I checked the logs and found a few of the following - any ideas?:


/!\ FAILSAFE /!\  Fri Aug 08 18:11:33 -0500 2008
 Status: 500 Internal Server Error
 IP spoofing attack?!
HTTP_CLIENT_IP="15.255.147.8"
HTTP_X_FORWARDED_FOR="15.251.201.71"

   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/request.rb:146:in `remote_ip'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/base.rb:1223:in `request_origin'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/base.rb:1150:in `log_processing'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/base.rb:528:in `process_without_filters'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/filters.rb:569:in `process_without_session_management_support'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/session_management.rb:130:in `process'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/base.rb:389:in `process'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:149:in `handle_request'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:107:in `dispatch'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:104:in `synchronize'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:104:in `dispatch'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:120:in `dispatch_cgi'
   /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.1.0/lib/action_controller/dispatcher.rb:35:in `dispatch'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/rails.rb:76:in `process'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/rails.rb:74:in `synchronize'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/rails.rb:74:in `process'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:159:in `process_client'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:158:in `each'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:158:in `process_client'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:285:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:285:in `initialize'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:285:in `new'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:285:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:268:in `initialize'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:268:in `new'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel.rb:268:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/configurator.rb:282:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/configurator.rb:281:in `each'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/configurator.rb:281:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/mongrel_rails:128:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/../lib/mongrel/command.rb:212:in `run'
   /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.4/bin/mongrel_rails:281
   /usr/local/bin/mongrel_rails:19:in `load'
   /usr/local/bin/mongrel_rails:19

2008-08-08 07:13 PM

The following link will provide more information about this error and a possible solution.

http://www.ruby-forum.com/topic/154836

2008-08-08 07:39 PM

Rails 2.1.1 includes this patch, but it didn't seem do it for me.  It looks like the best current fix is described at http://iprog.com/posting/2008/08/rails_500_error_ip_spoofing_attack .

I tried adding RequestHeader unset Client-IP to .htaccess but it didn't work.

Are mod_headers enabled?

2008-09-18 02:59 PM

Yes, the apache module mod_headers is enabled on the server.

2008-09-18 03:40 PM

Any idea why "RequestHeader unset Client-IP" in .htaccess doesn't remove the header?

2008-09-18 03:50 PM

Probably the issue might get fixed by adding the line directly in the domain's vhost entry. For this could you please contact our support team with the exact URL for which the issue is persisting.

2008-09-18 09:05 PM

vhost entry did it.

2008-09-19 02:45 PM


Hello Guest! In order to post you must be an active client with us, please log in or sign up.