February 02, 2014, 01:24:30 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
  Home Help Search Login Register  
  Show Posts
Pages: [1]
1  General Category / General Discussion / Re: SignatureDoesNotMatch/403 Forbidden (s3sync, s3cmd is fine) on: January 26, 2009, 08:03:41 PM
Yeah, nothing changed on my end.

FWIW, I'm running on Windows.  I can provide more specifics if you want to do some negative testing.

Perhaps an s3sync config could be added for "include amz headers in signature calculation" in case this flip flops more?  Modifying code is probably beyond most people, and it did indeed take me about 3 hours to dig out that needle form the haystack! Smiley

2  General Category / General Discussion / SignatureDoesNotMatch/403 Forbidden (s3sync, s3cmd is fine) on: January 25, 2009, 02:37:04 AM
I was trying to figure out why my s3sync commands tonite would not succeed.  I suddenly started getting SignatureDoesNotMatch errors.  After some testing with s3cmd and performing few packet traces I found that s3sync adds some x-amz headers to the PUT calls, whereas s3cmd does not.

Perplexed by this, I looked up the documentation and found at http://docs.amazonwebservices.com/AmazonS3/latest/index.html?RESTAuthentication.html#RESTAuthenticationExamples that it states you HAVE to calculate your Authorization Signature by including specific information which includes the x-amz headers, which s3sync IS doing properly.

What has changed (cause this worked previously) appears to be on Amazon's side because my same backups used to work flawlessly.  I removed the logic from the S3.rb file in the S3.canonical_string() function which includes the AMAZON_HEADER_PREFIX by simply changing the line of code to:

    lk =~ /^x#{AMAZON_HEADER_PREFIX}/o)

Adding the "x" at the beginning made it not match, and now the x-amz headers are no longer used in the Authentication Signature calculation.

Why would this have changed at Amazon?  Note the link above which makes this a requirement is a reference to the "latest" documents...


3  General Category / Closed Bugs / Error when trying to use cool --progress feature! :) on: April 06, 2007, 01:33:18 AM
When I try to use --progress with 1.1.2 I get the following:

/usr/lib/ruby/1.8/delegate.rb:158:in `method_missing': undefined method `length' for nil:S3sync::ProgressStream (NoMethodError)
        from /usr/lib/ruby/1.8/net/http.rb:1533:in `send_request_with_body'
        from /usr/lib/ruby/1.8/net/http.rb:1522:in `exec'
        from /usr/lib/ruby/1.8/net/http.rb:1045:in `_HTTPStremaing_request'
        from ./HTTPStreaming.rb:45:in `request'
        from ./S3_s3sync_mod.rb:50:in `make_request'
        from ./S3.rb:152:in `put'
        from ./s3try.rb:57:in `send'
        from ./s3try.rb:57:in `S3try'
        from ./s3sync.rb:499:in `updateFrom'
        from ./s3sync.rb:370:in `main'
        from ./s3sync.rb:690

Actual command line is:

    ./s3sync.rb --progress -v /data/share/Backups/file.gz my.bucket.prefix:

I'm on Debian running Ruby 1.8.5:

# dpkg -l | grep -i ruby
ii  libopenssl-ruby               1.0.0+ruby1.8.2-1          OpenSSL interface for Ruby
ii  libopenssl-ruby1.8            1.8.5-4                    OpenSSL interface for Ruby 1.8
ii  libruby1.8                    1.8.5-4                    Libraries necessary to run Ruby 1.8
ii  ruby1.8                       1.8.5-4                    Interpreter of object-oriented scripting lan

Hope that helps ya out!  Can't wait to try the progress feature!!  Cheesy

Pages: [1]
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!