-
-
Notifications
You must be signed in to change notification settings - Fork 7
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
Some uri escape to %2520 instead of %20 #17
Comments
Just some clarification (and a reminder for myself) on what the issue actually is. The URL from dropbox is already correctly escaped when we get it, as such the |
OK I have an idea that might solve the bug |
hmm, just playing with a thought here and wanted your input. Could perhaps add a check to see if the url matches the following |
I believe that would be the easiest right now, and could perhaps improve the check over time when needed. |
Yeah that would be the easiest too, 😄 |
wait, I was a little quick. I actually meant |
a new version was pushed to chocolatey now, I'll update the core team repo when it has been approved. |
Get-RedirectedUrl "https://www.dropbox.com/download?build=48.4.58&plat=win&type=full"
Get-RedirectedUrl "https://electron.authy.com/download?channel=stable&arch=x64&platform=win32&version=latest&product=authy"
both of these urls should return the same with spaces escaped to
%20
, and they don't right nowExpected Behavior
If you're describing a bug, tell us what should happen
When using the powershell command
[uri]::EscapeUriString($url)
in
Get-RedirectedUrl
helperthe result is
https://clientupdates.dropboxstatic.com/dbx-releng/client/Dropbox%252048.4.58%2520Offline%2520Installer.exe
when it should be
https://clientupdates.dropboxstatic.com/dbx-releng/client/Dropbox%252048.4.58%20Offline%20Installer.exe
Current Behavior
If describing a bug, tell us what happens instead of the expected behavior
The current behavior results in a 403 forbidden error
Possible Solution
The easiest fix is to PR the
Get-RedirectedUrl
helper to have a switch for EscapeUriString usagePR submitted with automated check also with regex
Steps to Reproduce (for bugs)
Get-RedirectedUrl "https://www.dropbox.com/download?build=48.4.58&plat=win&type=full"
Get-RedirectedUrl "https://electron.authy.com/download?channel=stable&arch=x64&platform=win32&version=latest&product=authy"
Context
Your Environment
The text was updated successfully, but these errors were encountered: