title: Savon HTTPS Request with HTTP authentication
body: <p>I have written an integration with a SOAP API using savon. I am running into issue which seems to be only with certain OSs. The reason I say that is because the same code works on CentOS6 and MacOSX but it refuses to work with Ubuntu12.04. The code I'm using is:</p>
  <pre><code>@client = Savon.client do
    wsdl &quot;mywsdl&quot;
    basic_auth [&quot;username&quot;, &quot;password&quot;]
  end
  
  @client.call(:set_session_parameters, message: {viewSettings: {rollingPeriod: &quot;Today&quot;, shiftStart: &quot;25200000&quot;, statisticsRange: &quot;CurrentDay&quot;,timeZone: -21600000}})
  </code></pre>
  <p>The error I get back is:</p>
  <pre><code>[2013-06-03T18:22:31.784007 #16304] DEBUG -- : HTTPI POST request to api.five9.com (httpclient)
  I, [2013-06-03T18:22:42.413083 #16304]  INFO -- : SOAP response (status 401)
  D, [2013-06-03T18:22:42.413378 #16304] DEBUG -- : &lt;html&gt;&lt;head&gt;&lt;title&gt;JBoss Web/2.1.3.GA - Error report&lt;/title&gt;&lt;style&gt;&lt;!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--&gt;&lt;/style&gt; &lt;/head&gt;&lt;body&gt;&lt;h1&gt;HTTP Status 401 - No user credentials found&lt;/h1&gt;&lt;HR size=&quot;1&quot; noshade=&quot;noshade&quot;&gt;&lt;p&gt;&lt;b&gt;type&lt;/b&gt; Status report&lt;/p&gt;&lt;p&gt;&lt;b&gt;message&lt;/b&gt; &lt;u&gt;No user credentials found&lt;/u&gt;&lt;/p&gt;&lt;p&gt;&lt;b&gt;description&lt;/b&gt; &lt;u&gt;This request requires HTTP authentication (No user credentials found).&lt;/u&gt;&lt;/p&gt;&lt;HR size=&quot;1&quot; noshade=&quot;noshade&quot;&gt;&lt;h3&gt;JBoss Web/2.1.3.GA&lt;/h3&gt;&lt;/body&gt;&lt;/html&gt;
  Savon::HTTPError: HTTP error (401): &lt;html&gt;&lt;head&gt;&lt;title&gt;JBoss Web/2.1.3.GA - Error report&lt;/title&gt;&lt;style&gt;&lt;!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--&gt;&lt;/style&gt; &lt;/head&gt;&lt;body&gt;&lt;h1&gt;HTTP Status 401 - No user credentials found&lt;/h1&gt;&lt;HR size=&quot;1&quot; noshade=&quot;noshade&quot;&gt;&lt;p&gt;&lt;b&gt;type&lt;/b&gt; Status report&lt;/p&gt;&lt;p&gt;&lt;b&gt;message&lt;/b&gt; &lt;u&gt;No user credentials found&lt;/u&gt;&lt;/p&gt;&lt;p&gt;&lt;b&gt;description&lt;/b&gt; &lt;u&gt;This request requires HTTP authentication (No user credentials found).&lt;/u&gt;&lt;/p&gt;&lt;HR size=&quot;1&quot; noshade=&quot;noshade&quot;&gt;&lt;h3&gt;JBoss Web/2.1.3.GA&lt;/h3&gt;&lt;/body&gt;&lt;/html&gt;
      from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/savon-2.2.0/lib/savon/response.rb:71:in `raise_soap_and_http_errors!'
      from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/savon-2.2.0/lib/savon/response.rb:13:in `initialize'
      from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/savon-2.2.0/lib/savon/operation.rb:53:in `new'
      from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/savon-2.2.0/lib/savon/operation.rb:53:in `call'
      from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/savon-2.2.0/lib/savon/client.rb:36:in `call'
  </code></pre>
  <p>Like I said on other OSs the code works fine. Is there something that I need to install to make this work on Ubuntu12.04?</p>
  <h1>It is definitely not a username and password error seeing as an exact replica works on another OS.</h1>
  <p>Any help with this issue would be appreciated. Thanks!</p>