[PATCH] https with basic http authentication

Bug #1015131 reported by Pali
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apt-mirror (Ubuntu)
Fix Released
Wishlist
Unassigned
Precise
Fix Released
Undecided
Unassigned

Bug Description

New wget version do not automatically send Basic HTTP authentication information (plaintext username and password) for all requests when specified username and password (old version Wget 1.10.2 and prior did it). In new version of wget was introduced param --auth-no-challenge which switch to old wget behaviour (see man 1 wget). Some apt servers (like server for Maemo 5 N900: https://downloads.maemo.nokia.com) needs to always receive Basic HTTP authentication. So I patched apt-mirror to added support for these servers with new version of wget. Patch adds new config variable auth_no_challenge (with 0 or 1) and apt-mirror exec wget with --auth-no-challenge if config is 1. It also add config variable no_check_certificate which disable checking SSL certificate for https (add wget param --no-check-certificate).

https support without basic http authentication working in apt-mirror without problem (with or without this patch).

[Impact]
* apt-mirror in precise refuse to mirror apt repository from https server with certificate not trusted by wget
* apt-mirror in precise does not working with http/https servers which needs basic http authentification
* new version 0.4.8-6 which is in quantal fixing both problems

[Test Case]
* try to mirror some apt repository with self signed https certificate or which needs to receive basic http authentification
* without patch apt-mirror fail
* one example is maemo5 repositories, full config file is on:
http://wiki.maemo.org/Apt-mirror#mirror.list_for_Maemo_5_Fremantle

[Regression Potential]
* patch is simple and does not chaning default values and code, so it should not break anything
* it is in debian and quantal for a long time and no problem was reported

Revision history for this message
Pali (pali) wrote :
Revision history for this message
Pali (pali) wrote :

This patch propably fixing bug #1003672

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "apt-mirror-https.patch" of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

Benjamin Drung (bdrung)
Changed in apt-mirror (Ubuntu):
status: New → Fix Committed
importance: Undecided → Wishlist
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apt-mirror - 0.4.8-6

---------------
apt-mirror (0.4.8-6) unstable; urgency=low

  * Fix regex problem: arm overrides armhf. Thanks to hawken. (Closes: #682395)
  * Bump Standard-Version to 3.9.3 (no changes needed).
  * Add support for HTTPS with basic HTTP authentication. Thanks to Pali
    for the patch. (LP: #1015131)

 -- Benjamin Drung <email address hidden> Fri, 27 Jul 2012 00:51:30 +0200

Changed in apt-mirror (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Pali (pali) wrote :

Will be this new version 0.4.8-6 backported to ubuntu 12.04?

Revision history for this message
Brian Murray (brian-murray) wrote :

If you are interested in seeing this added to the version of apt-mirror in Precise please follow the Stable Release Updates procedure documented at http://wiki.ubuntu.com/StableReleaseUpdates. Thanks!

Revision history for this message
Pali (pali) wrote :

Who can promote backporting this patch to LTS precise release?

Pali (pali)
description: updated
Revision history for this message
Phillip Susi (psusi) wrote :

You need to nominate a bug task for precise and ask a manager in #ubuntu-bugs to approve it.

Revision history for this message
Benjamin Drung (bdrung) wrote :

@Pali: Everyone can go ahead and prepare a patch.

I have prepared a patch (attached) and uploaded it to precise-proposed.

Revision history for this message
Benjamin Drung (bdrung) wrote :
Changed in apt-mirror (Ubuntu Precise):
status: New → Fix Committed
Revision history for this message
Benjamin Drung (bdrung) wrote :

Here's an updated debdiff that reference bug #977278.

Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Pali, or anyone else affected,

Accepted apt-mirror into precise-proposed. The package will build now and be available at http://launchpad.net/ubuntu/+source/apt-mirror/0.4.8-5ubuntu0.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed
Revision history for this message
Pali (pali) wrote :

Now I tested updated apt-mirror package from precise-proposed/universe and it working fine for mirroring maemo5 apt repositories.

Pali (pali)
tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apt-mirror - 0.4.8-5ubuntu0.2

---------------
apt-mirror (0.4.8-5ubuntu0.2) precise-proposed; urgency=low

  * Fix regex problem: arm overrides armhf. Thanks to hawken.
    (Closes: #682395, LP: #977278)
  * Add support for HTTPS with basic HTTP authentication. Thanks to Pali
    for the patch. (LP: #1015131)
 -- Benjamin Drung <email address hidden> Fri, 22 Nov 2013 00:03:34 +0100

Changed in apt-mirror (Ubuntu Precise):
status: Fix Committed → Fix Released
Revision history for this message
Brian Murray (brian-murray) wrote : Update Released

The verification of the Stable Release Update for apt-mirror has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regresssions.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.