VirtualBox

Ticket #19518 (closed defect: fixed)

Opened 6 weeks ago

Last modified 4 weeks ago

Guest command execution fails if more than 2 environment vars are provided => fixed in svn/6.1.x x>6

Reported by: mskov Owned by: paulson
Component: guest additions Version: VirtualBox 6.1.6
Keywords: Cc:
Guest type: Linux Host type: Windows

Description

If more than 2 environment vars are provided during the guest command execution, we get an error VERR_ENV_INVALID_VAR_NAME:

C:\WINDOWS\system32>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" guestcontrol TestVM run --username root --password keins --exe /bin/ls --putenv "test1=test" --putenv "test2=test" --putenv "test3=test" --wait-stdout
VBoxManage.exe: error: VERR_ENV_INVALID_VAR_NAME
VBoxManage.exe: error: Details: code VBOX_E_IPRT_ERROR (0x80bb0005), component GuestProcessWrap, interface IGuestProcess, callee IUnknown
VBoxManage.exe: error: Context: "WaitForArray(ComSafeArrayAsInParam(aWaitStartFlags), gctlRunGetRemainingTime(msStart, cMsTimeout), &waitResult)" at line 1470 of file VBoxManageGuestCtrl.cpp

With 2 vars it works fine:

C:\WINDOWS\system32>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" guestcontrol TestVM run --username root --password keins --exe /bin/ls --putenv "test1=test" --putenv "test2=test" --wait-stdout
bin
boot
data
dev
....

The problem happens with a Debian 10 guest with GAs 6.1.6. It does not happen with GAs 6.1.4 (or earlier).

Change History

comment:1 Changed 4 weeks ago by paulson

  • Owner set to paulson
  • Status changed from new to assigned

Thanks for the report. The environment variable handling in VBoxService was simplified in VirtualBox revision r83269 in the development branch and these changes were backported to 6.0.20 and 6.1.6. However a regression was introduced in that changeset which broke the handling of environment variables when there are more than two of them. A fix is in progress.

Last edited 4 weeks ago by paulson (previous) (diff)

comment:2 Changed 4 weeks ago by paulson

  • Status changed from assigned to closed
  • Resolution set to fixed
  • Summary changed from Guest command execution fails if more than 2 environment vars are provided to Guest command execution fails if more than 2 environment vars are provided => fixed in svn/6.1.x x>6

This has been addressed in revision r137736 of the development branch of VirtualBox and will be available in any development snapshot Testbuilds of the Guest Additions which includes that revision. The fix has also been backported to the 6.1 branch of VirtualBox as of revision r137747 and will be available in any 6.1.x Testbuilds of the Guest Additions which include that revision. The fix will also be part of the next maintenance release of VirtualBox 6.1.x.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use