search

Home  >  Q&A  >  body text

android - 如何保证上传文件只能由上传者下载?

已经取消上传文件的外链,那么只能用FTP下载,但是我FTP下载代码是放在Android代码里的,那FTP账号密码也都要写在代码里?如何防止账号密码不泄露出去?

高洛峰高洛峰2831 days ago851

reply all(1)I'll reply

  • PHP中文网

    PHP中文网2017-04-17 11:33:28

    It is not recommended that you use FTP to download files on the client. Security is one aspect, and there is no CDN acceleration effect through FTP.
    You can enable Token anti-leeching, request your own server to calculate and obtain the Token before downloading the file, and then the client can directly download the file through HTTP.

    reply
    0
  • Cancelreply