public EnvironmentAWSCredentials()
{
NameValueCollection appConfig = ConfigurationManager.AppSettings;
var accessKey = appConfig[ACCESSKEY];
var secretKey = appConfig[SECRETKEY];
if (string.IsNullOrEmpty(accessKey))
throw new ArgumentException(string.Format(CultureInfo.InvariantCulture, "Access Key could not be found. Add an appsetting to your App.config with the name {0} with a value of your access key.", ACCESSKEY));
if (string.IsNullOrEmpty(secretKey))
throw new ArgumentException(string.Format(CultureInfo.InvariantCulture, "Secret Key could not be found. Add an appsetting to your App.config with the name {0} with a value of your secret key.", SECRETKEY));
this._wrappedCredentials = new ImmutableCredentials(accessKey, secretKey, null);
}