mirror of
https://github.com/gnif/LookingGlass.git
synced 2026-11-12 23:07:21 +00:00
[client/idd] network: allow unencrypted 1-RTT payloads
Expose the insecure MsQuic draft API and add an opt-in setting on both peers. Query the negotiated state after connection establishment so one-sided opt-in remains encrypted and is logged accurately.
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>$(LGMsQuicSourceDir)src\inc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>QUIC_BUILD_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>QUIC_BUILD_STATIC;QUIC_API_ENABLE_INSECURE_FEATURES=1;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(LGMsQuicStaticLibrary);$(LGMsQuicCoreLibrary);$(LGMsQuicPlatformLibrary);ws2_32.lib;schannel.lib;secur32.lib;OneCore.lib;wbemuuid.lib;winmm.lib;ntdll.lib;bcrypt.lib;ncrypt.lib;crypt32.lib;iphlpapi.lib;advapi32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
@@ -34,7 +34,7 @@
|
||||
<!-- NormalizeDirectory adds a trailing slash. The dot prevents that slash
|
||||
from escaping the closing quote in the command line. -->
|
||||
<Exec
|
||||
Command="cmake -S "$(LGMsQuicSourceDir)." -B "$(LGMsQuicBuildDir)." -G "Visual Studio 17 2022" -A "$(LGMsQuicArchitecture)" -T v143 -DCMAKE_SYSTEM_VERSION="$(WindowsTargetPlatformVersion)" -DQUIC_BUILD_SHARED=OFF -DQUIC_BUILD_TOOLS=OFF -DQUIC_BUILD_TEST=OFF -DQUIC_BUILD_PERF=OFF -DQUIC_TLS_LIB=schannel -DQUIC_ENABLE_LOGGING=OFF -DQUIC_STATIC_LINK_CRT=OFF -DQUIC_STATIC_LINK_PARTIAL_CRT=OFF -DQUIC_SOURCE_LINK=OFF -DQUIC_PDBALTPATH=OFF -DQUIC_EMBED_GIT_HASH=OFF -DCMAKE_PROJECT_INCLUDE="$(MSBuildThisFileDirectory)MsQuic.cmake" -DLG_MSQUIC_DISABLE_CODE_ANALYSIS=ON" />
|
||||
Command="cmake -S "$(LGMsQuicSourceDir)." -B "$(LGMsQuicBuildDir)." -G "Visual Studio 17 2022" -A "$(LGMsQuicArchitecture)" -T v143 -DCMAKE_SYSTEM_VERSION="$(WindowsTargetPlatformVersion)" -DQUIC_BUILD_SHARED=OFF -DQUIC_BUILD_TOOLS=OFF -DQUIC_BUILD_TEST=OFF -DQUIC_BUILD_PERF=OFF -DQUIC_TLS_LIB=schannel -DQUIC_ENABLE_LOGGING=OFF -DQUIC_STATIC_LINK_CRT=OFF -DQUIC_STATIC_LINK_PARTIAL_CRT=OFF -DQUIC_SOURCE_LINK=OFF -DQUIC_PDBALTPATH=OFF -DQUIC_EMBED_GIT_HASH=OFF -DCMAKE_PROJECT_INCLUDE="$(MSBuildThisFileDirectory)MsQuic.cmake" -DLG_MSQUIC_DISABLE_CODE_ANALYSIS=ON -DLG_MSQUIC_ENABLE_INSECURE_FEATURES=ON" />
|
||||
</Target>
|
||||
<Target
|
||||
Name="BuildLGMsQuic"
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
include(ExternalProject)
|
||||
|
||||
if(LG_MSQUIC_ENABLE_INSECURE_FEATURES)
|
||||
add_compile_definitions(QUIC_API_ENABLE_INSECURE_FEATURES=1)
|
||||
endif()
|
||||
|
||||
# MsQuic's static archive flattener must be able to see this imported target
|
||||
# from outside the directory where FindOpenSSL is invoked.
|
||||
if(LG_MSQUIC_OPENSSL_CRYPTO_LIBRARY AND NOT TARGET OpenSSL::Crypto)
|
||||
@@ -125,6 +129,7 @@ function(lg_add_static_msquic)
|
||||
"-DQUIC_SOURCE_LINK=OFF"
|
||||
"-DQUIC_PDBALTPATH=OFF"
|
||||
"-DQUIC_EMBED_GIT_HASH=OFF"
|
||||
"-DLG_MSQUIC_ENABLE_INSECURE_FEATURES=ON"
|
||||
)
|
||||
|
||||
if(NOT EXISTS "${LG_MSQUIC_SOURCE_DIR}/CMakeLists.txt")
|
||||
@@ -495,7 +500,7 @@ function(lg_add_static_msquic)
|
||||
IMPORTED_LOCATION_RELEASE "${LG_MSQUIC_RELEASE_LIBRARY}"
|
||||
IMPORTED_LOCATION_RELWITHDEBINFO "${LG_MSQUIC_RELEASE_LIBRARY}"
|
||||
IMPORTED_LOCATION_MINSIZEREL "${LG_MSQUIC_RELEASE_LIBRARY}"
|
||||
INTERFACE_COMPILE_DEFINITIONS QUIC_BUILD_STATIC
|
||||
INTERFACE_COMPILE_DEFINITIONS "QUIC_BUILD_STATIC;QUIC_API_ENABLE_INSECURE_FEATURES=1"
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${LG_MSQUIC_SOURCE_DIR}/src/inc"
|
||||
INTERFACE_LINK_LIBRARIES "${LG_MSQUIC_LINK_LIBRARIES}"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user