Cloudreve icon indicating copy to clipboard operation
Cloudreve copied to clipboard

Allow configuration of share link length

Open Nullpntr1337 opened this issue 3 weeks ago • 3 comments

Is your feature request related to a problem? Please describe. Yes. Currently, the generated share links are extremely short, which makes them vulnerable to brute‑force guessing. This raises privacy and security concerns, as unauthorized users might be able to access shared files simply by enumerating possible link combinations.

Describe the solution you'd like I would like an option for users to configure the length (and possibly complexity) of share links. For example, allowing users to choose between standard, long, or custom‑length tokens would increase security and reduce the risk of brute‑forcing.

Describe alternatives you've considered

Additional context

Nullpntr1337 avatar Dec 06 '25 11:12 Nullpntr1337

The share link is generated directly based on share_id via hash, and its length grows with larger id.

YUDONGLING avatar Dec 06 '25 12:12 YUDONGLING

The share link is generated directly based on share_id via hash, and its length grows with larger id.

I don't fully understand. Can share_id be changed?

Nullpntr1337 avatar Dec 06 '25 17:12 Nullpntr1337

The share link is generated directly based on share_id via hash, and its length grows with larger id.

I don't fully understand. Can share_id be changed?

[!CAUTION] You may change id in table shares in database directly, BUT, after that, the previous share link to this record will be NOT available.

You may also set the AUTO_INCREMENT to a large number, then all newly generated share links will be longer.

Image

YUDONGLING avatar Dec 08 '25 03:12 YUDONGLING