drakkan / sftpgo

Full-featured and highly configurable SFTP, HTTP/S, FTP/S and WebDAV server - S3, Google Cloud Storage, Azure Blob
https://sftpgo.com
GNU Affero General Public License v3.0
9.52k stars 739 forks source link

Allow users to create API keys in WebClient UI #1725

Open fostermi opened 3 months ago

fostermi commented 3 months ago

Is your feature request related to a problem? Please describe.

Unless I'm misunderstanding this, if sftpgo is configured to use OIDC for its authentication system, there is no way for users to use the REST API as they will not be able to create a JWT token from sftpgo (/api/v2/user/token) because there is no local user for sftpgo to validate the username/password to the token endpoint. There should be a way to create the key in the UI.

Describe the solution you'd like

Just like with SSH keys, there should be a section to generate and store API keys (non-recoverable) to allow programmatic access to sftpgo via HTTPS instead of SSH/SFTP. As a nice to have, would be a way to set an expiration date on the API key.

Describe alternatives you've considered

No response

What are you using SFTPGo for?

Medium business

Additional context

This is similar to https://github.com/drakkan/sftpgo/issues/1623 but for regular users, who supposedly are allowed to use the REST API as well.