[修改] 增加freeRTOS

1. 版本FreeRTOSv202212.01,命名为kernel;
This commit is contained in:
2023-05-06 16:43:01 +00:00
commit a345df017b
20944 changed files with 11094377 additions and 0 deletions

View File

@ -0,0 +1,263 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>17.0</VCProjectVersion>
<ProjectGuid>{C90E6CC5-818B-4C97-8876-0986D989387C}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
<RootNamespace>FreeRTOS_TCP</RootNamespace>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Platform)'=='Win32'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Platform)'=='x64'">
<LinkIncremental>true</LinkIncremental>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<PublicIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<LibraryPath>$(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);..\..\ThirdParty\winpcap\lib\x64</LibraryPath>
<IncludePath>$(IncludePath)</IncludePath>
<PublicModuleDirectories>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\</PublicModuleDirectories>
<SourcePath>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools;$(SourcePath)</SourcePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<PublicIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<LibraryPath>$(VC_LibraryPath_x64);$(WindowsSDK_LibraryPath_x64);..\..\ThirdParty\winpcap\lib\x64</LibraryPath>
<IncludePath>$(IncludePath)</IncludePath>
<PublicModuleDirectories>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\</PublicModuleDirectories>
<SourcePath>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools;$(SourcePath)</SourcePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<PublicIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<LibraryPath>$(VC_LibraryPath_x86);$(WindowsSDK_LibraryPath_x86);..\..\ThirdParty\winpcap\lib\x86</LibraryPath>
<IncludePath>$(IncludePath)</IncludePath>
<PublicModuleDirectories>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\</PublicModuleDirectories>
<SourcePath>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools;$(SourcePath)</SourcePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<PublicIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<LibraryPath>$(VC_LibraryPath_x86);$(WindowsSDK_LibraryPath_x86);..\..\ThirdParty\winpcap\lib\x86</LibraryPath>
<IncludePath>$(IncludePath)</IncludePath>
<PublicModuleDirectories>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;.\</PublicModuleDirectories>
<SourcePath>..\..\Source\FreeRTOS-Plus-TCP\source;..\..\Source\FreeRTOS-Plus-TCP\tools;$(SourcePath)</SourcePath>
</PropertyGroup>
<PropertyGroup Label="Vcpkg">
<VcpkgEnabled>false</VcpkgEnabled>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\ThirdParty\winpcap\include;..\..\ThirdParty\winpcap\include\pcap;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
<Lib>
<AdditionalDependencies>wpcap.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<AdditionalIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\ThirdParty\winpcap\include;..\..\ThirdParty\winpcap\include\pcap;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
<Lib>
<AdditionalDependencies>wpcap.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile />
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\ThirdParty\winpcap\include;..\..\ThirdParty\winpcap\include\pcap;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Lib>
<AdditionalDependencies>wpcap.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Lib>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<AdditionalIncludeDirectories>..\..\Source\FreeRTOS-Plus-TCP\source\include;..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC;..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include;..\..\ThirdParty\winpcap\include;..\..\ThirdParty\winpcap\include\pcap;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Lib>
<AdditionalDependencies>wpcap.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Lib>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_ARP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DHCP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Cache.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Callback.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Networking.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Parser.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_ICMP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP_Timers.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP_Utils.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Sockets.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Stream_Buffer.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_IP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Reception.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_State_Handling.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Transmission.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Utils.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_WIN.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Tiny_TCP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_UDP_IP.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\BufferManagement\BufferAllocation_2.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_dump_packets.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_mem_stats.c" />
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_netstat.c" />
<ClCompile Include="NetworkInterface_WinPCap.c" />
<ClCompile Include="plus_tcp_hooks_winsim.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOSIPConfigDefaults.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_ARP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DHCP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Cache.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Callback.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Globals.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Networking.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Parser.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_errno_TCP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_ICMP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Private.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Timers.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Utils.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_Sockets.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_Stream_Buffer.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_IP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Reception.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_State_Handling.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Transmission.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Utils.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_WIN.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_UDP_IP.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\IPTraceMacroDefaults.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\NetworkBufferManagement.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\NetworkInterface.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC\pack_struct_end.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC\pack_struct_start.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_dump_packets.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_mem_stats.h" />
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_netstat.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\bittypes.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\ip6_misc.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\Packet32.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-bpf.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-namedb.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-stdinc.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\bluetooth.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\bpf.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\namedb.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\pcap.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\sll.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\usb.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\vlan.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\remote-ext.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\Win32-Extensions.h" />
<ClInclude Include="FreeRTOSIPConfig.h" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj">
<Project>{72c209c4-49a4-4942-a201-44706c9d77ec}</Project>
<Private>false</Private>
<LinkLibraryDependencies>true</LinkLibraryDependencies>
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,258 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="source">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="include">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;hm;inl;inc;xsd</Extensions>
</Filter>
<Filter Include="compiler_msvc">
<UniqueIdentifier>{a3216426-70cf-4b4f-8b8f-423c8d0416cb}</UniqueIdentifier>
</Filter>
<Filter Include="tcp_utilities">
<UniqueIdentifier>{b2e06bcd-b665-4ef4-8eff-5203748463d1}</UniqueIdentifier>
</Filter>
<Filter Include="tcp_utilities\include">
<UniqueIdentifier>{af7dc417-59c0-4c2b-bb4b-cc9b84817e89}</UniqueIdentifier>
</Filter>
<Filter Include="winpcap">
<UniqueIdentifier>{97a99563-c215-4975-9cb8-c6a29a30f03f}</UniqueIdentifier>
<Extensions>h</Extensions>
</Filter>
<Filter Include="winpcap\include">
<UniqueIdentifier>{7a52d3bf-8fc9-4242-8636-e173ade0aa68}</UniqueIdentifier>
</Filter>
<Filter Include="winpcap\include\pcap">
<UniqueIdentifier>{2968f486-aba8-47f5-a175-fe77e197a2c6}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_ICMP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Stream_Buffer.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Tiny_TCP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_State_Handling.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Callback.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Reception.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Utils.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_UDP_IP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Parser.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Networking.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_Sockets.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP_Utils.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DHCP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_IP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_WIN.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP_Timers.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_ARP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_TCP_Transmission.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_DNS_Cache.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\FreeRTOS_IP.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_dump_packets.c">
<Filter>tcp_utilities</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_mem_stats.c">
<Filter>tcp_utilities</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\tcp_netstat.c">
<Filter>tcp_utilities</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\BufferManagement\BufferAllocation_2.c">
<Filter>source</Filter>
</ClCompile>
<ClCompile Include="plus_tcp_hooks_winsim.c" />
<ClCompile Include="NetworkInterface_WinPCap.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_Sockets.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_errno_TCP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Utils.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Globals.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Networking.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_WIN.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_IP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DHCP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Cache.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\NetworkBufferManagement.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_ARP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\NetworkInterface.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Transmission.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Timers.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOSIPConfigDefaults.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP_Private.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_IP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_Stream_Buffer.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_ICMP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Callback.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_State_Handling.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Reception.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_UDP_IP.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_TCP_Utils.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\IPTraceMacroDefaults.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\include\FreeRTOS_DNS_Parser.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_dump_packets.h">
<Filter>tcp_utilities\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_netstat.h">
<Filter>tcp_utilities\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\tools\tcp_utilities\include\tcp_mem_stats.h">
<Filter>tcp_utilities\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC\pack_struct_end.h">
<Filter>compiler_msvc</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\FreeRTOS-Plus-TCP\source\portable\Compiler\MSVC\pack_struct_start.h">
<Filter>compiler_msvc</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\sll.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\usb.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\vlan.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-bpf.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-namedb.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\remote-ext.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\bittypes.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\ip6_misc.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\Win32-Extensions.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\Packet32.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap-stdinc.h">
<Filter>winpcap\include</Filter>
</ClInclude>
<ClInclude Include="FreeRTOSIPConfig.h" />
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\pcap.h">
<Filter>winpcap\include\pcap</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\namedb.h">
<Filter>winpcap\include\pcap</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\bpf.h">
<Filter>winpcap\include\pcap</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\winpcap\include\pcap\bluetooth.h">
<Filter>winpcap\include\pcap</Filter>
</ClInclude>
</ItemGroup>
</Project>

View File

@ -0,0 +1,326 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/*****************************************************************************
*
* See the following URL for configuration information.
* https://www.FreeRTOS.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/TCP_IP_Configuration.html
*
*****************************************************************************/
#ifndef FREERTOS_IP_CONFIG_H
#define FREERTOS_IP_CONFIG_H
#include "FreeRTOSConfig.h"
#include "tcp_netstat.h"
/* Prototype for the function used to print out. In this case it prints to the
* console before the network is connected then a UDP port after the network has
* connected. */
extern void vLoggingPrintf( const char * pcFormatString,
... );
/* Set to 1 to print out debug messages. If ipconfigHAS_DEBUG_PRINTF is set to
* 1 then FreeRTOS_debug_printf should be defined to the function used to print
* out the debugging messages. */
#define ipconfigHAS_DEBUG_PRINTF 1
#if ( ipconfigHAS_DEBUG_PRINTF == 1 )
#define FreeRTOS_debug_printf( X ) vLoggingPrintf X
#endif
/* Set to 1 to print out non debugging messages, for example the output of the
* FreeRTOS_netstat() command, and ping replies. If ipconfigHAS_PRINTF is set to 1
* then FreeRTOS_printf should be set to the function used to print out the
* messages. */
#define ipconfigHAS_PRINTF 1
#if ( ipconfigHAS_PRINTF == 1 )
#define FreeRTOS_printf( X ) vLoggingPrintf X
#endif
/* Define the byte order of the target MCU (the MCU FreeRTOS+TCP is executing
* on). Valid options are pdFREERTOS_BIG_ENDIAN and pdFREERTOS_LITTLE_ENDIAN. */
#define ipconfigBYTE_ORDER pdFREERTOS_LITTLE_ENDIAN
/* If the network card/driver includes checksum offloading (IP/TCP/UDP checksums)
* then set ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM to 1 to prevent the software
* stack repeating the checksum calculations. */
#define ipconfigDRIVER_INCLUDED_RX_IP_CHECKSUM 1
/* Several API's will block until the result is known, or the action has been
* performed, for example FreeRTOS_send() and FreeRTOS_recv(). The timeouts can be
* set per socket, using setsockopt(). If not set, the times below will be
* used as defaults. */
#define ipconfigSOCK_DEFAULT_RECEIVE_BLOCK_TIME ( 5000 )
#define ipconfigSOCK_DEFAULT_SEND_BLOCK_TIME ( 5000 )
/* Include support for LLMNR: Link-local Multicast Name Resolution
* (non-Microsoft) */
#define ipconfigUSE_LLMNR ( 0 )
/* Include support for NBNS: NetBIOS Name Service (Microsoft) */
#define ipconfigUSE_NBNS ( 0 )
/* Include support for DNS caching. For TCP, having a small DNS cache is very
* useful. When a cache is present, ipconfigDNS_REQUEST_ATTEMPTS can be kept low
* and also DNS may use small timeouts. If a DNS reply comes in after the DNS
* socket has been destroyed, the result will be stored into the cache. The next
* call to FreeRTOS_gethostbyname() will return immediately, without even creating
* a socket. */
#define ipconfigUSE_DNS_CACHE 1
#define ipconfigDNS_CACHE_NAME_LENGTH ( 64U )
#define ipconfigDNS_CACHE_ENTRIES ( 4U )
#define ipconfigDNS_REQUEST_ATTEMPTS ( 2U )
/* The IP stack executes it its own task (although any application task can make
* use of its services through the published sockets API). ipconfigUDP_TASK_PRIORITY
* sets the priority of the task that executes the IP stack. The priority is a
* standard FreeRTOS task priority so can take any value from 0 (the lowest
* priority) to (configMAX_PRIORITIES - 1) (the highest priority).
* configMAX_PRIORITIES is a standard FreeRTOS configuration parameter defined in
* FreeRTOSConfig.h, not FreeRTOSIPConfig.h. Consideration needs to be given as to
* the priority assigned to the task executing the IP stack relative to the
* priority assigned to tasks that use the IP stack. */
#define ipconfigIP_TASK_PRIORITY ( configMAX_PRIORITIES - 2U )
/* The size, in words (not bytes), of the stack allocated to the FreeRTOS+TCP
* task. This setting is less important when the FreeRTOS Win32 simulator is used
* as the Win32 simulator only stores a fixed amount of information on the task
* stack. FreeRTOS includes optional stack overflow detection, see:
* https://www.FreeRTOS.org/Stacks-and-stack-overflow-checking.html */
#define ipconfigIP_TASK_STACK_SIZE_WORDS ( configMINIMAL_STACK_SIZE * 5U )
/* ipconfigRAND32() is called by the IP stack to generate random numbers for
* things such as a DHCP transaction number or initial sequence number. Random
* number generation is performed via this macro to allow applications to use their
* own random number generation method. For example, it might be possible to
* generate a random number by sampling noise on an analogue input. */
extern UBaseType_t uxRand();
#define ipconfigRAND32() uxRand()
/* If ipconfigUSE_NETWORK_EVENT_HOOK is set to 1 then FreeRTOS+TCP will call the
* network event hook at the appropriate times. If ipconfigUSE_NETWORK_EVENT_HOOK
* is not set to 1 then the network event hook will never be called. See
* https://www.FreeRTOS.org/FreeRTOS-Plus/FreeRTOS_Plus_UDP/API/vApplicationIPNetworkEventHook.shtml
*/
#define ipconfigUSE_NETWORK_EVENT_HOOK 1
/* Sockets have a send block time attribute. If FreeRTOS_sendto() is called but
* a network buffer cannot be obtained then the calling task is held in the Blocked
* state (so other tasks can continue to executed) until either a network buffer
* becomes available or the send block time expires. If the send block time expires
* then the send operation is aborted. The maximum allowable send block time is
* capped to the value set by ipconfigMAX_SEND_BLOCK_TIME_TICKS. Capping the
* maximum allowable send block time prevents a deadlock occurring when
* all the network buffers are in use and the tasks that process (and subsequently
* free) the network buffers are themselves blocked waiting for a network buffer.
* ipconfigMAX_SEND_BLOCK_TIME_TICKS is specified in RTOS ticks. A time in
* milliseconds can be converted to a time in ticks by dividing the time in
* milliseconds by portTICK_PERIOD_MS. */
#define ipconfigUDP_MAX_SEND_BLOCK_TIME_TICKS ( 5000U / portTICK_PERIOD_MS )
/* If ipconfigUSE_DHCP is 1 then FreeRTOS+TCP will attempt to retrieve an IP
* address, netmask, DNS server address and gateway address from a DHCP server. If
* ipconfigUSE_DHCP is 0 then FreeRTOS+TCP will use a static IP address. The
* stack will revert to using the static IP address even when ipconfigUSE_DHCP is
* set to 1 if a valid configuration cannot be obtained from a DHCP server for any
* reason. The static configuration used is that passed into the stack by the
* FreeRTOS_IPInit() function call. */
#define ipconfigUSE_DHCP 1
/* When ipconfigUSE_DHCP is set to 1, DHCP requests will be sent out at
* increasing time intervals until either a reply is received from a DHCP server
* and accepted, or the interval between transmissions reaches
* ipconfigMAXIMUM_DISCOVER_TX_PERIOD. The IP stack will revert to using the
* static IP address passed as a parameter to FreeRTOS_IPInit() if the
* re-transmission time interval reaches ipconfigMAXIMUM_DISCOVER_TX_PERIOD without
* a DHCP reply being received. */
#define ipconfigMAXIMUM_DISCOVER_TX_PERIOD ( 120000U / portTICK_PERIOD_MS )
/* The ARP cache is a table that maps IP addresses to MAC addresses. The IP
* stack can only send a UDP message to a remove IP address if it knowns the MAC
* address associated with the IP address, or the MAC address of the router used to
* contact the remote IP address. When a UDP message is received from a remote IP
* address the MAC address and IP address are added to the ARP cache. When a UDP
* message is sent to a remote IP address that does not already appear in the ARP
* cache then the UDP message is replaced by a ARP message that solicits the
* required MAC address information. ipconfigARP_CACHE_ENTRIES defines the maximum
* number of entries that can exist in the ARP table at any one time. */
#define ipconfigARP_CACHE_ENTRIES 6
/* ARP requests that do not result in an ARP response will be re-transmitted a
* maximum of ipconfigMAX_ARP_RETRANSMISSIONS times before the ARP request is
* aborted. */
#define ipconfigMAX_ARP_RETRANSMISSIONS ( 5 )
/* ipconfigMAX_ARP_AGE defines the maximum time between an entry in the ARP
* table being created or refreshed and the entry being removed because it is stale.
* New ARP requests are sent for ARP cache entries that are nearing their maximum
* age. ipconfigMAX_ARP_AGE is specified in tens of seconds, so a value of 150 is
* equal to 1500 seconds (or 25 minutes). */
#define ipconfigMAX_ARP_AGE 150U
/* Implementing FreeRTOS_inet_addr() necessitates the use of string handling
* routines, which are relatively large. To save code space the full
* FreeRTOS_inet_addr() implementation is made optional, and a smaller and faster
* alternative called FreeRTOS_inet_addr_quick() is provided. FreeRTOS_inet_addr()
* takes an IP in decimal dot format (for example, "192.168.0.1") as its parameter.
* FreeRTOS_inet_addr_quick() takes an IP address as four separate numerical octets
* (for example, 192, 168, 0, 1) as its parameters. If
* ipconfigINCLUDE_FULL_INET_ADDR is set to 1 then both FreeRTOS_inet_addr() and
* FreeRTOS_indet_addr_quick() are available. If ipconfigINCLUDE_FULL_INET_ADDR is
* not set to 1 then only FreeRTOS_indet_addr_quick() is available. */
#define ipconfigINCLUDE_FULL_INET_ADDR 1
/* ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS defines the total number of network buffer that
* are available to the IP stack. The total number of network buffers is limited
* to ensure the total amount of RAM that can be consumed by the IP stack is capped
* to a pre-determinable value. */
#define ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS 60U
/* A FreeRTOS queue is used to send events from application tasks to the IP
* stack. ipconfigEVENT_QUEUE_LENGTH sets the maximum number of events that can
* be queued for processing at any one time. The event queue must be a minimum of
* 5 greater than the total number of network buffers. */
#define ipconfigEVENT_QUEUE_LENGTH ( ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS + 5 )
/* The address of a socket is the combination of its IP address and its port
* number. FreeRTOS_bind() is used to manually allocate a port number to a socket
* (to 'bind' the socket to a port), but manual binding is not normally necessary
* for client sockets (those sockets that initiate outgoing connections rather than
* wait for incoming connections on a known port number). If
* ipconfigALLOW_SOCKET_SEND_WITHOUT_BIND is set to 1 then calling
* FreeRTOS_sendto() on a socket that has not yet been bound will result in the IP
* stack automatically binding the socket to a port number from the range
* socketAUTO_PORT_ALLOCATION_START_NUMBER to 0xffff. If
* ipconfigALLOW_SOCKET_SEND_WITHOUT_BIND is set to 0 then calling FreeRTOS_sendto()
* on a socket that has not yet been bound will result in the send operation being
* aborted. */
#define ipconfigALLOW_SOCKET_SEND_WITHOUT_BIND 1
/* Defines the Time To Live (TTL) values used in outgoing UDP packets. */
#define ipconfigUDP_TIME_TO_LIVE 128
#define ipconfigTCP_TIME_TO_LIVE 128 /* also defined in FreeRTOSIPConfigDefaults.h */
/* USE_TCP: Use TCP and all its features */
#define ipconfigUSE_TCP ( 1 )
/* Use the TCP socket wake context with a callback. */
#define ipconfigSOCKET_HAS_USER_WAKE_CALLBACK ( 1 )
/* USE_WIN: Let TCP use windowing mechanism. */
#define ipconfigUSE_TCP_WIN ( 1 )
/* The MTU is the maximum number of bytes the payload of a network frame can
* contain. For normal Ethernet V2 frames the maximum MTU is 1500. Setting a
* lower value can save RAM, depending on the buffer management scheme used. If
* ipconfigCAN_FRAGMENT_OUTGOING_PACKETS is 1 then (ipconfigNETWORK_MTU - 28) must
* be divisible by 8. */
#define ipconfigNETWORK_MTU 1500U
/* Set ipconfigUSE_DNS to 1 to include a basic DNS client/resolver. DNS is used
* through the FreeRTOS_gethostbyname() API function. */
#define ipconfigUSE_DNS 1
/* If ipconfigREPLY_TO_INCOMING_PINGS is set to 1 then the IP stack will
* generate replies to incoming ICMP echo (ping) requests. */
#define ipconfigREPLY_TO_INCOMING_PINGS 1
/* If ipconfigSUPPORT_OUTGOING_PINGS is set to 1 then the
* FreeRTOS_SendPingRequest() API function is available. */
#define ipconfigSUPPORT_OUTGOING_PINGS 0
/* If ipconfigSUPPORT_SELECT_FUNCTION is set to 1 then the FreeRTOS_select()
* (and associated) API function is available. */
#define ipconfigSUPPORT_SELECT_FUNCTION 1
/* If ipconfigFILTER_OUT_NON_ETHERNET_II_FRAMES is set to 1 then Ethernet frames
* that are not in Ethernet II format will be dropped. This option is included for
* potential future IP stack developments. */
#define ipconfigFILTER_OUT_NON_ETHERNET_II_FRAMES 1
/* If ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES is set to 1 then it is the
* responsibility of the Ethernet interface to filter out packets that are of no
* interest. If the Ethernet interface does not implement this functionality, then
* set ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES to 0 to have the IP stack
* perform the filtering instead (it is much less efficient for the stack to do it
* because the packet will already have been passed into the stack). If the
* Ethernet driver does all the necessary filtering in hardware then software
* filtering can be removed by using a value other than 1 or 0. */
#define ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES 1
/* The windows simulator cannot really simulate MAC interrupts, and needs to
* block occasionally to allow other tasks to run. */
#define configWINDOWS_MAC_INTERRUPT_SIMULATOR_DELAY ( 20 / portTICK_PERIOD_MS )
/* Advanced only: in order to access 32-bit fields in the IP packets with
* 32-bit memory instructions, all packets will be stored 32-bit-aligned, plus 16-bits.
* This has to do with the contents of the IP-packets: all 32-bit fields are
* 32-bit-aligned, plus 16-bit(!) */
#define ipconfigPACKET_FILLER_SIZE 2U
/* Define the size of the pool of TCP window descriptors. On the average, each
* TCP socket will use up to 2 x 6 descriptors, meaning that it can have 2 x 6
* outstanding packets (for Rx and Tx). When using up to 10 TP sockets
* simultaneously, one could define TCP_WIN_SEG_COUNT as 120. */
#define ipconfigTCP_WIN_SEG_COUNT 240U
/* Each TCP socket has a circular buffers for Rx and Tx, which have a fixed
* maximum size. Define the size of Rx buffer for TCP sockets. */
#define ipconfigTCP_RX_BUFFER_LENGTH ( 4096U )
/* Define the size of Tx buffer for TCP sockets. */
#define ipconfigTCP_TX_BUFFER_LENGTH ( 4096U )
/* When using call-back handlers, the driver may check if the handler points to
* real program memory (RAM or flash) or just has a random non-zero value. */
#define ipconfigIS_VALID_PROG_ADDRESS( x ) ( ( x ) != NULL )
/* Include support for TCP hang protection. All sockets in a connecting or
* disconnecting stage will timeout after a period of non-activity. */
#define ipconfigTCP_HANG_PROTECTION ( 1 )
#define ipconfigTCP_HANG_PROTECTION_TIME ( 30 )
/* Include support for TCP keep-alive messages. */
#define ipconfigTCP_KEEP_ALIVE ( 1 )
#define ipconfigTCP_KEEP_ALIVE_INTERVAL ( 20U ) /* in seconds */
#define portINLINE __inline
#include <stdint.h>
/* Set ipconfigBUFFER_PADDING on 64-bit platforms */
#if INTPTR_MAX == INT64_MAX
#define ipconfigBUFFER_PADDING ( 14U )
#endif /* INTPTR_MAX == INT64_MAX */
#define configMAC
extern BaseType_t xPlatformIsNetworkUp(void);
#endif /* FREERTOS_IP_CONFIG_H */

View File

@ -0,0 +1,797 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
#include <stdlib.h>
/* WinPCap includes. */
#define HAVE_REMOTE
#include "pcap.h"
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#include "task.h"
#include "semphr.h"
/* FreeRTOS+TCP includes. */
#include "FreeRTOS_IP.h"
#include "FreeRTOS_IP_Private.h"
#include "NetworkBufferManagement.h"
/* Thread-safe circular buffers are being used to pass data to and from the PCAP
* access functions. */
#include "Win32-Extensions.h"
#include "FreeRTOS_Stream_Buffer.h"
/* Sizes of the thread safe circular buffers used to pass data to and from the
* WinPCAP Windows threads. */
#define xSEND_BUFFER_SIZE 32768
#define xRECV_BUFFER_SIZE 32768
/* If ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES is set to 1, then the Ethernet
* driver will filter incoming packets and only pass the stack those packets it
* considers need processing. */
#if ( ipconfigETHERNET_DRIVER_FILTERS_FRAME_TYPES == 0 )
#define ipCONSIDER_FRAME_FOR_PROCESSING( pucEthernetBuffer ) eProcessBuffer
#else
#define ipCONSIDER_FRAME_FOR_PROCESSING( pucEthernetBuffer ) eConsiderFrameForProcessing( ( pucEthernetBuffer ) )
#endif
/* Used to insert test code only. */
#define niDISRUPT_PACKETS 0
/*-----------------------------------------------------------*/
/*
* Windows threads that are outside of the control of the FreeRTOS simulator are
* used to interface with the WinPCAP libraries.
*/
DWORD WINAPI prvWinPcapRecvThread( void * pvParam );
DWORD WINAPI prvWinPcapSendThread( void * pvParam );
/*
* Print out a numbered list of network interfaces that are available on the
* host computer.
*/
static pcap_if_t * prvPrintAvailableNetworkInterfaces( void );
/*
* Open the network interface. The number of the interface to be opened is set
* by the configNETWORK_INTERFACE_TO_USE constant in FreeRTOSConfig.h.
*/
static void prvOpenSelectedNetworkInterface( pcap_if_t * pxAllNetworkInterfaces );
static int prvOpenInterface( const char * pucName );
/*
* Configure the capture filter to allow blocking reads, and to filter out
* packets that are not of interest to this demo.
*/
static void prvConfigureCaptureBehaviour( void );
/*
* A function that simulates Ethernet interrupts by periodically polling the
* WinPCap interface for new data.
*/
static void prvInterruptSimulatorTask( void * pvParameters );
/*
* Create the buffers that are used to pass data between the FreeRTOS simulator
* and the Win32 threads that manage WinPCAP.
*/
static void prvCreateThreadSafeBuffers( void );
/*
* This function is equivalent to uxStreamBufferAdd from
* FreeRTOS_Stream_Buffer.c in the case that the stream buffer is being used
* as a normal circular buffer (i.e. only the tail and head pointers are
* needed). Thus, this function does not take the offset argument, and does not
* update the front pointer of the stream buffer. This allows the removal of
* the calls to vTaskSuspendAll and xTaskResumeAll, as the head and front
* pointer no longer need to be atomically updated, allowing this function to be
* safely used by a Windows thread.
*/
static size_t prvStreamBufferAdd( StreamBuffer_t * pxBuffer,
const uint8_t * pucData,
size_t uxByteCount );
/*
* Utility function used to format print messages only.
*/
static const char * prvRemoveSpaces( char * pcBuffer,
int aBuflen,
const char * pcMessage );
/*-----------------------------------------------------------*/
/* Required by the WinPCap library. */
static char cErrorBuffer[ PCAP_ERRBUF_SIZE ];
/* An event used to wake up the Win32 thread that sends data through the WinPCAP
* library. */
static void * pvSendEvent = NULL;
/* _HT_ made the PCAP interface number configurable through the program's
* parameters in order to test in different machines. */
static BaseType_t xConfigNetworkInterfaceToUse = configNETWORK_INTERFACE_TO_USE;
/* Handles to the Windows threads that handle the PCAP IO. */
static HANDLE vWinPcapRecvThreadHandle = NULL;
static HANDLE vWinPcapSendThreadHandle = NULL;
/* The interface being used by WinPCap. */
static pcap_t * pxOpenedInterfaceHandle = NULL;
/* Circular buffers used by the PCAP Win32 threads. */
static StreamBuffer_t * xSendBuffer = NULL;
static StreamBuffer_t * xRecvBuffer = NULL;
/* Logs the number of WinPCAP send failures, for viewing in the debugger only. */
static volatile uint32_t ulWinPCAPSendFailures = 0;
/*-----------------------------------------------------------*/
BaseType_t xNetworkInterfaceInitialise( void )
{
BaseType_t xReturn = pdFALSE;
pcap_if_t * pxAllNetworkInterfaces;
/* Query the computer the simulation is being executed on to find the
* network interfaces it has installed. */
pxAllNetworkInterfaces = prvPrintAvailableNetworkInterfaces();
/* Open the network interface. The number of the interface to be opened is
* set by the configNETWORK_INTERFACE_TO_USE constant in FreeRTOSConfig.h.
* Calling this function will set the pxOpenedInterfaceHandle variable. If,
* after calling this function, pxOpenedInterfaceHandle is equal to NULL, then
* the interface could not be opened. */
if( pxAllNetworkInterfaces != NULL )
{
prvOpenSelectedNetworkInterface( pxAllNetworkInterfaces );
}
if( pxOpenedInterfaceHandle != NULL )
{
xReturn = pdPASS;
}
return xReturn;
}
/*-----------------------------------------------------------*/
static void prvCreateThreadSafeBuffers( void )
{
/* The buffer used to pass data to be transmitted from a FreeRTOS task to
* the Win32 thread that sends via the WinPCAP library. */
if( xSendBuffer == NULL )
{
xSendBuffer = ( StreamBuffer_t * ) malloc( sizeof( *xSendBuffer ) - sizeof( xSendBuffer->ucArray ) + xSEND_BUFFER_SIZE + 1 );
configASSERT( xSendBuffer );
memset( xSendBuffer, '\0', sizeof( *xSendBuffer ) - sizeof( xSendBuffer->ucArray ) );
xSendBuffer->LENGTH = xSEND_BUFFER_SIZE + 1;
}
/* The buffer used to pass received data from the Win32 thread that receives
* via the WinPCAP library to the FreeRTOS task. */
if( xRecvBuffer == NULL )
{
xRecvBuffer = ( StreamBuffer_t * ) malloc( sizeof( *xRecvBuffer ) - sizeof( xRecvBuffer->ucArray ) + xRECV_BUFFER_SIZE + 1 );
configASSERT( xRecvBuffer );
memset( xRecvBuffer, '\0', sizeof( *xRecvBuffer ) - sizeof( xRecvBuffer->ucArray ) );
xRecvBuffer->LENGTH = xRECV_BUFFER_SIZE + 1;
}
}
/*-----------------------------------------------------------*/
static size_t prvStreamBufferAdd( StreamBuffer_t * pxBuffer,
const uint8_t * pucData,
size_t uxByteCount )
{
size_t uxSpace, uxNextHead, uxFirst;
size_t uxCount = uxByteCount;
uxSpace = uxStreamBufferGetSpace( pxBuffer );
/* The number of bytes that can be written is the minimum of the number of
* bytes requested and the number available. */
uxCount = FreeRTOS_min_size_t( uxSpace, uxCount );
if( uxCount != 0U )
{
uxNextHead = pxBuffer->uxHead;
if( pucData != NULL )
{
/* Calculate the number of bytes that can be added in the first
* write - which may be less than the total number of bytes that need
* to be added if the buffer will wrap back to the beginning. */
uxFirst = FreeRTOS_min_size_t( pxBuffer->LENGTH - uxNextHead, uxCount );
/* Write as many bytes as can be written in the first write. */
( void ) memcpy( &( pxBuffer->ucArray[ uxNextHead ] ), pucData, uxFirst );
/* If the number of bytes written was less than the number that
* could be written in the first write... */
if( uxCount > uxFirst )
{
/* ...then write the remaining bytes to the start of the
* buffer. */
( void ) memcpy( pxBuffer->ucArray, &( pucData[ uxFirst ] ), uxCount - uxFirst );
}
}
uxNextHead += uxCount;
if( uxNextHead >= pxBuffer->LENGTH )
{
uxNextHead -= pxBuffer->LENGTH;
}
pxBuffer->uxHead = uxNextHead;
}
return uxCount;
}
/*-----------------------------------------------------------*/
BaseType_t xNetworkInterfaceOutput( NetworkBufferDescriptor_t * const pxNetworkBuffer,
BaseType_t bReleaseAfterSend )
{
size_t xSpace;
iptraceNETWORK_INTERFACE_TRANSMIT();
configASSERT( xIsCallingFromIPTask() == pdTRUE );
/* Both the length of the data being sent and the actual data being sent
* are placed in the thread safe buffer used to pass data between the FreeRTOS
* tasks and the Win32 thread that sends data via the WinPCAP library. Drop
* the packet if there is insufficient space in the buffer to hold both. */
xSpace = uxStreamBufferGetSpace( xSendBuffer );
if( ( pxNetworkBuffer->xDataLength <= ( ipconfigNETWORK_MTU + ipSIZE_OF_ETH_HEADER ) ) &&
( xSpace >= ( pxNetworkBuffer->xDataLength + sizeof( pxNetworkBuffer->xDataLength ) ) ) )
{
/* First write in the length of the data, then write in the data
* itself. */
uxStreamBufferAdd( xSendBuffer, 0, ( const uint8_t * ) &( pxNetworkBuffer->xDataLength ), sizeof( pxNetworkBuffer->xDataLength ) );
uxStreamBufferAdd( xSendBuffer, 0, ( const uint8_t * ) pxNetworkBuffer->pucEthernetBuffer, pxNetworkBuffer->xDataLength );
}
else
{
FreeRTOS_debug_printf( ( "xNetworkInterfaceOutput: send buffers full to store %lu\n", pxNetworkBuffer->xDataLength ) );
}
/* Kick the Tx task in either case in case it doesn't know the buffer is
* full. */
SetEvent( pvSendEvent );
/* The buffer has been sent so can be released. */
if( bReleaseAfterSend != pdFALSE )
{
vReleaseNetworkBufferAndDescriptor( pxNetworkBuffer );
}
return pdPASS;
}
/*-----------------------------------------------------------*/
static pcap_if_t * prvPrintAvailableNetworkInterfaces( void )
{
pcap_if_t * pxAllNetworkInterfaces = NULL, * xInterface;
int32_t lInterfaceNumber = 1;
char cBuffer[ 512 ];
static BaseType_t xInvalidInterfaceDetected = pdFALSE;
if( xInvalidInterfaceDetected == pdFALSE )
{
if( pcap_findalldevs_ex( PCAP_SRC_IF_STRING, NULL, &pxAllNetworkInterfaces, cErrorBuffer ) == -1 )
{
printf( "Could not obtain a list of network interfaces\n%s\n", cErrorBuffer );
pxAllNetworkInterfaces = NULL;
}
else
{
printf( "\r\n\r\nThe following network interfaces are available:\r\n\r\n" );
}
if( pxAllNetworkInterfaces != NULL )
{
/* Print out the list of network interfaces. The first in the list
* is interface '1', not interface '0'. */
for(xInterface = pxAllNetworkInterfaces; xInterface != NULL; xInterface = xInterface->next)
{
/* The descriptions of the devices can be full of spaces, clean them
* a little. printf() can only be used here because the network is not
* up yet - so no other network tasks will be running. */
printf( "Interface %d - %s\n", lInterfaceNumber, prvRemoveSpaces( cBuffer, sizeof( cBuffer ), xInterface->name ) );
printf( " (%s)\n", prvRemoveSpaces( cBuffer, sizeof( cBuffer ), xInterface->description ? xInterface->description : "No description" ) );
printf( "\n" );
lInterfaceNumber++;
}
}
if( lInterfaceNumber == 1 )
{
/* The interface number was never incremented, so the above for() loop
* did not execute meaning no interfaces were found. */
printf( " \nNo network interfaces were found.\n" );
pxAllNetworkInterfaces = NULL;
}
printf( "\r\nThe interface that will be opened is set by " );
printf( "\"configNETWORK_INTERFACE_TO_USE\", which\r\nshould be defined in FreeRTOSConfig.h\r\n" );
if( ( xConfigNetworkInterfaceToUse < 1L ) || ( xConfigNetworkInterfaceToUse >= lInterfaceNumber ) )
{
printf( "\r\nERROR: configNETWORK_INTERFACE_TO_USE is set to %d, which is an invalid value.\r\n", xConfigNetworkInterfaceToUse );
printf( "Please set configNETWORK_INTERFACE_TO_USE to one of the interface numbers listed above,\r\n" );
printf( "then re-compile and re-start the application. Only Ethernet (as opposed to WiFi)\r\n" );
printf( "interfaces are supported.\r\n\r\nHALTING\r\n\r\n\r\n" );
xInvalidInterfaceDetected = pdTRUE;
if( pxAllNetworkInterfaces != NULL )
{
/* Free the device list, as no devices are going to be opened. */
pcap_freealldevs( pxAllNetworkInterfaces );
pxAllNetworkInterfaces = NULL;
}
}
else
{
printf( "Attempting to open interface number %d.\n", xConfigNetworkInterfaceToUse );
}
}
return pxAllNetworkInterfaces;
}
/*-----------------------------------------------------------*/
static int prvOpenInterface( const char * pucName )
{
static char pucInterfaceName[ 256 ];
if( pucName != NULL )
{
strncpy( pucInterfaceName, pucName, sizeof( pucInterfaceName ) );
}
pxOpenedInterfaceHandle = pcap_open( pucInterfaceName, /* The name of the selected interface. */
ipTOTAL_ETHERNET_FRAME_SIZE, /* The size of the packet to capture. */
PCAP_OPENFLAG_PROMISCUOUS, /* Open in promiscuous mode as the MAC and
* IP address is going to be "simulated", and
* not be the real MAC and IP address. This allows
* traffic to the simulated IP address to be routed
* to uIP, and traffic to the real IP address to be
* routed to the Windows TCP/IP stack. */
100,
NULL, /* No authentication is required as this is
* not a remote capture session. */
cErrorBuffer
);
if( pxOpenedInterfaceHandle == NULL )
{
printf( "\n%s is not supported by WinPcap and cannot be opened\n", pucInterfaceName );
return 1;
}
else
{
/* Configure the capture filter to allow blocking reads, and to filter
* out packets that are not of interest to this demo. */
prvConfigureCaptureBehaviour();
}
return 0;
}
/*-----------------------------------------------------------*/
static void prvOpenSelectedNetworkInterface( pcap_if_t * pxAllNetworkInterfaces )
{
pcap_if_t * pxInterface;
int32_t x;
/* Walk the list of devices until the selected device is located. */
pxInterface = pxAllNetworkInterfaces;
for(x = 0L; x < ( xConfigNetworkInterfaceToUse - 1L ); x++)
{
pxInterface = pxInterface->next;
}
/* Open the selected interface. */
if( prvOpenInterface( pxInterface->name ) == 0 )
{
printf( "Successfully opened interface number %d.\n", x + 1 );
}
else
{
printf( "Failed to open interface number %d.\n", x + 1 );
}
/* The device list is no longer required. */
pcap_freealldevs( pxAllNetworkInterfaces );
}
/*-----------------------------------------------------------*/
static void prvConfigureCaptureBehaviour( void )
{
struct bpf_program xFilterCode;
uint32_t ulNetMask;
/* Set up a filter so only the packets of interest are passed to the IP
* stack. cErrorBuffer is used for convenience to create the string. Don't
* confuse this with an error message. */
sprintf( cErrorBuffer, "broadcast or multicast or ether host %x:%x:%x:%x:%x:%x",
ipLOCAL_MAC_ADDRESS[ 0 ], ipLOCAL_MAC_ADDRESS[ 1 ], ipLOCAL_MAC_ADDRESS[ 2 ], ipLOCAL_MAC_ADDRESS[ 3 ], ipLOCAL_MAC_ADDRESS[ 4 ], ipLOCAL_MAC_ADDRESS[ 5 ] );
ulNetMask = ( configNET_MASK3 << 24UL ) | ( configNET_MASK2 << 16UL ) | ( configNET_MASK1 << 8L ) | configNET_MASK0;
if( pcap_compile( pxOpenedInterfaceHandle, &xFilterCode, cErrorBuffer, 1, ulNetMask ) < 0 )
{
printf( "\nThe packet filter string is invalid\n" );
}
else
{
if( pcap_setfilter( pxOpenedInterfaceHandle, &xFilterCode ) < 0 )
{
printf( "\nAn error occurred setting the packet filter.\n" );
}
/* When pcap_compile() succeeds, it allocates memory for the memory pointed to by the bpf_program struct
* parameter.pcap_freecode() will free that memory. */
pcap_freecode( &xFilterCode );
}
/* Create the buffers used to pass packets between the FreeRTOS simulator
* and the Win32 threads that are handling WinPCAP. */
prvCreateThreadSafeBuffers();
if( pvSendEvent == NULL )
{
/* Create event used to signal the Win32 WinPCAP Tx thread. */
pvSendEvent = CreateEvent( NULL, FALSE, TRUE, NULL );
/* Create the Win32 thread that handles WinPCAP Rx. */
vWinPcapRecvThreadHandle = CreateThread(
NULL, /* Pointer to thread security attributes. */
0, /* Initial thread stack size, in bytes. */
prvWinPcapRecvThread, /* Pointer to thread function. */
NULL, /* Argument for new thread. */
0, /* Creation flags. */
NULL );
/* Use the cores that are not used by the FreeRTOS tasks. */
SetThreadAffinityMask( vWinPcapRecvThreadHandle, ~0x01u );
/* Create the Win32 thread that handlers WinPCAP Tx. */
vWinPcapSendThreadHandle = CreateThread(
NULL, /* Pointer to thread security attributes. */
0, /* initial thread stack size, in bytes. */
prvWinPcapSendThread, /* Pointer to thread function. */
NULL, /* Argument for new thread. */
0, /* Creation flags. */
NULL );
/* Use the cores that are not used by the FreeRTOS tasks. */
SetThreadAffinityMask( vWinPcapSendThreadHandle, ~0x01u );
/* Create a task that simulates an interrupt in a real system. This will
* block waiting for packets, then send a message to the IP task when data
* is available. */
xTaskCreate( prvInterruptSimulatorTask, "MAC_ISR", configMINIMAL_STACK_SIZE, NULL, configMAC_ISR_SIMULATOR_PRIORITY, NULL );
}
}
/*-----------------------------------------------------------*/
/* WinPCAP function. */
void pcap_callback( u_char * user,
const struct pcap_pkthdr * pkt_header,
const u_char * pkt_data )
{
( void ) user;
/* THIS IS CALLED FROM A WINDOWS THREAD - DO NOT ATTEMPT ANY FREERTOS CALLS
* OR TO PRINT OUT MESSAGES HERE. */
/* Pass data to the FreeRTOS simulator on a thread safe circular buffer. */
if( ( pkt_header->caplen <= ( ipconfigNETWORK_MTU + ipSIZE_OF_ETH_HEADER ) ) &&
( uxStreamBufferGetSpace( xRecvBuffer ) >= ( ( ( size_t ) pkt_header->caplen ) + sizeof( *pkt_header ) ) ) )
{
/* The received packets will be written to a C source file,
* only if 'ipconfigUSE_DUMP_PACKETS' is defined.
* Otherwise, there is no action. */
iptraceDUMP_PACKET( ( const uint8_t * ) pkt_data, ( size_t ) pkt_header->caplen, pdTRUE );
/* NOTE. The prvStreamBufferAdd function is used here in place of
* uxStreamBufferAdd since the uxStreamBufferAdd call will suspend
* the FreeRTOS scheduler to atomically update the head and front
* of the stream buffer. Since xRecvBuffer is being used as a regular
* circular buffer (i.e. only the head and tail are needed), this call
* only updates the head of the buffer, removing the need to suspend
* the scheduler, and allowing this function to be safely called from
* a Windows thread. */
prvStreamBufferAdd( xRecvBuffer, ( const uint8_t * ) pkt_header, sizeof( *pkt_header ) );
prvStreamBufferAdd( xRecvBuffer, ( const uint8_t * ) pkt_data, ( size_t ) pkt_header->caplen );
}
}
/*-----------------------------------------------------------*/
DWORD WINAPI prvWinPcapRecvThread( void * pvParam )
{
( void ) pvParam;
/* THIS IS A WINDOWS THREAD - DO NOT ATTEMPT ANY FREERTOS CALLS OR TO PRINT
* OUT MESSAGES HERE. */
for( ; ; )
{
pcap_dispatch( pxOpenedInterfaceHandle, 1, pcap_callback, ( u_char * ) "mydata" );
}
}
/*-----------------------------------------------------------*/
DWORD WINAPI prvWinPcapSendThread( void * pvParam )
{
size_t xLength;
uint8_t ucBuffer[ ipconfigNETWORK_MTU + ipSIZE_OF_ETH_HEADER ];
static char cErrorMessage[ 1024 ];
const DWORD xMaxMSToWait = 1000;
/* THIS IS A WINDOWS THREAD - DO NOT ATTEMPT ANY FREERTOS CALLS OR TO PRINT
* OUT MESSAGES HERE. */
/* Remove compiler warnings about unused parameters. */
( void ) pvParam;
for( ; ; )
{
/* Wait until notified of something to send. */
WaitForSingleObject( pvSendEvent, xMaxMSToWait );
/* Is there more than the length value stored in the circular buffer
* used to pass data from the FreeRTOS simulator into this Win32 thread? */
while( uxStreamBufferGetSize( xSendBuffer ) > sizeof( xLength ) )
{
uxStreamBufferGet( xSendBuffer, 0, ( uint8_t * ) &xLength, sizeof( xLength ), pdFALSE );
uxStreamBufferGet( xSendBuffer, 0, ( uint8_t * ) ucBuffer, xLength, pdFALSE );
/* The packets sent will be written to a C source file,
* only if 'ipconfigUSE_DUMP_PACKETS' is defined.
* Otherwise, there is no action. */
iptraceDUMP_PACKET( ucBuffer, xLength, pdFALSE );
if( pcap_sendpacket( pxOpenedInterfaceHandle, ucBuffer, xLength ) != 0 )
{
ulWinPCAPSendFailures++;
}
}
}
}
/*-----------------------------------------------------------*/
static BaseType_t xPacketBouncedBack( const uint8_t * pucBuffer )
{
EthernetHeader_t * pxEtherHeader;
BaseType_t xResult;
pxEtherHeader = ( EthernetHeader_t * ) pucBuffer;
/* Sometimes, packets are bounced back by the driver and we need not process them. Check
* whether this packet is one such packet. */
if( memcmp( ipLOCAL_MAC_ADDRESS, pxEtherHeader->xSourceAddress.ucBytes, ipMAC_ADDRESS_LENGTH_BYTES ) == 0 )
{
xResult = pdTRUE;
}
else
{
xResult = pdFALSE;
}
return xResult;
}
/*-----------------------------------------------------------*/
static void prvInterruptSimulatorTask( void * pvParameters )
{
struct pcap_pkthdr xHeader;
static struct pcap_pkthdr * pxHeader;
const uint8_t * pucPacketData;
uint8_t ucRecvBuffer[ ipconfigNETWORK_MTU + ipSIZE_OF_ETH_HEADER ];
NetworkBufferDescriptor_t * pxNetworkBuffer;
IPStackEvent_t xRxEvent = { eNetworkRxEvent, NULL };
eFrameProcessingResult_t eResult;
/* Remove compiler warnings about unused parameters. */
( void ) pvParameters;
for( ; ; )
{
/* Does the circular buffer used to pass data from the Win32 thread that
* handles WinPCAP Rx into the FreeRTOS simulator contain another packet? */
if( uxStreamBufferGetSize( xRecvBuffer ) > sizeof( xHeader ) )
{
/* Get the next packet. */
uxStreamBufferGet( xRecvBuffer, 0, ( uint8_t * ) &xHeader, sizeof( xHeader ), pdFALSE );
uxStreamBufferGet( xRecvBuffer, 0, ( uint8_t * ) ucRecvBuffer, ( size_t ) xHeader.len, pdFALSE );
pucPacketData = ucRecvBuffer;
pxHeader = &xHeader;
iptraceNETWORK_INTERFACE_RECEIVE();
/* Check for minimal size. */
if( pxHeader->len >= sizeof( EthernetHeader_t ) )
{
eResult = ipCONSIDER_FRAME_FOR_PROCESSING( pucPacketData );
}
else
{
eResult = eReleaseBuffer;
}
if( eResult == eProcessBuffer )
{
/* Will the data fit into the frame buffer? */
if( pxHeader->len <= ipTOTAL_ETHERNET_FRAME_SIZE )
{
/* Obtain a buffer into which the data can be placed. This
* is only an interrupt simulator, not a real interrupt, so it
* is ok to call the task level function here, but note that
* some buffer implementations cannot be called from a real
* interrupt. */
if( xPacketBouncedBack( pucPacketData ) == pdFALSE )
{
pxNetworkBuffer = pxGetNetworkBufferWithDescriptor( pxHeader->len, 0 );
}
else
{
pxNetworkBuffer = NULL;
}
if( pxNetworkBuffer != NULL )
{
memcpy( pxNetworkBuffer->pucEthernetBuffer, pucPacketData, pxHeader->len );
pxNetworkBuffer->xDataLength = ( size_t ) pxHeader->len;
#if ( niDISRUPT_PACKETS == 1 )
{
pxNetworkBuffer = vRxFaultInjection( pxNetworkBuffer, pucPacketData );
}
#endif /* niDISRUPT_PACKETS */
if( pxNetworkBuffer != NULL )
{
xRxEvent.pvData = ( void * ) pxNetworkBuffer;
/* Data was received and stored. Send a message to
* the IP task to let it know. */
if( xSendEventStructToIPTask( &xRxEvent, ( TickType_t ) 0 ) == pdFAIL )
{
/* The buffer could not be sent to the stack so
* must be released again. This is only an
* interrupt simulator, not a real interrupt, so it
* is ok to use the task level function here, but
* note no all buffer implementations will allow
* this function to be executed from a real
* interrupt. */
vReleaseNetworkBufferAndDescriptor( pxNetworkBuffer );
iptraceETHERNET_RX_EVENT_LOST();
}
}
else
{
/* The packet was already released or stored inside
* vRxFaultInjection(). Don't release it here. */
}
}
else
{
iptraceETHERNET_RX_EVENT_LOST();
}
}
else
{
/* Log that a packet was dropped because it would have
* overflowed the buffer, but there may be more buffers to
* process. */
}
}
}
else
{
/* There is no real way of simulating an interrupt. Make sure
* other tasks can run. */
vTaskDelay( configWINDOWS_MAC_INTERRUPT_SIMULATOR_DELAY );
}
}
}
/*-----------------------------------------------------------*/
static const char * prvRemoveSpaces( char * pcBuffer,
int aBuflen,
const char * pcMessage )
{
char * pcTarget = pcBuffer;
/* Utility function used to format messages being printed only. */
while( ( *pcMessage != 0 ) && ( pcTarget < ( pcBuffer + aBuflen - 1 ) ) )
{
*( pcTarget++ ) = *pcMessage;
if( isspace( *pcMessage ) != pdFALSE )
{
while( isspace( *pcMessage ) != pdFALSE )
{
pcMessage++;
}
}
else
{
pcMessage++;
}
}
*pcTarget = '\0';
return pcBuffer;
}
#define BUFFER_SIZE ( ipTOTAL_ETHERNET_FRAME_SIZE + ipBUFFER_PADDING )
#define BUFFER_SIZE_ROUNDED_UP ( ( BUFFER_SIZE + 7 ) & ~0x07UL )
void vNetworkInterfaceAllocateRAMToBuffers( NetworkBufferDescriptor_t pxNetworkBuffers[ ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS ] )
{
static uint8_t * pucNetworkPacketBuffers = NULL;
size_t uxIndex;
if( pucNetworkPacketBuffers == NULL )
{
pucNetworkPacketBuffers = ( uint8_t * ) malloc( ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS * BUFFER_SIZE_ROUNDED_UP );
}
if( pucNetworkPacketBuffers == NULL )
{
FreeRTOS_printf( ( "Failed to allocate memory for pxNetworkBuffers" ) );
configASSERT( 0 );
}
else
{
for(uxIndex = 0; uxIndex < ipconfigNUM_NETWORK_BUFFER_DESCRIPTORS; uxIndex++)
{
size_t uxOffset = uxIndex * BUFFER_SIZE_ROUNDED_UP;
NetworkBufferDescriptor_t ** ppDescriptor;
/* At the beginning of each pbuff is a pointer to the relevant descriptor */
ppDescriptor = ( NetworkBufferDescriptor_t ** ) &( pucNetworkPacketBuffers[ uxOffset ] );
/* Set this pointer to the address of the correct descriptor */
*ppDescriptor = &( pxNetworkBuffers[ uxIndex ] );
/* pucEthernetBuffer is set to point ipBUFFER_PADDING bytes in from the
* beginning of the allocated buffer. */
pxNetworkBuffers[ uxIndex ].pucEthernetBuffer = &( pucNetworkPacketBuffers[ uxOffset + ipBUFFER_PADDING ] );
}
}
}

View File

@ -0,0 +1,185 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/* Standard includes. */
#include <stdio.h>
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#include "task.h"
/* TCP/IP stack includes. */
#include "FreeRTOS_IP.h"
#include "FreeRTOS_Sockets.h"
/*-----------------------------------------------------------*/
#if ( ipconfigUSE_LLMNR != 0 ) || ( ipconfigUSE_NBNS != 0 ) || ( ipconfigDHCP_REGISTER_HOSTNAME == 1 )
const char * pcApplicationHostnameHook( void )
{
/* Assign the name "FreeRTOS" to this network node. This function will
* be called during the DHCP: the machine will be registered with an IP
* address plus this name. */
return "FreeRTOSWinSim";
}
#endif
/*-----------------------------------------------------------*/
#if ( ipconfigUSE_LLMNR != 0 ) || ( ipconfigUSE_NBNS != 0 )
BaseType_t xApplicationDNSQueryHook( const char * pcName )
{
BaseType_t xReturn;
/* Determine if a name lookup is for this node. Two names are given
* to this node: that returned by pcApplicationHostnameHook() and that set
* by mainDEVICE_NICK_NAME. */
if( _stricmp( pcName, pcApplicationHostnameHook() ) == 0 )
{
xReturn = pdPASS;
}
else if( _stricmp( pcName, mainDEVICE_NICK_NAME ) == 0 )
{
xReturn = pdPASS;
}
else
{
xReturn = pdFAIL;
}
return xReturn;
}
#endif /* if ( ipconfigUSE_LLMNR != 0 ) || ( ipconfigUSE_NBNS != 0 ) */
/*
* Set *pulNumber to a random number, and return pdTRUE. When the random number
* generator is broken, it shall return pdFALSE.
*/
BaseType_t xApplicationGetRandomNumber( uint32_t * pulNumber )
{
*pulNumber = ( uint32_t ) uxRand();
return pdTRUE;
}
/*-----------------------------------------------------------*/
/*
* Callback that provides the inputs necessary to generate a randomized TCP
* Initial Sequence Number per RFC 6528. THIS IS ONLY A DUMMY IMPLEMENTATION
* THAT RETURNS A PSEUDO RANDOM NUMBER SO IS NOT INTENDED FOR USE IN PRODUCTION
* SYSTEMS.
*/
uint32_t ulApplicationGetNextSequenceNumber( uint32_t ulSourceAddress,
uint16_t usSourcePort,
uint32_t ulDestinationAddress,
uint16_t usDestinationPort )
{
( void ) ulSourceAddress;
( void ) usSourcePort;
( void ) ulDestinationAddress;
( void ) usDestinationPort;
return ( uint32_t ) uxRand();
}
/* Called by FreeRTOS+TCP when the network connects or disconnects. Disconnect
* events are only received if implemented in the MAC driver. */
void vApplicationIPNetworkEventHook( eIPCallbackEvent_t eNetworkEvent )
{
uint32_t ulIPAddress, ulNetMask, ulGatewayAddress, ulDNSServerAddress;
char cBuffer[ 16 ];
static BaseType_t xTasksAlreadyCreated = pdFALSE;
/* If the network has just come up...*/
if( eNetworkEvent == eNetworkUp )
{
/* Print out the network configuration, which may have come from a DHCP
* server. */
FreeRTOS_GetAddressConfiguration( &ulIPAddress, &ulNetMask, &ulGatewayAddress, &ulDNSServerAddress );
FreeRTOS_inet_ntoa( ulIPAddress, cBuffer );
FreeRTOS_printf( ( "\r\n\r\nIP Address: %s\r\n", cBuffer ) );
FreeRTOS_inet_ntoa( ulNetMask, cBuffer );
FreeRTOS_printf( ( "Subnet Mask: %s\r\n", cBuffer ) );
FreeRTOS_inet_ntoa( ulGatewayAddress, cBuffer );
FreeRTOS_printf( ( "Gateway Address: %s\r\n", cBuffer ) );
FreeRTOS_inet_ntoa( ulDNSServerAddress, cBuffer );
FreeRTOS_printf( ( "DNS Server Address: %s\r\n\r\n\r\n", cBuffer ) );
}
}
/*-----------------------------------------------------------*/
void vPlatformInitIpStack( void )
{
BaseType_t xResult;
uint8_t ucIPAddress[ 4 ];
uint8_t ucNetMask[ 4 ] = { configNET_MASK0, configNET_MASK1, configNET_MASK2, configNET_MASK3 };
uint8_t ucMACAddress[ 6 ];
uint8_t ucDNSServerAddress[ 4 ];
uint8_t ucGatewayAddress[ 4 ];
ucMACAddress[ 0 ] = configMAC_ADDR0;
ucMACAddress[ 1 ] = configMAC_ADDR1;
ucMACAddress[ 2 ] = configMAC_ADDR2;
ucMACAddress[ 3 ] = configMAC_ADDR3;
ucMACAddress[ 4 ] = configMAC_ADDR4;
ucMACAddress[ 5 ] = configMAC_ADDR5;
ucIPAddress[ 0 ] = configIP_ADDR0;
ucIPAddress[ 1 ] = configIP_ADDR1;
ucIPAddress[ 2 ] = configIP_ADDR2;
ucIPAddress[ 3 ] = configIP_ADDR3;
ucDNSServerAddress[ 0 ] = configDNS_SERVER_ADDR0;
ucDNSServerAddress[ 1 ] = configDNS_SERVER_ADDR1;
ucDNSServerAddress[ 2 ] = configDNS_SERVER_ADDR2;
ucDNSServerAddress[ 3 ] = configDNS_SERVER_ADDR3;
ucGatewayAddress[ 0 ] = configGATEWAY_ADDR0;
ucGatewayAddress[ 1 ] = configGATEWAY_ADDR1;
ucGatewayAddress[ 2 ] = configGATEWAY_ADDR2;
ucGatewayAddress[ 3 ] = configGATEWAY_ADDR3;
xResult = FreeRTOS_IPInit( ucIPAddress, ucNetMask, ucGatewayAddress, ucDNSServerAddress, ucMACAddress );
configASSERT( xResult == pdTRUE );
}
/*-----------------------------------------------------------*/
BaseType_t xPlatformIsNetworkUp( void )
{
return FreeRTOS_IsNetworkUp();
}
/*-----------------------------------------------------------*/

View File

@ -0,0 +1,176 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>17.0</VCProjectVersion>
<ProjectGuid>{72C209C4-49A4-4942-A201-44706C9D77EC}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
<RootNamespace>FreeRTOS-Kernel</RootNamespace>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<IncludePath>$(VC_IncludePath);$(WindowsSDK_IncludePath);$(IncludePath)</IncludePath>
<SourcePath>..\..\..\FreeRTOS\Source;$(SourcePath)</SourcePath>
<PublicModuleDirectories>..\..\..\FreeRTOS\Source;..\..\..\FreeRTOS\Source\include;..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\portable\MemMang;$(PublicModuleDirectories)</PublicModuleDirectories>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>true</LinkIncremental>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<IncludePath>$(VC_IncludePath);$(WindowsSDK_IncludePath);$(IncludePath)</IncludePath>
<SourcePath>..\..\..\FreeRTOS\Source;$(SourcePath)</SourcePath>
<PublicModuleDirectories>..\..\..\FreeRTOS\Source;..\..\..\FreeRTOS\Source\include;..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\portable\MemMang;$(PublicModuleDirectories)</PublicModuleDirectories>
</PropertyGroup>
<PropertyGroup>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<PublicIncludeDirectories>..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\include;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<IncludePath>$(VC_IncludePath);$(WindowsSDK_IncludePath);$(IncludePath)</IncludePath>
<SourcePath>..\..\..\FreeRTOS\Source;$(SourcePath)</SourcePath>
<PublicModuleDirectories>..\..\..\FreeRTOS\Source;..\..\..\FreeRTOS\Source\include;..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\portable\MemMang;$(PublicModuleDirectories)</PublicModuleDirectories>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<IncludePath>$(VC_IncludePath);$(WindowsSDK_IncludePath);$(IncludePath)</IncludePath>
<SourcePath>..\..\..\FreeRTOS\Source;$(SourcePath)</SourcePath>
<PublicModuleDirectories>..\..\..\FreeRTOS\Source;..\..\..\FreeRTOS\Source\include;..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\portable\MemMang;$(PublicModuleDirectories)</PublicModuleDirectories>
</PropertyGroup>
<PropertyGroup Label="Vcpkg">
<VcpkgEnabled>false</VcpkgEnabled>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<Optimization>Disabled</Optimization>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<Link>
<TargetMachine>MachineX86</TargetMachine>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup>
<ClCompile>
<AdditionalIncludeDirectories>..\..\..\FreeRTOS\Source\portable\MSVC-MingW;..\..\..\FreeRTOS\Source\include;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Release|x64'">_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
</ItemDefinitionGroup>
<ItemGroup>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\atomic.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\deprecated_definitions.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\event_groups.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\FreeRTOS.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\list.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\message_buffer.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\mpu_prototypes.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\mpu_wrappers.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\portable.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\projdefs.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\queue.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\semphr.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\StackMacros.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\stack_macros.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\stream_buffer.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\task.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\include\timers.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\portable\MSVC-MingW\portmacro.h" />
<ClInclude Include="FreeRTOSConfig.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\..\FreeRTOS\Source\event_groups.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\list.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\portable\MemMang\heap_4.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\portable\MSVC-MingW\port.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\queue.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\stream_buffer.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\tasks.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\timers.c" />
<ClCompile Include="freertos_hooks_winsim.c" />
<ClCompile Include="runtime_stats_winsim.c" />
</ItemGroup>
<ItemGroup>
<None Include="..\..\..\FreeRTOS\Source\include\stdint.readme" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,95 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="include">
<UniqueIdentifier>{03334b83-3266-4cf4-9640-4962e653bdba}</UniqueIdentifier>
</Filter>
<Filter Include="Kernel">
<UniqueIdentifier>{7eca6f04-3532-407e-990c-0ec553526fea}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\list.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\message_buffer.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\mpu_prototypes.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\mpu_wrappers.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\portable.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\projdefs.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\queue.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\semphr.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\stack_macros.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\StackMacros.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\stream_buffer.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\task.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\timers.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\atomic.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\deprecated_definitions.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\event_groups.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="..\..\..\FreeRTOS\Source\include\FreeRTOS.h">
<Filter>include</Filter>
</ClInclude>
<ClInclude Include="FreeRTOSConfig.h" />
<ClInclude Include="..\..\..\FreeRTOS\Source\portable\MSVC-MingW\portmacro.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\..\FreeRTOS\Source\list.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\queue.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\stream_buffer.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\tasks.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\timers.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\event_groups.c">
<Filter>Kernel</Filter>
</ClCompile>
<ClCompile Include="..\..\..\FreeRTOS\Source\portable\MemMang\heap_4.c" />
<ClCompile Include="..\..\..\FreeRTOS\Source\portable\MSVC-MingW\port.c" />
<ClCompile Include="freertos_hooks_winsim.c" />
<ClCompile Include="runtime_stats_winsim.c" />
</ItemGroup>
<ItemGroup>
<None Include="..\..\..\FreeRTOS\Source\include\stdint.readme">
<Filter>include</Filter>
</None>
</ItemGroup>
</Project>

View File

@ -0,0 +1,228 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
#ifndef FREERTOS_CONFIG_H
#define FREERTOS_CONFIG_H
#include <stdint.h>
/*-----------------------------------------------------------
* Application specific definitions.
*
* These definitions should be adjusted for your particular hardware and
* application requirements.
*
* THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE
* FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE.
* https://www.FreeRTOS.org/a00110.html
*
* The bottom of this file contains some constants specific to running the UDP
* stack in this demo. Constants specific to FreeRTOS+TCP itself (rather than
* the demo) are contained in FreeRTOSIPConfig.h.
*----------------------------------------------------------*/
#define configUSE_PREEMPTION 1
#define configUSE_PORT_OPTIMISED_TASK_SELECTION 1
#define configMAX_PRIORITIES ( 32 )
#define configTICK_RATE_HZ ( 1000 ) /* In this non-real time simulated environment the tick frequency has to be at least a multiple of the Win32 tick frequency, and therefore very slow. */
#define configMINIMAL_STACK_SIZE ( ( unsigned short ) 60 ) /* In this simulated case, the stack only has to hold one small structure as the real stack is part of the Win32 thread. */
#define configTOTAL_HEAP_SIZE ( ( size_t ) ( 2048U * 1024U ) )
#define configMAX_TASK_NAME_LEN ( 15 )
#define configUSE_TRACE_FACILITY 1
#define configUSE_16_BIT_TICKS 0
#define configIDLE_SHOULD_YIELD 1
#define configUSE_MUTEXES 1
#define configUSE_RECURSIVE_MUTEXES 1
#define configQUEUE_REGISTRY_SIZE 0
#define configUSE_APPLICATION_TASK_TAG 0
#define configUSE_COUNTING_SEMAPHORES 1
#define configUSE_ALTERNATIVE_API 0
#define configNUM_THREAD_LOCAL_STORAGE_POINTERS 8
#define configENABLE_BACKWARD_COMPATIBILITY 1
#define configSUPPORT_STATIC_ALLOCATION 1
/* Hook function related definitions. */
#define configUSE_TICK_HOOK 0
#define configUSE_IDLE_HOOK 0
#define configUSE_MALLOC_FAILED_HOOK 0
#define configCHECK_FOR_STACK_OVERFLOW 0 /* Not applicable to the Win32 port. */
/* Software timer related definitions. */
#define configUSE_TIMERS 1
#define configTIMER_TASK_PRIORITY ( configMAX_PRIORITIES - 1 )
#define configTIMER_QUEUE_LENGTH 5
#define configTIMER_TASK_STACK_DEPTH ( configMINIMAL_STACK_SIZE * 2 )
/* Event group related definitions. */
#define configUSE_EVENT_GROUPS 1
/* Set the following definitions to 1 to include the API function, or zero
* to exclude the API function. */
#define INCLUDE_vTaskPrioritySet 1
#define INCLUDE_uxTaskPriorityGet 1
#define INCLUDE_vTaskDelete 1
#define INCLUDE_vTaskCleanUpResources 1
#define INCLUDE_vTaskSuspend 1
#define INCLUDE_vTaskDelayUntil 1
#define INCLUDE_vTaskDelay 1
#define INCLUDE_uxTaskGetStackHighWaterMark 1
#define INCLUDE_xTaskGetSchedulerState 1
#define INCLUDE_xTimerGetTimerTaskHandle 1
#define INCLUDE_xTaskGetIdleTaskHandle 1
#define INCLUDE_xQueueGetMutexHolder 1
#define INCLUDE_eTaskGetState 1
#define INCLUDE_xEventGroupSetBitsFromISR 1
#define INCLUDE_xTimerPendFunctionCall 1
#define INCLUDE_pcTaskGetTaskName 1
#define INCLUDE_xTaskGetCurrentTaskHandle 1
/* This demo makes use of one or more example stats formatting functions. These
* format the raw data provided by the uxTaskGetSystemState() function in to human
* readable ASCII form. See the notes in the implementation of vTaskList() within
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
* is set to 2 so the formatting functions are included without the stdio.h being
* included in tasks.c. That is because this project defines its own sprintf()
* functions. */
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
/* Assert call defined for debug builds. */
#ifdef _DEBUG
extern void vAssertCalled( const char * pcFile,
uint32_t ulLine );
#define configASSERT( x ) if( ( x ) == 0 ) vAssertCalled( __FILE__, __LINE__ )
#endif /* _DEBUG */
/* Run time stats gathering definitions. */
unsigned long ulGetRunTimeCounterValue( void );
void vConfigureTimerForRunTimeStats( void );
#define configGENERATE_RUN_TIME_STATS 1
#define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS() vConfigureTimerForRunTimeStats()
#define portGET_RUN_TIME_COUNTER_VALUE() ulGetRunTimeCounterValue()
/* Application specific definitions follow. **********************************/
/* Only used when running in the FreeRTOS Windows simulator. Defines the
* priority of the task used to simulate Ethernet interrupts. */
#define configMAC_ISR_SIMULATOR_PRIORITY ( configMAX_PRIORITIES - 1 )
/* This demo creates a virtual network connection by accessing the raw Ethernet
* or WiFi data to and from a real network connection. Many computers have more
* than one real network port, and configNETWORK_INTERFACE_TO_USE is used to tell
* the demo which real port should be used to create the virtual port. The ports
* available are displayed on the console when the application is executed. For
* example, on my development laptop setting configNETWORK_INTERFACE_TO_USE to 4
* results in the wired network being used, while setting
* configNETWORK_INTERFACE_TO_USE to 2 results in the wireless network being
* used. */
#define configNETWORK_INTERFACE_TO_USE ( 1L )
/* The address to which logging is sent should UDP logging be enabled. */
#define configUDP_LOGGING_ADDR0 192
#define configUDP_LOGGING_ADDR1 168
#define configUDP_LOGGING_ADDR2 0
#define configUDP_LOGGING_ADDR3 11
/* Default MAC address configuration. The demo creates a virtual network
* connection that uses this MAC address by accessing the raw Ethernet/WiFi data
* to and from a real network connection on the host PC. See the
* configNETWORK_INTERFACE_TO_USE definition above for information on how to
* configure the real network connection to use. */
#define configMAC_ADDR0 0x00
#define configMAC_ADDR1 0x11
#define configMAC_ADDR2 0x11
#define configMAC_ADDR3 0x11
#define configMAC_ADDR4 0x11
#define configMAC_ADDR5 0x41
/* Default IP address configuration. Used in ipconfigUSE_DNS is set to 0, or
* ipconfigUSE_DNS is set to 1 but a DNS server cannot be contacted. */
#define configIP_ADDR0 10
#define configIP_ADDR1 10
#define configIP_ADDR2 10
#define configIP_ADDR3 200
/* Default gateway IP address configuration. Used in ipconfigUSE_DNS is set to
* 0, or ipconfigUSE_DNS is set to 1 but a DNS server cannot be contacted. */
#define configGATEWAY_ADDR0 10
#define configGATEWAY_ADDR1 10
#define configGATEWAY_ADDR2 10
#define configGATEWAY_ADDR3 1
/* Default DNS server configuration. OpenDNS addresses are 208.67.222.222 and
* 208.67.220.220. Used in ipconfigUSE_DNS is set to 0, or ipconfigUSE_DNS is set
* to 1 but a DNS server cannot be contacted.*/
#define configDNS_SERVER_ADDR0 208
#define configDNS_SERVER_ADDR1 67
#define configDNS_SERVER_ADDR2 222
#define configDNS_SERVER_ADDR3 222
/* Default netmask configuration. Used in ipconfigUSE_DNS is set to 0, or
* ipconfigUSE_DNS is set to 1 but a DNS server cannot be contacted. */
#define configNET_MASK0 255
#define configNET_MASK1 0
#define configNET_MASK2 0
#define configNET_MASK3 0
/* The UDP port to which print messages are sent. */
#define configPRINT_PORT ( 15000 )
#if ( defined( _MSC_VER ) && ( _MSC_VER <= 1600 ) && !defined( snprintf ) )
/* Map to Windows names. */
#define snprintf _snprintf
#define vsnprintf _vsnprintf
#endif
/* Visual studio does not have an implementation of strcasecmp(). */
#define strcasecmp _stricmp
#define strncasecmp _strnicmp
#define strcmpi _strcmpi
/* Prototype for the function used to print out. In this case it prints to the
* console before the network is connected then a UDP port after the network has
* connected. */
extern void vLoggingPrintf( const char * pcFormatString,
... );
#define configPRINTF( X ) vLoggingPrintf X
#define portNOP() __nop()
/* The UDP port to use for incoming command inputs. The outgoing port is
set to ( configUDP_CLI_PORT_NUMBER + 1 ). */
#define configUDP_CLI_PORT_NUMBER 5001
/* The size of the global output buffer that is available for use when there
are multiple command interpreters running at once (for example, one on a UART
and one on TCP/IP). This is done to prevent an output buffer being defined by
each implementation - which would waste RAM. In this case, there is only one
command interpreter running, and it has its own local output buffer, so the
global buffer is just set to be one byte long as it is not used and should not
take up unnecessary RAM. */
#define configCOMMAND_INT_MAX_OUTPUT_SIZE 1
#endif /* FREERTOS_CONFIG_H */

View File

@ -0,0 +1,283 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/* Standard includes. */
#include <stdio.h>
#include <time.h>
/* Visual studio intrinsics used so the __debugbreak() function is available
* should an assert get hit. */
#include <intrin.h>
/* Windows Crypt api for uxRand() */
#include <windows.h>
#include <wincrypt.h>
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#include "task.h"
/*-----------------------------------------------------------*/
void vAssertCalled( const char * pcFile,
uint32_t ulLine )
{
volatile uint32_t ulBlockVariable = 0UL;
volatile char * pcFileName = ( volatile char * ) pcFile;
volatile uint32_t ulLineNumber = ulLine;
( void ) pcFileName;
( void ) ulLineNumber;
printf( "vAssertCalled( %s, %u\n", pcFile, ulLine );
/* Setting ulBlockVariable to a non-zero value in the debugger will allow
* this function to be exited. */
taskENTER_CRITICAL();
{
while( ulBlockVariable == 0UL )
{
__debugbreak();
}
}
taskEXIT_CRITICAL();
}
/*-----------------------------------------------------------*/
UBaseType_t uxRand( void )
{
HCRYPTPROV hProv = 0;
BOOL xResult = 0;
UBaseType_t uxRandNum = 0U;
xResult = CryptAcquireContextA( &hProv, NULL, NULL, PROV_RSA_FULL, CRYPT_VERIFYCONTEXT );
configASSERT( xResult );
xResult = CryptGenRandom( hProv, sizeof( UBaseType_t ), ( uint8_t * ) ( &uxRandNum ) );
configASSERT( xResult );
CryptReleaseContext( hProv, 0 );
return uxRandNum;
}
/*-----------------------------------------------------------*/
#if defined( configUSE_STATIC_ALLOCATION ) && ( configUSE_STATIC_ALLOCATION == 1U )
/* configUSE_STATIC_ALLOCATION is set to 1, so the application must provide an
* implementation of vApplicationGetIdleTaskMemory() to provide the memory that is
* used by the Idle task. */
void vApplicationGetIdleTaskMemory( StaticTask_t ** ppxIdleTaskTCBBuffer,
StackType_t ** ppxIdleTaskStackBuffer,
uint32_t * pulIdleTaskStackSize )
{
/* If the buffers to be provided to the Idle task are declared inside this
* function then they must be declared static - otherwise they will be allocated on
* the stack and so not exists after this function exits. */
static StaticTask_t xIdleTaskTCB;
static StackType_t uxIdleTaskStack[ configMINIMAL_STACK_SIZE ];
/* Pass out a pointer to the StaticTask_t structure in which the Idle task's
* state will be stored. */
*ppxIdleTaskTCBBuffer = &xIdleTaskTCB;
/* Pass out the array that will be used as the Idle task's stack. */
*ppxIdleTaskStackBuffer = uxIdleTaskStack;
/* Pass out the size of the array pointed to by *ppxIdleTaskStackBuffer.
* Note that, as the array is necessarily of type StackType_t,
* configMINIMAL_STACK_SIZE is specified in words, not bytes. */
*pulIdleTaskStackSize = configMINIMAL_STACK_SIZE;
}
/*-----------------------------------------------------------*/
#if defined( configUSE_TIMERS ) && ( configUSE_TIMERS == 1U )
/* configUSE_STATIC_ALLOCATION and configUSE_TIMERS are both set to 1, so the
* application must provide an implementation of vApplicationGetTimerTaskMemory()
* to provide the memory that is used by the Timer service task. */
void vApplicationGetTimerTaskMemory( StaticTask_t ** ppxTimerTaskTCBBuffer,
StackType_t ** ppxTimerTaskStackBuffer,
uint32_t * pulTimerTaskStackSize )
{
/* If the buffers to be provided to the Timer task are declared inside this
* function then they must be declared static - otherwise they will be allocated on
* the stack and so not exists after this function exits. */
static StaticTask_t xTimerTaskTCB;
static StackType_t uxTimerTaskStack[ configTIMER_TASK_STACK_DEPTH ];
/* Pass out a pointer to the StaticTask_t structure in which the Timer
* task's state will be stored. */
*ppxTimerTaskTCBBuffer = &xTimerTaskTCB;
/* Pass out the array that will be used as the Timer task's stack. */
*ppxTimerTaskStackBuffer = uxTimerTaskStack;
/* Pass out the size of the array pointed to by *ppxTimerTaskStackBuffer.
* Note that, as the array is necessarily of type StackType_t,
* configMINIMAL_STACK_SIZE is specified in words, not bytes. */
*pulTimerTaskStackSize = configTIMER_TASK_STACK_DEPTH;
}
#endif /* defined( configUSE_TIMERS ) && ( configUSE_TIMERS == 1U ) */
#endif /* defined( configUSE_STATIC_ALLOCATION ) && ( configUSE_STATIC_ALLOCATION == 1U ) */
/*-----------------------------------------------------------*/
#if( configUSE_MALLOC_FAILED_HOOK == 1U )
void vApplicationMallocFailedHook( void )
{
/*
* vApplicationMallocFailedHook() will only be called if
* configUSE_MALLOC_FAILED_HOOK is set to 1 in FreeRTOSConfig.h. It is a hook
* function that will get called if a call to pvPortMalloc() fails.
* pvPortMalloc() is called internally by the kernel whenever a task, queue,
* timer or semaphore is created. It is also called by various parts of the
* demo application. If heap_1.c, heap_2.c or heap_4.c is being used, then the
* size of the heap available to pvPortMalloc() is defined by
* configTOTAL_HEAP_SIZE in FreeRTOSConfig.h, and the xPortGetFreeHeapSize()
* API function can be used to query the size of free heap space that remains
* (although it does not provide information on how the remaining heap might be
* fragmented). See http://www.freertos.org/a00111.html for more
* information.
*/
vAssertCalled( __FILE__, __LINE__ );
}
#endif /* configUSE_MALLOC_FAILED_HOOK == 1U */
/*-----------------------------------------------------------*/
#if( configUSE_IDLE_HOOK == 1U )
void vApplicationIdleHook( void )
{
/*
* vApplicationIdleHook() will only be called if configUSE_IDLE_HOOK is set
* to 1 in FreeRTOSConfig.h. It will be called on each iteration of the idle
* task. It is essential that code added to this hook function never attempts
* to block in any way (for example, call xQueueReceive() with a block time
* specified, or call vTaskDelay()). If application tasks make use of the
* vTaskDelete() API function to delete themselves then it is also important
* that vApplicationIdleHook() is permitted to return to its calling function,
* because it is the responsibility of the idle task to clean up memory
* allocated by the kernel to any task that has since deleted itself.
*/
}
#endif /* configUSE_IDLE_HOOK */
/*-----------------------------------------------------------*/
#if( configUSE_TICK_HOOK == 1U )
void vApplicationTickHook( void )
{
/*
* This function will be called by each tick interrupt if
* configUSE_TICK_HOOK is set to 1 in FreeRTOSConfig.h. User code can be
* added here, but the tick hook is called from an interrupt context, so
* code must not attempt to block, and only the interrupt safe FreeRTOS API
* functions can be used (those that end in FromISR()).
*/
}
#endif /* configUSE_TICK_HOOK == 1U */
/*-----------------------------------------------------------*/
#if( configSUPPORT_STATIC_ALLOCATION == 1U )
/*
* configSUPPORT_STATIC_ALLOCATION and configUSE_TIMERS are both set to 1, so the
* application must provide an implementation of vApplicationGetTimerTaskMemory()
* to provide the memory that is used by the Timer service task.
*/
void vApplicationGetTimerTaskMemory( StaticTask_t **ppxTimerTaskTCBBuffer,
StackType_t **ppxTimerTaskStackBuffer,
uint32_t *pulTimerTaskStackSize )
{
/*
* If the buffers to be provided to the Timer task are declared inside this
* function then they must be declared static - otherwise they will be allocated on
* the stack and so not exists after this function exits.
*/
static StaticTask_t xTimerTaskTCB;
static StackType_t uxTimerTaskStack[ configTIMER_TASK_STACK_DEPTH ];
/*
* Pass out a pointer to the StaticTask_t structure in which the Timer
* task's state will be stored.
*/
*ppxTimerTaskTCBBuffer = &xTimerTaskTCB;
/* Pass out the array that will be used as the Timer task's stack. */
*ppxTimerTaskStackBuffer = uxTimerTaskStack;
/*
* Pass out the size of the array pointed to by *ppxTimerTaskStackBuffer.
* Note that, as the array is necessarily of type StackType_t,
* configMINIMAL_STACK_SIZE is specified in words, not bytes.
*/
*pulTimerTaskStackSize = configTIMER_TASK_STACK_DEPTH;
}
#endif /* configSUPPORT_STATIC_ALLOCATION == 1U */
/*-----------------------------------------------------------*/
#if( configSUPPORT_STATIC_ALLOCATION == 1U )
/*
* configSUPPORT_STATIC_ALLOCATION is set to 1, so the application must provide an
* implementation of vApplicationGetIdleTaskMemory() to provide the memory that is
* used by the Idle task.
*/
void vApplicationGetIdleTaskMemory( StaticTask_t **ppxIdleTaskTCBBuffer,
StackType_t **ppxIdleTaskStackBuffer,
uint32_t *pulIdleTaskStackSize )
{
/*
* If the buffers to be provided to the Idle task are declared inside this
* function then they must be declared static - otherwise they will be allocated on
* the stack and so not exists after this function exits.
*/
static StaticTask_t xIdleTaskTCB;
static StackType_t uxIdleTaskStack[ configMINIMAL_STACK_SIZE ];
/*
* Pass out a pointer to the StaticTask_t structure in which the Idle task's
* state will be stored.
*/
*ppxIdleTaskTCBBuffer = &xIdleTaskTCB;
/* Pass out the array that will be used as the Idle task's stack. */
*ppxIdleTaskStackBuffer = uxIdleTaskStack;
/*
* Pass out the size of the array pointed to by *ppxIdleTaskStackBuffer.
* Note that, as the array is necessarily of type StackType_t,
* configMINIMAL_STACK_SIZE is specified in words, not bytes.
*/
*pulIdleTaskStackSize = configMINIMAL_STACK_SIZE;
}
#endif /* configSUPPORT_STATIC_ALLOCATION == 1U */
/*-----------------------------------------------------------*/

View File

@ -0,0 +1,69 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/*
* Utility functions required to gather run time statistics. See:
* https://www.FreeRTOS.org/rtos-run-time-stats.html
*
* Note that this is a simulated port, where simulated time is a lot slower than
* real time, therefore the run time counter values have no real meaningful
* units.
*
* Also note that it is assumed this demo is going to be used for short periods
* of time only, and therefore timer overflows are not handled.
*/
#include <time.h>
#include <Windows.h>
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#if configGENERATE_RUN_TIME_STATS == 1
/* Time at start of day (in ns). */
static LARGE_INTEGER lStartTime;
/*-----------------------------------------------------------*/
void vConfigureTimerForRunTimeStats( void )
{
( void ) QueryPerformanceCounter( &lStartTime );
}
/*-----------------------------------------------------------*/
unsigned long ulGetRunTimeCounterValue( void )
{
LARGE_INTEGER lCurrentTime;
( void ) QueryPerformanceCounter( &lCurrentTime );
configASSERT( lCurrentTime.QuadPart > lStartTime.QuadPart );
return ( unsigned long ) ( lCurrentTime.QuadPart - lStartTime.QuadPart );
}
/*-----------------------------------------------------------*/
#endif /* configGENERATE_RUN_TIME_STATS == 1 */

View File

@ -0,0 +1,81 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.3.32819.101
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FreeRTOS+TCP", "FreeRTOS+TCP\FreeRTOS+TCP.vcxproj", "{C90E6CC5-818B-4C97-8876-0986D989387C}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "FreeRTOS-Kernel", "FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj", "{72C209C4-49A4-4942-A201-44706C9D77EC}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "MbedTLS", "MbedTLS\MbedTLS.vcxproj", "{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "coreHTTP", "coreHTTP\coreHTTP.vcxproj", "{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Logging", "Logging\Logging.vcxproj", "{BE362AC0-B10B-4276-B84E-6304652BA228}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "corePKCS11", "corePKCS11\corePKCS11.vcxproj", "{19F0FF1A-3368-491A-9932-A2F089508F51}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{C90E6CC5-818B-4C97-8876-0986D989387C}.Debug|x64.ActiveCfg = Debug|x64
{C90E6CC5-818B-4C97-8876-0986D989387C}.Debug|x64.Build.0 = Debug|x64
{C90E6CC5-818B-4C97-8876-0986D989387C}.Debug|x86.ActiveCfg = Debug|Win32
{C90E6CC5-818B-4C97-8876-0986D989387C}.Debug|x86.Build.0 = Debug|Win32
{C90E6CC5-818B-4C97-8876-0986D989387C}.Release|x64.ActiveCfg = Release|x64
{C90E6CC5-818B-4C97-8876-0986D989387C}.Release|x64.Build.0 = Release|x64
{C90E6CC5-818B-4C97-8876-0986D989387C}.Release|x86.ActiveCfg = Release|Win32
{C90E6CC5-818B-4C97-8876-0986D989387C}.Release|x86.Build.0 = Release|Win32
{72C209C4-49A4-4942-A201-44706C9D77EC}.Debug|x64.ActiveCfg = Debug|x64
{72C209C4-49A4-4942-A201-44706C9D77EC}.Debug|x64.Build.0 = Debug|x64
{72C209C4-49A4-4942-A201-44706C9D77EC}.Debug|x86.ActiveCfg = Debug|Win32
{72C209C4-49A4-4942-A201-44706C9D77EC}.Debug|x86.Build.0 = Debug|Win32
{72C209C4-49A4-4942-A201-44706C9D77EC}.Release|x64.ActiveCfg = Release|x64
{72C209C4-49A4-4942-A201-44706C9D77EC}.Release|x64.Build.0 = Release|x64
{72C209C4-49A4-4942-A201-44706C9D77EC}.Release|x86.ActiveCfg = Release|Win32
{72C209C4-49A4-4942-A201-44706C9D77EC}.Release|x86.Build.0 = Release|Win32
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Debug|x64.ActiveCfg = Debug|x64
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Debug|x64.Build.0 = Debug|x64
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Debug|x86.ActiveCfg = Debug|Win32
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Debug|x86.Build.0 = Debug|Win32
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Release|x64.ActiveCfg = Release|x64
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Release|x64.Build.0 = Release|x64
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Release|x86.ActiveCfg = Release|Win32
{E1016F3E-94E9-4864-9FD8-1D7C1FEFBFD7}.Release|x86.Build.0 = Release|Win32
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Debug|x64.ActiveCfg = Debug|x64
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Debug|x64.Build.0 = Debug|x64
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Debug|x86.ActiveCfg = Debug|Win32
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Debug|x86.Build.0 = Debug|Win32
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Release|x64.ActiveCfg = Release|x64
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Release|x64.Build.0 = Release|x64
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Release|x86.ActiveCfg = Release|Win32
{EE39FA0F-CEFB-4C29-A571-05A28FDD47FD}.Release|x86.Build.0 = Release|Win32
{BE362AC0-B10B-4276-B84E-6304652BA228}.Debug|x64.ActiveCfg = Debug|x64
{BE362AC0-B10B-4276-B84E-6304652BA228}.Debug|x64.Build.0 = Debug|x64
{BE362AC0-B10B-4276-B84E-6304652BA228}.Debug|x86.ActiveCfg = Debug|Win32
{BE362AC0-B10B-4276-B84E-6304652BA228}.Debug|x86.Build.0 = Debug|Win32
{BE362AC0-B10B-4276-B84E-6304652BA228}.Release|x64.ActiveCfg = Release|x64
{BE362AC0-B10B-4276-B84E-6304652BA228}.Release|x64.Build.0 = Release|x64
{BE362AC0-B10B-4276-B84E-6304652BA228}.Release|x86.ActiveCfg = Release|Win32
{BE362AC0-B10B-4276-B84E-6304652BA228}.Release|x86.Build.0 = Release|Win32
{19F0FF1A-3368-491A-9932-A2F089508F51}.Debug|x64.ActiveCfg = Debug|x64
{19F0FF1A-3368-491A-9932-A2F089508F51}.Debug|x64.Build.0 = Debug|x64
{19F0FF1A-3368-491A-9932-A2F089508F51}.Debug|x86.ActiveCfg = Debug|Win32
{19F0FF1A-3368-491A-9932-A2F089508F51}.Debug|x86.Build.0 = Debug|Win32
{19F0FF1A-3368-491A-9932-A2F089508F51}.Release|x64.ActiveCfg = Release|x64
{19F0FF1A-3368-491A-9932-A2F089508F51}.Release|x64.Build.0 = Release|x64
{19F0FF1A-3368-491A-9932-A2F089508F51}.Release|x86.ActiveCfg = Release|Win32
{19F0FF1A-3368-491A-9932-A2F089508F51}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {7FF11C8F-8F21-4D4D-9881-D9D35E3F70B3}
EndGlobalSection
EndGlobal

View File

@ -0,0 +1,178 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{be362ac0-b10b-4276-b84e-6304652ba228}</ProjectGuid>
<RootNamespace>Logging</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<PublicIncludeDirectories>..\..\Source\Utilities\logging;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<PublicIncludeDirectories>..\..\Source\Utilities\logging;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<PublicIncludeDirectories>..\..\Source\Utilities\logging;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<PublicIncludeDirectories>..\..\Source\Utilities\logging;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>$(PublicIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>$(PublicIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>$(PublicIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>$(PublicIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\Utilities\logging\logging.h" />
<ClInclude Include="..\..\Source\Utilities\logging\logging_levels.h" />
<ClInclude Include="..\..\Source\Utilities\logging\logging_stack.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Demo\Common\Logging\windows\Logging_WinSim.c" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\FreeRTOS+TCP\FreeRTOS+TCP.vcxproj">
<Project>{c90e6cc5-818b-4c97-8876-0986d989387c}</Project>
<Private>false</Private>
<LinkLibraryDependencies>false</LinkLibraryDependencies>
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj">
<Project>{72c209c4-49a4-4942-a201-44706c9d77ec}</Project>
<Private>false</Private>
<LinkLibraryDependencies>false</LinkLibraryDependencies>
<UseLibraryDependencyInputs>false</UseLibraryDependencyInputs>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\Utilities\logging\logging_levels.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Utilities\logging\logging_stack.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Utilities\logging\logging.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Demo\Common\Logging\windows\Logging_WinSim.c">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
</Project>

View File

@ -0,0 +1,375 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\aes.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\aria.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\asn1.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\asn1write.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\base64.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\bignum.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\build_info.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\camellia.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ccm.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\chacha20.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\chachapoly.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\check_config.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\cipher.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\cmac.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\compat-2.x.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\config_psa.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\constant_time.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ctr_drbg.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\debug.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\des.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\dhm.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecdh.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecdsa.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecjpake.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecp.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\entropy.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\error.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\gcm.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\hkdf.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\hmac_drbg.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\mbedtls_config.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\md.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\md5.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\memory_buffer_alloc.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\net_sockets.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\nist_kw.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\oid.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pem.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pk.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pkcs12.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pkcs5.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform_time.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform_util.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\poly1305.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\private_access.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\psa_util.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ripemd160.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\rsa.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha1.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha256.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha512.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_cache.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_ciphersuites.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_cookie.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_ticket.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\threading.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\timing.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\version.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_crl.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_crt.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_csr.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_builtin_composites.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_builtin_primitives.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_compat.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_config.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_common.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_contexts_composites.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_contexts_primitives.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_extra.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_platform.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_se_driver.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_sizes.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_struct.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_types.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_values.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\aesni.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\bignum_internal.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\bn_mul.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\check_crypto_config.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\cipher_wrap.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\common.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\constant_time_internal.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\constant_time_invasive.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ecp_internal_alt.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ecp_invasive.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\entropy_poll.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\md_wrap.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_common.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_error.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_reader.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_trace.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\padlock.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\pkwrite.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\pk_wrap.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_aead.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_cipher.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_core.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_driver_wrappers.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_ecp.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_hash.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_invasive.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_its.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_mac.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_random_impl.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_rsa.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_se.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_slot_management.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_storage.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\rsa_alt_helpers.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_client.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_debug_helpers.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_misc.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_invasive.h" />
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_keys.h" />
<ClInclude Include="mbedtls_config_v3.2.1.h" />
<ClInclude Include="mbedtls_freertos_port.h" />
<ClInclude Include="threading_alt.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aes.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aesni.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aria.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\asn1parse.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\asn1write.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\base64.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\bignum.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\camellia.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ccm.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\chacha20.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\chachapoly.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cipher.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cipher_wrap.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cmac.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\constant_time.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ctr_drbg.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\debug.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\des.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\dhm.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecdh.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecdsa.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecjpake.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecp.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecp_curves.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\entropy.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\entropy_poll.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\error.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\gcm.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\hkdf.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\hmac_drbg.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\md.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\md5.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\memory_buffer_alloc.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\mps_reader.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\mps_trace.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\net_sockets.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\nist_kw.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\oid.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\padlock.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pem.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pk.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkcs12.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkcs5.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkparse.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkwrite.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pk_wrap.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\platform.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\platform_util.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\poly1305.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_aead.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_cipher.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_client.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_driver_wrappers.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_ecp.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_hash.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_mac.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_rsa.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_se.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_slot_management.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_storage.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_its_file.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ripemd160.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\rsa.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\rsa_alt_helpers.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha1.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha256.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha512.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_cache.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_ciphersuites.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_client.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_cookie.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_debug_helpers_generated.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_msg.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_ticket.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls12_client.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls12_server.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_client.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_generic.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_keys.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_server.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\threading.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\timing.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\version.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\version_features.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509write_crt.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509write_csr.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_create.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_crl.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_crt.c" />
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_csr.c" />
<ClCompile Include="mbedtls_freertos_port.c" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj">
<Project>{72c209c4-49a4-4942-a201-44706c9d77ec}</Project>
<LinkLibraryDependencies>true</LinkLibraryDependencies>
<Private>false</Private>
</ProjectReference>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{e1016f3e-94e9-4864-9fd8-1d7c1fefbfd7}</ProjectGuid>
<RootNamespace>MbedTLS</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<OutDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</OutDir>
<IntDir>build\$(ProjectName)\$(Platform)\$(Configuration)\</IntDir>
<PublicIncludeDirectories>..\..\ThirdParty\mbedtls\include;.\;$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Label="Vcpkg">
<VcpkgEnabled>false</VcpkgEnabled>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions);MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h"</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>.\;..\..\ThirdParty\mbedtls\library;..\..\ThirdParty\mbedtls\include</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions);MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h"</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>.\;..\..\ThirdParty\mbedtls\library;..\..\ThirdParty\mbedtls\include</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions);MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h"</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>.\;..\..\ThirdParty\mbedtls\library;..\..\ThirdParty\mbedtls\include</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions);MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h"</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>.\;..\..\ThirdParty\mbedtls\library;..\..\ThirdParty\mbedtls\include</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,664 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="MbedTLS Headers">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
</Filter>
<Filter Include="MbedTLS Headers\mbedtls">
<UniqueIdentifier>{d6421bca-1a38-4144-b1c3-ac3a279ac261}</UniqueIdentifier>
</Filter>
<Filter Include="MbedTLS Headers\psa">
<UniqueIdentifier>{7cf97e0d-061b-496a-a961-2ef5816190ec}</UniqueIdentifier>
</Filter>
<Filter Include="MbedTLS Source">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\compat-2.x.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pem.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\check_config.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\error.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\oid.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\build_info.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pkcs5.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ripemd160.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\debug.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\version.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecp.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\base64.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\asn1.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\memory_buffer_alloc.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_csr.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform_util.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\poly1305.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\threading.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\hkdf.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\md5.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\timing.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\chachapoly.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha256.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecdsa.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\nist_kw.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\md.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\cipher.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecjpake.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\net_sockets.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\entropy.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pkcs12.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha512.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\pk.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform_time.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\constant_time.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\camellia.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_crt.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\aes.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_cookie.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\config_psa.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\dhm.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ctr_drbg.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\chacha20.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\des.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\x509_crl.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ecdh.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\psa_util.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\sha1.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\gcm.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\rsa.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\hmac_drbg.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\private_access.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_ticket.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_ciphersuites.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ssl_cache.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\cmac.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\platform.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\bignum.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\aria.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\asn1write.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\mbedtls_config.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\mbedtls\ccm.h">
<Filter>MbedTLS Headers\mbedtls</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_se_driver.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_extra.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_builtin_composites.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_struct.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_builtin_primitives.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_contexts_primitives.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_platform.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_config.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_contexts_composites.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_sizes.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_types.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_values.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_driver_common.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\include\psa\crypto_compat.h">
<Filter>MbedTLS Headers\psa</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\aesni.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\bignum_internal.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\bn_mul.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\check_crypto_config.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\cipher_wrap.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\common.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\constant_time_internal.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\constant_time_invasive.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ecp_internal_alt.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ecp_invasive.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\entropy_poll.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\md_wrap.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_common.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_error.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_reader.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\mps_trace.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\padlock.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\pk_wrap.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\pkwrite.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_aead.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_cipher.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_core.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_driver_wrappers.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_ecp.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_hash.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_invasive.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_its.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_mac.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_random_impl.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_rsa.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_se.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_slot_management.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\psa_crypto_storage.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\rsa_alt_helpers.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_client.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_debug_helpers.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_misc.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_invasive.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_keys.h">
<Filter>MbedTLS Source</Filter>
</ClInclude>
<ClInclude Include="mbedtls_config_v3.2.1.h" />
<ClInclude Include="mbedtls_freertos_port.h" />
<ClInclude Include="threading_alt.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\timing.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\version.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\version_features.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_create.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_crl.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_crt.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509_csr.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509write_crt.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\x509write_csr.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aes.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aesni.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\aria.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\asn1parse.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\asn1write.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\base64.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\bignum.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\camellia.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ccm.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\chacha20.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\chachapoly.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cipher.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cipher_wrap.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\cmac.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\constant_time.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ctr_drbg.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\debug.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\des.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\dhm.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecdh.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecdsa.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecjpake.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecp.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ecp_curves.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\entropy.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\entropy_poll.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\error.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\gcm.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\hkdf.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\hmac_drbg.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\md.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\md5.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\memory_buffer_alloc.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\mps_reader.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\mps_trace.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\net_sockets.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\nist_kw.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\oid.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\padlock.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pem.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pk.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pk_wrap.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkcs5.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkcs12.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkparse.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\pkwrite.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\platform.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\platform_util.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\poly1305.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_aead.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_cipher.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_client.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_driver_wrappers.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_ecp.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_hash.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_mac.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_rsa.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_se.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_slot_management.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_crypto_storage.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\psa_its_file.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ripemd160.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\rsa.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\rsa_alt_helpers.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha1.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha256.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\sha512.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_cache.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_ciphersuites.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_client.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_cookie.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_debug_helpers_generated.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_msg.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_ticket.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls12_client.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls12_server.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_client.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_generic.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_keys.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\ssl_tls13_server.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="..\..\ThirdParty\mbedtls\library\threading.c">
<Filter>MbedTLS Source</Filter>
</ClCompile>
<ClCompile Include="mbedtls_freertos_port.c" />
</ItemGroup>
</Project>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,359 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
#include <stdlib.h>
#include <string.h>
#include "FreeRTOSConfig.h"
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#include "semphr.h"
/* mbed TLS includes. */
#if defined( MBEDTLS_CONFIG_FILE )
#include MBEDTLS_CONFIG_FILE
#else
#include "mbedtls/mbedtls_config.h"
#endif
#include "mbedtls/entropy.h"
#include "entropy_poll.h"
#include "mbedtls_freertos_port.h"
/*-----------------------------------------------------------*/
/**
* @brief Allocates memory for an array of members.
*
* @param[in] nmemb Number of members that need to be allocated.
* @param[in] size Size of each member.
*
* @return Pointer to the beginning of newly allocated memory.
*/
void * mbedtls_platform_calloc( size_t nmemb,
size_t size )
{
size_t totalSize = nmemb * size;
void * pBuffer = NULL;
/* Check that neither nmemb nor size were 0. */
if( totalSize > 0 )
{
/* Overflow check. */
if( ( totalSize / size ) == nmemb )
{
pBuffer = pvPortMalloc( totalSize );
if( pBuffer != NULL )
{
( void ) memset( pBuffer, 0U, totalSize );
}
}
}
return pBuffer;
}
/*-----------------------------------------------------------*/
/**
* @brief Frees the space previously allocated by calloc.
*
* @param[in] ptr Pointer to the memory to be freed.
*/
void mbedtls_platform_free( void * ptr )
{
if( ptr != NULL )
{
vPortFree( ptr );
}
}
/*-----------------------------------------------------------*/
#if defined( MBEDTLS_THREADING_C )
/**
* @brief Creates a mutex.
*
* @param[in, out] pMutex mbedtls mutex handle.
*/
static void mbedtls_platform_mutex_init( mbedtls_threading_mutex_t * pMutex )
{
configASSERT( pMutex != NULL );
#if( configSUPPORT_STATIC_ALLOCATION == 1 )
/* Create a statically-allocated FreeRTOS mutex. This should never fail as
* storage is provided. */
pMutex->mutexHandle = xSemaphoreCreateMutexStatic( &( pMutex->mutexStorage ) );
#elif( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
pMutex->mutexHandle = xSemaphoreCreateMutex();
#endif
configASSERT( pMutex->mutexHandle != NULL );
}
/*-----------------------------------------------------------*/
/**
* @brief Frees a mutex.
*
* @param[in] pMutex mbedtls mutex handle.
*
* @note This function is an empty stub as nothing needs to be done to free
* a statically allocated FreeRTOS mutex.
*/
static void mbedtls_platform_mutex_free( mbedtls_threading_mutex_t * pMutex )
{
vSemaphoreDelete( pMutex->mutexHandle );
pMutex->mutexHandle = NULL;
}
/*-----------------------------------------------------------*/
/**
* @brief Function to lock a mutex.
*
* @param[in] pMutex mbedtls mutex handle.
*
* @return 0 (success) is always returned as any other failure is asserted.
*/
static int mbedtls_platform_mutex_lock( mbedtls_threading_mutex_t * pMutex )
{
BaseType_t mutexStatus = 0;
configASSERT( pMutex != NULL );
configASSERT( pMutex->mutexHandle != NULL );
/* mutexStatus is not used if asserts are disabled. */
( void ) mutexStatus;
/* This function should never fail if the mutex is initialized. */
mutexStatus = xSemaphoreTake( pMutex->mutexHandle, portMAX_DELAY );
configASSERT( mutexStatus == pdTRUE );
return 0;
}
/*-----------------------------------------------------------*/
/**
* @brief Function to unlock a mutex.
*
* @param[in] pMutex mbedtls mutex handle.
*
* @return 0 is always returned as any other failure is asserted.
*/
static int mbedtls_platform_mutex_unlock( mbedtls_threading_mutex_t * pMutex )
{
BaseType_t mutexStatus = 0;
configASSERT( pMutex != NULL );
configASSERT( pMutex->mutexHandle != NULL );
/* mutexStatus is not used if asserts are disabled. */
( void ) mutexStatus;
/* This function should never fail if the mutex is initialized. */
mutexStatus = xSemaphoreGive( pMutex->mutexHandle );
configASSERT( mutexStatus == pdTRUE );
return 0;
}
/*-----------------------------------------------------------*/
#if defined( MBEDTLS_THREADING_ALT )
int mbedtls_platform_threading_init( void )
{
mbedtls_threading_set_alt( mbedtls_platform_mutex_init,
mbedtls_platform_mutex_free,
mbedtls_platform_mutex_lock,
mbedtls_platform_mutex_unlock );
return 0;
}
#else /* !MBEDTLS_THREADING_ALT */
void (* mbedtls_mutex_init)( mbedtls_threading_mutex_t * mutex ) = mbedtls_platform_mutex_init;
void (* mbedtls_mutex_free)( mbedtls_threading_mutex_t * mutex ) = mbedtls_platform_mutex_free;
int (* mbedtls_mutex_lock)( mbedtls_threading_mutex_t * mutex ) = mbedtls_platform_mutex_lock;
int (* mbedtls_mutex_unlock)( mbedtls_threading_mutex_t * mutex ) = mbedtls_platform_mutex_unlock;
#endif /* !MBEDTLS_THREADING_ALT */
#endif /* MBEDTLS_THREADING_C */
/*-----------------------------------------------------------*/
#if defined( MBEDTLS_ENTROPY_HARDWARE_ALT )
/* Determine which API is available */
#if defined(_WIN32)
#define RNG_SOURCE_WINDOWS_CRYPT
#elif defined(__linux__)
#include <unistd.h>
#include <sys/syscall.h>
#if defined(SYS_getrandom)
#define RNG_SOURCE_GETRANDOM
#endif /* SYS_getrandom */
#elif defined( ARM_RDI_MONITOR ) || defined( SEMIHOSTING )
#define RNG_SOURCE_SEMIHOST
#else
#define RNG_SOURCE_DEV_RANDOM
#endif
#if defined(RNG_SOURCE_WINDOWS_CRYPT)
#include <windows.h>
#include <wincrypt.h>
int mbedtls_hardware_poll( void * data,
unsigned char * output,
size_t len,
size_t * olen )
{
int lStatus = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
HCRYPTPROV hProv = 0;
/* Unferenced parameter. */
( void ) data;
/*
* This is port-specific for the Windows simulator, so just use Crypto API.
*/
if( TRUE == CryptAcquireContextA(
&hProv, NULL, NULL, PROV_RSA_FULL, CRYPT_VERIFYCONTEXT ) )
{
if( TRUE == CryptGenRandom( hProv, len, output ) )
{
lStatus = 0;
*olen = len;
}
CryptReleaseContext( hProv, 0 );
}
return lStatus;
}
#elif defined( RNG_SOURCE_GETRANDOM )
int mbedtls_hardware_poll( void * data,
unsigned char * output,
size_t len,
size_t * olen )
{
( void ) data;
int rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
configASSERT( olen != NULL );
rslt = getrandom( output, len, 0 );
if( rslt >= 0 )
{
*olen = (size_t) rslt;
rslt = 0;
}
else
{
rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
return rslt;
}
#elif defined( RNG_SOURCE_SEMIHOST )
int mbedtls_hardware_poll( void * data,
unsigned char * output,
size_t len,
size_t * olen )
{
int rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
int file;
(void) data;
configASSERT( olen != NULL );
configASSERT( output != NULL );
file = _open( "/dev/urandom", O_RDONLY );
if( file >= 0 )
{
rslt = _read( file, ( char * ) output, len );
}
if( rslt >= 0 )
{
*olen = len;
}
if( rslt >= 0 )
{
*olen = len;
rslt = 0;
}
else
{
rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
( void ) _close( file );
return rslt;
}
#else
#include <stdio.h>
int mbedtls_hardware_poll( void * data,
unsigned char * output,
size_t len,
size_t * olen )
{
int rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
FILE * file;
size_t read_length = 0U;
configASSERT( olen != NULL );
configASSERT( output != NULL );
file = fopen("/dev/urandom", "rb");
if( file != NULL )
{
rslt = fread( output, 1, len, file );
fclose( file );
}
if( rslt >= 0 )
{
*olen = len;
rslt = 0;
}
else
{
rslt = MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
return rslt;
}
#endif
#endif
/*-----------------------------------------------------------*/

View File

@ -0,0 +1,66 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/**
* @file mbedtls_freertos_port.h
* @brief mbed TLS threading functions implemented for FreeRTOS.
*/
#ifndef MBEDTLS_FREERTOS_PORT_H_
#define MBEDTLS_FREERTOS_PORT_H_
/* FreeRTOS includes. */
#include "FreeRTOS.h"
#include "semphr.h"
/**
* @brief mbed TLS mutex type definition for MBEDTLS_THREADING_C implementation.
*/
typedef struct mbedtls_threading_mutex
{
SemaphoreHandle_t mutexHandle;
#if( configSUPPORT_STATIC_ALLOCATION == 1 )
StaticSemaphore_t mutexStorage;
#endif /* configSUPPORT_STATIC_ALLOCATION == 1 */
} mbedtls_threading_mutex_t;
#if defined( MBEDTLS_THREADING_ALT )
int mbedtls_platform_threading_init( void );
#endif
int mbedtls_platform_send( void * ctx,
const unsigned char * buf,
size_t len );
int mbedtls_platform_recv( void * ctx,
unsigned char * buf,
size_t len );
void * mbedtls_platform_calloc( size_t nmemb,
size_t size );
void mbedtls_platform_free( void * ptr );
#endif /* ifndef MBEDTLS_FREERTOS_PORT_H_ */

View File

@ -0,0 +1,32 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
#ifndef __THREADING_ALT_H__
#define __THREADING_ALT_H__
#include "mbedtls_freertos_port.h"
#endif /* ifndef __THREADING_ALT_H__ */

View File

@ -0,0 +1,184 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{ee39fa0f-cefb-4c29-a571-05a28fdd47fd}</ProjectGuid>
<RootNamespace>coreHTTP</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<PublicIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories);$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<PublicIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories);$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<PublicIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories);$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<PublicIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories);$(PublicIncludeDirectories)</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Label="Vcpkg">
<VcpkgEnabled>false</VcpkgEnabled>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\Application-Protocols\coreHTTP\source\include;..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include;..\..\Source\Application-Protocols\coreHTTP\source\interface;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\core_http_client.c" />
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\api.c" />
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\http.c" />
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\llhttp.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include\llhttp.h" />
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_client.h" />
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_client_private.h" />
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_config_defaults.h" />
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\interface\transport_interface.h" />
<ClInclude Include="core_http_config.h" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj">
<Project>{72c209c4-49a4-4942-a201-44706c9d77ec}</Project>
</ProjectReference>
<ProjectReference Include="..\Logging\Logging.vcxproj">
<Project>{be362ac0-b10b-4276-b84e-6304652ba228}</Project>
<LinkLibraryDependencies>false</LinkLibraryDependencies>
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
<Private>false</Private>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,51 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="llhttp">
<UniqueIdentifier>{25550967-a280-49b0-a199-9d2d754afb4b}</UniqueIdentifier>
</Filter>
<Filter Include="coreHTTP">
<UniqueIdentifier>{be7b37ec-e95c-4fe8-8bab-707d7b545230}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\http.c">
<Filter>llhttp</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\llhttp.c">
<Filter>llhttp</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\src\api.c">
<Filter>llhttp</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\Application-Protocols\coreHTTP\source\core_http_client.c">
<Filter>coreHTTP</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\dependency\3rdparty\llhttp\include\llhttp.h">
<Filter>llhttp</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_client.h">
<Filter>coreHTTP</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_client_private.h">
<Filter>coreHTTP</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\include\core_http_config_defaults.h">
<Filter>coreHTTP</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\Application-Protocols\coreHTTP\source\interface\transport_interface.h">
<Filter>coreHTTP</Filter>
</ClInclude>
<ClInclude Include="core_http_config.h" />
</ItemGroup>
</Project>

View File

@ -0,0 +1,69 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
#ifndef CORE_HTTP_CONFIG_H_
#define CORE_HTTP_CONFIG_H_
/**************************************************/
/******* DO NOT CHANGE the following order ********/
/**************************************************/
/* Logging config definition and header files inclusion are required in the following order:
* 1. Include the header file "logging_levels.h".
* 2. Define the LIBRARY_LOG_NAME and LIBRARY_LOG_LEVEL macros depending on
* the logging configuration for HTTP.
* 3. Include the header file "logging_stack.h", if logging is enabled for HTTP.
*/
#include "logging_levels.h"
/* Logging configuration for the HTTP library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "HTTP"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_INFO
#endif
/* Prototype for the function used to print to console on Windows simulator
* of FreeRTOS.
* The function prints to the console before the network is connected;
* then a UDP port after the network has connected. */
extern void vLoggingPrintf( const char * pcFormatString,
... );
/* Map the SdkLog macro to the logging function to enable logging
* on Windows simulator. */
#ifndef SdkLog
#define SdkLog( message ) vLoggingPrintf message
#endif
#include "logging_stack.h"
/************ End of logging configuration ****************/
#endif /* ifndef CORE_HTTP_CONFIG_H_ */

View File

@ -0,0 +1,187 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{19f0ff1a-3368-491a-9932-a2f089508f51}</ProjectGuid>
<RootNamespace>corePKCS11</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<PublicIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<PublicIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<PublicIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<PublicIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\</PublicIncludeDirectories>
<AllProjectIncludesArePublic>true</AllProjectIncludesArePublic>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h";WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\portable\os;..\..\Source\corePKCS11\source\portable\os\freertos_winsim;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h";WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\portable\os;..\..\Source\corePKCS11\source\portable\os\freertos_winsim;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h";_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\portable\os;..\..\Source\corePKCS11\source\portable\os\freertos_winsim;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>MBEDTLS_CONFIG_FILE="mbedtls_config_v3.2.1.h";NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
<AdditionalIncludeDirectories>..\..\Source\corePKCS11\source\include;..\..\Source\corePKCS11\source\portable\os;..\..\Source\corePKCS11\source\portable\os\freertos_winsim;..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils;..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11;.\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ProjectReference Include="..\FreeRTOS-Kernel\FreeRTOS-Kernel.vcxproj">
<Project>{72c209c4-49a4-4942-a201-44706c9d77ec}</Project>
</ProjectReference>
<ProjectReference Include="..\Logging\Logging.vcxproj">
<Project>{be362ac0-b10b-4276-b84e-6304652ba228}</Project>
</ProjectReference>
<ProjectReference Include="..\MbedTLS\MbedTLS.vcxproj">
<Project>{e1016f3e-94e9-4864-9fd8-1d7c1fefbfd7}</Project>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\corePKCS11\source\core_pkcs11.c" />
<ClCompile Include="..\..\Source\corePKCS11\source\core_pki_utils.c" />
<ClCompile Include="..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils\mbedtls_utils.c" />
<ClCompile Include="..\..\Source\corePKCS11\source\portable\mbedtls\core_pkcs11_mbedtls.c" />
<ClCompile Include="..\..\Source\corePKCS11\source\portable\os\core_pkcs11_pal_utils.c" />
<ClCompile Include="..\..\Source\corePKCS11\source\portable\os\freertos_winsim\core_pkcs11_pal.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils\mbedtls_utils.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11f.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11t.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11_config_defaults.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11_pal.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pki_utils.h" />
<ClInclude Include="..\..\Source\corePKCS11\source\portable\os\core_pkcs11_pal_utils.h" />
<ClInclude Include="core_pkcs11_config.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -0,0 +1,78 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="pkcs11_api">
<UniqueIdentifier>{87f448f0-826d-4964-8c17-2dafde7cdc17}</UniqueIdentifier>
</Filter>
<Filter Include="corePKCS11">
<UniqueIdentifier>{f837be63-52d6-4f7a-b057-323ad9c20295}</UniqueIdentifier>
</Filter>
<Filter Include="corePKCS11\include">
<UniqueIdentifier>{a67eb7ab-543a-475e-88ea-d2543002780c}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\Source\corePKCS11\source\core_pkcs11.c">
<Filter>corePKCS11</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\corePKCS11\source\portable\mbedtls\core_pkcs11_mbedtls.c">
<Filter>corePKCS11</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\corePKCS11\source\core_pki_utils.c">
<Filter>corePKCS11</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils\mbedtls_utils.c">
<Filter>corePKCS11</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\corePKCS11\source\portable\os\core_pkcs11_pal_utils.c">
<Filter>corePKCS11</Filter>
</ClCompile>
<ClCompile Include="..\..\Source\corePKCS11\source\portable\os\freertos_winsim\core_pkcs11_pal.c">
<Filter>corePKCS11</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11t.h">
<Filter>pkcs11_api</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11.h">
<Filter>pkcs11_api</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\pkcs11\pkcs11f.h">
<Filter>pkcs11_api</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11_config_defaults.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pkcs11_pal.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\portable\os\core_pkcs11_pal_utils.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\include\core_pki_utils.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="..\..\Source\corePKCS11\source\dependency\3rdparty\mbedtls_utils\mbedtls_utils.h">
<Filter>corePKCS11\include</Filter>
</ClInclude>
<ClInclude Include="core_pkcs11_config.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>

View File

@ -0,0 +1,212 @@
/*
* FreeRTOS V202212.01
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* 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 AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* https://www.FreeRTOS.org
* https://github.com/FreeRTOS
*
*/
/**
* @file core_pkcs11_config.h
* @brief PCKS#11 config options.
*/
#ifndef _CORE_PKCS11_CONFIG_H_
#define _CORE_PKCS11_CONFIG_H_
#include "FreeRTOS.h"
/**************************************************/
/******* DO NOT CHANGE the following order ********/
/**************************************************/
/* Include logging header files and define logging macros in the following order:
* 1. Include the header file "logging_levels.h".
* 2. Define the LIBRARY_LOG_NAME and LIBRARY_LOG_LEVEL macros depending on
* the logging configuration for PKCS #11.
* 3. Include the header file "logging_stack.h", if logging is enabled for PKCS #11.
*/
#include "logging_levels.h"
/* Logging configuration for the PKCS #11 library. */
#ifndef LIBRARY_LOG_NAME
#define LIBRARY_LOG_NAME "PKCS11"
#endif
#ifndef LIBRARY_LOG_LEVEL
#define LIBRARY_LOG_LEVEL LOG_ERROR
#endif
/* Prototype for the function used to print to console on Windows simulator
* of FreeRTOS.
* The function prints to the console before the network is connected;
* then a UDP port after the network has connected. */
extern void vLoggingPrintf( const char * pcFormatString,
... );
/* Map the SdkLog macro to the logging function to enable logging
* on Windows simulator. */
#ifndef SdkLog
#define SdkLog( message ) vLoggingPrintf message
#endif
#include "logging_stack.h"
/************ End of logging configuration ****************/
#include <stdlib.h>
/**
* @brief Malloc API used by core_pkcs11.h
*/
#define PKCS11_MALLOC pvPortMalloc
/**
* @brief Free API used by core_pkcs11.h
*/
#define PKCS11_FREE vPortFree
/**
* @brief PKCS #11 default user PIN.
*
* The PKCS #11 standard specifies the presence of a user PIN. That feature is
* sensible for applications that have an interactive user interface and memory
* protections. However, since typical microcontroller applications lack one or
* both of those, the user PIN is assumed to be used herein for interoperability
* purposes only, and not as a security feature.
*
* Note: Do not cast this to a pointer! The library calls sizeof to get the length
* of this string.
*/
#define configPKCS11_DEFAULT_USER_PIN "0000"
/**
* @brief Maximum length (in characters) for a PKCS #11 CKA_LABEL
* attribute.
*/
#define pkcs11configMAX_LABEL_LENGTH 32UL
/**
* @brief Maximum number of token objects that can be stored
* by the PKCS #11 module.
*/
#define pkcs11configMAX_NUM_OBJECTS 6UL
/**
* @brief Maximum number of sessions that can be stored
* by the PKCS #11 module.
*/
#define pkcs11configMAX_SESSIONS 10UL
/**
* @brief Set to 1 if a PAL destroy object is implemented.
*
* If set to 0, no PAL destroy object is implemented, and this functionality
* is implemented in the common PKCS #11 layer.
*/
#define pkcs11configPAL_DESTROY_SUPPORTED 1
/**
* @brief Set to 1 if OTA image verification via PKCS #11 module is supported.
*
* If set to 0, OTA code signing certificate is built in via
* aws_ota_codesigner_certificate.h.
*/
#define pkcs11configOTA_SUPPORTED 1
/**
* @brief Set to 1 if PAL supports storage for JITP certificate,
* code verify certificate, and trusted server root certificate.
*
* If set to 0, PAL does not support storage mechanism for these, and
* they are accessed via headers compiled into the code.
*/
#define pkcs11configJITP_CODEVERIFY_ROOT_CERT_SUPPORTED 1
/**
* @brief The PKCS #11 label for the object to be used for HMAC operations.
*/
#define pkcs11configLABEL_HMAC_KEY "HMAC Key"
/**
* @brief The PKCS #11 label for the object to be used for CMAC operations.
*/
#define pkcs11configLABEL_CMAC_KEY "CMAC Key"
/**
* @brief The PKCS #11 label for device private key.
*
* Private key for connection to AWS IoT endpoint. The corresponding
* public key should be registered with the AWS IoT endpoint.
*/
#define pkcs11configLABEL_DEVICE_PRIVATE_KEY_FOR_TLS "Device Priv TLS Key"
/**
* @brief The PKCS #11 label for device public key.
*
* The public key corresponding to pkcs11configLABEL_DEVICE_PRIVATE_KEY_FOR_TLS.
*/
#define pkcs11configLABEL_DEVICE_PUBLIC_KEY_FOR_TLS "Device Pub TLS Key"
/**
* @brief The PKCS #11 label for the device certificate.
*
* Device certificate corresponding to pkcs11configLABEL_DEVICE_PRIVATE_KEY_FOR_TLS.
*/
#define pkcs11configLABEL_DEVICE_CERTIFICATE_FOR_TLS "Device Cert"
/**
* @brief The PKCS #11 label for the object to be used for code verification.
*
* Used by over-the-air update code to verify an incoming signed image.
*/
#define pkcs11configLABEL_CODE_VERIFICATION_KEY "Code Verify Key"
/**
* @brief The PKCS #11 label for the claim certificate for Fleet Provisioning.
*/
#define pkcs11configLABEL_CLAIM_CERTIFICATE "Claim Cert"
/**
* @brief The PKCS #11 label for the claim private key for Fleet Provisioning.
*/
#define pkcs11configLABEL_CLAIM_PRIVATE_KEY "Claim Key"
/**
* @brief The PKCS #11 label for Just-In-Time-Provisioning.
*
* The certificate corresponding to the issuer of the device certificate
* (pkcs11configLABEL_DEVICE_CERTIFICATE_FOR_TLS) when using the JITR or
* JITP flow.
*/
#define pkcs11configLABEL_JITP_CERTIFICATE "JITP Cert"
/**
* @brief The PKCS #11 label for the AWS Trusted Root Certificate.
*
* @see aws_default_root_certificates.h
*/
#define pkcs11configLABEL_ROOT_CERTIFICATE "Root Cert"
#endif /* _CORE_PKCS11_CONFIG_H_ */