Bug 1210275

Summary: DNF doesn't support http authentication
Product: [Fedora] Fedora Reporter: Kim B. Heino <b>
Component: dnfAssignee: Michael Mráka <mmraka>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: jsilhan, mluscon, mmraka, packaging-team-maint, pnemade, rholy, tim.lauridsen, vmukhame
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: dnf-plugins-core-0.1.7-1.fc22 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-05-08 07:27:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Add user/pass support for repositories none

Description Kim B. Heino 2015-04-09 10:28:31 UTC
Created attachment 1012640 [details]
Add user/pass support for repositories

Description of problem:

With YUM you can use HTTP basic authentication (username and password keywords) in repositories:

[reponame]
username=foo
password=bar
baseurl=https://domain.invalid/repo/$releasever/$basearch/
...

This is not supported by DNF. 


Version-Release number of selected component (if applicable):

dnf-0.6.4-1.fc21


How reproducible:

Enable HTTP basic authentication on web server and try to download metadata or package with dnf.


Steps to Reproduce:
1.
2.
3.

Actual results:

HTTP error 401.


Expected results:

Download success.


Additional info:

Attached single line patch fixes this problem.

Comment 1 Michael Mráka 2015-04-14 12:10:55 UTC
Fixed in upstream by
https://github.com/rpm-software-management/dnf/pull/251

Comment 2 Fedora Update System 2015-05-02 13:49:46 UTC
dnf-plugins-core-0.1.7-1.fc22,hawkey-0.5.5-1.fc22,dnf-1.0.0-1.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/dnf-plugins-core-0.1.7-1.fc22,hawkey-0.5.5-1.fc22,dnf-1.0.0-1.fc22

Comment 3 Fedora Update System 2015-05-03 17:24:41 UTC
Package dnf-plugins-core-0.1.7-1.fc22, hawkey-0.5.5-1.fc22, dnf-1.0.0-1.fc22:
* should fix your issue,
* was pushed to the Fedora 22 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing dnf-plugins-core-0.1.7-1.fc22 hawkey-0.5.5-1.fc22 dnf-1.0.0-1.fc22'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-7483/dnf-plugins-core-0.1.7-1.fc22,hawkey-0.5.5-1.fc22,dnf-1.0.0-1.fc22
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2015-05-08 07:27:22 UTC
dnf-plugins-core-0.1.7-1.fc22, hawkey-0.5.5-1.fc22, dnf-1.0.0-1.fc22 has been pushed to the Fedora 22 stable repository.  If problems still persist, please make note of it in this bug report.