]> git.netwichtig.de Git - user/henk/code/ruby/rbot.git/blobdiff - lib/rbot/httputil.rb
Fri Jul 29 13:07:56 BST 2005 Tom Gilbert <tom@linuxbrit.co.uk>
[user/henk/code/ruby/rbot.git] / lib / rbot / httputil.rb
index ff3216a6bd62df9efac78d3bb2ff5cf276792a9c..85b56be48ba348dfefd07c4b0dda27a7f604bff5 100644 (file)
@@ -25,17 +25,19 @@ class HttpUtil
     if (ENV['http_proxy'])
       proxy = URI.parse ENV['http_proxy']
     end
-    if (@bot.config["http_proxy"])
+    if (@bot.config["http.proxy"])
       proxy = URI.parse ENV['http_proxy']
     end
 
     # if http_proxy_include or http_proxy_exclude are set, then examine the
     # uri to see if this is a proxied uri
+    # the excludes are a list of regexps, and each regexp is checked against
+    # the server name, and its IP addresses
     if uri
-      if @bot.config["http_proxy_exclude"]
+      if @bot.config["http.proxy_exclude"]
         # TODO
       end
-      if @bot.config["http_proxy_include"]
+      if @bot.config["http.proxy_include"]
       end
     end
     
@@ -43,10 +45,10 @@ class HttpUtil
     proxy_port = nil
     proxy_user = nil
     proxy_pass = nil
-    if @bot.config["http_proxy_user"]
-      proxy_user = @bot.config["http_proxy_user"]
-      if @bot.config["http_proxy_pass"]
-        proxy_pass = @bot.config["http_proxy_pass"]
+    if @bot.config["http.proxy_user"]
+      proxy_user = @bot.config["http.proxy_user"]
+      if @bot.config["http.proxy_pass"]
+        proxy_pass = @bot.config["http.proxy_pass"]
       end
     end
     if proxy