Wykres commitów

203 Commity (217308abd735c5f6e31ef4cf8351d5b287a5dc03)

Autor SHA1 Wiadomość Data
Florin Peter 217308abd7
Support for transparent encryption
Co-authored-by: Florin Peter <Florin-Alexandru.Peter@t-systems.com>
2022-03-26 22:05:08 +09:00
Xavier Gourmandin 05a39cf745
Support for Junit 5 Extension mechanism
Fixes #288
2022-03-02 23:36:11 +09:00
Tamas Cservenak 2839107c6f UT for #392
This UT reproduces issue #392:
attempts a plain simple putObject without
any "trickery", and fails with SignatureDoesNotMatch.

The trick is, to use such Content-Type header that
is cached by Jetty, as it seems all the UTs are using
content types that are not quite common, hence Jetty
cache is not pre-populated with those.
2022-01-22 19:41:04 +09:00
Timur Alperovich 512c926b6e Fix anonymous bucket listing bug
If the bucket locator is used with anonymous access, listing a container
results in a null-pointer exception, as there are no blobstores in the
locator. In that case, we should use the globLocator structure and
return the first available blobstore.
2021-10-26 13:15:02 +09:00
Timur Alperovich a2e9e22719 Fix a bug in blobstore locator
558efb7b29 introduced a bug where if anonymous access is
configured, the bucket locator hits a null pointer exception. There is
an additional bug where if an incorrect identity is used with the
blobstore locator (as in, the request identity does not match the
configured bucket's blobstore identity), another null pointer exception
can be triggered.

The patch creates a new GlobBlobStoreLocator class and adds tests to it,
as it is difficult to test Main.java directly. The blobstore locator
logic is also reworked to fix the above bugs.
2021-10-24 18:20:25 +09:00
Timur Alperovich 35fea54d63 Alias middleware to remap backend buckets
Alias middleware implements a way to remap backend buckets to a
configurable front-end name. The mappings are configured as:
s3proxy.alias-blobstore.<s3proxy bucket> = <backend bucket>

A single bucket cannot be mapped to multiple names.
2021-09-11 21:57:56 +09:00
Andrew Gaul 619b4170c9 Skip AwsSdkTest.testAwsV4SignatureBadCredential
This randomly fails with SocketException: Broken pipe.
2021-09-08 21:48:32 +09:00
Timur Alperovich 0d8f9aa96d Add Sharded Bucket middleware
Adds the sharded bucket middleware, which allows for splitting objects
across multiple backend buckets for a given virtual bucket. The
middleware should be configured as:
s3proxy.sharded-blobstore.<bucket name>.shards=<number of shards>
s3proxy.sharded-blobstore.<bucket name>.prefix=<prefix>.

All shards are named <prefix>-<index>, where index is an
integer from 0 to <number of shards> - 1. If the <prefix> is not
supplied, the <bucket name> is used as the prefix.

Listing the virtual bucket and multipart uploads are not supported. When
listing all containers, the shards are elided from the result.

Fixes #325
Fixes #351
2021-06-05 23:23:38 +09:00
Andrew Gaul 4686ede0bd Upgrade to Jetty 9.4.41.v20210516
Enabled by Java 8.  Release notes for 9.3.0 and 9.4.0:

https://dev.eclipse.org/mhonarc/lists/jetty-announce/msg00080.html
https://dev.eclipse.org/mhonarc/lists/jetty-announce/msg00097.html

Fixes #121.
2021-06-05 23:18:07 +09:00
Andrew Gaul 1f79d30df5 Update copyright year 2021-03-29 21:04:28 +09:00
Andrew Gaul 94f19b0fab Add HEAD to test expectations 2021-03-07 11:53:22 +09:00
Andrew Gaul c66e29cd0a Check object size in testMaximumMultipartUpload
Also use constant for part size.
2021-02-03 23:22:22 +09:00
D044166 208ff3e136 Adding testcases for cors-allow-all 2021-01-26 12:38:48 +09:00
D044166 5b818f4e0a Better support for AllowOrigins *
If the Allowed Origin * is configured, the ACCESS_CONTROL_ALLOW_ORIGIN
header in CORS responses will contain * as well.
The ACCESS_CONTROL_ALLOW_METHODS header will always include all allowed
methods.

This is inline with a native S3 CORS response and will help esp. in CDN
caching scenarios. All requested Origins can now be served with a cached
response.
2021-01-26 12:38:48 +09:00
Falk Reimann d7281b1b1e CORS header for MultiPart Requests
Adding CORS headers `Access-Control-Allow-Origin` and
`Access-Control-Allow-Methods` in Multipart Reposnes if the
`Origin` Header is included in the Request and does match the
CORS rules.
2020-09-28 22:14:40 +09:00
Andrew Gaul 27e6a98f84 Enable Glacier storage class tests 2020-08-21 23:12:46 +09:00
Andrew Gaul 6d2a9428c8 Skip failing testPutMultipartInputStream 2020-08-21 23:12:01 +09:00
Andrew Gaul 34b844fcaf Do not accept multipart sizes less than 5 MB
Continue to enforce greater minimum blob sizes when storage backend
requires it.  Fixes #324.
2020-06-24 22:59:48 +09:00
Andrew Gaul 51ce7a91ad Update copyright year 2020-05-02 19:50:19 +09:00
Andrew Gaul 6291e93582 Update copyright year 2019-10-22 10:26:10 -07:00
Daan Kerkhofs 9abc9931f7 Fixes 299 Emit 404 for non-existing bucket during GetBucketAcl 2019-09-06 09:52:14 -07:00
Andrew Gaul 32fe8d0343 Emit MalformedXML with empty multi delete objects
Cannot test in s3-tests since the boto client prevents this.
Fixes #300.
2019-05-20 10:27:22 +09:00
Andrew Gaul f45d6e7fce Prefer HTTPS links where possible 2019-05-20 09:30:27 +09:00
Andrew Gaul c8d8126b3f Add simple handler for GetBucketPolicy
Fixes #301.
2019-05-10 19:19:56 +07:00
Andrew Gaul 3fed3941f1 Add partial support for list objects v2
Not supporting fetch-owner until jclouds adds support for this.
Several applications like AWS CLI now require this RPC.  Fixes #168.
2019-02-13 09:57:47 -08:00
Andrew Gaul 8223f443c7 Fix NullBlobStore multipart upload
Complete multipart upload lists the parts to get their sizes but the
NullBlobStore reported 8 bytes for the physical size instead of the
logical size embedded with the part.  There is no readable space to
store the logical size so we create a companion single-part object for
every part.
2019-02-06 16:35:19 -08:00
Andrew Gaul 43a45e36b6 Fix error prone 2.3.2 warnings 2019-02-05 15:33:46 -08:00
Andrew Gaul c6b4839d2b Allow glacier storage tier during PUT object
Amazon now allows this:

https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectPUT.html
2019-02-04 18:28:22 -08:00
Falk Reimann e3277a4c1f Basic CORS support
This commit adds a globally configurable CORS support.  Note that this differs from AWS per-bucket support.
2018-12-22 07:19:50 +09:00
Andrew Gaul 92db458cf2 error-prone 2.3.2 fixes 2018-10-14 23:03:41 -07:00
Andrew Gaul 86e1302bc9 Make a few fields final
Found via error-prone 2.3.1.
2018-04-21 11:43:50 -07:00
Daniel del Castillo 45e4d6348f Add JUnit Rule to project
This provides a convenience mechanism when writing tests.  Fixes #261.
2018-03-01 10:35:47 -08:00
Andrew Gaul 19807d0c2a Add support for storage classes
Supported for head, get, put, multipart put, and list objects.  Not
supported for list multipart uploads and copy objects.  Fixes #234.
2018-02-22 00:23:54 -08:00
Andrew Gaul 4f14a8419f Upgrade to jclouds 2.1.0
B2 and GCS now included in allblobstore.  Update signing tests which
now pass.  Improve invalid range read error handling.  Address Guava
18 warnings.  Fixes #191.  Fixes #209.  Changelog:

https://jclouds.apache.org/releasenotes/2.1.0/
2018-02-22 00:23:41 -08:00
Philipp Marx 24a3d64134 Test for chunked encoding with anonymous access
References #145.
2018-01-09 00:20:14 -08:00
Andrew Gaul a80e75a20f Add test for anonymous authentication
Fixes #200.
2018-01-08 22:56:28 -08:00
Andrew Gaul c410df593d Parameterize TestUtils.startS3Proxy 2018-01-08 22:56:28 -08:00
Andrew Gaul 2905b720b8 Update copyright year 2018-01-04 14:57:47 -08:00
Andrew Gaul 94bf8ca88e Add missing @Nullable 2017-12-23 08:03:29 -08:00
Andrew Gaul 11f82ec997 Factor out properties parsing into Builder 2017-11-08 17:34:09 -08:00
Andrew Gaul 732a24d990 Allow limiting the number of Jetty threads
Also name Jetty threads more specifically.  References #180.
2017-11-08 15:25:57 -08:00
Andrew Gaul f48bd352c4 Consume S3Object InputStream
Previously these tests leaked HTTP connections from the AWS SDK pool.
2017-11-08 11:41:35 -08:00
Andrew Gaul 251082f7e7 Support multiple configurations
Fixes #11.
2017-11-07 17:06:57 -08:00
Andrew Gaul 35d7c48475 Read-only middleware
Fixes #217.
2017-10-08 18:11:14 -07:00
Andrew Gaul f6c3ab9e75 Add @Nullable annotations where appropriate
Found via error-prone 2.1.0.
2017-08-21 19:46:33 -07:00
Andrew Gaul 51aa2e7fcd Address modern Guava deprecations 2017-08-21 15:04:41 -07:00
Andrew Gaul 233559bb2b Do not ignore x-amz-storage-class if not STANDARD
Clients can set the ignore unknown headers parameter to preserve the
existing behavior.  References #234.
2017-08-16 18:04:52 -07:00
Andrew Gaul 9c74851c43 Address error-prone 2.0.19 issues 2017-05-06 17:00:38 -07:00
Andrew Gaul d005f452de Prefer failBecauseExceptionWasNotThrown over fail 2017-04-18 11:53:09 -07:00
Andrew Gaul dea4b3bae3 Handle testMultipartUploadAbort azureblob quirks 2017-04-16 19:50:18 -07:00