fixed handling of secret & key in command line; added support for different regions