# Type of request: This is a ...
[ ] bug report
[x] feature request

# Detailed description
As a Developer,
I want to be able to simulate BadDigest and InvalidDigest errors,
So that I can test the error handling logic

## Expected behavior
https://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html
BadDigest: The Content-MD5 you specified did not match what we received.
InvalidDigest: The Content-MD5 you specified is not valid.

## Actual behavior
localstack returns InvalidDigest when MD5 does not match payload.


from localstack.utils.analytics import event_publisher
from localstack.utils.http_utils import uses_chunked_encoding
from localstack.utils.persistence import PersistingProxyListener
from localstack.utils.aws.aws_responses import requests_response
CONTENT_SHA256_HEADER = 'x-amz-content-sha256'
STREAMING_HMAC_PAYLOAD = 'STREAMING-AWS4-HMAC-SHA256-PAYLOAD'
PORT_S3_BACKEND = None
S3_NOTIFICATIONS = {}
BUCKET_CORS = {}
BUCKET_LIFECYCLE = {}
BUCKET_REPLICATIONS = {}
BUCKET_ENCRYPTIONS = {}
OBJECT_LOCK_CONFIGS = {}
OBJECT_EXPIRY = {}
LOGGER = logging.getLogger(__name__)
XMLNS_S3 = 'http://s3.amazonaws.com/doc/2006-03-01/'
BUCKET_NAME_REGEX = (r'(?=^.{3,63}$)(?!^(\d+\.)+\d+$)' +
    r'(^(([a-z0-9]|[a-z0-9][a-z0-9\-]*[a-z0-9])\.)*([a-z0-9]|[a-z0-9][a-z0-9\-]*[a-z0-9])$)')
NOTIFICATION_DESTINATION_TYPES = ('Queue', 'Topic', 'CloudFunction', 'LambdaFunction')
OBJECT_METADATA_KEY_PREFIX = 'x-amz-meta-'
ALLOWED_HEADER_OVERRIDES = {
    'response-content-type': 'Content-Type',
    'response-content-language': 'Content-Language',
    'response-expires': 'Expires',
    'response-cache-control': 'Cache-Control',
    'response-content-disposition': 'Content-Disposition',
    'response-content-encoding': 'Content-Encoding',
}
POLICY_EXPIRATION_FORMAT = '%Y-%m-%dT%H:%M:%SZ'
def event_type_matches(events, action, api_method):