1
Short answer: the wrapper you are using doesn’t support custom encryption key, due to obsoleted boto2 implementation.
Long answer :
Here is the source of S3BotoStorage. Now here come the puzzle of how boto2 saving file. Where did you find the header? So I see they suggest something like this
AWS_HEADERS = {
'Expires': 'Thu, 15 Apr 2010 20:00:00 GMT',
'Cache-Control': 'max-age=86400',
}
There is no example for encryption headers passing to boto. The header you given, is for REST API, not the S3BotoStorage wrapper. So you may only able to use this and forget about setting the AWS_HEADERS for the encryption algorithm, give custom encryption key.
And the confusing part is , in boto2, S3 object name are call key (in boto3, they improve it and call it key_name explicitly) . This has nothing to do with encryption key.
Source:stackexchange.com