Created
April 13, 2015 20:28
-
-
Save cyberplant/a81717e3956ed5e19b1d to your computer and use it in GitHub Desktop.
Get SMTP password from AWS Credentials: https://docs.aws.amazon.com/ses/latest/DeveloperGuide/smtp-credentials.html
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hmac | |
import hashlib | |
import base64 | |
AWS_SECRET_KEY = raw_input("AWS Secret Key >") | |
MESSAGE = "SendRawEmail" | |
VERSION = chr(0x02) | |
hm = hmac.new(AWS_SECRET_KEY, msg=MESSAGE, digestmod=hashlib.sha256) | |
print base64.b64encode(VERSION + hm.digest()).decode() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment