更改测试
This commit is contained in:
parent
ad04506904
commit
e14729f621
@ -25,7 +25,7 @@ public class DownloadController : Controller
|
|||||||
[HttpGet("")]
|
[HttpGet("")]
|
||||||
public IActionResult Download(string fileName, string sign, long t)
|
public IActionResult Download(string fileName, string sign, long t)
|
||||||
{
|
{
|
||||||
// 1. 校验时效(5分钟内有效)
|
// 1. 校验时效(5分钟内有效)--
|
||||||
var now = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
var now = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds();
|
||||||
if (now - t > 300000)
|
if (now - t > 300000)
|
||||||
return BadRequest("过期访问!");
|
return BadRequest("过期访问!");
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user