Michael wrote: > I send you this email because I have a trouble to download some files. > Since the last change of the FileTransfer.js, I can't download files containing > in their name an <@< (for example : < [email protected] >).
That sounds like this file:
cordova-plugin-file-transfer/www/FileTransfer.js
function getUrlCredentials(urlString) {
var credentialsPattern = /^http\:\/\/((.*?)\:(.*?))@.*$/g,
credentials = credentialsPattern.exec(urlString);
return credentials && credentials[1];
}
And yes, its regular expression is horribly broken.
https://github.com/blackberry/cordova-blackberry/commit/a6d166a03b38bb591c3e
2d3f85146ed84d3b6cd4
has the regexp I recently fixed cordova-blackberry to use because of a
similar complaint.
> I found the source of my problem. It is on the download function which
calls
> the getUrlCredentials function.
> It changes my remote source url. It replaces my url to a new url without
all
> characters before @.
> For example, if my source is :
> http://myServer/files/images/myPicture@2015/jpg the function try to
> download a file with url : http://2015.jpg.
> I think it's a regression linked to the fixed of the CB-7316 Improves
current
> specs compatibility.
> PS : I tried to send anle email to [email protected] but I
received a
> failure notice.
You should either file a bug a bug:
https://issues.apache.org/jira/browse/CB/
or comment on
https://issues.apache.org/jira/browse/CB-7316 directly.
smime.p7s
Description: S/MIME cryptographic signature
