@classmethod
    def generate_key(cls, secret_key, region, service, date,
                     intermediates=False):
        init_key = ('AWS4' + secret_key).encode('utf-8')
        date_key = cls.sign_sha256(init_key, date)
        region_key = cls.sign_sha256(date_key, region)
        service_key = cls.sign_sha256(region_key, service)
        key = cls.sign_sha256(service_key, 'aws4_request')
        if intermediates:
            return (key, date_key, region_key, service_key)
        else:
            return key
Grab user input from command line.
dataset/ETHPy150Open sam-washington/requests-aws4auth/requests_aws4auth/aws4signingkey.py/AWS4SigningKey.generate_key--crossover with--dataset/ETHPy150Open RoseOu/flasky/venv/lib/python2.7/site-packages/flask_script/cli.py/prompt