When creating a HTTP proxy the username and password is used verbatim, leading to issues if they contain special characters
Steps to Reproduce:
1. Configure a squid proxy with the following details.
proxy: password: test]satellite@password+
2. Go to Satellite GUI --> Infrastructure --> HTTP Proxies --> Fill up all the details including the proxy_password, in Test URL mention "https://aws.amazon.com" and then click on "Test Connection".
3. With all options filled up, submit the settings.
4. Now open the newly created proxy and look at the password field.
At Step 2, with test connection, you will get an error pop up saying "bad password component"
At Step 4, we will be able to see that the password is blank
Satellite 6.7 should be able to accept the password with special characters properly and allow it to save\user further from GUI.
There are two issues at play here.
The first is on our side. We try to stuff the user provided strings into an URI object, but that fails because special characters are not allowed there. If we escape the user provided strings first (turn '@' into '%40' and so on), this part should be resolved.
The other issue is restclient (the library we use for making http requests) does not unescape the proxy username and password, so even if we fix the first issue, then the escaped form will be sent to the proxy and the proxy will reject it. There is a PR1 opened against restclient which fixes this, but last movement there was in October 2018, so I'm afraid we can't wait for this to be fixed there. Unless I'm missing something the only real option we have is to monkey-patch restclient the same way ManageIQ did2.