]> git.ipfire.org Git - thirdparty/open-vm-tools.git/log
thirdparty/open-vm-tools.git
8 years agoRemove Str_Mbscpy and Str_Mbscat
Oliver Kurth [Mon, 23 Oct 2017 21:21:18 +0000 (14:21 -0700)] 
Remove Str_Mbscpy and Str_Mbscat

Since we assume that all non-wide-char strings are UTF-8, the
implementations of Str_Mbscpy and Str_Mbscat are basically
identical to those of Str_Strcpy and Str_Strcat.  We thus do
not need the Str_Mbs versions.

8 years agoGOSTable: Linux 4.x kernel
Oliver Kurth [Mon, 23 Oct 2017 21:21:18 +0000 (14:21 -0700)] 
GOSTable: Linux 4.x kernel

Add Linux 4.x entries to the Guest OS table.

8 years agolib/file: FileIO_AtomicUpdateEx ASSERT
Oliver Kurth [Mon, 23 Oct 2017 21:21:18 +0000 (14:21 -0700)] 
lib/file: FileIO_AtomicUpdateEx ASSERT

ASSERT(File_IsSameFile(dirName, dstDirName)) fired when NFS went
down at just the right moment.  It was not obvious that the ASSERT
fired due to an NFS failure.

File_IsSameFile correctly returns errno upon failure.  Check the
errno value to properly detect and return an error.

8 years agoWith the build of VMware Tools 10.2.0 product shifted to the
Oliver Kurth [Mon, 2 Oct 2017 22:28:57 +0000 (15:28 -0700)] 
With the build of VMware Tools 10.2.0 product shifted to the
product release branch, changing the 10.2.0 release macros to
reflect that change of status.

8 years agoUpdate the Tools-10.2.0-Beta Open Source License Files.
Oliver Kurth [Mon, 2 Oct 2017 22:28:57 +0000 (15:28 -0700)] 
Update the Tools-10.2.0-Beta Open Source License Files.

8 years agoupdate release notes and ChangeLog stable-10.1.x 10.1.15 stable-10.1.15
Oliver Kurth [Fri, 29 Sep 2017 22:21:10 +0000 (15:21 -0700)] 
update release notes and ChangeLog

8 years agoupdate version numbers
Oliver Kurth [Fri, 29 Sep 2017 21:03:35 +0000 (14:03 -0700)] 
update version numbers

8 years agoUpdate the Tools-10.1.15 Open Source License Files.
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
Update the Tools-10.1.15 Open Source License Files.

8 years agoIf for some reason RandR12GetInfo failed to return RandR12Info,
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
If for some reason RandR12GetInfo failed to return RandR12Info,
it should not follow the cleanup path to free it. Instead it
should return FALSE.

8 years agoTools Hgfs Plugin: refresh Hgfs drives on client start
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
Tools Hgfs Plugin: refresh Hgfs drives on client start

In order to get Explorer to see that VMware Shared Folders drives are
available when the feature is enabled, we touch each drive that is
mapped as a VMware Shared Folder.  This is to prevent users being
confused when the have the feature enabled but Explorer creates the
user's drive mappings before the tools service has initialized the
Hgfs plugin and started the Hgfs client.  In this situation the drives
were marked as red (disconnected) until the user clicks on the mapped
drive.  Then Explorer will refresh the connction and set it to green
(connected).

8 years agoFor FreeBSD 11 and later the correct osname is "freeBSD11".
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
For FreeBSD 11 and later the correct osname is "freeBSD11".
Without the correct osname, guestInfo ends up with wrong guestId
and guestFullName.  Adjust the osname based on the FreeBSD release.

8 years agoReport version data via guestinfo vars.
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
Report version data via guestinfo vars.

8 years agoBump VMTools version to 10.1.15 for the next 10.1.x update release
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
Bump VMTools version to 10.1.15 for the next 10.1.x update release

Define TOOLS_VERSION_SCREW_DRIVER_UPDATE3 as 10.1.15.

8 years agoAdd entries for MacOS 10.13 (High Sierra) to guest_os_tables.h.
Oliver Kurth [Fri, 29 Sep 2017 19:52:44 +0000 (12:52 -0700)] 
Add entries for MacOS 10.13 (High Sierra) to guest_os_tables.h.

8 years agocopy README.md from master
Oliver Kurth [Fri, 15 Sep 2017 18:47:09 +0000 (11:47 -0700)] 
copy README.md from master

8 years agoupdate version to 10.2.0
Oliver Kurth [Fri, 15 Sep 2017 18:32:25 +0000 (11:32 -0700)] 
update version to 10.2.0

8 years agosync libDeployPkg files
Oliver Kurth [Fri, 15 Sep 2017 18:35:01 +0000 (11:35 -0700)] 
sync libDeployPkg files

8 years agoGuestStats: Report memNeeded on ESX as a guest
Oliver Kurth [Fri, 15 Sep 2017 18:23:58 +0000 (11:23 -0700)] 
GuestStats: Report memNeeded on ESX as a guest

8 years agoGOSTable: Add MacOS 10.14 and FreeBSD 12
Oliver Kurth [Fri, 15 Sep 2017 18:23:58 +0000 (11:23 -0700)] 
GOSTable: Add MacOS 10.14 and FreeBSD 12

8 years agoGuest OS: Add CentOS 8, OracleLinux 8, and AsiaNux 8
Oliver Kurth [Fri, 15 Sep 2017 18:23:58 +0000 (11:23 -0700)] 
Guest OS: Add CentOS 8, OracleLinux 8, and AsiaNux 8

8 years agolib/file: Remove long dead functions from file.h
Oliver Kurth [Fri, 15 Sep 2017 18:23:58 +0000 (11:23 -0700)] 
lib/file: Remove long dead functions from file.h

These routines no longer exist. Remove them from the header file.

8 years agoRevert part of the previous commit.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Revert part of the previous commit.

Remove the VIM mapping for now.

8 years agoguestOS: Add SLES 15 and RHEL 8
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
guestOS: Add SLES 15 and RHEL 8

8 years agoChange to common header file; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Change to common header file; not applicable to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoChanges to common header files; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Changes to common header files; not applicable to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agolib/file: Improve File_CreateDirectoryHierarchy error detection
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
lib/file: Improve File_CreateDirectoryHierarchy error detection

8 years agoFix processing RPC data in TimeSync RPC handler
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Fix processing RPC data in TimeSync RPC handler

RPC data is whitespace delimited string and any leading whitespaces need to
be ignoreed before processing data. The data here indicates whether timeSync
should do a backward sync on this RPC callback.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:57 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoAdjust some logging levels
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Adjust some logging levels

Make some of the more common vgauth failure cases show up at default
debug level.

8 years agoAdd support for 64-bit inodes in FreeBSD 12
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Add support for 64-bit inodes in FreeBSD 12

FreeBSD 12 is switching to 64-bit inodes which will cause some ABI
breakage in user code.  This fix modifies the getdirentries() syscall
used in hgfsServerLinux.c for that FBSD 12 64-bit inodes.

The fix was provided by Josh Paetzel in open-vm-tools pull request
https://github.com/vmware/open-vm-tools/pull/190

8 years agoEnable bsd_vsnprintf for __ANDROID__
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Enable bsd_vsnprintf for __ANDROID__

Remove the __ANDROID__ check from Str_Vsnprintf, et al.  It's
not supposed to be there anymore.

8 years agoAdd support to check if a native guest time sync service is running.
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Add support to check if a native guest time sync service is running.

This change adds support to VMware tools timesync to identify if a guest
native time synchronization service is running. If a native sync service is
running, then a resync command is issued. If native time sync service is not
running, we fall back on legacy VMware tools onetime sync to do guest time
correction.

We also post a callback to do legacy VMware tools onetime sync after a
timeout period. A timeout can be configured if guest native resync command
fails to sync guest time.

8 years agoFix some compatibility issues between bsd_vsnprintf and bsd_vsnwprintf
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Fix some compatibility issues between bsd_vsnprintf and bsd_vsnwprintf

Fix some compatibility issues between bsd_vsnprintf and
bsd_vsnwprintf so that the lib/string unit tests can have
consistent results.

* bsd_vsnprintf used uppercase hexadecimal digits for %p but
bsd_vsnwprintf used lowercase.  vsnprintf has much more
inertia, so use uppercase in both.

* bsd_vsnprintf's floating point output was adjusted for bug
704706, but corresponding changes were not made to
bsd_vsnwprintf.

8 years agolib/file: Continue simplifying and optimizing
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
lib/file: Continue simplifying and optimizing

Since we're UTF8 only, there are simplifications and
optimizations that can be done to lib/file, particularly in the
routines that look for directory separators and ASCII characters like
'.'. We don't need to use the unicode library to deal with these
type of code points.

This is the second in a sequence of changes to improve lib/file.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoFix lib/string unit tests
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
Fix lib/string unit tests

Updates to lib/string.str.c and its unit tests.

* On Linux, Str_Vsnwprintf uses vswprintf from glibc[1].
However, glibc's vswprintf implementation appears to be
broken by not NUL-terminating the destination if truncation
occurs.  Make Str_Vsnwprintf explicitly NUL-terminate along
this path.

* The unit tests expected that Str_Vsnwprintf use %s for
wchar_t* arguments (and %S for char* ones).  That is a
Microsoft-ism (necessary for TCHAR-based printf functions
to use the same format strings with or without _UNICODE).
Our bsd_vsnwprintf function instead uses %s for char* (and
%S for wchar_t*).  Existing callers to Str_...wprintf use
use the BSD implementation and expect the BSD behavior
(which is consistent with standard C in this regard), so
go with the existing behavior and adjust the tests.

* Some of the tests passed int arguments for floating-point
format specifiers.  This is undefined behavior.

* Some of the tests had more format specifiers than
arguments.  More undefined behavior.

* Finally, the existing Str_...printf tests are
fundamentally flawed: they compare output against the
system's printf functions.  However, the whole point of
having our own is to have consistent behavior across
platforms and to work around bugs; the output therefore
cannot be expected to consistently match.  Instead rewrite
the tests to compare Str_...printf output against fixed
strings.[2]  Additionally, enable these tests only if
HAS_BSD_PRINTF/HAS_BSD_WPRINTF are enabled; I see no point
in testing the system versions (which won't have consistent
output), and IMO the BSD implementations are the only ones
we should be supporting.

[1] I do not understand why HAS_BSD_WPRINTF is enabled on
Linux only for < gcc 2.96 (and not at all for macOS).
This probably should be fixed, but not as part of this
change. (I also don't know why HAS_BSD_WPRINTF is
distinct from HAS_BSD_PRINTF.)

[2] bsd_vsnwprintf is not consistent with bsd_vsnprintf for
all format specifiers.  I plan to deal with this later,
but for now, make the expected strings match the actual
output so we have a starting point where everything
passes.

8 years agolib/file: Cleanly handle directory separators
Oliver Kurth [Fri, 15 Sep 2017 18:23:56 +0000 (11:23 -0700)] 
lib/file: Cleanly handle directory separators

We want to handle Windows allowance of "/" and "\" as directory
separators. Let's have an easy way to check things and use it.

This is first in a sequence of changes to improve our handling of
directory separators in lib/file.

8 years agoAdd missing "const" to previous commit.
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Add missing "const" to previous commit.

8 years agolib/file: Rework File_ReplaceExtension and File_RemoveExtension
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
lib/file: Rework File_ReplaceExtension and File_RemoveExtension

Fix a bug and simplify the code.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoRename some parameters
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Rename some parameters

The generic parameter names for Posix_Symlink/Posix_Link are
rather confusing.  Rename them.

8 years agoRevert previous commit.
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Revert previous commit.

8 years agolib/file: File_ReplaceExtension fails in the root directory
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
lib/file: File_ReplaceExtension fails in the root directory

On Linux, File_ReplaceExtension returns an incorrect path name for a
file in the root directory. The code, as written, doesn't differentiate
"test.txt" from "/test.txt". Fix this.

8 years agoUpdate AUTHORS with pull request for fixing gcc6 build issues.
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Update AUTHORS with pull request for fixing gcc6 build issues.

The issue in linuxDeployment.c has been fixed. This change is to
udpate the AUTHORS file.

- https://github.com/vmware/open-vm-tools/pull/107
- https://github.com/vmware/open-vm-tools/pull/107/files#diff-ffeb9f9be2f25b5b92ecf9101fa3aae5

8 years agoUpdate __IS_FREE_BSD__ macro in vm_basic_defs.h
Oliver Kurth [Fri, 15 Sep 2017 18:23:55 +0000 (11:23 -0700)] 
Update __IS_FREE_BSD__ macro in vm_basic_defs.h

The __IS_FREEBSD__ macro in vm_basic_defs.h uses "defined" in
the definition.  That is undefined behavior and the FreeBSD default
compiler, clang (LLVM), warns about this pervasively misused
construct.  With all warnings equivalent to an error, builds fail.

The object-like macro __IS_FREEBSD__ has been rewritten in a manner
acceptable to the current C standard.

Open-vm-tools pull request: https://github.com/vmware/open-vm-tools/pull/136

8 years agoCommon header file change; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Common header file change; not applicable to open-vm-tools.

8 years agoInclude new CAF PMT files in open-vm-tools
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Include new CAF PMT files in open-vm-tools

Add new CAF PMT files CmonitorListener.cpp, CMonitorListener.h,
and preconfigure-Listener.sh to open-vm-tools.

8 years agoRe-instate ASSERTS in circList.h
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Re-instate ASSERTS in circList.h

8 years agoservices/plugins/dndcp/dnd/dndCPMsgV4.c:
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
services/plugins/dndcp/dnd/dndCPMsgV4.c:
  - Rework DnDCP v4 message validation.

8 years agodeployPkg: Fix duplicate log message issue
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
deployPkg: Fix duplicate log message issue

Use linebuffer to prevent duplicate log message for forked off processes during customization.

8 years agoMake TimeUtil_GetTimeFormat avoid a null pointer dereference if ctime_r fails
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Make TimeUtil_GetTimeFormat avoid a null pointer dereference if ctime_r fails

ctime_r potentially could return NULL on failure.  Instead of
blindly dereferencing the result, TimeUtil_GetTimeFormat
should check for that and also return NULL (which callers
should already expect on failure).

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoresolutionSet: Should not free RandR12Info when RandR12GetInfo failed
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
resolutionSet: Should not free RandR12Info when RandR12GetInfo failed

If for some reason RandR12GetInfo failed to return RandR12Info,
it should not follow the cleanup path to free it. Instead it
should return FALSE.

8 years agoExport and call a valist version of Msg_Append
Oliver Kurth [Fri, 15 Sep 2017 18:23:54 +0000 (11:23 -0700)] 
Export and call a valist version of Msg_Append

This change exports a valist version of Msg_Append.

8 years agoCommon header file change: not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Common header file change: not applicable to open-vm-tools.

8 years agoVThreadID: change to uintptr_t
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
VThreadID: change to uintptr_t

8 years agoAdd 10.1.15 update release to vm_tools_version.h
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Add 10.1.15 update release to vm_tools_version.h

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agolib/file: Posix FileLock_Lock pathName handling
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
lib/file: Posix FileLock_Lock pathName handling

Locking "/tmp" should create a lock "/tmp.lck".
Locking "tmp" should create a lock "./tmp.lck".

8 years agoAdd vmx config options for guest time service resync.
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Add vmx config options for guest time service resync.

VMware tools timeSync can be enabled in a guest that also has a native
time service running. This can lead to race conditions when both the time
services are trying to correct system time. Particularly, when both of
these services tries to do a step correction on certain events, guest
time behaves in an undesirable manner that could cause guest
applications to fail. This change introduces a couple of vmx config options
that can be used to eliminate or atleast reduce the chance of race
condition between VMware tools timeSync and guest native time service
(like w32time or NTP).

The basic idea is to utilize native time service to resynchronize and
recalibrate its parameters and force to do a step correction if
necessary. VMware tools timeSync would send a service request to native
guest time service when it needs to do a step correction, rather than
correcting system time itself. This helps in having a single service
responsible for correcting guest system time and eliminates/reduces race
condition.

"time.synchronize.guest.resync"=<TRUE|FALSE> controls whether this new
method of guest time synchronization is enabled or not.
There might be situations where native guest time service resync request
is not successful. This could happen if the native time service is not
configured correctly or if there is an intermittent network outage, etc.
We would like to fall back to using legacy way of VMware tool timeSync
onetime correction in such failure scenarios.
"time.synchronize.guest.resync.timeout>=0" vmx option allows us to achieve
that. Tools timeSync would initiate a resync request, then wait for
'timeout' period of time and would fall back of legacy timeSync onetime
sync behavior. This allows us to correct guest time even in case of
native guest time service failure.

8 years agoCommon source file change; not directly applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Common source file change; not directly applicable to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:53 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoVThread: factor out common thread-name assignment
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
VThread: factor out common thread-name assignment

8 years agoHgfs OSX Server: Create and use server callback table for change notifications
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Hgfs OSX Server: Create and use server callback table for change notifications

There are now three different callbacks into the Hgfs server from the file
change notification component. So we now pass these in a table to the nofify
module when it is initialized instead of ad hoc. Previously, the same
callback is passed for every subscriber watch event and therefore duplicated
and stored in each subscriber.

Note that the feature is currently switched off by default until these changes
are complete. A user will explicitly have to enable the VMX file setting and
would cause a VMX assert to be triggered.

Details:
- The server now creates a table for its notification callbacks and passes
  it to the notify initialization function.
- The server now includes the async thread registration callbacks previously
  ifdef'd out.
- The Notify_Init function APIs are updated to reflect the new argument for
  callbacks.
- The HgfsNotify_AddSubscriber argument does not include the callback as it
  is now passed once at the initialization time.
- The HgfsNotifyEventReceiveCb type has been modified now it is an entry in
  the callback table.
- The subscriber callback function call is now validated to be non-NULL
  before calling.
- The Mac notify module adds the server callback table to its FS event
  context which is passed to the event generating submodule for the Mac
  implementation.
- The Mac notify module adds its own FS event callbacks for thread register
  and unregister called from the FS event module when registering and
  unregistering its FS event thread.

8 years agoCAF - Preconfigure the listener + follow guest proxy
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
CAF - Preconfigure the listener + follow guest proxy

Listener is auto configured during the install upon MA being started.
Listener is started/stopped automatically when tunnel is enabled/disabled.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoAdd error logging to lib/file/file.c create folder functions
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Add error logging to lib/file/file.c create folder functions

8 years agoRe-gen rabbitproxy key if its perms are bad
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Re-gen rabbitproxy key if its perms are bad

Make sure nothing has played with our keyfile permissions.
The old (9.10) VB script that generated the key left it world-readable,
and it's also possible someone could mess up the perms.
This change checks the perms, and if they're wrong, regenerates
the cert & key.

8 years agoGuestInfo: Add option to exclude network interfaces
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
GuestInfo: Add option to exclude network interfaces

VMs running docker can have hundred of virtual network interfaces.
Also, docker creates one virtual network interface 'docker0' with
an IPv4 address. This address is useless outside the VM, and should
not be propagated via GuestInfo, or even as the primary network
address.

This change adds on option for tools.conf to exclude specific
network interface names using patterns with wildcards. This makes
it easy to exclude virtual docker interface names with the option

exclude-nics=docker*,veth*

For convenience, the option is set to docker*,veth* by default,
except for Windows, where it is "vEthernet*". To
send information of all interfaces, including docker* and veth*,
the option needs to be set to an empty value: exclude-nics=

8 years agoFix vm_basic_types.h broken in previous commit.
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Fix vm_basic_types.h broken in previous commit.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoRemove VThread_WaitThread
Oliver Kurth [Fri, 15 Sep 2017 18:23:52 +0000 (11:23 -0700)] 
Remove VThread_WaitThread

8 years agoVThreadBase: Final cleanups
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
VThreadBase: Final cleanups

8 years agoTools Hgfs Plugin: Refresh Hgfs drives on client start
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
Tools Hgfs Plugin: Refresh Hgfs drives on client start

In order to get Explorer to see that VMware Shared Fodlers
drives are available when the feature is enabled, we touch
each drive that is mapped as a VMware Shared Folder. This
is to prevent users being confused when they have the feature
enabled but Explorer creates the user's drive mappings before
the tools service has initialized the Hgfs plugin and started
the Hgfs client. In this situation the drives are marked
as red (disconnected) until the user clicks on the mapped
drive when Explorer will refresh the connction and set it
to green (connected).

Details:
- Main service will usually create otheriwse open a named event
  to synchronize with the user service.
- Main service will start the HGFS client redirector (as before
  this is not new).
- Main service will set the synchronization event to signalled.
- User service will usually open the named event (or create it
  if first).
- User service will enumerate all the mapped network drives and,
  if they are provided by the VMware Shared Folder redirector,
  reconnect them.
- The named event will be created with Administrators group all
  access and Everyone with modify state to signal it and synchronize
  to wait on it.

8 years agoEmphatically close virtual disk.
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
Emphatically close virtual disk.

Sometimes I/O stack modules return EBUSY during teardown.
This may be due to an external process opening files at
inopportune moments. The workaround is to retry the affected
operations.

8 years agolib/file/filePosix.c: Implement File_GetMountPath() for POSIX
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
lib/file/filePosix.c: Implement File_GetMountPath() for POSIX
  - The change implements File_GetMountPath() for POSIX,
    using realpath(3) and readlink(2).

Changes to common header files; not applicable to open-vm-tools.

8 years agoVThreadBase: Switch to "stable" thread IDs
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
VThreadBase: Switch to "stable" thread IDs

Now that lib/thread no longer has a dependency on small-numbered
VThreadIDs, and now that lib/thread has ceeded control of assigning
VThreadIDs to threads, we can make VThreadBase really simple.

8 years agolib/lock: Clarify comments
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
lib/lock: Clarify comments

8 years agoClear vmusr as resolution_server when resolutionKMS is enabled
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
Clear vmusr as resolution_server when resolutionKMS is enabled

Whenever resolutionKMS is enabled, send
"tools.capability.resolution_server toolbox-dnd 0" to clear
resolutionSet as resolution server.

8 years agoChanges to common source files; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
Changes to common source files; not applicable to open-vm-tools.

8 years agoUse correct osname for FreeBSD 11.
Oliver Kurth [Fri, 15 Sep 2017 18:23:51 +0000 (11:23 -0700)] 
Use correct osname for FreeBSD 11.

For FreeBSD 11 and later the correct osname is "freeBSD11".
Without the correct osname, guestInfo ends up with the wrong
guestId and guestFullName.

Also cleaned up some unused code.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoCommon header file change; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Common header file change; not applicable to open-vm-tools.

8 years agoCommon header file change; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Common header file change; not applicable to open-vm-tools.

8 years agoChange to shared header file unrelated to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Change to shared header file unrelated to open-vm-tools.

8 years agoVSOCK: Add getsockopt to determine stream socket disconnect cause
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
VSOCK: Add getsockopt to determine stream socket disconnect cause

This is the vSocket part of adding support for getting the
disconnect cause of a vSocket stream socket. This adds a
getsockopt option to determine stream socket disconnect cause
as registered by the underlying VMCI queue pair.

8 years agoConvert Util_GetCurrentThreadId to VThreadBase_GetKernelID
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Convert Util_GetCurrentThreadId to VThreadBase_GetKernelID

This code now "lives" in VThreadBase since it is thread-related. The
two functions behave (very) similarly.

Some locations should use VThreadIDs instead of KernelIDs. Convert them.

Remove the util.h and lib/misc bits.

8 years agoRemove Util_GetCurrentThreadId from VIX
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Remove Util_GetCurrentThreadId from VIX

Some cleanup now that VThreadBase_GetKernelID() is available
in VIX code, we log the thread which made certain API calls.

The thread name is already logged in our Log() implementation,
so having the thread ID merely wastes bytes. Remove it.

(Thread IDs like this are useful for correlating with kernel logs.
Which in practice does not apply to VIX).

8 years agoAdd some tweaks to make it easier to test old tokens
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Add some tweaks to make it easier to test old tokens

At times its useful to be able to play with SAML tokens
which have expired assertions but we still care about
signing or aliasStore configuration issues.  This change makes it
easy to tweak the code and run these old tokens through.

8 years agoEnable XML manifest by default.
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
Enable XML manifest by default.

Enable Tools enableXmlManifest by default for quiesced snapshots on Linux.

8 years agolib/file: Must be errno safe
Oliver Kurth [Fri, 15 Sep 2017 18:23:50 +0000 (11:23 -0700)] 
lib/file: Must be errno safe

lib/file is documented to be safe about returning errno. This is true
on Window and Posix platforms. We've had a bug where free can change
errno. We created Posix_Free to protect errno but haven't used it
consistently.

Make lib/file use Posix_Free universally.

8 years agoChanges to common header files; not applicable to open-vm-tools.
Oliver Kurth [Fri, 15 Sep 2017 18:23:49 +0000 (11:23 -0700)] 
Changes to common header files; not applicable to open-vm-tools.

8 years agoHgfs Server: Fix the tools build
Oliver Kurth [Fri, 15 Sep 2017 18:23:49 +0000 (11:23 -0700)] 
Hgfs Server: Fix the tools build

Make the HgfsServerAsyncInfoIncCount to be VMX code only as the current
usage is not in the tools implementation.

8 years agoHgfs Server: Move async request globals into the Hgfs session
Oliver Kurth [Fri, 15 Sep 2017 18:23:49 +0000 (11:23 -0700)] 
Hgfs Server: Move async request globals into the Hgfs session

This change moves the async request globals into the Hgfs session.
They are only applicable to a session and only used during a session's
lifetime, so making them global is not necessary and means that
they take up resources when not used.

Details:
- Move the previous globals into a structure for async requests.
- Add the async requests structure to the HgfsSessionInfo object.
- Create a set of helper functions to init, exit and manipulate the
  async requests structure.
- Remove the calls to init and teardown the globals now they don't
  exist.
- Add the helper calls to the session creation and destruction.
- Add the helper calls to replace adding a new async request, removing
  an async request, and waiting for all async requests to complete.