mirror of
https://github.com/pocoproject/poco.git
synced 2024-12-13 02:22:57 +01:00
Net::Route (windows compile)
Net::Route (windows compile only)
This commit is contained in:
parent
eb8c662c4c
commit
325a98a91f
@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="debug_shared|Win32">
|
||||
@ -32,76 +32,76 @@
|
||||
<RootNamespace>Net</RootNamespace>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props"/>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props"/>
|
||||
<ImportGroup Label="ExtensionSettings"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros"/>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">..\bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">..\bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">PocoNetd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">PocoNetmdd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">PocoNetmtd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">PocoNet</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">PocoNetmd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">PocoNetmt</TargetName>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">..\bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">..\bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">..\lib\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">PocoNetd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">PocoNetmdd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">PocoNetmtd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">PocoNet</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">PocoNetmd</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">PocoNetmt</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\include;..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -114,7 +114,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
<CompileAs>Default</CompileAs>
|
||||
@ -132,7 +132,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -147,9 +147,9 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -166,7 +166,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\include;..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -179,7 +179,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<ProgramDataBaseFileName>..\lib\PocoNetmtd.pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
@ -190,7 +190,7 @@
|
||||
<OutputFile>..\lib\PocoNetmtd.lib</OutputFile>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -205,9 +205,9 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -215,7 +215,7 @@
|
||||
<OutputFile>..\lib\PocoNetmt.lib</OutputFile>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\include;..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -228,7 +228,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<ProgramDataBaseFileName>..\lib\PocoNetmdd.pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
@ -239,7 +239,7 @@
|
||||
<OutputFile>..\lib\PocoNetmdd.lib</OutputFile>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -254,10 +254,10 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<ProgramDataBaseFileName>..\lib\PocoNetmd.pdb</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -267,204 +267,230 @@
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="include\Poco\Net\DNS.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HostEntry.h"/>
|
||||
<ClInclude Include="include\Poco\Net\IPAddress.h"/>
|
||||
<ClInclude Include="include\Poco\Net\Net.h"/>
|
||||
<ClInclude Include="include\Poco\Net\NetException.h"/>
|
||||
<ClInclude Include="include\Poco\Net\NetworkInterface.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketAddress.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketDefs.h"/>
|
||||
<ClInclude Include="include\Poco\Net\DatagramSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\DialogSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MulticastSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\RawSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\RawSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ServerSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\Socket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\StreamSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\FilePartSource.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MediaType.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MessageHeader.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MultipartReader.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MultipartWriter.h"/>
|
||||
<ClInclude Include="include\Poco\Net\NameValueCollection.h"/>
|
||||
<ClInclude Include="include\Poco\Net\NullPartHandler.h"/>
|
||||
<ClInclude Include="include\Poco\Net\PartHandler.h"/>
|
||||
<ClInclude Include="include\Poco\Net\PartSource.h"/>
|
||||
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h"/>
|
||||
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h"/>
|
||||
<ClInclude Include="include\Poco\Net\StringPartSource.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPCookie.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPCredentials.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPMessage.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequest.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPResponse.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\TCPServer.h"/>
|
||||
<ClInclude Include="include\Poco\Net\TCPServerConnection.h"/>
|
||||
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h"/>
|
||||
<ClInclude Include="include\Poco\Net\TCPServerParams.h"/>
|
||||
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServer.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerParams.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPClientSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPIOStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\HTMLForm.h"/>
|
||||
<ClInclude Include="include\Poco\Net\FTPClientSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketAcceptor.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketConnector.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketNotification.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketNotifier.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SocketReactor.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MailMessage.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MailRecipient.h"/>
|
||||
<ClInclude Include="include\Poco\Net\MailStream.h"/>
|
||||
<ClInclude Include="include\Poco\Net\POP3ClientSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SMTPClientSession.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPClient.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPPacket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h"/>
|
||||
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h"/>
|
||||
<ClInclude Include="include\Poco\Net\SMTPChannel.h"/>
|
||||
<ClInclude Include="include\Poco\Net\WebSocket.h"/>
|
||||
<ClInclude Include="include\Poco\Net\WebSocketImpl.h"/>
|
||||
<ClInclude Include="include\Poco\Net\DNS.h" />
|
||||
<ClInclude Include="include\Poco\Net\HostEntry.h" />
|
||||
<ClInclude Include="include\Poco\Net\IPAddress.h" />
|
||||
<ClInclude Include="include\Poco\Net\Net.h" />
|
||||
<ClInclude Include="include\Poco\Net\NetException.h" />
|
||||
<ClInclude Include="include\Poco\Net\NetworkInterface.h" />
|
||||
<ClInclude Include="include\Poco\Net\Route.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketAddress.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketDefs.h" />
|
||||
<ClInclude Include="include\Poco\Net\DatagramSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\DialogSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\MulticastSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\RawSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\RawSocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\ServerSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\Socket.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\StreamSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\FilePartSource.h" />
|
||||
<ClInclude Include="include\Poco\Net\MediaType.h" />
|
||||
<ClInclude Include="include\Poco\Net\MessageHeader.h" />
|
||||
<ClInclude Include="include\Poco\Net\MultipartReader.h" />
|
||||
<ClInclude Include="include\Poco\Net\MultipartWriter.h" />
|
||||
<ClInclude Include="include\Poco\Net\NameValueCollection.h" />
|
||||
<ClInclude Include="include\Poco\Net\NullPartHandler.h" />
|
||||
<ClInclude Include="include\Poco\Net\PartHandler.h" />
|
||||
<ClInclude Include="include\Poco\Net\PartSource.h" />
|
||||
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h" />
|
||||
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h" />
|
||||
<ClInclude Include="include\Poco\Net\StringPartSource.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPCookie.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPCredentials.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPMessage.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequest.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPResponse.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\TCPServer.h" />
|
||||
<ClInclude Include="include\Poco\Net\TCPServerConnection.h" />
|
||||
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h" />
|
||||
<ClInclude Include="include\Poco\Net\TCPServerParams.h" />
|
||||
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServer.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerParams.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPServerSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPClientSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPIOStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\HTMLForm.h" />
|
||||
<ClInclude Include="include\Poco\Net\FTPClientSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketAcceptor.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketConnector.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketNotification.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketNotifier.h" />
|
||||
<ClInclude Include="include\Poco\Net\SocketReactor.h" />
|
||||
<ClInclude Include="include\Poco\Net\MailMessage.h" />
|
||||
<ClInclude Include="include\Poco\Net\MailRecipient.h" />
|
||||
<ClInclude Include="include\Poco\Net\MailStream.h" />
|
||||
<ClInclude Include="include\Poco\Net\POP3ClientSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\SMTPClientSession.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPClient.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPPacket.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h" />
|
||||
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h" />
|
||||
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h" />
|
||||
<ClInclude Include="include\Poco\Net\SMTPChannel.h" />
|
||||
<ClInclude Include="include\Poco\Net\WebSocket.h" />
|
||||
<ClInclude Include="include\Poco\Net\WebSocketImpl.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\DNS.cpp"/>
|
||||
<ClCompile Include="src\HostEntry.cpp"/>
|
||||
<ClCompile Include="src\IPAddress.cpp"/>
|
||||
<ClCompile Include="src\NetException.cpp"/>
|
||||
<ClCompile Include="src\NetworkInterface.cpp"/>
|
||||
<ClCompile Include="src\SocketAddress.cpp"/>
|
||||
<ClCompile Include="src\DatagramSocket.cpp"/>
|
||||
<ClCompile Include="src\DatagramSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\DialogSocket.cpp"/>
|
||||
<ClCompile Include="src\MulticastSocket.cpp"/>
|
||||
<ClCompile Include="src\RawSocket.cpp"/>
|
||||
<ClCompile Include="src\RawSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\ServerSocket.cpp"/>
|
||||
<ClCompile Include="src\ServerSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\Socket.cpp"/>
|
||||
<ClCompile Include="src\SocketImpl.cpp"/>
|
||||
<ClCompile Include="src\SocketStream.cpp"/>
|
||||
<ClCompile Include="src\StreamSocket.cpp"/>
|
||||
<ClCompile Include="src\StreamSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\FilePartSource.cpp"/>
|
||||
<ClCompile Include="src\MediaType.cpp"/>
|
||||
<ClCompile Include="src\MessageHeader.cpp"/>
|
||||
<ClCompile Include="src\MultipartReader.cpp"/>
|
||||
<ClCompile Include="src\MultipartWriter.cpp"/>
|
||||
<ClCompile Include="src\NameValueCollection.cpp"/>
|
||||
<ClCompile Include="src\NullPartHandler.cpp"/>
|
||||
<ClCompile Include="src\PartHandler.cpp"/>
|
||||
<ClCompile Include="src\PartSource.cpp"/>
|
||||
<ClCompile Include="src\QuotedPrintableDecoder.cpp"/>
|
||||
<ClCompile Include="src\QuotedPrintableEncoder.cpp"/>
|
||||
<ClCompile Include="src\StringPartSource.cpp"/>
|
||||
<ClCompile Include="src\HTTPAuthenticationParams.cpp"/>
|
||||
<ClCompile Include="src\HTTPBasicCredentials.cpp"/>
|
||||
<ClCompile Include="src\HTTPBufferAllocator.cpp"/>
|
||||
<ClCompile Include="src\HTTPChunkedStream.cpp"/>
|
||||
<ClCompile Include="src\HTTPCookie.cpp"/>
|
||||
<ClCompile Include="src\HTTPCredentials.cpp"/>
|
||||
<ClCompile Include="src\HTTPDigestCredentials.cpp"/>
|
||||
<ClCompile Include="src\HTTPFixedLengthStream.cpp"/>
|
||||
<ClCompile Include="src\HTTPHeaderStream.cpp"/>
|
||||
<ClCompile Include="src\HTTPMessage.cpp"/>
|
||||
<ClCompile Include="src\HTTPRequest.cpp"/>
|
||||
<ClCompile Include="src\HTTPResponse.cpp"/>
|
||||
<ClCompile Include="src\HTTPSession.cpp"/>
|
||||
<ClCompile Include="src\HTTPStream.cpp"/>
|
||||
<ClCompile Include="src\TCPServer.cpp"/>
|
||||
<ClCompile Include="src\TCPServerConnection.cpp"/>
|
||||
<ClCompile Include="src\TCPServerConnectionFactory.cpp"/>
|
||||
<ClCompile Include="src\TCPServerDispatcher.cpp"/>
|
||||
<ClCompile Include="src\TCPServerParams.cpp"/>
|
||||
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp"/>
|
||||
<ClCompile Include="src\HTTPRequestHandler.cpp"/>
|
||||
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp"/>
|
||||
<ClCompile Include="src\HTTPServer.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerConnection.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerConnectionFactory.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerParams.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerRequest.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerRequestImpl.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerResponse.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerResponseImpl.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerSession.cpp"/>
|
||||
<ClCompile Include="src\HTTPClientSession.cpp"/>
|
||||
<ClCompile Include="src\HTTPIOStream.cpp"/>
|
||||
<ClCompile Include="src\HTTPSessionFactory.cpp"/>
|
||||
<ClCompile Include="src\HTTPSessionInstantiator.cpp"/>
|
||||
<ClCompile Include="src\HTTPStreamFactory.cpp"/>
|
||||
<ClCompile Include="src\HTMLForm.cpp"/>
|
||||
<ClCompile Include="src\FTPClientSession.cpp"/>
|
||||
<ClCompile Include="src\FTPStreamFactory.cpp"/>
|
||||
<ClCompile Include="src\SocketNotification.cpp"/>
|
||||
<ClCompile Include="src\SocketNotifier.cpp"/>
|
||||
<ClCompile Include="src\SocketReactor.cpp"/>
|
||||
<ClCompile Include="src\MailMessage.cpp"/>
|
||||
<ClCompile Include="src\MailRecipient.cpp"/>
|
||||
<ClCompile Include="src\MailStream.cpp"/>
|
||||
<ClCompile Include="src\POP3ClientSession.cpp"/>
|
||||
<ClCompile Include="src\SMTPClientSession.cpp"/>
|
||||
<ClCompile Include="src\ICMPClient.cpp"/>
|
||||
<ClCompile Include="src\ICMPEventArgs.cpp"/>
|
||||
<ClCompile Include="src\ICMPPacket.cpp"/>
|
||||
<ClCompile Include="src\ICMPPacketImpl.cpp"/>
|
||||
<ClCompile Include="src\ICMPSocket.cpp"/>
|
||||
<ClCompile Include="src\ICMPSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\ICMPv4PacketImpl.cpp"/>
|
||||
<ClCompile Include="src\RemoteSyslogChannel.cpp"/>
|
||||
<ClCompile Include="src\RemoteSyslogListener.cpp"/>
|
||||
<ClCompile Include="src\SMTPChannel.cpp"/>
|
||||
<ClCompile Include="src\WebSocket.cpp"/>
|
||||
<ClCompile Include="src\WebSocketImpl.cpp"/>
|
||||
<ClCompile Include="src\DNS.cpp" />
|
||||
<ClCompile Include="src\HostEntry.cpp" />
|
||||
<ClCompile Include="src\IPAddress.cpp" />
|
||||
<ClCompile Include="src\NetException.cpp" />
|
||||
<ClCompile Include="src\NetworkInterface.cpp" />
|
||||
<ClCompile Include="src\Route.cpp" />
|
||||
<ClCompile Include="src\Route_BSD.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route_Linux.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route_WIN32.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\SocketAddress.cpp" />
|
||||
<ClCompile Include="src\DatagramSocket.cpp" />
|
||||
<ClCompile Include="src\DatagramSocketImpl.cpp" />
|
||||
<ClCompile Include="src\DialogSocket.cpp" />
|
||||
<ClCompile Include="src\MulticastSocket.cpp" />
|
||||
<ClCompile Include="src\RawSocket.cpp" />
|
||||
<ClCompile Include="src\RawSocketImpl.cpp" />
|
||||
<ClCompile Include="src\ServerSocket.cpp" />
|
||||
<ClCompile Include="src\ServerSocketImpl.cpp" />
|
||||
<ClCompile Include="src\Socket.cpp" />
|
||||
<ClCompile Include="src\SocketImpl.cpp" />
|
||||
<ClCompile Include="src\SocketStream.cpp" />
|
||||
<ClCompile Include="src\StreamSocket.cpp" />
|
||||
<ClCompile Include="src\StreamSocketImpl.cpp" />
|
||||
<ClCompile Include="src\FilePartSource.cpp" />
|
||||
<ClCompile Include="src\MediaType.cpp" />
|
||||
<ClCompile Include="src\MessageHeader.cpp" />
|
||||
<ClCompile Include="src\MultipartReader.cpp" />
|
||||
<ClCompile Include="src\MultipartWriter.cpp" />
|
||||
<ClCompile Include="src\NameValueCollection.cpp" />
|
||||
<ClCompile Include="src\NullPartHandler.cpp" />
|
||||
<ClCompile Include="src\PartHandler.cpp" />
|
||||
<ClCompile Include="src\PartSource.cpp" />
|
||||
<ClCompile Include="src\QuotedPrintableDecoder.cpp" />
|
||||
<ClCompile Include="src\QuotedPrintableEncoder.cpp" />
|
||||
<ClCompile Include="src\StringPartSource.cpp" />
|
||||
<ClCompile Include="src\HTTPAuthenticationParams.cpp" />
|
||||
<ClCompile Include="src\HTTPBasicCredentials.cpp" />
|
||||
<ClCompile Include="src\HTTPBufferAllocator.cpp" />
|
||||
<ClCompile Include="src\HTTPChunkedStream.cpp" />
|
||||
<ClCompile Include="src\HTTPCookie.cpp" />
|
||||
<ClCompile Include="src\HTTPCredentials.cpp" />
|
||||
<ClCompile Include="src\HTTPDigestCredentials.cpp" />
|
||||
<ClCompile Include="src\HTTPFixedLengthStream.cpp" />
|
||||
<ClCompile Include="src\HTTPHeaderStream.cpp" />
|
||||
<ClCompile Include="src\HTTPMessage.cpp" />
|
||||
<ClCompile Include="src\HTTPRequest.cpp" />
|
||||
<ClCompile Include="src\HTTPResponse.cpp" />
|
||||
<ClCompile Include="src\HTTPSession.cpp" />
|
||||
<ClCompile Include="src\HTTPStream.cpp" />
|
||||
<ClCompile Include="src\TCPServer.cpp" />
|
||||
<ClCompile Include="src\TCPServerConnection.cpp" />
|
||||
<ClCompile Include="src\TCPServerConnectionFactory.cpp" />
|
||||
<ClCompile Include="src\TCPServerDispatcher.cpp" />
|
||||
<ClCompile Include="src\TCPServerParams.cpp" />
|
||||
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp" />
|
||||
<ClCompile Include="src\HTTPRequestHandler.cpp" />
|
||||
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp" />
|
||||
<ClCompile Include="src\HTTPServer.cpp" />
|
||||
<ClCompile Include="src\HTTPServerConnection.cpp" />
|
||||
<ClCompile Include="src\HTTPServerConnectionFactory.cpp" />
|
||||
<ClCompile Include="src\HTTPServerParams.cpp" />
|
||||
<ClCompile Include="src\HTTPServerRequest.cpp" />
|
||||
<ClCompile Include="src\HTTPServerRequestImpl.cpp" />
|
||||
<ClCompile Include="src\HTTPServerResponse.cpp" />
|
||||
<ClCompile Include="src\HTTPServerResponseImpl.cpp" />
|
||||
<ClCompile Include="src\HTTPServerSession.cpp" />
|
||||
<ClCompile Include="src\HTTPClientSession.cpp" />
|
||||
<ClCompile Include="src\HTTPIOStream.cpp" />
|
||||
<ClCompile Include="src\HTTPSessionFactory.cpp" />
|
||||
<ClCompile Include="src\HTTPSessionInstantiator.cpp" />
|
||||
<ClCompile Include="src\HTTPStreamFactory.cpp" />
|
||||
<ClCompile Include="src\HTMLForm.cpp" />
|
||||
<ClCompile Include="src\FTPClientSession.cpp" />
|
||||
<ClCompile Include="src\FTPStreamFactory.cpp" />
|
||||
<ClCompile Include="src\SocketNotification.cpp" />
|
||||
<ClCompile Include="src\SocketNotifier.cpp" />
|
||||
<ClCompile Include="src\SocketReactor.cpp" />
|
||||
<ClCompile Include="src\MailMessage.cpp" />
|
||||
<ClCompile Include="src\MailRecipient.cpp" />
|
||||
<ClCompile Include="src\MailStream.cpp" />
|
||||
<ClCompile Include="src\POP3ClientSession.cpp" />
|
||||
<ClCompile Include="src\SMTPClientSession.cpp" />
|
||||
<ClCompile Include="src\ICMPClient.cpp" />
|
||||
<ClCompile Include="src\ICMPEventArgs.cpp" />
|
||||
<ClCompile Include="src\ICMPPacket.cpp" />
|
||||
<ClCompile Include="src\ICMPPacketImpl.cpp" />
|
||||
<ClCompile Include="src\ICMPSocket.cpp" />
|
||||
<ClCompile Include="src\ICMPSocketImpl.cpp" />
|
||||
<ClCompile Include="src\ICMPv4PacketImpl.cpp" />
|
||||
<ClCompile Include="src\RemoteSyslogChannel.cpp" />
|
||||
<ClCompile Include="src\RemoteSyslogListener.cpp" />
|
||||
<ClCompile Include="src\SMTPChannel.cpp" />
|
||||
<ClCompile Include="src\WebSocket.cpp" />
|
||||
<ClCompile Include="src\WebSocketImpl.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="..\DLLVersion.rc">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">true</ExcludedFromBuild>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||
<ImportGroup Label="ExtensionTargets"/>
|
||||
</Project>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
@ -414,6 +414,9 @@
|
||||
<ClInclude Include="include\Poco\Net\WebSocketImpl.h">
|
||||
<Filter>WebSocket\Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="include\Poco\Net\Route.h">
|
||||
<Filter>NetCore\Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\DNS.cpp">
|
||||
@ -686,6 +689,18 @@
|
||||
<ClCompile Include="src\WebSocketImpl.cpp">
|
||||
<Filter>WebSocket\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route.cpp">
|
||||
<Filter>NetCore\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route_WIN32.cpp">
|
||||
<Filter>NetCore\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route_BSD.cpp">
|
||||
<Filter>NetCore\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\Route_Linux.cpp">
|
||||
<Filter>NetCore\Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="..\DLLVersion.rc" />
|
||||
|
410
Net/include/Poco/Net/Route.h
Normal file
410
Net/include/Poco/Net/Route.h
Normal file
@ -0,0 +1,410 @@
|
||||
//
|
||||
// Route.h
|
||||
//
|
||||
// $Id: //poco/1.4/Net/include/Poco/Net/Route.h#1 $
|
||||
//
|
||||
// Library: Net
|
||||
// Package: NetCore
|
||||
// Module: Route
|
||||
//
|
||||
// Definition of the Route class.
|
||||
//
|
||||
// Copyright (c) 2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
#ifndef Net_Route_INCLUDED
|
||||
#define Net_Route_INCLUDED
|
||||
|
||||
|
||||
#include "Poco/Net/Net.h"
|
||||
|
||||
|
||||
#if defined(POCO_OS_FAMILY_WINDOWS)
|
||||
#ifndef POCO_NET_HAS_ROUTE
|
||||
#define POCO_NET_HAS_ROUTE
|
||||
#endif
|
||||
#elif defined(POCO_OS_FAMILY_BSD)
|
||||
#ifndef POCO_NET_HAS_ROUTE
|
||||
#define POCO_NET_HAS_ROUTE
|
||||
#endif
|
||||
#elif defined(POCO_OS_FAMILY_UNIX) && (POCO_OS == POCO_OS_LINUX)
|
||||
#ifndef POCO_NET_HAS_ROUTE
|
||||
#define POCO_NET_HAS_ROUTE
|
||||
#endif
|
||||
#else
|
||||
#ifdef POCO_NET_HAS_ROUTE
|
||||
#undef POCO_NET_HAS_ROUTE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef POCO_NET_HAS_ROUTE
|
||||
|
||||
|
||||
#include "Poco/Net/IPAddress.h"
|
||||
#include "Poco/Net/NetworkInterface.h"
|
||||
#include "Poco/Timestamp.h"
|
||||
#include <ctime>
|
||||
#include <list>
|
||||
|
||||
|
||||
namespace Poco {
|
||||
namespace Net {
|
||||
|
||||
|
||||
class RouteHelper;
|
||||
|
||||
|
||||
class Net_API Route
|
||||
{
|
||||
public:
|
||||
typedef std::list<Route> RouteList;
|
||||
|
||||
enum RouteType
|
||||
{
|
||||
ROUTE_NONE = 0,
|
||||
ROUTE_OTHER = 1,
|
||||
ROUTE_INVALID = 2,
|
||||
ROUTE_DIRECT = 3,
|
||||
ROUTE_INDIRECT = 4
|
||||
};
|
||||
|
||||
enum RouteProto
|
||||
{
|
||||
ROUTE_PROTO_NONE = 0,
|
||||
ROUTE_PROTO_OTHER = 1,
|
||||
ROUTE_PROTO_LOCAL = 2,
|
||||
ROUTE_PROTO_NET_MGMT = 3,
|
||||
ROUTE_PROTO_ICMP = 4,
|
||||
ROUTE_PROTO_EGP = 5,
|
||||
ROUTE_PROTO_GGP = 6,
|
||||
ROUTE_PROTO_HELLO = 7,
|
||||
ROUTE_PROTO_RIP = 8,
|
||||
ROUTE_PROTO_ISIS = 9,
|
||||
ROUTE_PROTO_ESIS = 10,
|
||||
ROUTE_PROTO_CISCO = 11, // EIGRP?
|
||||
ROUTE_PROTO_BBN = 12,
|
||||
ROUTE_PROTO_OSPF = 13,
|
||||
ROUTE_PROTO_BGP = 14,
|
||||
};
|
||||
|
||||
~Route();
|
||||
/// Destroys Route.
|
||||
|
||||
const IPAddress getDest() const;
|
||||
/// Returns destination.
|
||||
|
||||
unsigned getPrefix() const;
|
||||
/// Returns prefix.
|
||||
|
||||
const IPAddress getNetmask() const;
|
||||
/// Returns net mask (IPv4 only).
|
||||
|
||||
const IPAddress getNextHop() const;
|
||||
/// Returns next hop.
|
||||
|
||||
unsigned getIfIndex() const;
|
||||
/// Returns interface index.
|
||||
|
||||
const NetworkInterface getNetworkInterface() const;
|
||||
/// Returns netwrok interface.
|
||||
|
||||
RouteType getType() const;
|
||||
/// Returns route type.
|
||||
|
||||
unsigned getMetric() const;
|
||||
/// Returns metric; not available on all platforms.
|
||||
|
||||
unsigned getHops() const;
|
||||
/// Returns hops count; not available on all platforms.
|
||||
|
||||
unsigned getMTU() const;
|
||||
/// Returns MTU; not available on all platforms.
|
||||
|
||||
unsigned getUsage() const;
|
||||
/// Returns usage; not available on all platforms.
|
||||
|
||||
RouteProto getProto() const;
|
||||
/// Returns proto; not available on all platforms.
|
||||
|
||||
std::time_t getAge() const;
|
||||
/// Returns age; not available on all platforms.
|
||||
|
||||
bool validMetric() const;
|
||||
/// Returns true if metric is valid; not available on all platforms.
|
||||
|
||||
bool validHops() const;
|
||||
/// Returns true if hops are valid; not available on all platforms.
|
||||
|
||||
bool validMTU() const;
|
||||
/// Returns true if MTU is valid; not available on all platforms.
|
||||
|
||||
bool validUsage() const;
|
||||
/// Returns true if usage is valid; not available on all platforms.
|
||||
|
||||
bool validProto() const;
|
||||
/// Returns true if proto is valid; not available on all platforms.
|
||||
|
||||
bool validAge() const;
|
||||
/// Returns true if age is valid; not available on all platforms.
|
||||
|
||||
|
||||
bool operator == (const Route& other) const;
|
||||
/// Return strue if this route is equal to other.
|
||||
|
||||
bool operator != (const Route& other) const;
|
||||
/// Return strue if this route is not equal to other.
|
||||
|
||||
static RouteList list(IPAddress::Family family);
|
||||
/// Retruns the list of routes.
|
||||
|
||||
static RouteList defaults(IPAddress::Family family);
|
||||
/// Returns default routes.
|
||||
|
||||
static RouteList match(IPAddress target);
|
||||
/// Retruns routes matching target.
|
||||
|
||||
static const IPAddress getDefaultAddress(IPAddress::Family family);
|
||||
/// Returns default IP address for the family.
|
||||
|
||||
static std::string protocolName(RouteProto proto);
|
||||
/// Returns protocol as string.
|
||||
|
||||
protected:
|
||||
void setMTU(unsigned mtu);
|
||||
/// Sets the MTU to specified value.
|
||||
|
||||
void setAge(std::time_t created);
|
||||
/// Sets MTU to specified value.
|
||||
|
||||
void setProto(RouteProto proto);
|
||||
/// Sets proto to specified value.
|
||||
|
||||
void setMetric(unsigned metric);
|
||||
/// Sets metric to specified value.
|
||||
|
||||
void setHops(unsigned hops);
|
||||
/// Sets hops to specified value.
|
||||
|
||||
void setUsage(unsigned use);
|
||||
/// Sets usage to specified value.
|
||||
|
||||
private:
|
||||
Route(const IPAddress& dst, const IPAddress& netmask, const IPAddress& nextHop, unsigned ifIndex, RouteType type);
|
||||
/// Creates Route.
|
||||
|
||||
Route(const IPAddress& dst, const IPAddress& netmask, unsigned ifIndex, RouteType type);
|
||||
/// Creates Route.
|
||||
|
||||
Route(const IPAddress& dst, unsigned prefix, const IPAddress& nextHop, unsigned ifIndex, RouteType type);
|
||||
/// Creates Route.
|
||||
|
||||
Route(const IPAddress& dst, unsigned prefix, unsigned ifIndex, RouteType type);
|
||||
/// Creates Route.
|
||||
|
||||
// portable attributes
|
||||
IPAddress _dst;
|
||||
IPAddress _netmask;
|
||||
IPAddress _nextHop;
|
||||
unsigned _ifIndex;
|
||||
RouteType _type;
|
||||
|
||||
// optional attributes supported on some platforms
|
||||
unsigned _metric;
|
||||
unsigned _mtu;
|
||||
unsigned _hops;
|
||||
unsigned _use;
|
||||
RouteProto _proto;
|
||||
Timestamp _created;
|
||||
|
||||
friend class RouteHelper;
|
||||
};
|
||||
|
||||
|
||||
//
|
||||
// inlines
|
||||
//
|
||||
|
||||
|
||||
inline const IPAddress Route::getDest() const
|
||||
{
|
||||
return _dst;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getPrefix() const
|
||||
{
|
||||
return _netmask.prefixLength();
|
||||
}
|
||||
|
||||
|
||||
inline const IPAddress Route::getNetmask() const
|
||||
{
|
||||
return _netmask;
|
||||
}
|
||||
|
||||
|
||||
inline const IPAddress Route::getNextHop() const
|
||||
{
|
||||
return _nextHop;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getIfIndex() const
|
||||
{
|
||||
return _ifIndex;
|
||||
}
|
||||
|
||||
|
||||
inline const NetworkInterface Route::getNetworkInterface() const
|
||||
{
|
||||
return NetworkInterface::forIndex(_ifIndex);
|
||||
}
|
||||
|
||||
|
||||
inline Route::RouteType Route::getType() const
|
||||
{
|
||||
return _type;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getMetric() const
|
||||
{
|
||||
return _metric;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getHops() const
|
||||
{
|
||||
return _hops;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getMTU() const
|
||||
{
|
||||
return _mtu;
|
||||
}
|
||||
|
||||
|
||||
inline unsigned Route::getUsage() const
|
||||
{
|
||||
return _use;
|
||||
}
|
||||
|
||||
|
||||
inline Route::RouteProto Route::getProto() const
|
||||
{
|
||||
return _proto;
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validMetric() const
|
||||
{
|
||||
return (_metric != ~0U);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validHops() const
|
||||
{
|
||||
return (_hops != ~0U);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validMTU() const
|
||||
{
|
||||
return (_mtu != 0U);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validUsage() const
|
||||
{
|
||||
return (_use != ~0U);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validProto() const
|
||||
{
|
||||
return (_proto != (RouteProto)0);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::validAge() const
|
||||
{
|
||||
return (_created != 0U);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::operator == (const Route& other) const
|
||||
{
|
||||
return (_dst == other._dst
|
||||
&& _netmask == other._netmask
|
||||
&& _nextHop == other._nextHop
|
||||
&& _metric == other._metric
|
||||
&& _ifIndex == other._ifIndex
|
||||
&& _type == other._type
|
||||
&& _proto == other._proto
|
||||
&& _created == other._created);
|
||||
}
|
||||
|
||||
|
||||
inline bool Route::operator != (const Route& other) const
|
||||
{
|
||||
return !(*this == other);
|
||||
}
|
||||
|
||||
|
||||
inline void Route::setMTU(unsigned mtu)
|
||||
{
|
||||
_mtu = mtu;
|
||||
}
|
||||
|
||||
|
||||
inline void Route::setMetric(unsigned metric)
|
||||
{
|
||||
_metric = metric;
|
||||
}
|
||||
|
||||
|
||||
inline void Route::setHops(unsigned hops)
|
||||
{
|
||||
_hops = hops;
|
||||
}
|
||||
|
||||
|
||||
inline void Route::setUsage(unsigned use)
|
||||
{
|
||||
_use = use;
|
||||
}
|
||||
|
||||
|
||||
} } // Poco::Net
|
||||
|
||||
|
||||
#endif // POCO_NET_HAS_ROUTE
|
||||
|
||||
|
||||
#endif // Net_Route_INCLUDED
|
@ -131,7 +131,7 @@ public:
|
||||
#endif
|
||||
|
||||
void setUp(bool up);
|
||||
void setMtu(unsigned mtu);
|
||||
void setMTU(unsigned mtu);
|
||||
void setType(Type type);
|
||||
void setIndex(unsigned index);
|
||||
void setPhyParams();
|
||||
@ -227,7 +227,7 @@ void NetworkInterfaceImpl::setPhyParams()
|
||||
setFlags(ifr.ifr_flags);
|
||||
|
||||
ds.impl()->ioctl(SIOCGIFMTU, &ifr);
|
||||
setMtu(ifr.ifr_mtu);
|
||||
setMTU(ifr.ifr_mtu);
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -466,7 +466,7 @@ inline void NetworkInterfaceImpl::setUp(bool up)
|
||||
}
|
||||
|
||||
|
||||
inline void NetworkInterfaceImpl::setMtu(unsigned mtu)
|
||||
inline void NetworkInterfaceImpl::setMTU(unsigned mtu)
|
||||
{
|
||||
_mtu = mtu;
|
||||
}
|
||||
@ -1011,7 +1011,7 @@ NetworkInterface::Map NetworkInterface::map(bool ipOnly, bool upOnly)
|
||||
ifIt = result.insert(Map::value_type(ifIndex, ni)).first;
|
||||
|
||||
ifIt->second.impl().setFlags(pAddress->Flags, pAddress->IfType);
|
||||
ifIt->second.impl().setMtu(pAddress->Mtu);
|
||||
ifIt->second.impl().setMTU(pAddress->Mtu);
|
||||
ifIt->second.impl().setUp(pAddress->OperStatus == IfOperStatusUp);
|
||||
#if (_WIN32_WINNT >= 0x0600) // Vista and newer only
|
||||
ifIt->second.impl().setRunning(pAddress->ReceiveLinkSpeed > 0 || pAddress->TransmitLinkSpeed > 0);
|
||||
|
263
Net/src/Route.cpp
Normal file
263
Net/src/Route.cpp
Normal file
@ -0,0 +1,263 @@
|
||||
//
|
||||
// Route.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Foundation/src/Route.cpp#2 $
|
||||
//
|
||||
// Library: Net
|
||||
// Package: NetCore
|
||||
// Module: Route
|
||||
//
|
||||
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
#include "Poco/Net/Route.h"
|
||||
|
||||
|
||||
#ifdef POCO_NET_HAS_ROUTE
|
||||
|
||||
|
||||
#include "Poco/Net/IPAddress.h"
|
||||
#include "Poco/Net/NetException.h"
|
||||
#include <iphlpapi.h>
|
||||
|
||||
|
||||
#if defined(POCO_OS_FAMILY_WINDOWS)
|
||||
#include "Route_WIN32.cpp"
|
||||
#elif defined(POCO_OS_FAMILY_BSD)
|
||||
#include "Route_BSD.cpp"
|
||||
#elif defined(POCO_OS_FAMILY_UNIX) && (POCO_OS == POCO_OS_LINUX)
|
||||
#include "Route_Linux.cpp"
|
||||
#endif
|
||||
|
||||
|
||||
namespace Poco {
|
||||
namespace Net {
|
||||
|
||||
|
||||
Route::Route(const IPAddress& dst, const IPAddress& netmask, const IPAddress& nextHop, unsigned ifIndex, RouteType type) :
|
||||
_dst(dst),
|
||||
_netmask(netmask),
|
||||
_nextHop(nextHop),
|
||||
_ifIndex(ifIndex),
|
||||
_type(type),
|
||||
// attributes that might not be available on all platforms are set to sentinel values.
|
||||
_metric(~0),
|
||||
_hops(~0),
|
||||
_mtu(0),
|
||||
_use(~1),
|
||||
_proto(ROUTE_PROTO_NONE),
|
||||
_created(0)
|
||||
{
|
||||
if (_dst.family() != _nextHop.family())
|
||||
throw InvalidArgumentException("Destination and nextHop have different families");
|
||||
}
|
||||
|
||||
|
||||
Route::Route(const IPAddress& dst, const IPAddress& netmask, unsigned ifIndex, RouteType type) :
|
||||
_dst(dst),
|
||||
_netmask(netmask),
|
||||
_nextHop(IPAddress(dst.family())),
|
||||
_ifIndex(ifIndex),
|
||||
_type(type),
|
||||
// attributes that might not be available on all platforms are set to sentinel values.
|
||||
_metric(~0),
|
||||
_hops(~0),
|
||||
_mtu(0),
|
||||
_use(~1),
|
||||
_proto(ROUTE_PROTO_NONE),
|
||||
_created(0)
|
||||
{
|
||||
if (_dst.family() != _nextHop.family())
|
||||
throw InvalidArgumentException("Destination and nextHop have different families");
|
||||
}
|
||||
|
||||
|
||||
Route::Route(const IPAddress& dst, unsigned prefix, const IPAddress& nextHop, unsigned ifIndex, RouteType type) :
|
||||
_dst(dst),
|
||||
_netmask(IPAddress(prefix, dst.family())),
|
||||
_nextHop(nextHop),
|
||||
_ifIndex(ifIndex),
|
||||
_type(type),
|
||||
// attributes that might not be available on all platforms are set to sentinel values.
|
||||
_metric(~0),
|
||||
_hops(~0),
|
||||
_mtu(0),
|
||||
_use(~1),
|
||||
_proto(ROUTE_PROTO_NONE),
|
||||
_created(0)
|
||||
{
|
||||
if (_dst.family() != _nextHop.family())
|
||||
throw InvalidArgumentException("Destination and nextHop have different families");
|
||||
}
|
||||
|
||||
Route::Route(const IPAddress& dst, unsigned prefix, unsigned ifIndex, RouteType type) :
|
||||
_dst(dst),
|
||||
_netmask(IPAddress(prefix, dst.family())),
|
||||
_nextHop(IPAddress(dst.family())),
|
||||
_ifIndex(ifIndex),
|
||||
_type(type),
|
||||
// attributes that might not be available on all platforms are set to sentinel values.
|
||||
_metric(~0),
|
||||
_hops(~0),
|
||||
_mtu(0),
|
||||
_use(~1),
|
||||
_proto(ROUTE_PROTO_NONE),
|
||||
_created(0)
|
||||
{
|
||||
if (_dst.family() != _nextHop.family())
|
||||
throw InvalidArgumentException("Destination and nextHop have different families");
|
||||
}
|
||||
|
||||
|
||||
Route::~Route()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
std::time_t Route::getAge() const
|
||||
{
|
||||
std::time_t now = std::time(NULL);
|
||||
return ((_created != 0) ? (now - _created.epochTime()) : 0);
|
||||
}
|
||||
|
||||
|
||||
void Route::setAge(std::time_t created)
|
||||
{
|
||||
std::time_t now;
|
||||
time(&now);
|
||||
if (_created > now)
|
||||
throw std::invalid_argument("Creation time can't be in future");
|
||||
_created = Timestamp::fromEpochTime(created);
|
||||
}
|
||||
|
||||
|
||||
void Route::setProto(RouteProto proto)
|
||||
{
|
||||
#if defined(_WIN32)
|
||||
if (proto > ROUTE_PROTO_BGP) proto = ROUTE_PROTO_OTHER;
|
||||
#endif
|
||||
_proto = proto;
|
||||
}
|
||||
|
||||
|
||||
Route::RouteList Route::defaults(IPAddress::Family family)
|
||||
{
|
||||
Route::RouteList defaults, routes = Route::list(family);
|
||||
|
||||
for (Route::RouteList::const_iterator it = routes.begin();
|
||||
it != routes.end(); it++) {
|
||||
if (it->getPrefix() != 0) continue;
|
||||
|
||||
// look for insertion point
|
||||
Route::RouteList::iterator it2 = defaults.begin();
|
||||
Route::RouteList::const_iterator end = defaults.end();
|
||||
while (it2 != end && it2->getMetric() <= it->getMetric())
|
||||
it2++;
|
||||
defaults.insert(it2, *it);
|
||||
}
|
||||
|
||||
return defaults;
|
||||
}
|
||||
|
||||
|
||||
Route::RouteList Route::match(IPAddress target)
|
||||
{
|
||||
Route::RouteList targets, routes = Route::list(target.family());
|
||||
|
||||
for (Route::RouteList::const_iterator it = routes.begin();
|
||||
it != routes.end(); it++) {
|
||||
if ((target & it->getNetmask()) != it->getDest()) continue;
|
||||
|
||||
// look for insertion point
|
||||
Route::RouteList::iterator it2 = targets.begin();
|
||||
while (it2 != targets.end()
|
||||
&& (it2->getPrefix() > it->getPrefix()
|
||||
|| (it2->getPrefix() == it->getPrefix() && it2->getMetric() <= it->getMetric())))
|
||||
it2++;
|
||||
targets.insert(it2, *it);
|
||||
}
|
||||
|
||||
return targets;
|
||||
}
|
||||
|
||||
|
||||
const IPAddress Route::getDefaultAddress(IPAddress::Family family)
|
||||
{
|
||||
Route::RouteList routes = Route::defaults(family);
|
||||
|
||||
if (! routes.empty()) {
|
||||
Route::RouteList::const_iterator it = routes.begin();
|
||||
|
||||
IPAddress addr = it->getNetworkInterface().firstAddress(family);
|
||||
return addr;
|
||||
}
|
||||
|
||||
return IPAddress::wildcard(family);
|
||||
}
|
||||
|
||||
|
||||
std::string Route::protocolName(Route::RouteProto proto)
|
||||
{
|
||||
switch (proto) {
|
||||
default:
|
||||
return "unknown";
|
||||
case ROUTE_PROTO_OTHER:
|
||||
return "other";
|
||||
case ROUTE_PROTO_LOCAL:
|
||||
return "local";
|
||||
case ROUTE_PROTO_NET_MGMT:
|
||||
return "netmgmt";
|
||||
case ROUTE_PROTO_ICMP:
|
||||
return "icmp";
|
||||
case ROUTE_PROTO_EGP:
|
||||
return "egp";
|
||||
case ROUTE_PROTO_GGP:
|
||||
return "ggp";
|
||||
case ROUTE_PROTO_HELLO:
|
||||
return "hello";
|
||||
case ROUTE_PROTO_RIP:
|
||||
return "rip";
|
||||
case ROUTE_PROTO_ISIS:
|
||||
return "isis";
|
||||
case ROUTE_PROTO_ESIS:
|
||||
return "esis";
|
||||
case ROUTE_PROTO_CISCO:
|
||||
return "cisco";
|
||||
case ROUTE_PROTO_BBN:
|
||||
return "bbn";
|
||||
case ROUTE_PROTO_OSPF:
|
||||
return "ospf";
|
||||
case ROUTE_PROTO_BGP:
|
||||
return "bgp";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}} // namespace Poco::Net
|
||||
|
||||
|
||||
#endif // POCO_NET_HAS_ROUTE
|
237
Net/src/Route_BSD.cpp
Normal file
237
Net/src/Route_BSD.cpp
Normal file
@ -0,0 +1,237 @@
|
||||
//
|
||||
// Route_BSD.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Foundation/src/Route_BSD.cpp#2 $
|
||||
//
|
||||
// Library: Net
|
||||
// Package: NetCore
|
||||
// Module: Route
|
||||
//
|
||||
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include <net/if.h>
|
||||
#include <net/if_dl.h>
|
||||
#include <net/route.h>
|
||||
#include <sys/sysctl.h>
|
||||
#include <netinet/in.h>
|
||||
|
||||
#include <string>
|
||||
|
||||
|
||||
#define RTMSG_LEN (sizeof(struct rt_msghdr) + 512)
|
||||
#define ROUNDUP(a) ((a) > 0 ? (((a) + sizeof(uint32_t) - 1) & ~(sizeof(uint32_t) - 1)) : sizeof(long))
|
||||
#define NEXTADDR(w, u) \
|
||||
if (rtm_addrs & (w)) {\
|
||||
int l = ROUNDUP(u.sin_len); memmove(cp, &(u), l); cp += l;\
|
||||
}
|
||||
#define ADVANCE(x, n) (x += ROUNDUP((n)->sa_len))
|
||||
|
||||
#define SIN_OFFSET (offsetof(sockaddr_in,sin_addr))
|
||||
#define SIN_LENGTH (sizeof(struct in_addr))
|
||||
#define SIN6_OFFSET (offsetof(sockaddr_in6,sin6_addr))
|
||||
#define SIN6_LENGTH (sizeof(struct in6_addr))
|
||||
|
||||
|
||||
static int seq = rand();
|
||||
|
||||
static void get_rtaddrs(unsigned addrs, struct sockaddr *sa, struct sockaddr **rti_info)
|
||||
{
|
||||
for (unsigned i = 0; i < RTAX_MAX; i++) {
|
||||
if (addrs & (1 << i)) {
|
||||
rti_info[i] = sa;
|
||||
sa = (struct sockaddr *)((char *)sa + ROUNDUP(sa->sa_len));
|
||||
} else {
|
||||
rti_info[i] = NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static IPAddress unpack_sockaddr_inX(struct sockaddr *sa, bool ipv4)
|
||||
{
|
||||
const unsigned offset = (ipv4 ? SIN_OFFSET : SIN6_OFFSET);
|
||||
unsigned char *addr = (unsigned char*)sa + offset;
|
||||
|
||||
// return wildcard
|
||||
if (sa->sa_len == 0)
|
||||
return IPAddress(ipv4 ? IPAddress::IPv4 : IPAddress::IPv6);
|
||||
|
||||
struct in6_addr buf;
|
||||
memset(&buf, 0, sizeof(buf));
|
||||
memcpy(&buf, addr, sa->sa_len - offset);
|
||||
|
||||
IPAddress ip(&buf, (ipv4 ? SIN_LENGTH : SIN6_LENGTH));
|
||||
|
||||
return ip;
|
||||
}
|
||||
|
||||
class RouteHelper {
|
||||
public:
|
||||
static Route* createRoute(struct rt_msghdr2 *rtm, struct sockaddr **rti_info);
|
||||
|
||||
private:
|
||||
RouteHelper();
|
||||
~RouteHelper();
|
||||
};
|
||||
|
||||
Route* RouteHelper::createRoute(struct rt_msghdr2 *rtm, struct sockaddr **rti_info)
|
||||
{
|
||||
IPAddress dest, netmask, nexthop;
|
||||
int ifIndex = rtm->rtm_index;
|
||||
bool adjacent = false;
|
||||
sa_family_t family = AF_MAX;
|
||||
char macaddr[16]; // should be plenty, right?
|
||||
|
||||
for (unsigned i = 0; i < RTAX_MAX; i++) {
|
||||
sockaddr* sa = (struct sockaddr*)rti_info[i];
|
||||
|
||||
if (sa == NULL) continue;
|
||||
|
||||
switch (i) {
|
||||
case RTAX_DST:
|
||||
poco_assert(sa->sa_family == AF_INET || sa->sa_family == AF_INET6);
|
||||
family = sa->sa_family;
|
||||
if (family == AF_INET) {
|
||||
struct sockaddr_in *sin = (struct sockaddr_in *)sa;
|
||||
dest = IPAddress(&sin->sin_addr, SIN_LENGTH);
|
||||
} else {
|
||||
struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)sa;
|
||||
dest = IPAddress(&sin6->sin6_addr, SIN6_LENGTH, rtm->rtm_index);
|
||||
}
|
||||
break;
|
||||
|
||||
case RTAX_GATEWAY:
|
||||
poco_assert((sa->sa_family == family || sa->sa_family == AF_LINK));
|
||||
switch (sa->sa_family) {
|
||||
case AF_INET:
|
||||
{
|
||||
struct sockaddr_in *sin = (struct sockaddr_in *)sa;
|
||||
nexthop = IPAddress(&sin->sin_addr, SIN_LENGTH);
|
||||
break;
|
||||
}
|
||||
case AF_INET6:
|
||||
{
|
||||
struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)sa;
|
||||
nexthop = IPAddress(&sin6->sin6_addr, SIN6_LENGTH, rtm->rtm_index);
|
||||
break;
|
||||
}
|
||||
case AF_LINK:
|
||||
{
|
||||
struct sockaddr_dl *sdl = (struct sockaddr_dl *)sa;
|
||||
adjacent = true;
|
||||
ifIndex = sdl->sdl_index;
|
||||
memcpy(macaddr, sdl->sdl_data, sdl->sdl_alen);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case RTAX_NETMASK:
|
||||
netmask = unpack_sockaddr_inX(sa, (family == AF_INET));
|
||||
break;
|
||||
|
||||
case RTAX_GENMASK:
|
||||
// IPAddress genmask = unpack_sockaddr_inX(sa, (family == AF_INET));
|
||||
break;
|
||||
|
||||
default:
|
||||
// do something?
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (rtm->rtm_flags & RTF_HOST) {
|
||||
poco_assert(! (rtm->rtm_addrs & RTA_NETMASK));
|
||||
if (family == AF_INET)
|
||||
netmask = IPAddress(32, IPAddress::IPv4);
|
||||
else
|
||||
netmask = IPAddress(128, IPAddress::IPv6);
|
||||
}
|
||||
|
||||
Route *route;
|
||||
|
||||
if (adjacent)
|
||||
route = new Route(dest, netmask, ifIndex, Route::ROUTE_DIRECT);
|
||||
else
|
||||
route = new Route(dest, netmask, nexthop, ifIndex, Route::ROUTE_INDIRECT);
|
||||
|
||||
route->setMTU(rtm->rtm_rmx.rmx_mtu);
|
||||
route->setHops(rtm->rtm_rmx.rmx_hopcount);
|
||||
route->setUsage(rtm->rtm_use);
|
||||
|
||||
return route;
|
||||
}
|
||||
|
||||
Route::RouteList Route::list(IPAddress::Family family)
|
||||
{
|
||||
Route::RouteList routes;
|
||||
int mib[6];
|
||||
|
||||
mib[0] = CTL_NET;
|
||||
mib[1] = PF_ROUTE;
|
||||
mib[2] = mib[3] = 0;
|
||||
mib[4] = NET_RT_DUMP2;
|
||||
mib[5] = 0;
|
||||
|
||||
size_t needed = 0;
|
||||
if (sysctl(mib, 6, NULL, &needed, NULL, 0) < 0)
|
||||
throw std::runtime_error("sysctl failed to return routing table size");;
|
||||
|
||||
char *buf = new char[needed];
|
||||
|
||||
if (sysctl(mib, 6, buf, &needed, NULL, 0) < 0)
|
||||
throw std::runtime_error("sysctl faield to populate routing table");
|
||||
|
||||
struct rt_msghdr2 *rtm = NULL;
|
||||
for (char *next = buf, *lim = &buf[needed]; next < lim; next += rtm->rtm_msglen) {
|
||||
rtm = (struct rt_msghdr2 *)next;
|
||||
|
||||
struct sockaddr_in *sin = (struct sockaddr_in*)(rtm + 1);
|
||||
|
||||
if (sin->sin_family != ((family == IPAddress::IPv4) ? AF_INET : AF_INET6)) continue;
|
||||
|
||||
// skip cloned routes
|
||||
if (rtm->rtm_parentflags & RTF_PRCLONING) continue;
|
||||
|
||||
struct sockaddr* rti_info[RTAX_MAX];
|
||||
get_rtaddrs(rtm->rtm_addrs, (struct sockaddr *)sin, rti_info);
|
||||
|
||||
Route *route = RouteHelper::createRoute(rtm, rti_info);
|
||||
|
||||
// RTF_IFSCOPE?
|
||||
|
||||
routes.push_back(route);
|
||||
}
|
||||
|
||||
delete[] buf;
|
||||
|
||||
return routes;
|
||||
}
|
332
Net/src/Route_Linux.cpp
Normal file
332
Net/src/Route_Linux.cpp
Normal file
@ -0,0 +1,332 @@
|
||||
//
|
||||
// Route_Linux.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Foundation/src/Route_Linux.cpp#2 $
|
||||
//
|
||||
// Library: Net
|
||||
// Package: NetCore
|
||||
// Module: Route
|
||||
//
|
||||
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
#include <time.h>
|
||||
#include <string.h>
|
||||
#include <arpa/inet.h>
|
||||
|
||||
#include <net/route.h>
|
||||
#include <linux/if.h>
|
||||
#include <libmnl/libmnl.h>
|
||||
#include <linux/rtnetlink.h>
|
||||
|
||||
class RouteHelper
|
||||
{
|
||||
public:
|
||||
static void createRouteIPv4(Route::RouteList *routes, struct rt_container *rt_stuff);
|
||||
static void createRouteIPv6(Route::RouteList *routes, struct rt_container *rt_stuff);
|
||||
|
||||
private:
|
||||
RouteHelper();
|
||||
~RouteHelper();
|
||||
};
|
||||
|
||||
typedef union
|
||||
{
|
||||
struct in_addr u_in;
|
||||
struct in6_addr u_in6;
|
||||
} in_addrX;
|
||||
|
||||
#define in4 u_in
|
||||
#define in6 u_in6
|
||||
|
||||
struct rt_container
|
||||
{
|
||||
const struct nlattr *tb[RTA_MAX+1];
|
||||
in_addrX gw;
|
||||
in_addrX dest;
|
||||
in_addrX src;
|
||||
in_addrX prefsrc;
|
||||
uint32_t oif, flow, priority;
|
||||
unsigned char family;
|
||||
unsigned char prefix;
|
||||
unsigned char table;
|
||||
unsigned char protocol;
|
||||
unsigned char scope;
|
||||
unsigned char type;
|
||||
uint32_t metrics[RTA_MAX+1];
|
||||
};
|
||||
|
||||
static inline bool in6zero(struct in6_addr in6)
|
||||
{
|
||||
return ((in6.s6_addr32[0] | in6.s6_addr32[1] | in6.s6_addr32[2] | in6.s6_addr32[3]) == 0);
|
||||
}
|
||||
|
||||
static Route::RouteProto xlateProto(unsigned prot)
|
||||
{
|
||||
switch (prot) {
|
||||
default:
|
||||
// fallthru
|
||||
case RTPROT_UNSPEC:
|
||||
return Route::ROUTE_PROTO_OTHER;
|
||||
case RTPROT_REDIRECT:
|
||||
return Route::ROUTE_PROTO_ICMP;
|
||||
case RTPROT_KERNEL:
|
||||
case RTPROT_BOOT:
|
||||
case RTPROT_STATIC:
|
||||
return Route::ROUTE_PROTO_LOCAL;
|
||||
|
||||
// others?
|
||||
}
|
||||
}
|
||||
|
||||
void RouteHelper::createRouteIPv4(Route::RouteList *routes, struct rt_container *rt_stuff)
|
||||
{
|
||||
if (rt_stuff->table == RT_TABLE_MAIN && rt_stuff->type <= RTN_MULTICAST) {
|
||||
Route *route;
|
||||
|
||||
if (rt_stuff->gw.in4.s_addr != 0)
|
||||
route = new Route(IPAddress(&rt_stuff->dest.in4, sizeof(rt_stuff->dest.in4)), IPAddress(rt_stuff->prefix, IPAddress::IPv4), IPAddress(&rt_stuff->gw.in4, sizeof(rt_stuff->gw.in4)), rt_stuff->oif, Route::ROUTE_INDIRECT);
|
||||
else
|
||||
route = new Route(IPAddress(&rt_stuff->dest.in4, sizeof(rt_stuff->dest.in4)), IPAddress(rt_stuff->prefix, IPAddress::IPv4), rt_stuff->oif, Route::ROUTE_DIRECT);
|
||||
|
||||
route->setProto(xlateProto(rt_stuff->protocol));
|
||||
route->setMetric(rt_stuff->metrics[0]);
|
||||
// route->setPriority(rt_stuff->priority);
|
||||
|
||||
// no hops, usage, mtu, or age...
|
||||
routes->push_back(route);
|
||||
}
|
||||
}
|
||||
|
||||
void RouteHelper::createRouteIPv6(Route::RouteList *routes, struct rt_container *rt_stuff)
|
||||
{
|
||||
if (rt_stuff->table == RT_TABLE_MAIN && rt_stuff->type <= RTN_MULTICAST) {
|
||||
Route *route;
|
||||
|
||||
if (!in6zero(rt_stuff->gw.in6))
|
||||
route = new Route(IPAddress(&rt_stuff->dest.in6, sizeof(rt_stuff->dest.in6)), IPAddress(rt_stuff->prefix, IPAddress::IPv6), IPAddress(&rt_stuff->gw.in6, sizeof(rt_stuff->gw.in6), rt_stuff->oif), rt_stuff->oif, Route::ROUTE_INDIRECT);
|
||||
else
|
||||
route = new Route(IPAddress(&rt_stuff->dest.in6, sizeof(rt_stuff->dest.in6)), IPAddress(rt_stuff->prefix, IPAddress::IPv6), rt_stuff->oif, Route::ROUTE_DIRECT);
|
||||
|
||||
route->setProto(xlateProto(rt_stuff->protocol));
|
||||
route->setMetric(rt_stuff->metrics[0]);
|
||||
// route->setPriority(rt_stuff->priority);
|
||||
|
||||
// no hops, usage, mtu, or age...
|
||||
routes->push_back(route);
|
||||
}
|
||||
}
|
||||
|
||||
static int data_attr_cb2(const struct nlattr *attr, void *)
|
||||
{
|
||||
// skip unsupported attribute in user-space
|
||||
if (mnl_attr_type_valid(attr, RTAX_MAX) < 0)
|
||||
return MNL_CB_OK;
|
||||
|
||||
if (mnl_attr_validate(attr, MNL_TYPE_U32) < 0)
|
||||
return MNL_CB_ERROR;
|
||||
return MNL_CB_OK;
|
||||
}
|
||||
|
||||
static void parse_attrs_ipv4(struct rt_container *rt_stuff)
|
||||
{
|
||||
if (rt_stuff->tb[RTA_TABLE])
|
||||
rt_stuff->table = mnl_attr_get_u32(rt_stuff->tb[RTA_TABLE]);
|
||||
if (rt_stuff->tb[RTA_DST])
|
||||
rt_stuff->dest.in4 = *(struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_DST]);
|
||||
if (rt_stuff->tb[RTA_SRC])
|
||||
rt_stuff->src.in4 = *(struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_SRC]);
|
||||
if (rt_stuff->tb[RTA_OIF])
|
||||
rt_stuff->oif = mnl_attr_get_u32(rt_stuff->tb[RTA_OIF]);
|
||||
if (rt_stuff->tb[RTA_FLOW])
|
||||
rt_stuff->flow = mnl_attr_get_u32(rt_stuff->tb[RTA_FLOW]);
|
||||
if (rt_stuff->tb[RTA_PRIORITY])
|
||||
rt_stuff->priority = mnl_attr_get_u32(rt_stuff->tb[RTA_PRIORITY]);
|
||||
if (rt_stuff->tb[RTA_PREFSRC])
|
||||
rt_stuff->prefsrc.in4 = *(struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_PREFSRC]);
|
||||
if (rt_stuff->tb[RTA_GATEWAY])
|
||||
rt_stuff->gw.in4 = *(struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_GATEWAY]);
|
||||
if (rt_stuff->tb[RTA_METRICS]) {
|
||||
struct nlattr *tbx[RTAX_MAX+1] = {};
|
||||
mnl_attr_parse_nested(rt_stuff->tb[RTA_METRICS], data_attr_cb2, tbx);
|
||||
|
||||
for (unsigned i = 0; i < RTAX_MAX; ++i)
|
||||
if (tbx[i])
|
||||
rt_stuff->metrics[i] = mnl_attr_get_u32(tbx[i]);
|
||||
}
|
||||
}
|
||||
|
||||
static void parse_attrs_ipv6(struct rt_container *rt_stuff)
|
||||
{
|
||||
if (rt_stuff->tb[RTA_TABLE])
|
||||
rt_stuff->table = mnl_attr_get_u32(rt_stuff->tb[RTA_TABLE]);
|
||||
if (rt_stuff->tb[RTA_DST])
|
||||
memcpy(&rt_stuff->dest.in6, (struct in6_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_DST]), sizeof(struct in6_addr));
|
||||
if (rt_stuff->tb[RTA_SRC])
|
||||
memcpy(&rt_stuff->src.in6, (struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_SRC]), sizeof(struct in6_addr));
|
||||
if (rt_stuff->tb[RTA_OIF])
|
||||
rt_stuff->oif = mnl_attr_get_u32(rt_stuff->tb[RTA_OIF]);
|
||||
if (rt_stuff->tb[RTA_FLOW])
|
||||
rt_stuff->flow = mnl_attr_get_u32(rt_stuff->tb[RTA_FLOW]);
|
||||
if (rt_stuff->tb[RTA_PRIORITY])
|
||||
rt_stuff->priority = mnl_attr_get_u32(rt_stuff->tb[RTA_PRIORITY]);
|
||||
if (rt_stuff->tb[RTA_PREFSRC])
|
||||
memcpy(&rt_stuff->prefsrc.in6, (struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_PREFSRC]), sizeof(struct in6_addr));
|
||||
if (rt_stuff->tb[RTA_GATEWAY])
|
||||
memcpy(&rt_stuff->gw.in6, (struct in_addr *)mnl_attr_get_payload(rt_stuff->tb[RTA_GATEWAY]), sizeof(struct in6_addr));
|
||||
if (rt_stuff->tb[RTA_METRICS]) {
|
||||
struct nlattr *tbx[RTAX_MAX+1] = {};
|
||||
mnl_attr_parse_nested(rt_stuff->tb[RTA_METRICS], data_attr_cb2, tbx);
|
||||
|
||||
for (unsigned i = 0; i < RTAX_MAX; ++i)
|
||||
if (tbx[i])
|
||||
rt_stuff->metrics[i] = mnl_attr_get_u32(tbx[i]);
|
||||
}
|
||||
}
|
||||
|
||||
static int data_attr_cb(const struct nlattr *attr, void *data)
|
||||
{
|
||||
struct rt_container *rt_stuff = (struct rt_container*)data;
|
||||
int type = mnl_attr_get_type(attr);
|
||||
|
||||
if (mnl_attr_type_valid(attr, RTA_MAX) < 0)
|
||||
return MNL_CB_OK;
|
||||
|
||||
switch (type) {
|
||||
case RTA_DST:
|
||||
case RTA_SRC:
|
||||
case RTA_PREFSRC:
|
||||
case RTA_GATEWAY:
|
||||
if (rt_stuff->family == AF_INET) {
|
||||
if (mnl_attr_validate(attr, MNL_TYPE_U32) < 0)
|
||||
return MNL_CB_ERROR;
|
||||
} else {
|
||||
if (mnl_attr_validate2(attr, MNL_TYPE_BINARY, sizeof(struct in6_addr)) < 0)
|
||||
return MNL_CB_ERROR;
|
||||
}
|
||||
break;
|
||||
case RTA_TABLE:
|
||||
case RTA_OIF:
|
||||
case RTA_FLOW:
|
||||
case RTA_PRIORITY:
|
||||
if (mnl_attr_validate(attr, MNL_TYPE_U32) < 0)
|
||||
return MNL_CB_ERROR;
|
||||
break;
|
||||
case RTA_METRICS:
|
||||
if (mnl_attr_validate(attr, MNL_TYPE_NESTED) < 0)
|
||||
return MNL_CB_ERROR;
|
||||
break;
|
||||
}
|
||||
rt_stuff->tb[type] = attr;
|
||||
return MNL_CB_OK;
|
||||
}
|
||||
|
||||
static int data_cb(const struct nlmsghdr *nlh, void *data)
|
||||
{
|
||||
const struct rtmsg *rm = (const struct rtmsg *)mnl_nlmsg_get_payload(nlh);
|
||||
Route::RouteList *routes = (Route::RouteList *)data;
|
||||
struct rt_container rt_stuff;
|
||||
|
||||
memset(&rt_stuff, 0, sizeof(rt_stuff));
|
||||
|
||||
rt_stuff.family = rm->rtm_family;
|
||||
rt_stuff.prefix = rm->rtm_dst_len;
|
||||
rt_stuff.protocol = rm->rtm_protocol;
|
||||
rt_stuff.scope = rm->rtm_scope;
|
||||
rt_stuff.type = rm->rtm_type;
|
||||
|
||||
mnl_attr_parse(nlh, sizeof(*rm), data_attr_cb, &rt_stuff);
|
||||
|
||||
switch (rm->rtm_family) {
|
||||
case AF_INET:
|
||||
parse_attrs_ipv4(&rt_stuff);
|
||||
|
||||
RouteHelper::createRouteIPv4(routes, &rt_stuff);
|
||||
break;
|
||||
|
||||
case AF_INET6:
|
||||
parse_attrs_ipv6(&rt_stuff);
|
||||
|
||||
RouteHelper::createRouteIPv6(routes, &rt_stuff);
|
||||
break;
|
||||
}
|
||||
|
||||
return MNL_CB_OK;
|
||||
}
|
||||
|
||||
Route::RouteList Route::list(IPAddress::Family family)
|
||||
{
|
||||
struct mnl_socket *nl;
|
||||
char buf[MNL_SOCKET_BUFFER_SIZE];
|
||||
struct nlmsghdr *nlh;
|
||||
struct rtmsg *rtm;
|
||||
int ret;
|
||||
unsigned seq, portid;
|
||||
|
||||
nlh = mnl_nlmsg_put_header(buf);
|
||||
nlh->nlmsg_type = RTM_GETROUTE;
|
||||
nlh->nlmsg_flags = NLM_F_REQUEST | NLM_F_DUMP;
|
||||
nlh->nlmsg_seq = seq = time(NULL);
|
||||
|
||||
rtm = (struct rtmsg *)mnl_nlmsg_put_extra_header(nlh, sizeof(struct rtmsg));
|
||||
rtm->rtm_family = ((family == IPAddress::IPv4) ? AF_INET : AF_INET6);
|
||||
|
||||
Route::RouteList routes;
|
||||
|
||||
do {
|
||||
|
||||
nl = mnl_socket_open(NETLINK_ROUTE);
|
||||
if (nl == NULL)
|
||||
break;
|
||||
|
||||
if (mnl_socket_bind(nl, 0, MNL_SOCKET_AUTOPID) < 0)
|
||||
break;
|
||||
|
||||
portid = mnl_socket_get_portid(nl);
|
||||
|
||||
if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0)
|
||||
break;
|
||||
|
||||
while (1) {
|
||||
ret = mnl_socket_recvfrom(nl, buf, sizeof(buf));
|
||||
if (ret <= 0)
|
||||
break;
|
||||
ret = mnl_cb_run(buf, ret, seq, portid, data_cb, &routes);
|
||||
if (ret == MNL_CB_ERROR)
|
||||
throw std::runtime_error("Couldn't parse routing table");
|
||||
else if (ret == MNL_CB_STOP)
|
||||
break;
|
||||
}
|
||||
if (ret == -1)
|
||||
throw std::runtime_error("Couldn't talk to kernel");
|
||||
|
||||
} while (false);
|
||||
|
||||
if (nl)
|
||||
mnl_socket_close(nl);
|
||||
|
||||
return routes;
|
||||
}
|
76
Net/src/Route_WIN32.cpp
Normal file
76
Net/src/Route_WIN32.cpp
Normal file
@ -0,0 +1,76 @@
|
||||
//
|
||||
// Route_WIN32.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Foundation/src/Route_WIN32.cpp#2 $
|
||||
//
|
||||
// Library: Net
|
||||
// Package: NetCore
|
||||
// Module: Route
|
||||
//
|
||||
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
namespace Poco {
|
||||
namespace Net {
|
||||
|
||||
|
||||
Route::RouteList Route::list(IPAddress::Family family)
|
||||
{
|
||||
std::time_t now;
|
||||
PMIB_IPFORWARD_TABLE2 pIpForwardTable2 = NULL;
|
||||
|
||||
if (GetIpForwardTable2(((family == IPAddress::IPv4) ? AF_INET : AF_INET6), &pIpForwardTable2) != NO_ERROR)
|
||||
throw std::runtime_error("Couldn't fetch routing table");
|
||||
|
||||
::time(&now);
|
||||
|
||||
RouteList list;
|
||||
|
||||
for (unsigned i = 0; i < pIpForwardTable2->NumEntries; ++i)
|
||||
{
|
||||
PMIB_IPFORWARD_ROW2 pIp2 = &pIpForwardTable2->Table[i];
|
||||
IPAddress::Family family2 = (pIp2->DestinationPrefix.Prefix.si_family == AF_INET ? IPAddress::IPv4 : IPAddress::IPv6);
|
||||
|
||||
IPAddress dest(*(struct sockaddr *)&pIp2->DestinationPrefix.Prefix);
|
||||
IPAddress netmask(pIp2->DestinationPrefix.PrefixLength, family2);
|
||||
IPAddress nexthop(*(struct sockaddr *)&pIp2->NextHop);
|
||||
|
||||
Route route(dest, netmask, nexthop, pIp2->InterfaceIndex, nexthop.isWildcard() ? ROUTE_INDIRECT : ROUTE_INDIRECT);
|
||||
route.setMetric(pIp2->Metric);
|
||||
route.setAge(now - pIp2->Age);
|
||||
route.setProto((RouteProto) pIp2->Protocol);
|
||||
|
||||
list.push_back(route);
|
||||
}
|
||||
|
||||
FreeMibTable(pIpForwardTable2);
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
}} // namespace Poco::Net
|
@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="debug_shared|Win32">
|
||||
@ -32,86 +32,86 @@
|
||||
<RootNamespace>TestSuite</RootNamespace>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props"/>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Static</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Static</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="Configuration">
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>Dynamic</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props"/>
|
||||
<ImportGroup Label="ExtensionSettings"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros"/>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">bin\static_mt\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">bin\static_mt\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">bin\static_md\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">bin\static_md\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">false</LinkIncremental>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">TestSuite</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">TestSuite</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">TestSuite</TargetName>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">bin\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">bin\static_mt\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">bin\static_mt\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">false</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">bin\static_md\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">bin\static_md\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">obj\$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">false</LinkIncremental>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">TestSuited</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">TestSuite</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">TestSuite</TargetName>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">TestSuite</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -124,7 +124,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
<CompileAs>Default</CompileAs>
|
||||
@ -141,7 +141,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -156,9 +156,9 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -173,7 +173,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -186,7 +186,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
<CompileAs>Default</CompileAs>
|
||||
@ -204,7 +204,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -219,9 +219,9 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -237,7 +237,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\include;..\..\CppUnit\include;..\..\CppUnit\WinTestRunner\include;..\..\Foundation\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@ -250,7 +250,7 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
<CompileAs>Default</CompileAs>
|
||||
@ -267,7 +267,7 @@
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
@ -282,9 +282,9 @@
|
||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader/>
|
||||
<PrecompiledHeader />
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat/>
|
||||
<DebugInformationFormat />
|
||||
<CompileAs>Default</CompileAs>
|
||||
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
|
||||
</ClCompile>
|
||||
@ -300,120 +300,122 @@
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="src\DNSTest.h"/>
|
||||
<ClInclude Include="src\IPAddressTest.h"/>
|
||||
<ClInclude Include="src\NetCoreTestSuite.h"/>
|
||||
<ClInclude Include="src\NetworkInterfaceTest.h"/>
|
||||
<ClInclude Include="src\SocketAddressTest.h"/>
|
||||
<ClInclude Include="src\NetTestSuite.h"/>
|
||||
<ClInclude Include="src\DatagramSocketTest.h"/>
|
||||
<ClInclude Include="src\DialogServer.h"/>
|
||||
<ClInclude Include="src\DialogSocketTest.h"/>
|
||||
<ClInclude Include="src\EchoServer.h"/>
|
||||
<ClInclude Include="src\MulticastEchoServer.h"/>
|
||||
<ClInclude Include="src\MulticastSocketTest.h"/>
|
||||
<ClInclude Include="src\RawSocketTest.h"/>
|
||||
<ClInclude Include="src\SocketsTestSuite.h"/>
|
||||
<ClInclude Include="src\SocketStreamTest.h"/>
|
||||
<ClInclude Include="src\SocketTest.h"/>
|
||||
<ClInclude Include="src\UDPEchoServer.h"/>
|
||||
<ClInclude Include="src\MediaTypeTest.h"/>
|
||||
<ClInclude Include="src\MessageHeaderTest.h"/>
|
||||
<ClInclude Include="src\MessagesTestSuite.h"/>
|
||||
<ClInclude Include="src\MultipartReaderTest.h"/>
|
||||
<ClInclude Include="src\MultipartWriterTest.h"/>
|
||||
<ClInclude Include="src\NameValueCollectionTest.h"/>
|
||||
<ClInclude Include="src\QuotedPrintableTest.h"/>
|
||||
<ClInclude Include="src\HTTPCookieTest.h"/>
|
||||
<ClInclude Include="src\HTTPCredentialsTest.h"/>
|
||||
<ClInclude Include="src\HTTPRequestTest.h"/>
|
||||
<ClInclude Include="src\HTTPResponseTest.h"/>
|
||||
<ClInclude Include="src\HTTPTestServer.h"/>
|
||||
<ClInclude Include="src\HTTPTestSuite.h"/>
|
||||
<ClInclude Include="src\TCPServerTest.h"/>
|
||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
||||
<ClInclude Include="src\HTTPServerTest.h"/>
|
||||
<ClInclude Include="src\HTTPServerTestSuite.h"/>
|
||||
<ClInclude Include="src\HTMLFormTest.h"/>
|
||||
<ClInclude Include="src\HTMLTestSuite.h"/>
|
||||
<ClInclude Include="src\HTTPClientSessionTest.h"/>
|
||||
<ClInclude Include="src\HTTPClientTestSuite.h"/>
|
||||
<ClInclude Include="src\HTTPStreamFactoryTest.h"/>
|
||||
<ClInclude Include="src\FTPClientSessionTest.h"/>
|
||||
<ClInclude Include="src\FTPClientTestSuite.h"/>
|
||||
<ClInclude Include="src\FTPStreamFactoryTest.h"/>
|
||||
<ClInclude Include="src\ReactorTestSuite.h"/>
|
||||
<ClInclude Include="src\SocketReactorTest.h"/>
|
||||
<ClInclude Include="src\MailMessageTest.h"/>
|
||||
<ClInclude Include="src\MailStreamTest.h"/>
|
||||
<ClInclude Include="src\MailTestSuite.h"/>
|
||||
<ClInclude Include="src\POP3ClientSessionTest.h"/>
|
||||
<ClInclude Include="src\SMTPClientSessionTest.h"/>
|
||||
<ClInclude Include="src\ICMPClientTest.h"/>
|
||||
<ClInclude Include="src\ICMPClientTestSuite.h"/>
|
||||
<ClInclude Include="src\ICMPSocketTest.h"/>
|
||||
<ClInclude Include="src\SyslogTest.h"/>
|
||||
<ClInclude Include="src\WebSocketTest.h"/>
|
||||
<ClInclude Include="src\WebSocketTestSuite.h"/>
|
||||
<ClInclude Include="src\DNSTest.h" />
|
||||
<ClInclude Include="src\IPAddressTest.h" />
|
||||
<ClInclude Include="src\NetCoreTestSuite.h" />
|
||||
<ClInclude Include="src\NetworkInterfaceTest.h" />
|
||||
<ClInclude Include="src\RouteTest.h" />
|
||||
<ClInclude Include="src\SocketAddressTest.h" />
|
||||
<ClInclude Include="src\NetTestSuite.h" />
|
||||
<ClInclude Include="src\DatagramSocketTest.h" />
|
||||
<ClInclude Include="src\DialogServer.h" />
|
||||
<ClInclude Include="src\DialogSocketTest.h" />
|
||||
<ClInclude Include="src\EchoServer.h" />
|
||||
<ClInclude Include="src\MulticastEchoServer.h" />
|
||||
<ClInclude Include="src\MulticastSocketTest.h" />
|
||||
<ClInclude Include="src\RawSocketTest.h" />
|
||||
<ClInclude Include="src\SocketsTestSuite.h" />
|
||||
<ClInclude Include="src\SocketStreamTest.h" />
|
||||
<ClInclude Include="src\SocketTest.h" />
|
||||
<ClInclude Include="src\UDPEchoServer.h" />
|
||||
<ClInclude Include="src\MediaTypeTest.h" />
|
||||
<ClInclude Include="src\MessageHeaderTest.h" />
|
||||
<ClInclude Include="src\MessagesTestSuite.h" />
|
||||
<ClInclude Include="src\MultipartReaderTest.h" />
|
||||
<ClInclude Include="src\MultipartWriterTest.h" />
|
||||
<ClInclude Include="src\NameValueCollectionTest.h" />
|
||||
<ClInclude Include="src\QuotedPrintableTest.h" />
|
||||
<ClInclude Include="src\HTTPCookieTest.h" />
|
||||
<ClInclude Include="src\HTTPCredentialsTest.h" />
|
||||
<ClInclude Include="src\HTTPRequestTest.h" />
|
||||
<ClInclude Include="src\HTTPResponseTest.h" />
|
||||
<ClInclude Include="src\HTTPTestServer.h" />
|
||||
<ClInclude Include="src\HTTPTestSuite.h" />
|
||||
<ClInclude Include="src\TCPServerTest.h" />
|
||||
<ClInclude Include="src\TCPServerTestSuite.h" />
|
||||
<ClInclude Include="src\HTTPServerTest.h" />
|
||||
<ClInclude Include="src\HTTPServerTestSuite.h" />
|
||||
<ClInclude Include="src\HTMLFormTest.h" />
|
||||
<ClInclude Include="src\HTMLTestSuite.h" />
|
||||
<ClInclude Include="src\HTTPClientSessionTest.h" />
|
||||
<ClInclude Include="src\HTTPClientTestSuite.h" />
|
||||
<ClInclude Include="src\HTTPStreamFactoryTest.h" />
|
||||
<ClInclude Include="src\FTPClientSessionTest.h" />
|
||||
<ClInclude Include="src\FTPClientTestSuite.h" />
|
||||
<ClInclude Include="src\FTPStreamFactoryTest.h" />
|
||||
<ClInclude Include="src\ReactorTestSuite.h" />
|
||||
<ClInclude Include="src\SocketReactorTest.h" />
|
||||
<ClInclude Include="src\MailMessageTest.h" />
|
||||
<ClInclude Include="src\MailStreamTest.h" />
|
||||
<ClInclude Include="src\MailTestSuite.h" />
|
||||
<ClInclude Include="src\POP3ClientSessionTest.h" />
|
||||
<ClInclude Include="src\SMTPClientSessionTest.h" />
|
||||
<ClInclude Include="src\ICMPClientTest.h" />
|
||||
<ClInclude Include="src\ICMPClientTestSuite.h" />
|
||||
<ClInclude Include="src\ICMPSocketTest.h" />
|
||||
<ClInclude Include="src\SyslogTest.h" />
|
||||
<ClInclude Include="src\WebSocketTest.h" />
|
||||
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\DNSTest.cpp"/>
|
||||
<ClCompile Include="src\IPAddressTest.cpp"/>
|
||||
<ClCompile Include="src\NetCoreTestSuite.cpp"/>
|
||||
<ClCompile Include="src\NetworkInterfaceTest.cpp"/>
|
||||
<ClCompile Include="src\SocketAddressTest.cpp"/>
|
||||
<ClCompile Include="src\NetTestSuite.cpp"/>
|
||||
<ClCompile Include="src\WinDriver.cpp"/>
|
||||
<ClCompile Include="src\DatagramSocketTest.cpp"/>
|
||||
<ClCompile Include="src\DialogServer.cpp"/>
|
||||
<ClCompile Include="src\DialogSocketTest.cpp"/>
|
||||
<ClCompile Include="src\EchoServer.cpp"/>
|
||||
<ClCompile Include="src\MulticastEchoServer.cpp"/>
|
||||
<ClCompile Include="src\MulticastSocketTest.cpp"/>
|
||||
<ClCompile Include="src\RawSocketTest.cpp"/>
|
||||
<ClCompile Include="src\SocketsTestSuite.cpp"/>
|
||||
<ClCompile Include="src\SocketStreamTest.cpp"/>
|
||||
<ClCompile Include="src\SocketTest.cpp"/>
|
||||
<ClCompile Include="src\UDPEchoServer.cpp"/>
|
||||
<ClCompile Include="src\MediaTypeTest.cpp"/>
|
||||
<ClCompile Include="src\MessageHeaderTest.cpp"/>
|
||||
<ClCompile Include="src\MessagesTestSuite.cpp"/>
|
||||
<ClCompile Include="src\MultipartReaderTest.cpp"/>
|
||||
<ClCompile Include="src\MultipartWriterTest.cpp"/>
|
||||
<ClCompile Include="src\NameValueCollectionTest.cpp"/>
|
||||
<ClCompile Include="src\QuotedPrintableTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPCookieTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPCredentialsTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPRequestTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPResponseTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPTestServer.cpp"/>
|
||||
<ClCompile Include="src\HTTPTestSuite.cpp"/>
|
||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPServerTestSuite.cpp"/>
|
||||
<ClCompile Include="src\HTMLFormTest.cpp"/>
|
||||
<ClCompile Include="src\HTMLTestSuite.cpp"/>
|
||||
<ClCompile Include="src\HTTPClientSessionTest.cpp"/>
|
||||
<ClCompile Include="src\HTTPClientTestSuite.cpp"/>
|
||||
<ClCompile Include="src\HTTPStreamFactoryTest.cpp"/>
|
||||
<ClCompile Include="src\FTPClientSessionTest.cpp"/>
|
||||
<ClCompile Include="src\FTPClientTestSuite.cpp"/>
|
||||
<ClCompile Include="src\FTPStreamFactoryTest.cpp"/>
|
||||
<ClCompile Include="src\ReactorTestSuite.cpp"/>
|
||||
<ClCompile Include="src\SocketReactorTest.cpp"/>
|
||||
<ClCompile Include="src\MailMessageTest.cpp"/>
|
||||
<ClCompile Include="src\MailStreamTest.cpp"/>
|
||||
<ClCompile Include="src\MailTestSuite.cpp"/>
|
||||
<ClCompile Include="src\POP3ClientSessionTest.cpp"/>
|
||||
<ClCompile Include="src\SMTPClientSessionTest.cpp"/>
|
||||
<ClCompile Include="src\ICMPClientTest.cpp"/>
|
||||
<ClCompile Include="src\ICMPClientTestSuite.cpp"/>
|
||||
<ClCompile Include="src\ICMPSocketTest.cpp"/>
|
||||
<ClCompile Include="src\SyslogTest.cpp"/>
|
||||
<ClCompile Include="src\WebSocketTest.cpp"/>
|
||||
<ClCompile Include="src\WebSocketTestSuite.cpp"/>
|
||||
<ClCompile Include="src\DNSTest.cpp" />
|
||||
<ClCompile Include="src\IPAddressTest.cpp" />
|
||||
<ClCompile Include="src\NetCoreTestSuite.cpp" />
|
||||
<ClCompile Include="src\NetworkInterfaceTest.cpp" />
|
||||
<ClCompile Include="src\RouteTest.cpp" />
|
||||
<ClCompile Include="src\SocketAddressTest.cpp" />
|
||||
<ClCompile Include="src\NetTestSuite.cpp" />
|
||||
<ClCompile Include="src\WinDriver.cpp" />
|
||||
<ClCompile Include="src\DatagramSocketTest.cpp" />
|
||||
<ClCompile Include="src\DialogServer.cpp" />
|
||||
<ClCompile Include="src\DialogSocketTest.cpp" />
|
||||
<ClCompile Include="src\EchoServer.cpp" />
|
||||
<ClCompile Include="src\MulticastEchoServer.cpp" />
|
||||
<ClCompile Include="src\MulticastSocketTest.cpp" />
|
||||
<ClCompile Include="src\RawSocketTest.cpp" />
|
||||
<ClCompile Include="src\SocketsTestSuite.cpp" />
|
||||
<ClCompile Include="src\SocketStreamTest.cpp" />
|
||||
<ClCompile Include="src\SocketTest.cpp" />
|
||||
<ClCompile Include="src\UDPEchoServer.cpp" />
|
||||
<ClCompile Include="src\MediaTypeTest.cpp" />
|
||||
<ClCompile Include="src\MessageHeaderTest.cpp" />
|
||||
<ClCompile Include="src\MessagesTestSuite.cpp" />
|
||||
<ClCompile Include="src\MultipartReaderTest.cpp" />
|
||||
<ClCompile Include="src\MultipartWriterTest.cpp" />
|
||||
<ClCompile Include="src\NameValueCollectionTest.cpp" />
|
||||
<ClCompile Include="src\QuotedPrintableTest.cpp" />
|
||||
<ClCompile Include="src\HTTPCookieTest.cpp" />
|
||||
<ClCompile Include="src\HTTPCredentialsTest.cpp" />
|
||||
<ClCompile Include="src\HTTPRequestTest.cpp" />
|
||||
<ClCompile Include="src\HTTPResponseTest.cpp" />
|
||||
<ClCompile Include="src\HTTPTestServer.cpp" />
|
||||
<ClCompile Include="src\HTTPTestSuite.cpp" />
|
||||
<ClCompile Include="src\TCPServerTest.cpp" />
|
||||
<ClCompile Include="src\TCPServerTestSuite.cpp" />
|
||||
<ClCompile Include="src\HTTPServerTest.cpp" />
|
||||
<ClCompile Include="src\HTTPServerTestSuite.cpp" />
|
||||
<ClCompile Include="src\HTMLFormTest.cpp" />
|
||||
<ClCompile Include="src\HTMLTestSuite.cpp" />
|
||||
<ClCompile Include="src\HTTPClientSessionTest.cpp" />
|
||||
<ClCompile Include="src\HTTPClientTestSuite.cpp" />
|
||||
<ClCompile Include="src\HTTPStreamFactoryTest.cpp" />
|
||||
<ClCompile Include="src\FTPClientSessionTest.cpp" />
|
||||
<ClCompile Include="src\FTPClientTestSuite.cpp" />
|
||||
<ClCompile Include="src\FTPStreamFactoryTest.cpp" />
|
||||
<ClCompile Include="src\ReactorTestSuite.cpp" />
|
||||
<ClCompile Include="src\SocketReactorTest.cpp" />
|
||||
<ClCompile Include="src\MailMessageTest.cpp" />
|
||||
<ClCompile Include="src\MailStreamTest.cpp" />
|
||||
<ClCompile Include="src\MailTestSuite.cpp" />
|
||||
<ClCompile Include="src\POP3ClientSessionTest.cpp" />
|
||||
<ClCompile Include="src\SMTPClientSessionTest.cpp" />
|
||||
<ClCompile Include="src\ICMPClientTest.cpp" />
|
||||
<ClCompile Include="src\ICMPClientTestSuite.cpp" />
|
||||
<ClCompile Include="src\ICMPSocketTest.cpp" />
|
||||
<ClCompile Include="src\SyslogTest.cpp" />
|
||||
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||
<ImportGroup Label="ExtensionTargets"/>
|
||||
</Project>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
@ -309,6 +309,9 @@
|
||||
<ClInclude Include="src\WebSocketTestSuite.h">
|
||||
<Filter>WebSocket\Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\RouteTest.h">
|
||||
<Filter>NetCore\Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\DNSTest.cpp">
|
||||
@ -479,5 +482,8 @@
|
||||
<ClCompile Include="src\WebSocketTestSuite.cpp">
|
||||
<Filter>WebSocket\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\RouteTest.cpp">
|
||||
<Filter>NetCore\Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
@ -35,6 +35,7 @@
|
||||
#include "SocketAddressTest.h"
|
||||
#include "DNSTest.h"
|
||||
#include "NetworkInterfaceTest.h"
|
||||
#include "RouteTest.h"
|
||||
|
||||
|
||||
CppUnit::Test* NetCoreTestSuite::suite()
|
||||
@ -45,6 +46,7 @@ CppUnit::Test* NetCoreTestSuite::suite()
|
||||
pSuite->addTest(SocketAddressTest::suite());
|
||||
pSuite->addTest(DNSTest::suite());
|
||||
pSuite->addTest(NetworkInterfaceTest::suite());
|
||||
pSuite->addTest(RouteTest::suite());
|
||||
|
||||
return pSuite;
|
||||
}
|
||||
|
119
Net/testsuite/src/RouteTest.cpp
Normal file
119
Net/testsuite/src/RouteTest.cpp
Normal file
@ -0,0 +1,119 @@
|
||||
//
|
||||
// RouteTest.cpp
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/RouteTest.cpp#2 $
|
||||
//
|
||||
// Copyright (c) 2005-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
#include "RouteTest.h"
|
||||
#include "CppUnit/TestCaller.h"
|
||||
#include "CppUnit/TestSuite.h"
|
||||
#include "Poco/Net/IPAddress.h"
|
||||
#include "Poco/Net/Route.h"
|
||||
#include "Poco/Net/NetException.h"
|
||||
|
||||
|
||||
using Poco::Net::IPAddress;
|
||||
using Poco::Net::Route;
|
||||
using Poco::Net::InvalidAddressException;
|
||||
|
||||
|
||||
RouteTest::RouteTest(const std::string& name): CppUnit::TestCase(name)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
RouteTest::~RouteTest()
|
||||
{
|
||||
}
|
||||
|
||||
//
|
||||
// we should have on most systems at least 3 routes: one for the local subnet,
|
||||
// one for the loopback subnet, and a default route.
|
||||
//
|
||||
// we should have at least one default route (possibly more on a multi-homed
|
||||
// system).
|
||||
//
|
||||
// we should have at least 2 multicast all-hosts routes: one for the local subnet,
|
||||
// and one for the loopback subnet.
|
||||
//
|
||||
// if we wish to do more sanity checking than this, we'd need to correlate it
|
||||
// with results we get back from NetworkInterface::list().
|
||||
//
|
||||
|
||||
void RouteTest::testDefaultRoute()
|
||||
{
|
||||
Route::RouteList routes = Route::list(IPAddress::IPv4);
|
||||
assert(routes.size() >= 3);
|
||||
}
|
||||
|
||||
|
||||
void RouteTest::testAllRoutes()
|
||||
{
|
||||
Route::RouteList defaults = Route::defaults(IPAddress::IPv4);
|
||||
assert(defaults.size() >= 1);
|
||||
}
|
||||
|
||||
|
||||
void RouteTest::testAllHostsRoutes()
|
||||
{
|
||||
IPAddress target("224.0.0.1");
|
||||
Route::RouteList targets = Route::match(target);
|
||||
assert(targets.size() >= 2);
|
||||
}
|
||||
|
||||
|
||||
void RouteTest::testLoopbackRoute()
|
||||
{
|
||||
IPAddress target("127.0.0.1");
|
||||
Route::RouteList targets = Route::match(target);
|
||||
assert(targets.size() >= 1);
|
||||
}
|
||||
|
||||
|
||||
void RouteTest::setUp()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
void RouteTest::tearDown()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
CppUnit::Test* RouteTest::suite()
|
||||
{
|
||||
CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("RouteTest");
|
||||
|
||||
CppUnit_addTest(pSuite, RouteTest, testDefaultRoute);
|
||||
CppUnit_addTest(pSuite, RouteTest, testAllRoutes);
|
||||
// CppUnit_addTest(pSuite, RouteTest, testAllHostsRoutes);
|
||||
CppUnit_addTest(pSuite, RouteTest, testLoopbackRoute);
|
||||
|
||||
return pSuite;
|
||||
}
|
63
Net/testsuite/src/RouteTest.h
Normal file
63
Net/testsuite/src/RouteTest.h
Normal file
@ -0,0 +1,63 @@
|
||||
//
|
||||
// RouteTest.h
|
||||
//
|
||||
// $Id: //poco/1.4/Net/testsuite/src/RouteTest.h#1 $
|
||||
//
|
||||
// Definition of the RouteTest class.
|
||||
//
|
||||
// Copyright (c) 2005-2006, Applied Informatics Software Engineering GmbH.
|
||||
// and Contributors.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person or organization
|
||||
// obtaining a copy of the software and accompanying documentation covered by
|
||||
// this license (the "Software") to use, reproduce, display, distribute,
|
||||
// execute, and transmit the Software, and to prepare derivative works of the
|
||||
// Software, and to permit third-parties to whom the Software is furnished to
|
||||
// do so, all subject to the following:
|
||||
//
|
||||
// The copyright notices in the Software and this entire statement, including
|
||||
// the above license grant, this restriction and the following disclaimer,
|
||||
// must be included in all copies of the Software, in whole or in part, and
|
||||
// all derivative works of the Software, unless such copies or derivative
|
||||
// works are solely in the form of machine-executable object code generated by
|
||||
// a source language processor.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
|
||||
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
|
||||
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
// DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
|
||||
|
||||
#ifndef RouteTest_INCLUDED
|
||||
#define RouteTest_INCLUDED
|
||||
|
||||
|
||||
#include "Poco/Net/Net.h"
|
||||
#include "CppUnit/TestCase.h"
|
||||
|
||||
|
||||
class RouteTest: public CppUnit::TestCase
|
||||
{
|
||||
public:
|
||||
RouteTest(const std::string& name);
|
||||
~RouteTest();
|
||||
|
||||
void testDefaultRoute();
|
||||
void testAllRoutes();
|
||||
void testAllHostsRoutes();
|
||||
void testLoopbackRoute();
|
||||
|
||||
void setUp();
|
||||
void tearDown();
|
||||
|
||||
static CppUnit::Test* suite();
|
||||
|
||||
private:
|
||||
};
|
||||
|
||||
|
||||
#endif // RouteTest_INCLUDED
|
Loading…
Reference in New Issue
Block a user