今日、HelloWorldAWSプログラムを作成しました。事前に作成されたS3バケットにファイルをアップロードするだけです。
クライアントデスクトップにデプロイされたこのプログラムのコンテキストでは(議論のために)、私のシークレットアクセスキーは安全ですか?
using (AmazonS3Client a = new AmazonS3Client("MyAccessKey", "MySecretAccessKey"))
{
foreach (ListViewItem lvi in listView1.Items)
{
TransferUtilityUploadRequest tr = new TransferUtilityUploadRequest()
.WithBucketName("test_mydomain_com")
.WithFilePath(((FileInfo)lvi.Tag).FullName)
.WithTimeout(5 * 60 * 1000);
TransferUtility tu = new TransferUtility(a);
tu.Upload(tr);
MessageBox.Show("Win!");
}
}