Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

从机driver中urlEncode代码错误 #1051

Closed
luyu6056 opened this issue Nov 12, 2021 · 1 comment
Closed

从机driver中urlEncode代码错误 #1051

luyu6056 opened this issue Nov 12, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@luyu6056
Copy link

pkg/filesystem/driver/remote/handler.go中
URLEncode是QueryEscape,这里错误的使用了decode函数QueryUnescape,这是一个严重的错误,会导致如xxx%xxx文件无法保存

@HFO4 HFO4 added the bug Something isn't working label Nov 13, 2021
@luyu6056
Copy link
Author

还发现了一个错误
pkg/filesystem/driver/remote/handler.go里面
func (handler Driver) Source函数,签名时候需要对fileName进行url.QueryEscape,否则上述文件会签名失败,参考代码signedURI, err = auth.SignURI( handler.AuthInstance, fmt.Sprintf("%s/%d/%s/%s", controller, speed, sourcePath, url.QueryEscape(fileName)), ttl, )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants