Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions test-server/php-v2-transition-server/src/get_object.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,10 @@ function handleGetObject($params)
}
if (strpos($e->getMessage(), "@SecurityProfile=V2") !== false) {
return S3EncryptionClientError($e->getMessage() . " " . "Enable legacy wrapping algorithms to use legacy key wrapping algorithm: kms");
} elseif (strpos($e->getMessage(), "One or more reserved keys found in Instruction file when they should not be present.") !== false) {
return S3EncryptionClientError($e->getMessage());
} elseif (strpos($e->getMessage(), "Expected a V3 envelope but was unable to constuct one.") !== false) {
return S3EncryptionClientError($e->getMessage());
} else {
error_log("This is the error: " . $e->getMessage());
return GenericServerError("Server error: " . $e->getMessage(), 500);
Expand Down
2 changes: 1 addition & 1 deletion test-server/php-v3-server/local-php-sdk
4 changes: 4 additions & 0 deletions test-server/php-v3-server/src/get_object.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ function handleGetObject($params)
return S3EncryptionClientError($e->getMessage());
} elseif (strpos($e->getMessage(), "Message is encrypted with a non commiting algorithm but commitment policy is set to REQUIRE_ENCRYPT_REQUIRE_DECRYPT. Select a valid commitment policy to decrypt this object.") !== false) {
return S3EncryptionClientError($e->getMessage());
} elseif (strpos($e->getMessage(), "One or more reserved keys found in Instruction file when they should not be present.") !== false) {
return S3EncryptionClientError($e->getMessage());
} elseif (strpos($e->getMessage(), "Expected a V3 envelope but was unable to constuct one.") !== false) {
return S3EncryptionClientError($e->getMessage());
} else {
error_log("This is the error: " . $e->getMessage());
return GenericServerError("Server argument: " . $e->getMessage(), 500);
Expand Down
Loading