Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Server-Side Encryption #113

Closed
numberoverzero opened this issue Mar 30, 2018 · 1 comment · Fixed by #114
Closed

Support Server-Side Encryption #113

numberoverzero opened this issue Mar 30, 2018 · 1 comment · Fixed by #114

Comments

@numberoverzero
Copy link
Owner

numberoverzero commented Mar 30, 2018

https://forums.aws.amazon.com/ann.jspa?annID=5434
https://aws.amazon.com/blogs/aws/new-encryption-at-rest-for-dynamodb/

CreateTable parameter is {"SSESpecification": {"Enabled": true}}
DescribeTable field is "SSEDescription": {"Status": STRING_ENUM} where STRING_ENUM is one of {ENABLING, ENABLED, DISABLING, DISABLED}

Like stream and ttl, This will be specified on the Meta object:

class User(BaseModel):
    id = Column(String, hash_key=True)
    expire_after = Column(Timestamp, dynamo_name="exp")

    class Meta:
        stream = {"include": {"new", "old"}}
        ttl = {"column": "expire_after"}
        encryption = {"enabled": True}

As with all optional meta config, when encryption isn't provided an existing value won't be validated. However a value is specified, it will be validated against the return value when binding the model.

@numberoverzero
Copy link
Owner Author

DescribeTable won't always return SSEDescription so sanitize_table_description needs to inject when missing with "Status": "DISABLED"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant