The --ssh-key changed behavior between hardy-updates and hardy-proposed

Bug #254966 reported by Michael Vogt on 2008-08-05
16
This bug affects 1 person
Affects Status Importance Assigned to Milestone
VMBuilder
Undecided
Unassigned
ubuntu-vm-builder (Ubuntu)
Medium
Michael Vogt
Hardy
Undecided
Unassigned
Intrepid
Medium
Michael Vogt

Bug Description

Binary package hint: ubuntu-vm-builder

There is a regression in hardy-proposed compared to hardy-updates version of ubuntu-vm-builder.

From the debdiff:
 --ssh-key Add the given ssh public key file (absolute path)
- to root's authorized keys and install openssh-server
+ to user's authorized keys and install openssh-server
                    (WARNING: this has strong security implications)
...
        fi
        # we have a key, add it
        chroot root apt-get install --force-yes -y openssh-server
- mkdir root/root/.ssh
- cp "$SSHKEY" root/root/.ssh/authorized_keys
+ mkdir root/home/$VMUSER/.ssh
+ cp "$SSHKEY" root/home/$VMUSER/.ssh/authorized_keys
+ chroot root chown -R $VMUSER:$VMUSER /home/$VMUSER/.ssh
+}
+

Michael Vogt (mvo) wrote :

Here is the debdiff:

diff -Nru ubuntu-vm-builder-0.4/debian/changelog ubuntu-vm-builder-0.4/debian/changelog
--- ubuntu-vm-builder-0.4/debian/changelog 2008-06-04 16:33:48.000000000 +0200
+++ ubuntu-vm-builder-0.4/debian/changelog 2008-08-05 14:59:58.000000000 +0200
@@ -1,3 +1,12 @@
+ubuntu-vm-builder (0.4-0ubuntu0.4) hardy-proposed; urgency=low
+
+ * revert change in behavior from 0.4-0ubuntu0.1 and 0.4-0ubuntu0.2
+ for the --ssh-key option. It used to add a ssh key for root logins,
+ but with that version it changes that to a $VMUSER login.
+ This change restores the old (hardy-final) behavior (LP: #254966)
+
+ -- Michael Vogt <email address hidden> Tue, 05 Aug 2008 14:50:33 +0200
+
 ubuntu-vm-builder (0.4-0ubuntu0.3) hardy-proposed; urgency=low

   * Add --in-place option that will allow ubuntu-vm-builder to function when
diff -Nru ubuntu-vm-builder-0.4/ubuntu-vm-builder ubuntu-vm-builder-0.4/ubuntu-vm-builder
--- ubuntu-vm-builder-0.4/ubuntu-vm-builder 2008-06-03 14:09:49.000000000 +0200
+++ ubuntu-vm-builder-0.4/ubuntu-vm-builder 2008-08-05 15:00:59.000000000 +0200
@@ -114,7 +114,7 @@
                    if your \$TMPDIR is nodev and/or nosuid, but will result in
                    slightly larger file system images.
 --ssh-key Add the given ssh public key file (absolute path)
- to user's authorized keys and install openssh-server
+ to root's authorized keys and install openssh-server
                    (WARNING: this has strong security implications)
 --exec Run the given script file. You can use
                    'chroot root <cmd>' to execute code in the guest.
@@ -794,9 +794,8 @@
        fi
        # we have a key, add it
        chroot root apt-get install --force-yes -y openssh-server
- mkdir root/home/$VMUSER/.ssh
- cp "$SSHKEY" root/home/$VMUSER/.ssh/authorized_keys
- chroot root chown -R $VMUSER:$VMUSER /home/$VMUSER/.ssh
+ mkdir root/root/.ssh
+ cp "$SSHKEY" root/root/.ssh/authorized_keys
 }

 do_sourceslist () {

Michael Vogt (mvo) on 2008-08-05
Changed in ubuntu-vm-builder:
assignee: nobody → mvo
importance: Undecided → Medium
status: New → In Progress
Martin Pitt (pitti) wrote :

Is this an issue in intrepid as well? Please upload the fix to intrepid or set the task to invalid.

Changed in ubuntu-vm-builder:
status: New → Fix Committed
Martin Pitt (pitti) wrote :

Accepted into -proposed, please test and give feedback here. Please see https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Michael Vogt (mvo) wrote :

This is fixed in intrepid as well.

Changed in ubuntu-vm-builder:
status: In Progress → Fix Released
Jamie Strandboge (jdstrand) wrote :

0.4-0ubuntu0.4 requires the fix for http://www.ubuntu.com/usn/usn-670-1.

I am seeing this bug in version 0.9-0ubuntu3 of python-vm-builder.

Martin Pitt (pitti) wrote :

Anyone who can test ubuntu-vm-builder 0.4-0ubuntu0.4 in hardy-proposed?

Martin Pitt (pitti) wrote :

Testing ping?

If this doesn't get any feedback, we'll need to remove the -proposed version (-0ubuntu0.2 to 0.4)

Paul Elliott (omahn) wrote :

I would be happy to test this but I'm unsure as to the exact test case. Please could somebody clarify, am I simply testing the behavior of the --ssh-key command in hardy-proposed (0.4-0ubuntu0.4) works the same as in hardy-updates (0.4-0ubuntu0.1) ?

Steve Beattie (sbeattie) wrote :

I have verified that the version of ubuntu-vm-builder in hardy-proposed, 0.4-0ubuntu0.4, treats authorized_keys files passed in via the --ssh-key argument in the same manner as the version in hardy-updates, 0.4-0ubuntu0.1; that is, that the public key gets copied to /root/.ssh/authorized_keys in the guest. Marking verification-done.

(Also note the verifications done for bug 218195, bug 221231, bug 228268, bug 230319, bug 230299, bug 230334, bug 232361, bug 230312, and bug 228744, the testing for regressions done for bug 230323. I also didn't see any regressions while testing for each of those bugs.)

tags: added: verification-done
removed: verification-needed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-vm-builder - 0.4-0ubuntu0.4

---------------
ubuntu-vm-builder (0.4-0ubuntu0.4) hardy-proposed; urgency=low

  * revert change in behavior from 0.4-0ubuntu0.1 to 0.4-0ubuntu0.2
    for the --ssh-key option. It used to add a ssh key for root logins,
    but with that version it changes that to a $VMUSER login.
    This change restores the old (hardy-final) behavior (LP: #254966)

 -- Michael Vogt <email address hidden> Tue, 05 Aug 2008 14:50:33 +0200

Changed in ubuntu-vm-builder (Ubuntu Hardy):
status: Fix Committed → Fix Released
Charles Hooper (chooper) on 2009-08-15
Changed in vmbuilder:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers