mirror of
https://github.com/pocoproject/poco.git
synced 2025-03-29 21:22:11 +01:00
added secure WebSocket tests
This commit is contained in:
parent
a68b3edd91
commit
c727402dd9
@ -1060,6 +1060,10 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\JSONString.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\MemoryPool.cpp"
|
||||
>
|
||||
@ -1276,6 +1280,10 @@
|
||||
RelativePath=".\include\Poco\Instantiator.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\include\Poco\JSONString.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\include\Poco\MemoryPool.h"
|
||||
>
|
||||
|
@ -1,16 +1,20 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
Name="TestSuite"
|
||||
Version="9.00"
|
||||
ProjectType="Visual C++"
|
||||
Version="9.00"
|
||||
Name="TestSuite"
|
||||
ProjectGUID="{B2B88092-5BCE-4AC0-941E-88167138B4A7}"
|
||||
RootNamespace="TestSuite"
|
||||
Keyword="Win32Proj">
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="0"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles/>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="debug_shared|Win32"
|
||||
@ -18,19 +22,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="2"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;..\..\XML\include;..\..\Util\include;..\..\Net\include;..\..\Crypto\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;WINVER=0x0501;"
|
||||
@ -48,39 +59,50 @@
|
||||
DebugInformationFormat="3"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnitd.lib WinTestRunnerd.lib libeay32.lib ssleay32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\TestSuited.exe"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="..\..\lib"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\lib"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="bin\TestSuited.pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="release_shared|Win32"
|
||||
@ -88,19 +110,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="2"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="4"
|
||||
InlineFunctionExpansion="1"
|
||||
EnableIntrinsicFunctions="true"
|
||||
@ -120,15 +149,19 @@
|
||||
DebugInformationFormat="0"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnit.lib WinTestRunner.lib libeay32.lib ssleay32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\TestSuite.exe"
|
||||
LinkIncremental="1"
|
||||
@ -138,21 +171,28 @@
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="debug_static_mt|Win32"
|
||||
@ -160,19 +200,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="1"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="4"
|
||||
AdditionalIncludeDirectories="..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;..\..\XML\include;..\..\Util\include;..\..\Net\include;..\..\Crypto\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;WINVER=0x0501;POCO_STATIC;"
|
||||
@ -190,40 +237,51 @@
|
||||
DebugInformationFormat="3"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnitmtd.lib WinTestRunnermtd.lib iphlpapi.lib winmm.lib nafxcwd.lib libcmtd.lib WinTestRunner.res libeay32mtd.lib ssleay32mtd.lib Crypt32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\static_mt\TestSuited.exe"
|
||||
LinkIncremental="2"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\lib"
|
||||
IgnoreDefaultLibraryNames="nafxcwd.lib;libcmtd.lib"
|
||||
SuppressStartupBanner="true"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="bin\static_mt\TestSuited.pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="release_static_mt|Win32"
|
||||
@ -231,19 +289,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="1"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="4"
|
||||
InlineFunctionExpansion="1"
|
||||
EnableIntrinsicFunctions="true"
|
||||
@ -263,15 +328,19 @@
|
||||
DebugInformationFormat="0"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnitmt.lib WinTestRunnermt.lib iphlpapi.lib winmm.lib nafxcw.lib libcmt.lib WinTestRunner.res libeay32mt.lib ssleay32mt.lib Crypt32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\static_mt\TestSuite.exe"
|
||||
LinkIncremental="1"
|
||||
@ -282,21 +351,28 @@
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="debug_static_md|Win32"
|
||||
@ -304,19 +380,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="2"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="4"
|
||||
AdditionalIncludeDirectories="..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;..\..\XML\include;..\..\Util\include;..\..\Net\include;..\..\Crypto\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;WINVER=0x0501;POCO_STATIC;"
|
||||
@ -334,39 +417,50 @@
|
||||
DebugInformationFormat="3"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnitmdd.lib WinTestRunnermdd.lib iphlpapi.lib winmm.lib WinTestRunner.res libeay32mdd.lib ssleay32mdd.lib Crypt32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\static_md\TestSuited.exe"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="..\..\lib"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\lib"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="bin\static_md\TestSuited.pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="release_static_md|Win32"
|
||||
@ -374,19 +468,26 @@
|
||||
IntermediateDirectory="obj\$(ConfigurationName)"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="2"
|
||||
CharacterSet="2">
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalOptions=""
|
||||
Optimization="4"
|
||||
InlineFunctionExpansion="1"
|
||||
EnableIntrinsicFunctions="true"
|
||||
@ -406,15 +507,19 @@
|
||||
DebugInformationFormat="0"
|
||||
CompileAs="0"
|
||||
DisableSpecificWarnings=""
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"/>
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""
|
||||
AdditionalDependencies="CppUnitmd.lib WinTestRunnermd.lib iphlpapi.lib winmm.lib WinTestRunner.res libeay32md.lib ssleay32md.lib Crypt32.lib ws2_32.lib iphlpapi.lib"
|
||||
OutputFile="bin\static_md\TestSuite.exe"
|
||||
LinkIncremental="1"
|
||||
@ -424,114 +529,206 @@
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
AdditionalOptions=""/>
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"/>
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"/>
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"/>
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"/>
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"/>
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"/>
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References/>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="HTTPS">
|
||||
Name="HTTPS"
|
||||
>
|
||||
<Filter
|
||||
Name="Header Files">
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSTestServer.h"/>
|
||||
RelativePath=".\src\HTTPSTestServer.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSTestServer.cpp"/>
|
||||
RelativePath=".\src\HTTPSTestServer.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="_Suite">
|
||||
Name="_Suite"
|
||||
>
|
||||
<Filter
|
||||
Name="Header Files">
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\NetSSLTestSuite.h"/>
|
||||
RelativePath=".\src\NetSSLTestSuite.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\NetSSLTestSuite.cpp"/>
|
||||
RelativePath=".\src\NetSSLTestSuite.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="_Driver">
|
||||
Name="_Driver"
|
||||
>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\WinDriver.cpp"/>
|
||||
RelativePath=".\src\WinDriver.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="TCPServer">
|
||||
Name="TCPServer"
|
||||
>
|
||||
<Filter
|
||||
Name="Header Files">
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\TCPServerTest.h"/>
|
||||
RelativePath=".\src\TCPServerTest.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\TCPServerTestSuite.h"/>
|
||||
RelativePath=".\src\TCPServerTestSuite.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\TCPServerTest.cpp"/>
|
||||
RelativePath=".\src\TCPServerTest.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\TCPServerTestSuite.cpp"/>
|
||||
RelativePath=".\src\TCPServerTestSuite.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="HTTPSServer">
|
||||
Name="HTTPSServer"
|
||||
>
|
||||
<Filter
|
||||
Name="Header Files">
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSServerTest.h"/>
|
||||
RelativePath=".\src\HTTPSServerTest.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSServerTestSuite.h"/>
|
||||
RelativePath=".\src\HTTPSServerTestSuite.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSServerTest.cpp"/>
|
||||
RelativePath=".\src\HTTPSServerTest.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSServerTestSuite.cpp"/>
|
||||
RelativePath=".\src\HTTPSServerTestSuite.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="HTTPSClient">
|
||||
Name="HTTPSClient"
|
||||
>
|
||||
<Filter
|
||||
Name="Header Files">
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSClientSessionTest.h"/>
|
||||
RelativePath=".\src\HTTPSClientSessionTest.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSClientTestSuite.h"/>
|
||||
RelativePath=".\src\HTTPSClientTestSuite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSStreamFactoryTest.h"/>
|
||||
RelativePath=".\src\HTTPSStreamFactoryTest.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Source Files">
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSClientSessionTest.cpp"/>
|
||||
RelativePath=".\src\HTTPSClientSessionTest.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSClientTestSuite.cpp"/>
|
||||
RelativePath=".\src\HTTPSClientTestSuite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
||||
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="WebSocket"
|
||||
>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\WebSocketTest.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\WebSocketTestSuite.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\src\WebSocketTest.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\src\WebSocketTestSuite.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals/>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
|
@ -15,6 +15,7 @@
|
||||
#include "HTTPSClientTestSuite.h"
|
||||
#include "TCPServerTestSuite.h"
|
||||
#include "HTTPSServerTestSuite.h"
|
||||
#include "WebSocketTestSuite.h"
|
||||
|
||||
|
||||
CppUnit::Test* NetSSLTestSuite::suite()
|
||||
@ -25,6 +26,7 @@ CppUnit::Test* NetSSLTestSuite::suite()
|
||||
pSuite->addTest(HTTPSClientTestSuite::suite());
|
||||
pSuite->addTest(TCPServerTestSuite::suite());
|
||||
pSuite->addTest(HTTPSServerTestSuite::suite());
|
||||
pSuite->addTest(WebSocketTestSuite::suite());
|
||||
|
||||
return pSuite;
|
||||
}
|
||||
|
231
NetSSL_OpenSSL/testsuite/src/WebSocketTest.cpp
Normal file
231
NetSSL_OpenSSL/testsuite/src/WebSocketTest.cpp
Normal file
@ -0,0 +1,231 @@
|
||||
//
|
||||
// WebSocketTest.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTest.cpp#3 $
|
||||
//
|
||||
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
//
|
||||
|
||||
|
||||
#include "WebSocketTest.h"
|
||||
#include "CppUnit/TestCaller.h"
|
||||
#include "CppUnit/TestSuite.h"
|
||||
#include "Poco/Net/WebSocket.h"
|
||||
#include "Poco/Net/SocketStream.h"
|
||||
#include "Poco/Net/HTTPSClientSession.h"
|
||||
#include "Poco/Net/HTTPServer.h"
|
||||
#include "Poco/Net/HTTPServerParams.h"
|
||||
#include "Poco/Net/HTTPRequestHandler.h"
|
||||
#include "Poco/Net/HTTPRequestHandlerFactory.h"
|
||||
#include "Poco/Net/HTTPServerRequest.h"
|
||||
#include "Poco/Net/HTTPServerResponse.h"
|
||||
#include "Poco/Net/SecureServerSocket.h"
|
||||
#include "Poco/Net/NetException.h"
|
||||
#include "Poco/Thread.h"
|
||||
|
||||
|
||||
using Poco::Net::HTTPSClientSession;
|
||||
using Poco::Net::HTTPRequest;
|
||||
using Poco::Net::HTTPResponse;
|
||||
using Poco::Net::HTTPServerRequest;
|
||||
using Poco::Net::HTTPServerResponse;
|
||||
using Poco::Net::SocketStream;
|
||||
using Poco::Net::WebSocket;
|
||||
using Poco::Net::WebSocketException;
|
||||
|
||||
|
||||
namespace
|
||||
{
|
||||
class WebSocketRequestHandler: public Poco::Net::HTTPRequestHandler
|
||||
{
|
||||
public:
|
||||
WebSocketRequestHandler(std::size_t bufSize = 1024): _bufSize(bufSize)
|
||||
{
|
||||
}
|
||||
|
||||
void handleRequest(HTTPServerRequest& request, HTTPServerResponse& response)
|
||||
{
|
||||
try
|
||||
{
|
||||
WebSocket ws(request, response);
|
||||
std::auto_ptr<char> pBuffer(new char[_bufSize]);
|
||||
int flags;
|
||||
int n;
|
||||
do
|
||||
{
|
||||
n = ws.receiveFrame(pBuffer.get(), _bufSize, flags);
|
||||
ws.sendFrame(pBuffer.get(), n, flags);
|
||||
}
|
||||
while (n > 0 || (flags & WebSocket::FRAME_OP_BITMASK) != WebSocket::FRAME_OP_CLOSE);
|
||||
}
|
||||
catch (WebSocketException& exc)
|
||||
{
|
||||
switch (exc.code())
|
||||
{
|
||||
case WebSocket::WS_ERR_HANDSHAKE_UNSUPPORTED_VERSION:
|
||||
response.set("Sec-WebSocket-Version", WebSocket::WEBSOCKET_VERSION);
|
||||
// fallthrough
|
||||
case WebSocket::WS_ERR_NO_HANDSHAKE:
|
||||
case WebSocket::WS_ERR_HANDSHAKE_NO_VERSION:
|
||||
case WebSocket::WS_ERR_HANDSHAKE_NO_KEY:
|
||||
response.setStatusAndReason(HTTPResponse::HTTP_BAD_REQUEST);
|
||||
response.setContentLength(0);
|
||||
response.send();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
std::size_t _bufSize;
|
||||
};
|
||||
|
||||
class WebSocketRequestHandlerFactory: public Poco::Net::HTTPRequestHandlerFactory
|
||||
{
|
||||
public:
|
||||
WebSocketRequestHandlerFactory(std::size_t bufSize = 1024): _bufSize(bufSize)
|
||||
{
|
||||
}
|
||||
|
||||
Poco::Net::HTTPRequestHandler* createRequestHandler(const HTTPServerRequest& request)
|
||||
{
|
||||
return new WebSocketRequestHandler(_bufSize);
|
||||
}
|
||||
|
||||
private:
|
||||
std::size_t _bufSize;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
WebSocketTest::WebSocketTest(const std::string& name): CppUnit::TestCase(name)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
WebSocketTest::~WebSocketTest()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void WebSocketTest::testWebSocket()
|
||||
{
|
||||
Poco::Net::SecureServerSocket ss(0);
|
||||
Poco::Net::HTTPServer server(new WebSocketRequestHandlerFactory, ss, new Poco::Net::HTTPServerParams);
|
||||
server.start();
|
||||
|
||||
Poco::Thread::sleep(200);
|
||||
|
||||
HTTPSClientSession cs("localhost", ss.address().port());
|
||||
HTTPRequest request(HTTPRequest::HTTP_GET, "/ws");
|
||||
HTTPResponse response;
|
||||
WebSocket ws(cs, request, response);
|
||||
|
||||
std::string payload("x");
|
||||
ws.sendFrame(payload.data(), (int) payload.size());
|
||||
char buffer[1024];
|
||||
int flags;
|
||||
int n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
assert (flags == WebSocket::FRAME_TEXT);
|
||||
|
||||
for (int i = 2; i < 20; i++)
|
||||
{
|
||||
payload.assign(i, 'x');
|
||||
ws.sendFrame(payload.data(), (int) payload.size());
|
||||
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
assert (flags == WebSocket::FRAME_TEXT);
|
||||
}
|
||||
|
||||
for (int i = 125; i < 129; i++)
|
||||
{
|
||||
payload.assign(i, 'x');
|
||||
ws.sendFrame(payload.data(), (int) payload.size());
|
||||
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
assert (flags == WebSocket::FRAME_TEXT);
|
||||
}
|
||||
|
||||
payload = "Hello, world!";
|
||||
ws.sendFrame(payload.data(), (int) payload.size());
|
||||
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
assert (flags == WebSocket::FRAME_TEXT);
|
||||
|
||||
payload = "Hello, universe!";
|
||||
ws.sendFrame(payload.data(), (int) payload.size(), WebSocket::FRAME_BINARY);
|
||||
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
assert (flags == WebSocket::FRAME_BINARY);
|
||||
|
||||
ws.shutdown();
|
||||
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||
assert (n == 2);
|
||||
assert ((flags & WebSocket::FRAME_OP_BITMASK) == WebSocket::FRAME_OP_CLOSE);
|
||||
|
||||
server.stop();
|
||||
}
|
||||
|
||||
|
||||
void WebSocketTest::testWebSocketLarge()
|
||||
{
|
||||
const int msgSize = 64000;
|
||||
|
||||
Poco::Net::SecureServerSocket ss(0);
|
||||
Poco::Net::HTTPServer server(new WebSocketRequestHandlerFactory(msgSize), ss, new Poco::Net::HTTPServerParams);
|
||||
server.start();
|
||||
|
||||
Poco::Thread::sleep(200);
|
||||
|
||||
HTTPSClientSession cs("localhost", ss.address().port());
|
||||
HTTPRequest request(HTTPRequest::HTTP_GET, "/ws");
|
||||
HTTPResponse response;
|
||||
WebSocket ws(cs, request, response);
|
||||
ws.setSendBufferSize(msgSize);
|
||||
ws.setReceiveBufferSize(msgSize);
|
||||
std::string payload(msgSize, 'x');
|
||||
SocketStream sstr(ws);
|
||||
sstr << payload;
|
||||
sstr.flush();
|
||||
|
||||
char buffer[msgSize + 1];
|
||||
int flags;
|
||||
int n = 0;
|
||||
do
|
||||
{
|
||||
n += ws.receiveFrame(buffer + n, sizeof(buffer) - n, flags);
|
||||
} while (n > 0 && n < msgSize);
|
||||
|
||||
assert (n == payload.size());
|
||||
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||
}
|
||||
|
||||
|
||||
void WebSocketTest::setUp()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void WebSocketTest::tearDown()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
CppUnit::Test* WebSocketTest::suite()
|
||||
{
|
||||
CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("WebSocketTest");
|
||||
|
||||
CppUnit_addTest(pSuite, WebSocketTest, testWebSocket);
|
||||
CppUnit_addTest(pSuite, WebSocketTest, testWebSocketLarge);
|
||||
|
||||
return pSuite;
|
||||
}
|
41
NetSSL_OpenSSL/testsuite/src/WebSocketTest.h
Normal file
41
NetSSL_OpenSSL/testsuite/src/WebSocketTest.h
Normal file
@ -0,0 +1,41 @@
|
||||
//
|
||||
// WebSocketTest.h
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTest.h#1 $
|
||||
//
|
||||
// Definition of the WebSocketTest class.
|
||||
//
|
||||
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
//
|
||||
|
||||
|
||||
#ifndef WebSocketTest_INCLUDED
|
||||
#define WebSocketTest_INCLUDED
|
||||
|
||||
|
||||
#include "Poco/Net/Net.h"
|
||||
#include "CppUnit/TestCase.h"
|
||||
|
||||
|
||||
class WebSocketTest: public CppUnit::TestCase
|
||||
{
|
||||
public:
|
||||
WebSocketTest(const std::string& name);
|
||||
~WebSocketTest();
|
||||
|
||||
void testWebSocket();
|
||||
void testWebSocketLarge();
|
||||
|
||||
void setUp();
|
||||
void tearDown();
|
||||
|
||||
static CppUnit::Test* suite();
|
||||
|
||||
private:
|
||||
};
|
||||
|
||||
|
||||
#endif // WebSocketTest_INCLUDED
|
24
NetSSL_OpenSSL/testsuite/src/WebSocketTestSuite.cpp
Normal file
24
NetSSL_OpenSSL/testsuite/src/WebSocketTestSuite.cpp
Normal file
@ -0,0 +1,24 @@
|
||||
//
|
||||
// WebSocketTestSuite.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTestSuite.cpp#1 $
|
||||
//
|
||||
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
//
|
||||
|
||||
|
||||
#include "WebSocketTestSuite.h"
|
||||
#include "WebSocketTest.h"
|
||||
|
||||
|
||||
CppUnit::Test* WebSocketTestSuite::suite()
|
||||
{
|
||||
CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("WebSocketTestSuite");
|
||||
|
||||
pSuite->addTest(WebSocketTest::suite());
|
||||
|
||||
return pSuite;
|
||||
}
|
29
NetSSL_OpenSSL/testsuite/src/WebSocketTestSuite.h
Normal file
29
NetSSL_OpenSSL/testsuite/src/WebSocketTestSuite.h
Normal file
@ -0,0 +1,29 @@
|
||||
//
|
||||
// WebSocketTestSuite.h
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTestSuite.h#1 $
|
||||
//
|
||||
// Definition of the WebSocketTestSuite class.
|
||||
//
|
||||
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
//
|
||||
|
||||
|
||||
#ifndef WebSocketTestSuite_INCLUDED
|
||||
#define WebSocketTestSuite_INCLUDED
|
||||
|
||||
|
||||
#include "CppUnit/TestSuite.h"
|
||||
|
||||
|
||||
class WebSocketTestSuite
|
||||
{
|
||||
public:
|
||||
static CppUnit::Test* suite();
|
||||
};
|
||||
|
||||
|
||||
#endif // WebSocketTestSuite_INCLUDED
|
Loading…
x
Reference in New Issue
Block a user