jfrog-cli icon indicating copy to clipboard operation
jfrog-cli copied to clipboard

Change default expiry for access token creation

Open DavidRadoorHummel opened this issue 3 years ago • 1 comments

Hello,

When attempting to create an access token:

jf rt atc developeruser --expiry=5000 --server-id=devuser

If you're non-admin, you'll get the error:

{
  "error": "invalid_request",
  "error_description": "The user: 'developeruser' can only create user token with expires in larger than 0 and smaller than 3600 seconds (requested: 5000)"
}

This threshold of 3600 seconds seems arbitrarily defined and is not in reference to any system configuration in Artifactory. In this concrete example, developeruser can create identity tokens with a default expiry of 31 days (2,678,400 seconds).

In our use-case a max value of 3600 is worthless - is there a way to increase the threshold? Is there a setting in Artifactory that we somehow missed? Or is this a limitation of JFrog CLI?

Best regards David

DavidRadoorHummel avatar Nov 23 '22 11:11 DavidRadoorHummel

Please reevaluate the reason for having the max expiry access token value as a constant set to 3600 seconds.

There should be no reason to even limit this value in the CLI client since the Artifactory instance it is communicating with will limit expiry based on the system configuration.

gangefors avatar Feb 14 '23 11:02 gangefors

This issue has been marked as stale due to 6 months of inactivity. As part of our effort to address every issue properly, please feel free to remove the stale label or keep this issue active by leaving a comment. Otherwise, it will be closed in 7 days

github-actions[bot] avatar Sep 23 '25 07:09 github-actions[bot]

This issue was closed due to 7 days of inactivity after being marked as stale. Feel free to reopen it if it remains relevant.

github-actions[bot] avatar Oct 02 '25 00:10 github-actions[bot]