'How to enable AWS managed key (aws/s3) as a AWS KMS key in S3 encryption

How can i enable AWS managed key (aws/s3) as a AWS KMS key in S3 encryption using cloud formation? I have the following code but i'm not sure if i should pass the key as an arn

MyBucket:
    Type: AWS::S3::Bucket
    Properties:
      BucketName:
      BucketEncryption:
        ServerSideEncryptionConfiguration:
          - ServerSideEncryptionByDefault:
              SSEAlgorithm: aws:kms
              KMSMasterKeyID: !GetAtt ARN?
      VersioningConfiguration:
        Status: Enabled


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source