[GH-ISSUE #1931] Add AWS SSO Authentifcation #970

Closed
opened 2026-03-04 01:50:19 +03:00 by kerem · 4 comments
Owner

Originally created by @VivienMoretto87 on GitHub (Apr 8, 2022).
Original GitHub issue: https://github.com/s3fs-fuse/s3fs-fuse/issues/1931

Hi,

I need to integrate the AWS SSO authentifcation in s3fs. I have just checked the opensource project aws-cli (SSOCredentialFetcher in credentials.py in the project https://github.com/aws/aws-cli/tree/v2/awscli ) and the s3fs seems not to be compatible with this kind of authentication.

I have modified the code :

  • get the cache json file with SSO credentials (it is the result sha1 of a json file { 'startUrl': self._start_url, 'roleName': self._role_name, 'accountId': self._account_id })
  • get credentials for the cache json file (parse the json with nlohmann library )

It seems to work.

Can you tell if it is possible to contribute the community by pushing my code and give some advises to have a clearer implementation ?

Regards,

Originally created by @VivienMoretto87 on GitHub (Apr 8, 2022). Original GitHub issue: https://github.com/s3fs-fuse/s3fs-fuse/issues/1931 Hi, I need to integrate the AWS SSO authentifcation in s3fs. I have just checked the opensource project aws-cli (SSOCredentialFetcher in credentials.py in the project https://github.com/aws/aws-cli/tree/v2/awscli ) and the s3fs seems not to be compatible with this kind of authentication. I have modified the code : - get the cache json file with SSO credentials (it is the result sha1 of a json file { 'startUrl': self._start_url, 'roleName': self._role_name, 'accountId': self._account_id }) - get credentials for the cache json file (parse the json with nlohmann library ) It seems to work. Can you tell if it is possible to contribute the community by pushing my code and give some advises to have a clearer implementation ? Regards,
kerem closed this issue 2026-03-04 01:50:19 +03:00
Author
Owner

@ggtakec commented on GitHub (Apr 10, 2022):

@VivienMoretto87 Thanks for your kindness.
s3fs-fuse doesn't currently support SSO authentication, so we'd appreciate it if you could make a PullRequest.
After that, @gaul and I will be able to review it.

As a solution to this problem, I am now submitting another PR (#1927).
This PR is the code to delegate the authentication process to an external DSO.
I think that combining this PR code with the DSO( https://github.com/ggtakec/s3fs-fuse-awscred-lib) should enable AWS SSO authentication.
This DSO just calls aws-sdk-cpp and it does the same authentication process as awscli and can get the tokens it needs.

If you are interested, I would be grateful if you could try # 1927 as well.

<!-- gh-comment-id:1094217203 --> @ggtakec commented on GitHub (Apr 10, 2022): @VivienMoretto87 Thanks for your kindness. s3fs-fuse doesn't currently support SSO authentication, so we'd appreciate it if you could make a PullRequest. After that, @gaul and I will be able to review it. As a solution to this problem, I am now submitting another PR (#1927). This PR is the code to delegate the authentication process to an external DSO. I think that combining this PR code with the DSO( https://github.com/ggtakec/s3fs-fuse-awscred-lib) should enable AWS SSO authentication. This DSO just calls aws-sdk-cpp and it does the same authentication process as awscli and can get the tokens it needs. If you are interested, I would be grateful if you could try # 1927 as well.
Author
Owner

@VivienMoretto87 commented on GitHub (Apr 10, 2022):

Thank you for the answer, I will push my code. I tested it Friday and it seems to work (other authentication too).

Regards,
Vivien

<!-- gh-comment-id:1094218821 --> @VivienMoretto87 commented on GitHub (Apr 10, 2022): Thank you for the answer, I will push my code. I tested it Friday and it seems to work (other authentication too). Regards, Vivien
Author
Owner

@Emru1 commented on GitHub (Sep 13, 2022):

Hey, can we expect this feature any time soon?
Looking forward to it

<!-- gh-comment-id:1244934988 --> @Emru1 commented on GitHub (Sep 13, 2022): Hey, can we expect this feature any time soon? Looking forward to it
Author
Owner

@ggtakec commented on GitHub (Mar 19, 2023):

#1927 adds credlib and credlib_ops options.
Authentication not currently supported by s3fs can be supported by specifying a dedicated DSO for these options.
Please try to create your own DSO or use a trusted one.
I provide https://github.com/ggtakec/s3fs-fuse-awscred-lib which can cover all AWS authentication.

We will continue to add support for AWS and other cloud-based authentication, but for now please try to use the above DSO for AWS authentication which are not supported by s3fs.

<!-- gh-comment-id:1475127051 --> @ggtakec commented on GitHub (Mar 19, 2023): #1927 adds `credlib` and `credlib_ops` options. Authentication not currently supported by s3fs can be supported by specifying a dedicated DSO for these options. Please try to create your own DSO or use a trusted one. I provide https://github.com/ggtakec/s3fs-fuse-awscred-lib which can cover all AWS authentication. We will continue to add support for AWS and other cloud-based authentication, but for now please try to use the above DSO for AWS authentication which are not supported by s3fs.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/s3fs-fuse#970
No description provided.