juno icon indicating copy to clipboard operation
juno copied to clipboard

Add option to regenerate asset token in the storage view

Open peterpeterparker opened this issue 7 months ago • 3 comments

Description

Assets in the storage can be made private by requiring a token for access.

For example:

  • Public URL which won't resolve and fail: /image/mydata.jpg
  • Private URL (with token) that succeed: /image/mydata.jpg?token=11223

Currently, once a token is created, there is no way to regenerate it from the Console.

Proposed solution

In the Console Storage view, when viewing the details of an asset:

  • Display a small "Regenerate token" (reload icon?) button next to the token.
  • Clicking the button opens a confirmation modal.
  • If the user confirms, the token is regenerated.
  • The new token is then displayed in the details view.

Expected behavior:

  • Users can regenerate tokens for private assets directly from the Console.
  • A confirmation step prevents accidental regeneration.
  • The updated token is immediately usable in the asset URL.

This will give developers better control over access to private assets and improve security hygiene.

Image

peterpeterparker avatar May 23 '25 13:05 peterpeterparker

Hi @peterpeterparker, can I take this up? Also, if you can suggest some quick wins! 😃

Malay-dev avatar Sep 30 '25 06:09 Malay-dev

Thanks for the interest @Malay-dev. Following your question, I had a deeper look and noticed that it actually requires some backend work as well, so it turns into quite a heavier job as I had foreseen. I think it’s probably quite an effort, as it would also require several separate PRs across Rust, tests, and frontend code. Therefore, I’ve removed it from the list of tasks for Hacktoberfest.

peterpeterparker avatar Sep 30 '25 07:09 peterpeterparker

Oh, I assumed there would be an existing API that I could hit and re-generate the token, then populate it back. No Problem, I'll check on other issues. Or if you have any suggestions, I'll take them up.

Malay-dev avatar Sep 30 '25 07:09 Malay-dev

Resolved. Will be shipped with next release.

peterpeterparker avatar Dec 01 '25 16:12 peterpeterparker