s3fs-fuse/src
Nathaniel W. Turner 584ea488bf Use role name instead of profile name when iam_role=auto
When using an instance with an IAM Role, transient credentials can be
found in http://169.254.169.254/latest/meta-data/ at
iam/security-credentials/role-name and s3fs tries to do this. However,
it is using the profile-name where role-name is needed. In many cases
the role and profile name are the same, but they are not always.

The simplest way to find the role name appears to be to GET
http://169.254.169.254/latest/meta-data/iam/security-credentials/
itself, which returns a listing of the role names for which temporary
credentials exist. (I think there will probably only be one, but we
probably want to split on newlines and take the first one here in case
that assumption is not valid). This is the approach the AWS SDK appears
to use (based on WireShark analysis).

Bug: https://github.com/s3fs-fuse/s3fs-fuse/issues/421
Signed-off-by: Nathaniel W. Turner <nate@houseofnate.net>
2016-05-24 13:34:19 -04:00
..
addhead.cpp Allow duplicate key in ahbe_conf - #386 2016-05-06 01:08:39 +00:00
addhead.h Sepalated AdditionalHeader class from curl.* 2016-02-07 05:41:56 +00:00
cache.cpp Fixed a bug about stat_cache_expire - #382 2016-05-14 09:03:52 +00:00
cache.h Chnaged about constructor(destructor) in cache.h 2016-03-13 09:47:37 +00:00
common_auth.cpp Move base64 and hex functions to string_util 2015-08-19 13:47:26 -07:00
common.h Fix syslog level used by S3FS_PRN_EXIT() 2015-11-25 13:53:08 -08:00
curl.cpp Use role name instead of profile name when iam_role=auto 2016-05-24 13:34:19 -04:00
curl.h loading IAM role name automatically(iam_role option) - #387 2016-05-06 04:37:32 +00:00
fdcache.cpp Fixed writing sparsed file - #375,#379,#394 2016-04-12 18:24:36 +00:00
fdcache.h Remove stat file cache dir if specified del_cache - #337 2016-02-06 18:59:13 +00:00
gnutls_auth.cpp Changed and cleaned the logic for debug message. 2015-09-30 19:41:27 +00:00
Makefile.am Sepalated AdditionalHeader class from curl.* 2016-02-07 05:41:56 +00:00
nss_auth.cpp Changed and cleaned the logic for debug message. 2015-09-30 19:41:27 +00:00
openssl_auth.cpp Changed and cleaned the logic for debug message. 2015-09-30 19:41:27 +00:00
s3fs_auth.h Move base64 and hex functions to string_util 2015-08-19 13:47:26 -07:00
s3fs_util.cpp loading IAM role name automatically(iam_role option) - #387 2016-05-06 04:37:32 +00:00
s3fs_util.h Added chacking cache dir perms at starting. 2015-08-23 03:57:34 +00:00
s3fs.cpp Use role name instead of profile name when iam_role=auto 2016-05-24 13:34:19 -04:00
s3fs.h Supported for SSE KMS 2015-10-06 14:46:14 +00:00
string_util.cpp NUL terminate decoded base64 string 2015-08-19 13:48:07 -07:00
string_util.h Move base64 and hex functions to string_util 2015-08-19 13:47:26 -07:00
test_string_util.cpp Add unit tests for base64 encoding and decoding 2015-08-19 13:49:10 -07:00
test_util.h Add unit tests for base64 encoding and decoding 2015-08-19 13:49:10 -07:00