Project

General

Profile

Bug #17598

Updated by Peter Amstutz almost 3 years ago

 
 With a config like this: 

 <pre> 
       WebDAVDownload: 
         ExternalURL: https://download.xxxx1.arvadosapi.com:443 
 </pre> 

 keep-web does a literal comparison of ExternalURL.Host with a http.Request.Host in `services/keep-web/handler.go` line 251, and the superfluous :443 in the config trips that up, which causes it to go into "turtle mode" and fall back to the anonymous token. In the normal (i.e. no anonymous access) case, that breaks all downloads with a 401, for example it makes viewing collection contents in WB2 fail. 

 keep-web should handle the special cases of :443 and :80 correctly. 

 two other lessons learned that need to be fixed: 

 # if AnonymousUserToken is empty, don't add it to 'tokens' in handler.go:349 
 # if "credentialsOK" is not true on like 295, it should log a warning saying that it is refusing to accept credentials, and give some indication why 

Back