Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Commits on Mar 9, 2015
  1. add 'version' to httpclient command

    % httpclient version
  2. support no header deflate compression

    Some server returns deflate content without zlib header. Try to detect
    it and fallback to plain deflate algorithm for
    Fixes #244.
Commits on Jan 20, 2015
  1. feat: accepts initialization block

    authored { |c| c.debug_dev = STDERR }.get("...")
Commits on Jan 3, 2015
  1. Version bump to

  2. fix: bin/httpclient one-liner broken

    db8166a broke one-liner style
    bin/httpclient execution.
  3. Version bump to 2.6.0

  4. refactor: do not use Queue#pop in sync request

    Let do_get_block return response object and do_request use it. It still
    has Connection object and call Queue#push for Newrelic gem:
  5. Revert "refactor: do not use Queue#pop in sync request"

    This reverts commit 45b1045 because it
    broke Webmock compatibility.
  6. Version bump to 2.6.0.pre

  7. Merge pull request #237 from nahi/http-cookie

    feat: use http-cookie for better Cookies spec compliance
  8. Add old test for reference

  9. Recover old cookie implementation as fallback

    http-cookie is used by default but you can restore original
    CookieManager behavior by loading 'httpclient/webagent-cookie' feature
    before 'httpclient' like this;
    require 'httpclient/webagent-cookie'
    require 'httpclient'
Commits on Jan 1, 2015
  1. refactor: do not use Queue#pop in sync request

    Let do_get_block return response object and do_request use it. It still
    has Connection object and call Queue#push for Newrelic gem:
Commits on Dec 31, 2014
  1. Update tests re: Cookie value escaping

    Reopened #145.
Commits on Dec 30, 2014
  1. feat: use http-cookie for better Cookies spec compliance

    Instead of WebAgent 0.6.2 that is not maintained over 10 years. To omit
    maintaining that library use http-cookie for better spec compliance and
    healthy development.
    This introduces following incompatibility from existing cookies
    * Expired cookies are not saved. With the old implementation expired
      cookies are saved in file and not be sent to the server. With the new
      implementation the expired cookies are not saved to the file and not
      be sent to the server.
    * Cookie#url -> Cookie#origin
    * Cookie#domain returns dot-less domain for domain cookies. Instead,
      Cookie#dot_domain returns with dot.
  2. fix: duplicated query params by follow_redirect

    When the original request has query and the server returns redirection
    response with Location, HTTPClient wrongly adds query to the new URI. In
    such case the Location header could include query part;
      -> Location: http://otherhost/api/call?limit=10
    HTTPClient should just hit the new location '/api/call?limit=10' not
    '/api/call?limit=10&limit=10'. Closes #236.
Commits on Dec 29, 2014
  1. fix: NTLM & Basic dual auth

    When a server returns two or more WWW-Authenticate headers and the first
    one is NTLM, say WWW-Authenticate: NTLM and WWW-Authenticate: Basic in
    this order, HTTPClient sent Basic Authorization header after finishing
    NTLM auth negotiation.
    NTLM auth is a connection authentication scheme so HTTPClient deleted
    the internal auth negotiation state so that NTLM authenticator does not
    do anything after the negotiation has completed. In such case, for the
    subsequent requests, NTLM authenticator does nothing but Basic
    authenticator sends Basic Authorization header to the server that is
    already negotiated via NTLM authenticator. This can cause authentication
    This commit changes the internal state handling not to delete the state
    but introduce :done state. NTLM authenticator returns :skip for the
    request to the server that auth negotiation has completed. WWWAuth skips
    other authenticator to avoid above issue.
    Closes #157.
  2. refactor: introduce AuthBase

    I checked that webmock master does not depend on Auth internal (spec
Commits on Dec 28, 2014
  1. fix: transplant IO positions to new request in negotiation

    In authorization negotiation HTTP::Message for request is generated for
    each request, of course, but HTTPClient didn't care the IO position
    recorded in the previous requests in the subsequent requests.
    Closes #130.
  2. fix: avoid inconsistent Content-Length and actual body

    If lengths of all posted arguments are known HTTPClient sends
    'Content-Length' as a sum length of all arguments. But the length of
    actual body was wrong because it read as much as possible regardless of
    what IO#size returned. So if the file is getting bigger while HTTPClient
    is processing a request the request has inconsistent Content-Length and
    This bug is found, and the fix is proposed both by @Teshootub7. Thank
    you very much for patient trouble shooting!
    Fixes #117.
  3. chore: restore ruby-ntlm test

  4. Keep quoted cookie value as is and send back to the server

    Try to send back the given Cookie value to the server as is to the
    extent possible. When Set-Cookie is 'key="value"', send 'key="value"' to
    the server not 'key=value'.
    Implementation: keep Cookie values without normalizing internally and do
    normalize when Cookie#value is called. The raw_value is written to
    Cookie file as well.  Closes #145.
  5. feat: Message#previous to get responses in negotiation

    HTTP::Message#previous keeps previous response in negotiation.  For
    redirection, authorization negotiation and retry from custom filter.
    Closes #234.
  6. Use bundled jruby-openssl

    Remove jruby-openssl definition from Gemfile
Something went wrong with that request. Please try again.