|
...
|
...
|
@@ -47,7 +47,7 @@ class TencentCosService extends BaseService |
|
|
|
$contentType = 'image/'.$image_type;
|
|
|
|
date_default_timezone_set('Asia/Shanghai');
|
|
|
|
$date = date('D, d M Y H:i:s \G\M\T');
|
|
|
|
$expiredTime = ( time() - 60 ) . ';' . ( string )( strtotime( '+30 minutes' ) );
|
|
|
|
$expiredTime = time() + 3600000;
|
|
|
|
$filePath = $path.'/'.$fileName;
|
|
|
|
$stringToSign = "{$httpVerb}\n{$contentMd5}\n{$contentType}\n{$date}\n/{$this->config['bucket']}/{$filePath}";
|
|
|
|
$sign = base64_encode(hash_hmac('sha1', $stringToSign, $this->config['secretKey'], true));
|
...
|
...
|
|