diff --git a/build/msvc/msvc-generate/msvc-generate.vcxproj b/build/msvc/msvc-generate/msvc-generate.vcxproj
index 8b7ec22003d..72d310af210 100644
--- a/build/msvc/msvc-generate/msvc-generate.vcxproj
+++ b/build/msvc/msvc-generate/msvc-generate.vcxproj
@@ -1,35 +1,64 @@
-
+
Debug
Win32
+
+ Debug
+ x64
+
Release
Win32
+
+ Release
+ x64
+
{8598C2C8-34C4-47A1-99B0-7C295A890615}
msvc-generate
MakeFileProj
+ 10.0.17134.0
Makefile
+ v141
+
+
+ Makefile
+ v141
Makefile
+ v141
+
+
+ Makefile
+ v141
+
+
+
+
+
+
+
+
+
+
@@ -37,25 +66,43 @@
$(Configuration)\
$(Configuration)\
nmake -f Makefile.mak all
+ nmake -f Makefile.mak all
nmake -f Makefile.mak clean all
+ nmake -f Makefile.mak clean all
nmake -f Makefile.mak clean
+ nmake -f Makefile.mak clean
config-msvc-version.h
+ config-msvc-version.h
WIN32;_DEBUG;$(NMakePreprocessorDefinitions)
+ WIN32;_DEBUG;$(NMakePreprocessorDefinitions)
$(NMakeIncludeSearchPath)
+ $(NMakeIncludeSearchPath)
$(NMakeForcedIncludes)
+ $(NMakeForcedIncludes)
$(NMakeAssemblySearchPath)
+ $(NMakeAssemblySearchPath)
$(NMakeForcedUsingAssemblies)
+ $(NMakeForcedUsingAssemblies)
$(Configuration)\
$(Configuration)\
nmake -f Makefile.mak all
+ nmake -f Makefile.mak all
nmake -f Makefile.mak clean all
+ nmake -f Makefile.mak clean all
nmake -f Makefile.mak clean
+ nmake -f Makefile.mak clean
config-msvc-version.h
+ config-msvc-version.h
WIN32;NDEBUG;$(NMakePreprocessorDefinitions)
+ WIN32;NDEBUG;$(NMakePreprocessorDefinitions)
$(NMakeIncludeSearchPath)
+ $(NMakeIncludeSearchPath)
$(NMakeForcedIncludes)
+ $(NMakeForcedIncludes)
$(NMakeAssemblySearchPath)
+ $(NMakeAssemblySearchPath)
$(NMakeForcedUsingAssemblies)
+ $(NMakeForcedUsingAssemblies)
@@ -66,4 +113,4 @@
-
\ No newline at end of file
+
diff --git a/config-msvc.h b/config-msvc.h
index 8be9195f08f..45fae8b0d80 100644
--- a/config-msvc.h
+++ b/config-msvc.h
@@ -5,6 +5,7 @@
#define ENABLE_DEF_AUTH 1
#define ENABLE_PF 1
#define ENABLE_CRYPTO_OPENSSL 1
+#define HAVE_AEAD_CIPHER_MODES 1
#define ENABLE_DEBUG 1
#define ENABLE_EUREPHIA 1
#define ENABLE_FRAGMENT 1
diff --git a/msvc-build.bat b/msvc-build.bat
index fd6d55882de..8256c62d340 100644
--- a/msvc-build.bat
+++ b/msvc-build.bat
@@ -7,13 +7,15 @@ setlocal ENABLEDELAYEDEXPANSION
cd /d %0\..
call msvc-env.bat
-set PLATFORMS=Win32
-set CONFIGURATIONS=Release
+set PLATFORMS=x64
+set CONFIGURATIONS=Debug Release
if exist "%VCHOME%\vcvarsall.bat" (
call "%VCHOME%\vcvarsall.bat"
) else if exist "%VCHOME%\bin\vcvars32.bat" (
call "%VCHOME%\bin\vcvars32.bat"
+) else if exist "%VCHOME%\Auxiliary\Build\vcvars32.bat" (
+ call "%VCHOME%\Auxiliary\Build\vcvars32.bat"
) else (
echo Cannot detect visual studio
goto error
diff --git a/msvc-dev.bat b/msvc-dev.bat
index dbd7be07de9..74aee0b0a82 100644
--- a/msvc-dev.bat
+++ b/msvc-dev.bat
@@ -8,6 +8,8 @@ if exist "%VSHOME%\Common7\IDE\VCExpress.exe" (
set IDE=%VSHOME%\Common7\IDE\VCExpress.exe
) else if exist "%VSHOME%\Common7\IDE\devenv.exe" (
set IDE=%VSHOME%\Common7\IDE\devenv.exe
+) else if exist "%VCHOME%\Auxiliary\Build\vcvars64.bat" (
+ call "%VCHOME%\Auxiliary\Build\vcvars64.bat"
) else (
echo "Cannot detect visual studio environment"
goto error
diff --git a/msvc-env.bat b/msvc-env.bat
index aabed750e93..cc9663df511 100644
--- a/msvc-env.bat
+++ b/msvc-env.bat
@@ -4,8 +4,8 @@ rem Put your own settings at msvc-env-local.bat
if exist msvc-env-local.bat call msvc-env-local.bat
if "%ProgramFiles(x86)%"=="" set ProgramFiles(x86)=%ProgramFiles%
-if "%VSCOMNTOOLS%"=="" SET VSCOMNTOOLS=%ProgramFiles(x86)%\Microsoft Visual Studio 10.0\Common7\Tools
-if "%VSCOMNTOOLS%"=="" SET VSCOMNTOOLS=%ProgramFiles(x86)%\Microsoft Visual Studio 9.0\Common7\Tools
+if "%VSCOMNTOOLS%"=="" set VSCOMNTOOLS=%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Professional\Common7\Tools
+if not exist "%VSCOMNTOOLS%" set VSCOMNTOOLS=%ProgramFiles(x86)%\Microsoft Visual Studio\2017\Community\Common7\Tools
if "%VSHOME%"=="" SET VSHOME=%VSCOMNTOOLS%\..\..
if "%VCHOME%"=="" SET VCHOME=%VSHOME%\VC
@@ -13,7 +13,7 @@ set SOURCEBASE=%cd%
set SOLUTION=openvpn.sln
set CPPFLAGS=%CPPFLAGS%;_CRT_SECURE_NO_WARNINGS;WIN32_LEAN_AND_MEAN;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS
set CPPFLAGS=%CPPFLAGS%;NTDDI_VERSION=NTDDI_VISTA;_WIN32_WINNT=_WIN32_WINNT_VISTA
-set CPPFLAGS=%CPPFLAGS%;_USE_32BIT_TIME_T
+set CPPFLAGS=%CPPFLAGS%;
set CPPFLAGS=%CPPFLAGS%;%EXTRA_CPPFLAGS%
if exist config-msvc-local.h set CPPFLAGS="%CPPFLAGS%;HAVE_CONFIG_MSVC_LOCAL_H"
diff --git a/openvpn.sln b/openvpn.sln
index 90c01b89b2b..51fdaf08bbf 100644
--- a/openvpn.sln
+++ b/openvpn.sln
@@ -1,6 +1,8 @@
-Microsoft Visual Studio Solution File, Format Version 11.00
-# Visual C++ Express 2010
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 15
+VisualStudioVersion = 15.0.28010.2026
+MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "openvpnserv", "src\openvpnserv\openvpnserv.vcxproj", "{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "openvpn", "src\openvpn\openvpn.vcxproj", "{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}"
@@ -12,27 +14,48 @@ EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
+ Debug|x64 = Debug|x64
Release|Win32 = Release|Win32
+ Release|x64 = Release|x64
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Debug|Win32.ActiveCfg = Debug|Win32
{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Debug|Win32.Build.0 = Debug|Win32
+ {9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Debug|x64.ActiveCfg = Debug|x64
+ {9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Debug|x64.Build.0 = Debug|x64
{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Release|Win32.ActiveCfg = Release|Win32
{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Release|Win32.Build.0 = Release|Win32
+ {9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Release|x64.ActiveCfg = Release|x64
+ {9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}.Release|x64.Build.0 = Release|x64
{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Debug|Win32.ActiveCfg = Debug|Win32
{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Debug|Win32.Build.0 = Debug|Win32
+ {29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Debug|x64.ActiveCfg = Debug|x64
+ {29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Debug|x64.Build.0 = Debug|x64
{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Release|Win32.ActiveCfg = Release|Win32
{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Release|Win32.Build.0 = Release|Win32
+ {29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Release|x64.ActiveCfg = Release|x64
+ {29DF226E-4D4E-440F-ADAF-5829CFD4CA94}.Release|x64.Build.0 = Release|x64
{8598C2C8-34C4-47A1-99B0-7C295A890615}.Debug|Win32.ActiveCfg = Debug|Win32
{8598C2C8-34C4-47A1-99B0-7C295A890615}.Debug|Win32.Build.0 = Debug|Win32
+ {8598C2C8-34C4-47A1-99B0-7C295A890615}.Debug|x64.ActiveCfg = Debug|x64
+ {8598C2C8-34C4-47A1-99B0-7C295A890615}.Debug|x64.Build.0 = Debug|x64
{8598C2C8-34C4-47A1-99B0-7C295A890615}.Release|Win32.ActiveCfg = Release|Win32
{8598C2C8-34C4-47A1-99B0-7C295A890615}.Release|Win32.Build.0 = Release|Win32
+ {8598C2C8-34C4-47A1-99B0-7C295A890615}.Release|x64.ActiveCfg = Release|x64
+ {8598C2C8-34C4-47A1-99B0-7C295A890615}.Release|x64.Build.0 = Release|x64
{4B2E2719-E661-45D7-9203-F6F456B22F19}.Debug|Win32.ActiveCfg = Debug|Win32
{4B2E2719-E661-45D7-9203-F6F456B22F19}.Debug|Win32.Build.0 = Debug|Win32
+ {4B2E2719-E661-45D7-9203-F6F456B22F19}.Debug|x64.ActiveCfg = Debug|x64
+ {4B2E2719-E661-45D7-9203-F6F456B22F19}.Debug|x64.Build.0 = Debug|x64
{4B2E2719-E661-45D7-9203-F6F456B22F19}.Release|Win32.ActiveCfg = Release|Win32
{4B2E2719-E661-45D7-9203-F6F456B22F19}.Release|Win32.Build.0 = Release|Win32
+ {4B2E2719-E661-45D7-9203-F6F456B22F19}.Release|x64.ActiveCfg = Release|x64
+ {4B2E2719-E661-45D7-9203-F6F456B22F19}.Release|x64.Build.0 = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {EB3CE5D3-415C-46F0-96AB-E1CDA287AB6D}
+ EndGlobalSection
EndGlobal
diff --git a/src/compat/PropertySheet.props b/src/compat/PropertySheet.props
new file mode 100644
index 00000000000..1e5c2f96143
--- /dev/null
+++ b/src/compat/PropertySheet.props
@@ -0,0 +1,40 @@
+
+
+
+
+ $(SolutionDir)
+ $(SOURCEBASE)\..\..\image
+ $(OPENVPN_DEPROOT)
+ $(OPENVPN_DEPROOT)
+ $(OPENVPN_DEPROOT)
+ $(OPENVPN_DEPROOT)
+
+
+
+
+
+ $(SOURCEBASE)
+ true
+
+
+ $(OPENVPN_DEPROOT)
+ true
+
+
+ $(OPENSSL_HOME)
+ true
+
+
+ $(TAP_WINDOWS_HOME)
+ true
+
+
+ $(LZO_HOME)
+ true
+
+
+ $(PKCS11H_HOME)
+ true
+
+
+
\ No newline at end of file
diff --git a/src/compat/compat.vcxproj b/src/compat/compat.vcxproj
index d2695e6bb20..07d6baf1ce7 100644
--- a/src/compat/compat.vcxproj
+++ b/src/compat/compat.vcxproj
@@ -1,47 +1,79 @@
-
+
Debug
Win32
+
+ Debug
+ x64
+
Release
Win32
+
+ Release
+ x64
+
{4B2E2719-E661-45D7-9203-F6F456B22F19}
compat
Win32Proj
+ 10.0.17134.0
StaticLibrary
MultiByte
true
- v120
+ v141
+
+
+ StaticLibrary
+ MultiByte
+ true
+ v141
StaticLibrary
MultiByte
- v120
+ v141
+
+
+ StaticLibrary
+ MultiByte
+ v141
+
+
+
+
+
+
+
+
+
+
<_ProjectFileVersion>10.0.30319.1
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
@@ -58,6 +90,19 @@
EditAndContinue
+
+
+ Disabled
+ $(SOURCEBASE);$(SOURCEBASE)/include;$(OPENSSL_HOME)/include;$(LZO_HOME)/include;$(PKCS11H_HOME)/include;%(AdditionalIncludeDirectories)
+ WIN32;_DEBUG;_LIB;$(CPPFLAGS);%(PreprocessorDefinitions)
+ EnableFastChecks
+ MultiThreadedDebugDLL
+
+
+ Level3
+ ProgramDatabase
+
+
MaxSpeed
@@ -72,6 +117,20 @@
ProgramDatabase
+
+
+ MaxSpeed
+ true
+ $(SOURCEBASE);$(SOURCEBASE)/include;$(OPENSSL_HOME)/include;$(LZO_HOME)/include;$(PKCS11H_HOME)/include;%(AdditionalIncludeDirectories)
+ WIN32;NDEBUG;_LIB;$(CPPFLAGS);%(PreprocessorDefinitions)
+ MultiThreadedDLL
+ true
+
+
+ Level3
+ ProgramDatabase
+
+
diff --git a/src/openvpn/openvpn.vcxproj b/src/openvpn/openvpn.vcxproj
index d1c0fdec2a9..e0da69f036b 100644
--- a/src/openvpn/openvpn.vcxproj
+++ b/src/openvpn/openvpn.vcxproj
@@ -1,50 +1,84 @@
-
+
Debug
Win32
+
+ Debug
+ x64
+
Release
Win32
+
+ Release
+ x64
+
{29DF226E-4D4E-440F-ADAF-5829CFD4CA94}
openvpn
Win32Proj
+ 10.0.17134.0
Application
true
Unicode
- v120
+ v141
+
+
+ Application
+ true
+ Unicode
+ v141
Application
Unicode
- v120
+ v141
+
+
+ Application
+ Unicode
+ v141
+
+
+
+
+
+
+
+
+
+
<_ProjectFileVersion>10.0.30319.1
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
true
+ true
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
false
+ false
@@ -64,13 +98,36 @@
$(SOURCEBASE);%(AdditionalIncludeDirectories)
- libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
+ legacy_stdio_definitions.lib;Ncrypt.lib;libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
$(OPENSSL_HOME)/lib;$(LZO_HOME)/lib;$(PKCS11H_HOME)/lib;%(AdditionalLibraryDirectories)
true
Console
MachineX86
+
+
+ Disabled
+ $(SOURCEBASE);$(SOURCEBASE)/src/compat;$(SOURCEBASE)/include;$(TAP_WINDOWS_HOME)/include;$(OPENSSL_HOME)/include;$(LZO_HOME)/include;$(PKCS11H_HOME)/include;%(AdditionalIncludeDirectories)
+ WIN32;_DEBUG;_CONSOLE;$(CPPFLAGS);%(PreprocessorDefinitions)
+ EnableFastChecks
+ MultiThreadedDebugDLL
+
+
+ Level3
+ ProgramDatabase
+ UNICODE
+
+
+ $(SOURCEBASE);%(AdditionalIncludeDirectories)
+
+
+ legacy_stdio_definitions.lib;Ncrypt.lib;libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
+ $(OPENSSL_HOME)/lib;$(LZO_HOME)/lib;$(PKCS11H_HOME)/lib;%(AdditionalLibraryDirectories)
+ true
+ Console
+
+
MaxSpeed
@@ -89,7 +146,7 @@
$(SOURCEBASE);%(AdditionalIncludeDirectories)
- libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
+ legacy_stdio_definitions.lib;Ncrypt.lib;libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
$(OPENSSL_HOME)/lib;$(LZO_HOME)/lib;$(PKCS11H_HOME)/lib;%(AdditionalLibraryDirectories)
true
Console
@@ -98,6 +155,32 @@
MachineX86
+
+
+ MaxSpeed
+ true
+ $(SOURCEBASE);$(SOURCEBASE)/src/compat;$(SOURCEBASE)/include;$(TAP_WINDOWS_HOME)/include;$(OPENSSL_HOME)/include;$(LZO_HOME)/include;$(PKCS11H_HOME)/include;%(AdditionalIncludeDirectories)
+ WIN32;NDEBUG;_CONSOLE;$(CPPFLAGS);%(PreprocessorDefinitions)
+ MultiThreadedDLL
+ true
+
+
+ Level3
+ ProgramDatabase
+ UNICODE
+
+
+ $(SOURCEBASE);%(AdditionalIncludeDirectories)
+
+
+ legacy_stdio_definitions.lib;Ncrypt.lib;libeay32.lib;ssleay32.lib;lzo2.lib;pkcs11-helper.dll.lib;gdi32.lib;ws2_32.lib;wininet.lib;crypt32.lib;iphlpapi.lib;winmm.lib;Fwpuclnt.lib;Rpcrt4.lib;%(AdditionalDependencies)
+ $(OPENSSL_HOME)/lib;$(LZO_HOME)/lib;$(PKCS11H_HOME)/lib;%(AdditionalLibraryDirectories)
+ true
+ Console
+ true
+ true
+
+
@@ -112,6 +195,7 @@
+
@@ -156,6 +240,7 @@
+
@@ -189,6 +274,7 @@
+
@@ -240,6 +326,7 @@
+
diff --git a/src/openvpn/syshead.h b/src/openvpn/syshead.h
index e83f9a3b500..ced7fdc139e 100644
--- a/src/openvpn/syshead.h
+++ b/src/openvpn/syshead.h
@@ -47,6 +47,7 @@
#ifdef _MSC_VER /* Visual Studio */
#define __func__ __FUNCTION__
#define __attribute__(x)
+#include
#endif
#if defined(__APPLE__)
diff --git a/src/openvpnserv/interactive.c b/src/openvpnserv/interactive.c
index 861f5e705bc..9d459a6124f 100644
--- a/src/openvpnserv/interactive.c
+++ b/src/openvpnserv/interactive.c
@@ -24,7 +24,6 @@
#include "service.h"
-#include
#include
#include
#include
diff --git a/src/openvpnserv/openvpnserv.vcxproj b/src/openvpnserv/openvpnserv.vcxproj
index c6760daf5b5..9098920efeb 100644
--- a/src/openvpnserv/openvpnserv.vcxproj
+++ b/src/openvpnserv/openvpnserv.vcxproj
@@ -1,55 +1,89 @@
-
+
Debug
Win32
+
+ Debug
+ x64
+
Release
Win32
+
+ Release
+ x64
+
{9C91EE0B-817D-420A-A1E6-15A5A9D98BAD}
openvpnserv
Win32Proj
+ 10.0.17134.0
Application
MultiByte
true
- v120
+ v141
+
+
+ Application
+ MultiByte
+ true
+ v141
Application
MultiByte
- v120
+ v141
+
+
+ Application
+ Unicode
+ v141
+
+
+
+
+
+
+
+
+
+
<_ProjectFileVersion>10.0.30319.1
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
true
+ true
$(SolutionDir)$(Platform)-Output\$(Configuration)\
+ $(SolutionDir)$(Platform)-Output\$(Configuration)\
$(Configuration)\
false
+ false
Disabled
- $(SOURCEBASE);%(AdditionalIncludeDirectories)
+ $(SOURCEBASE);..\..\include;..\openvpn;..\compat;%(AdditionalIncludeDirectories)
WIN32;_DEBUG;_CONSOLE;$(CPPFLAGS);%(PreprocessorDefinitions)
true
EnableFastChecks
@@ -63,16 +97,38 @@
$(SOURCEBASE);%(AdditionalIncludeDirectories)
+ Userenv.lib;Iphlpapi.lib;ntdll.lib;Fwpuclnt.lib;Netapi32.lib;Shlwapi.lib;%(AdditionalDependencies)
true
Console
MachineX86
+
+
+ Disabled
+ $(SOURCEBASE);..\..\include;..\openvpn;..\compat;%(AdditionalIncludeDirectories)
+ WIN32;_DEBUG;_CONSOLE;$(CPPFLAGS);%(PreprocessorDefinitions)
+ EnableFastChecks
+ MultiThreadedDebugDLL
+
+
+ Level3
+ ProgramDatabase
+
+
+ $(SOURCEBASE);%(AdditionalIncludeDirectories)
+
+
+ legacy_stdio_definitions.lib;Userenv.lib;Iphlpapi.lib;ntdll.lib;Fwpuclnt.lib;Netapi32.lib;Shlwapi.lib;%(AdditionalDependencies)
+ true
+ Console
+
+
MaxSpeed
true
- $(SOURCEBASE);%(AdditionalIncludeDirectories)
+ $(SOURCEBASE);..\..\include;..\openvpn;..\compat;%(AdditionalIncludeDirectories)
WIN32;NDEBUG;_CONSOLE;$(CPPFLAGS);%(PreprocessorDefinitions)
MultiThreadedDLL
true
@@ -85,6 +141,7 @@
$(SOURCEBASE);%(AdditionalIncludeDirectories)
+ Userenv.lib;Iphlpapi.lib;ntdll.lib;Fwpuclnt.lib;Netapi32.lib;Shlwapi.lib;%(AdditionalDependencies)
true
Console
true
@@ -92,12 +149,41 @@
MachineX86
+
+
+ MaxSpeed
+ true
+ $(SOURCEBASE);..\..\include;..\openvpn;..\compat;%(AdditionalIncludeDirectories)
+ MultiThreadedDLL
+ true
+
+
+ Level3
+ ProgramDatabase
+
+
+ $(SOURCEBASE);%(AdditionalIncludeDirectories)
+
+
+ legacy_stdio_definitions.lib;Userenv.lib;Iphlpapi.lib;ntdll.lib;Fwpuclnt.lib;Netapi32.lib;Shlwapi.lib;%(AdditionalDependencies)
+ true
+ Console
+ true
+ true
+
+
-
+
+
+
+
+
+
+
diff --git a/src/openvpnserv/service.h b/src/openvpnserv/service.h
index af8f37fa044..4d03b88bb3b 100644
--- a/src/openvpnserv/service.h
+++ b/src/openvpnserv/service.h
@@ -30,6 +30,7 @@
#include "config-msvc.h"
#endif
+#include
#include
#include
#include
diff --git a/src/openvpnserv/validate.c b/src/openvpnserv/validate.c
index 653bd12c593..91c6a2ba397 100644
--- a/src/openvpnserv/validate.c
+++ b/src/openvpnserv/validate.c
@@ -61,6 +61,9 @@ CheckConfigPath(const WCHAR *workdir, const WCHAR *fname, const settings_t *s)
WCHAR tmp[MAX_PATH];
const WCHAR *config_file = NULL;
const WCHAR *config_dir = NULL;
+#ifndef UNICODE
+ WCHAR widepath[MAX_PATH];
+#endif
/* convert fname to full path */
if (PathIsRelativeW(fname) )