[PATCH rhel6 master] Check for proper Proxy URL in loader (#604126)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Make sure the Proxy url starts with http or ftp://

Resolves: rhbz#604126
---
 loader/urls.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/loader/urls.c b/loader/urls.c
index 701f1c5..dbf343a 100644
--- a/loader/urls.c
+++ b/loader/urls.c
@@ -341,6 +341,12 @@ int urlMainSetupPanel(struct loaderData_s *loaderData, struct iurlinfo * ui) {
             ui->url = strdup(url);
 
             if (enableProxy == '*') {
+               if (strncmp(proxy, "http", 4) && strncmp(proxy, "ftp://";, 6)) {
+                   newtWinMessage(_("Error"), _("OK"),
+                                  _("Proxy must be either an ftp or http URL"));
+                   continue;
+               }
+
                loaderData->proxy = strdup(proxy);
                loaderData->proxyUser = strdup(proxyUser);
                loaderData->proxyPassword = strdup(proxyPassword);
-- 
1.7.0.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux