Skip to content

Commit 40d64bf

Browse files
authored
Merge branch 'fireegg-test-servers' into kessplas/rsa-aes
2 parents e61d975 + 3e29c21 commit 40d64bf

10 files changed

Lines changed: 518 additions & 6 deletions

File tree

.gitmodules

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,10 @@
4444
path = test-server/net-v2-v3-server/s3ec-net-v3
4545
url = https://github.com/aws/private-amazon-s3-encryption-client-dotnet-staging.git
4646
branch = s3ec-v3
47+
[submodule "test-server/go-v3-transition-server/local-go-s3ec"]
48+
path = test-server/go-v3-transition-server/local-go-s3ec
49+
url = https://github.com/aws/private-amazon-s3-encryption-client-go-staging
50+
branch = v3-strip
4751
[submodule "test-server/net-v3-transition-server/s3ec-v3-transition-branch"]
4852
path = test-server/net-v3-transition-server/s3ec-v3-transition-branch
4953
url = https://github.com/aws/private-amazon-s3-encryption-client-dotnet-staging.git
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
reports/
22
requirements/
3-
specification/
3+
specification/

test-server/go-v3-server/.duvet/config.toml renamed to test-server/go-v3-transition-server/.duvet/config.toml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
'$schema' = "https://awslabs.github.io/duvet/config/v0.4.0.json"
22

33
[[source]]
4-
pattern = "**/*.go"
4+
pattern = "local-go-s3ec/v4/**/*.go"
55

66
# Include required specifications here
77
[[specification]]
8-
source = "../specification/s3-encryption/data-format/content-metadata.md"
8+
source = "../specification/s3-encryption/client.md"
99
[[specification]]
10-
source = "../specification/s3-encryption/data-format/metadata-strategy.md"
10+
source = "../specification/s3-encryption/decryption.md"
1111
[[specification]]
1212
source = "../specification/s3-encryption/encryption.md"
1313
[[specification]]
14+
source = "../specification/s3-encryption/key-commitment.md"
15+
[[specification]]
1416
source = "../specification/s3-encryption/key-derivation.md"
17+
[[specification]]
18+
source = "../specification/s3-encryption/data-format/content-metadata.md"
19+
[[specification]]
20+
source = "../specification/s3-encryption/data-format/metadata-strategy.md"
1521

1622
[report.html]
1723
enabled = true
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Makefile for S3 Encryption Client Testing
2+
3+
.PHONY: start-server stop-server wait-for-server
4+
5+
PID_FILE := server.pid
6+
PORT := 8095
7+
8+
start-server:
9+
@echo "Starting Go V3 Transition server..."
10+
go mod tidy
11+
AWS_ACCESS_KEY_ID="$$AWS_ACCESS_KEY_ID" \
12+
AWS_SECRET_ACCESS_KEY="$$AWS_SECRET_ACCESS_KEY" \
13+
AWS_SESSION_TOKEN="$$AWS_SESSION_TOKEN" \
14+
AWS_REGION="us-west-2" \
15+
go run . & echo $$! > $(PID_FILE)
16+
@echo "Go V3 Transition server starting..."
17+
18+
stop-server:
19+
@if [ -f $(PID_FILE) ]; then \
20+
kill $$(cat $(PID_FILE)) 2>/dev/null || true; \
21+
rm $(PID_FILE); \
22+
fi
23+
24+
wait-for-server:
25+
$(MAKE) -C .. wait-for-port PORT=$(PORT)
26+
27+
duvet:
28+
duvet report
29+
30+
view-report-mac:
31+
open .duvet/reports/report.html
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# S3EC Go V3 Transition Test Server
2+
3+
This is the Go implementation of the S3ECTestServer framework for S3EC Go V3 Transition. It provides a server implementation for testing Go S3 Encryption Client V3 Transition functionality.
4+
5+
## Overview
6+
7+
The S3EC Go test server implements the S3ECTestServer service defined in the shared Smithy model. It provides endpoints for:
8+
9+
- Creating S3 Encryption Clients
10+
- Putting objects with encryption
11+
- Getting and decrypting objects
12+
13+
## Usage
14+
15+
To run the server:
16+
17+
```console
18+
go run .
19+
```
20+
21+
This will start the server running on port `8095`.
22+
23+
The server is used as part of the testing framework to verify cross-language compatibility of the S3 Encryption Client implementations.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
module github.com/aws/amazon-s3-encryption-client-python/test-server/go-server
2+
3+
go 1.21
4+
5+
require (
6+
github.com/aws/amazon-s3-encryption-client-go/v3 v3.0.0
7+
github.com/aws/aws-sdk-go-v2 v1.24.0
8+
github.com/aws/aws-sdk-go-v2/config v1.26.1
9+
github.com/aws/aws-sdk-go-v2/service/kms v1.27.4
10+
github.com/aws/aws-sdk-go-v2/service/s3 v1.47.5
11+
github.com/google/uuid v1.5.0
12+
github.com/gorilla/mux v1.8.1
13+
)
14+
15+
require (
16+
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.5.4 // indirect
17+
github.com/aws/aws-sdk-go-v2/credentials v1.16.12 // indirect
18+
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.14.10 // indirect
19+
github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.9 // indirect
20+
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.9 // indirect
21+
github.com/aws/aws-sdk-go-v2/internal/ini v1.7.2 // indirect
22+
github.com/aws/aws-sdk-go-v2/internal/v4a v1.2.9 // indirect
23+
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.10.4 // indirect
24+
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.2.9 // indirect
25+
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.9 // indirect
26+
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.16.9 // indirect
27+
github.com/aws/aws-sdk-go-v2/service/sso v1.18.5 // indirect
28+
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.21.5 // indirect
29+
github.com/aws/aws-sdk-go-v2/service/sts v1.26.5 // indirect
30+
github.com/aws/smithy-go v1.19.0 // indirect
31+
)
32+
33+
// S3EC Go V4 is not released to pkg.go.dev as of writing.
34+
// It is included as a submodule and referenced locally.
35+
replace github.com/aws/amazon-s3-encryption-client-go/v3 => ./local-go-s3ec/v3
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
2+
github.com/aws/aws-sdk-go-v2 v1.24.0 h1:890+mqQ+hTpNuw0gGP6/4akolQkSToDJgHfQE7AwGuk=
3+
github.com/aws/aws-sdk-go-v2 v1.24.0/go.mod h1:LNh45Br1YAkEKaAqvmE1m8FUx6a5b/V0oAKV7of29b4=
4+
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.5.4 h1:OCs21ST2LrepDfD3lwlQiOqIGp6JiEUqG84GzTDoyJs=
5+
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.5.4/go.mod h1:usURWEKSNNAcAZuzRn/9ZYPT8aZQkR7xcCtunK/LkJo=
6+
github.com/aws/aws-sdk-go-v2/config v1.26.1 h1:z6DqMxclFGL3Zfo+4Q0rLnAZ6yVkzCRxhRMsiRQnD1o=
7+
github.com/aws/aws-sdk-go-v2/config v1.26.1/go.mod h1:ZB+CuKHRbb5v5F0oJtGdhFTelmrxd4iWO1lf0rQwSAg=
8+
github.com/aws/aws-sdk-go-v2/credentials v1.16.12 h1:v/WgB8NxprNvr5inKIiVVrXPuuTegM+K8nncFkr1usU=
9+
github.com/aws/aws-sdk-go-v2/credentials v1.16.12/go.mod h1:X21k0FjEJe+/pauud82HYiQbEr9jRKY3kXEIQ4hXeTQ=
10+
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.14.10 h1:w98BT5w+ao1/r5sUuiH6JkVzjowOKeOJRHERyy1vh58=
11+
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.14.10/go.mod h1:K2WGI7vUvkIv1HoNbfBA1bvIZ+9kL3YVmWxeKuLQsiw=
12+
github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.9 h1:v+HbZaCGmOwnTTVS86Fleq0vPzOd7tnJGbFhP0stNLs=
13+
github.com/aws/aws-sdk-go-v2/internal/configsources v1.2.9/go.mod h1:Xjqy+Nyj7VDLBtCMkQYOw1QYfAEZCVLrfI0ezve8wd4=
14+
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.9 h1:N94sVhRACtXyVcjXxrwK1SKFIJrA9pOJ5yu2eSHnmls=
15+
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.5.9/go.mod h1:hqamLz7g1/4EJP+GH5NBhcUMLjW+gKLQabgyz6/7WAU=
16+
github.com/aws/aws-sdk-go-v2/internal/ini v1.7.2 h1:GrSw8s0Gs/5zZ0SX+gX4zQjRnRsMJDJ2sLur1gRBhEM=
17+
github.com/aws/aws-sdk-go-v2/internal/ini v1.7.2/go.mod h1:6fQQgfuGmw8Al/3M2IgIllycxV7ZW7WCdVSqfBeUiCY=
18+
github.com/aws/aws-sdk-go-v2/internal/v4a v1.2.9 h1:ugD6qzjYtB7zM5PN/ZIeaAIyefPaD82G8+SJopgvUpw=
19+
github.com/aws/aws-sdk-go-v2/internal/v4a v1.2.9/go.mod h1:YD0aYBWCrPENpHolhKw2XDlTIWae2GKXT1T4o6N6hiM=
20+
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.10.4 h1:/b31bi3YVNlkzkBrm9LfpaKoaYZUxIAj4sHfOTmLfqw=
21+
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.10.4/go.mod h1:2aGXHFmbInwgP9ZfpmdIfOELL79zhdNYNmReK8qDfdQ=
22+
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.2.9 h1:/90OR2XbSYfXucBMJ4U14wrjlfleq/0SB6dZDPncgmo=
23+
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.2.9/go.mod h1:dN/Of9/fNZet7UrQQ6kTDo/VSwKPIq94vjlU16bRARc=
24+
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.9 h1:Nf2sHxjMJR8CSImIVCONRi4g0Su3J+TSTbS7G0pUeMU=
25+
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.10.9/go.mod h1:idky4TER38YIjr2cADF1/ugFMKvZV7p//pVeV5LZbF0=
26+
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.16.9 h1:iEAeF6YC3l4FzlJPP9H3Ko1TXpdjdqWffxXjp8SY6uk=
27+
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.16.9/go.mod h1:kjsXoK23q9Z/tLBrckZLLyvjhZoS+AGrzqzUfEClvMM=
28+
github.com/aws/aws-sdk-go-v2/service/kms v1.27.4 h1:c75pHGBV3h6WOsIjbJhLyOnlCPXzap45nbiP2Z5jk5M=
29+
github.com/aws/aws-sdk-go-v2/service/kms v1.27.4/go.mod h1:D9FVDkZjkZnnFHymJ3fPVz0zOUlNSd0xcIIVmmrAac8=
30+
github.com/aws/aws-sdk-go-v2/service/s3 v1.47.5 h1:Keso8lIOS+IzI2MkPZyK6G0LYcK3My2LQ+T5bxghEAY=
31+
github.com/aws/aws-sdk-go-v2/service/s3 v1.47.5/go.mod h1:vADO6Jn+Rq4nDtfwNjhgR84qkZwiC6FqCaXdw/kYwjA=
32+
github.com/aws/aws-sdk-go-v2/service/sso v1.18.5 h1:ldSFWz9tEHAwHNmjx2Cvy1MjP5/L9kNoR0skc6wyOOM=
33+
github.com/aws/aws-sdk-go-v2/service/sso v1.18.5/go.mod h1:CaFfXLYL376jgbP7VKC96uFcU8Rlavak0UlAwk1Dlhc=
34+
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.21.5 h1:2k9KmFawS63euAkY4/ixVNsYYwrwnd5fIvgEKkfZFNM=
35+
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.21.5/go.mod h1:W+nd4wWDVkSUIox9bacmkBP5NMFQeTJ/xqNabpzSR38=
36+
github.com/aws/aws-sdk-go-v2/service/sts v1.26.5 h1:5UYvv8JUvllZsRnfrcMQ+hJ9jNICmcgKPAO1CER25Wg=
37+
github.com/aws/aws-sdk-go-v2/service/sts v1.26.5/go.mod h1:XX5gh4CB7wAs4KhcF46G6C8a2i7eupU19dcAAE+EydU=
38+
github.com/aws/smithy-go v1.19.0 h1:KWFKQV80DpP3vJrrA9sVAHQ5gc2z8i4EzrLhLlWXcBM=
39+
github.com/aws/smithy-go v1.19.0/go.mod h1:NukqUGpCZIILqqiV0NIjeFh24kd/FAa4beRb6nbIUPE=
40+
github.com/google/go-cmp v0.5.8 h1:e6P7q2lk1O+qJJb4BtCQXlK8vWEO8V1ZeuEdJNOqZyg=
41+
github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
42+
github.com/google/uuid v1.5.0 h1:1p67kYwdtXjb0gL0BPiP1Av9wiZPo5A8z2cWkTZ+eyU=
43+
github.com/google/uuid v1.5.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
44+
github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY=
45+
github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ=
Submodule local-go-s3ec added at 7a29344

0 commit comments

Comments
 (0)