Bug 159200 - up2date ISA proxy yum problem
up2date ISA proxy yum problem
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: python (Show other bugs)
4.0
All Linux
medium Severity medium
: ---
: ---
Assigned To: Dave Malcolm
BaseOS QE - Apps
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-05-31 11:08 EDT by Stephen Webb
Modified: 2012-06-20 12:07 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-06-20 12:07:33 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Bugzilla 102272 None None None Never

  None (edit)
Description Stephen Webb 2005-05-31 11:08:51 EDT
Description of problem:
I am not able to update packages from and internal yum repo. I feel that I have
tracked to problem down to my Microsoft ISA proxy server. I have tryed setting
the environment variables: http_proxy proxy_user proxy_passwd. This does not
seem to help at all. I have removed the ES 4 machine from out DMZ and it updates
from our yum repo just fine.

Also I feel that up2date should fail gracefully if it can not contact a up2date
source. Currently,if I have a yum source configured, the machine will not update
anything from RHN. I can see that it might take awhile to fail on the bad
source, but it should continue on the valid (or contactable sources) 


Version-Release number of selected component (if applicable):
Name        : up2date                      Relocations: (not relocatable)
Version     : 4.4.5.6                           Vendor: Red Hat, Inc.
Release     : 2                             Build Date: Thu 31 Mar 2005 11:39:54
AM CST
Install Date: Tue 17 May 2005 05:35:21 PM CDT      Build Host:
decompose.build.redhat.com
Group       : System Environment/Base       Source RPM: up2date-4.4.5.6-2.src.rpm
Size        : 5403428                          License: GPL
Signature   : DSA/SHA1, Thu 31 Mar 2005 01:18:29 PM CST, Key ID 219180cddb42a60e
Packager    : Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>
URL         : http://rhn.redhat.com
Summary     : Determines which system packages need to be updated via RHN.
Description :
The Red Hat Update Agent that automatically queries the Red Hat
Network servers and determines which packages need to be updated on
your machine.


Steps to Reproduce:
1. export http_proxy=http://xxxxxx.com:8080
2. export proxy_user=xxxxxxxx
3. export proxy_passwd=xxxxxxx
4. up2date -l
  
Actual results:
[root@localhost rhn]# up2date -l
There was a fatal error communicating with the server. The message was:

An HTTP error occurred:
URL: http://yum.internal/redhat/el4/en/i386/internal/headers/header.info
Status Code: 407
Error Message: Proxy Authentication Required ( The ISA Server requires
authorization to fulfill the request. Access to the Web Proxy service is denied.  )
Comment 1 Gene Dellinger 2005-09-15 21:30:21 EDT
I have just run into the same problem on RHEL3(stock everything). This was my 
first attempt to run up2date via a proxy server. I received the same error 
message. I provided proxyUser, proxyPassword, enableproxy=1, enableproxyauth=1 
all to no avail.

running 2.4.21-4.ELsmp
Comment 2 Gene Dellinger 2005-09-15 21:34:41 EDT
Additional comment:
I was trying to connect to the default URL's pre-configured in up2date.
Comment 3 Dayaanaand Ghule 2006-03-29 06:55:26 EST
This is due to python not handeling the sting user and proxy properly 

export http_proxy="http://$username:$password@$proxyserver:$proxyport/"
export ftp_proxy="http://$username:$password@$proxyserver:$proxyport/"
export HTTP_PROXY="http://$username:$password@$proxyserver:$proxyport/"
export FTP_PROXY="http://$username:$password@$proxyserver:$proxyport/"



Make follwoing changes to /usr/lib/python2.4/urllib2.py file 

  user, password = user_pass.split(':', 1)
                 user_pass = base64.encodestring('%s:%s' % (unquote(user),
                                                            unquote(password)))
+                user_pass = user_pass.strip()
                 req.add_header('Proxy-authorization', 'Basic ' + user_pass)
         host = unquote(host)
         req.set_proxy(host, type)


And the it works 

NOT A BUG WITH YUM
Comment 5 Miroslav Suchý 2010-04-09 05:21:43 EDT
If you set password and proxy from environment and tno in /etc/sysconfig/rhn/up2date, then it is is most probably urllib2.py problem, which is python.
Changing component.
Comment 6 Robert Barnett 2010-07-13 02:43:48 EDT
I've found that the @ symbol is not supported in the username for RHEL5.
I tried substituting it with %40 but the authentication fails
Comment 7 Jiri Pallich 2012-06-20 12:07:33 EDT
Thank you for submitting this issue for consideration in Red Hat Enterprise Linux. The release for which you requested us to review is now End of Life. 
Please See https://access.redhat.com/support/policy/updates/errata/

If you would like Red Hat to re-consider your feature request for an active release, please re-open the request via appropriate support channels and provide additional supporting details about the importance of this issue.

Note You need to log in before you can comment on or make changes to this bug.