Merge branch 'develop' of https://github.com/pocoproject/poco into develop

This commit is contained in:
Francis ANDRE
2019-11-17 13:21:35 +01:00
319 changed files with 14586 additions and 10664 deletions

12
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,12 @@
# These are supported funding model platforms
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: ['https://pocoproject.org/about.html#funding'] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

View File

@@ -32,7 +32,7 @@ services:
- postgresql - postgresql
- mysql - mysql
dist: trusty dist: xenai
sudo: enabled sudo: enabled
addons: addons:
@@ -68,113 +68,104 @@ matrix:
fast_finish: true fast_finish: true
include: include:
- env: test="android API level 19" - env: test="android API level 19 armeabi-v7a"
language: android addons:
jdk: openjdk8 apt:
android: packages:
components: - openjdk-8-jdk
- tools
- platform-tools
- tools
- build-tools-23.0.3
- extra-android-support
- extra-android-m2repository
- android-19
- android-24
- sys-img-armeabi-v7a-android-24
# Unfortunaly travis use the old android sdk tool instead of using the new sdkmanager.
# In this deprecated android sdk tool there is no ndk-bundle or cmake package!
licenses:
- '.+'
before_install: before_install:
- export TERM=dumb - export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
- sudo apt-get update -qq - wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip
# I don't understand why redis and mongodb are not installed although services added above ! - unzip -qq sdk-tools-linux-4333796.zip -d /opt/android-sdk
- sudo apt-get install -qq -y mongodb-server redis-server - rm sdk-tools-linux-4333796.zip
- /usr/bin/redis-server & - echo "y" | /opt/android-sdk/tools/bin/sdkmanager "platform-tools" "system-images;android-24;default;armeabi-v7a" "platforms;android-24" "emulator" "ndk-bundle" "cmake;3.10.2.4988404" > /dev/null
- sudo /usr/bin/mongod --config /etc/mongodb.conf &
- touch ~/.android/repositories.cfg
- mkdir -p /usr/local/android-sdk/licenses
- echo -e "\n8933bad161af4178b1185d1a37fbf41ea5269c55" > /usr/local/android-sdk/licenses/android-sdk-license
- echo -e "\nd56f5187479451eabf01fb78af6dfcb131a6481e" >> /usr/local/android-sdk/licenses/android-sdk-license
- echo -e "\n24333f8a63b6825ea9c5514f83c2829b004d1fee" >> /usr/local/android-sdk/licenses/android-sdk-license
# Install NDK and cmake via android sdkmanager.
- /usr/local/android-sdk/tools/bin/sdkmanager --update > /dev/null
- /usr/local/android-sdk/tools/bin/sdkmanager "emulator" "ndk-bundle" "cmake;3.6.4111459" > /dev/null
- /usr/local/android-sdk/tools/bin/sdkmanager --list
before_script: before_script:
- export TERM=dumb - export TERM=dumb
- export _NO_CHECK_SIGNATURE=true - export _NO_CHECK_SIGNATURE=true
- echo no | /usr/local/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;armeabi-v7a" - export ANDROID_SDK_ROOT=/opt/android-sdk
- /usr/local/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 & - echo no | /opt/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;armeabi-v7a"
- android-wait-for-emulator - /opt/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 &
- /usr/local/android-sdk/platform-tools/adb shell input keyevent 82 & #- android-wait-for-emulator || android-wait-for-emulator
- /opt/android-sdk/platform-tools/adb shell input keyevent 82 &
script: script:
# Mandatory cmake parameter to set API level and platform for the android toolchain: # Mandatory cmake parameter to set API level and platform for the android toolchain:
# /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22 # /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22
# See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake # See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
# Using the ninja build command. Is much faster then make build command. # Using the ninja build command. Is much faster then make build command.
- /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -H. -Bcmake-build -G'Android Gradle - Ninja' -DANDROID_ABI=armeabi-v7a -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-19 -DCMAKE_MAKE_PROGRAM=/usr/local/android-sdk/cmake/3.6.4111459/bin/ninja -DANDROID_STL="c++_static" -DANDROID_CPP_FEATURES="exceptions rtti" -DPOCO_ENABLE_APACHECONNECTOR=OFF -DPOCO_ENABLE_NETSSL=OFF -DPOCO_ENABLE_CRYPTO=OFF -DPOCO_ENABLE_SQL_MYSQL=OFF -DPOCO_ENABLE_SQL_POSTGRESQL=OFF -DPOCO_ENABLE_TESTS=ON -DPOCO_ENABLE_LONG_RUNNING_TESTS=OFF -DPOCO_OLD_REDIS_VERSION=ON && /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake --build cmake-build --target all && cd cmake-build &&travis_wait 30 /usr/local/android-sdk/cmake/3.6.4111459/bin/ctest -E Foundation --output-on-failure - /opt/android-sdk/cmake/3.10.2.4988404/bin/cmake -H. -Bcmake-build -GNinja
-DANDROID_ABI=armeabi-v7a
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
-DANDROID_PLATFORM=android-19
-DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.10.2.4988404/bin/ninja
-DANDROID_STL="c++_static"
-DANDROID_CPP_FEATURES="exceptions rtti"
-DPOCO_ENABLE_APACHECONNECTOR=OFF
-DPOCO_ENABLE_NETSSL=OFF
-DPOCO_ENABLE_CRYPTO=OFF
-DPOCO_ENABLE_SQL_MYSQL=OFF
-DPOCO_ENABLE_SQL_POSTGRESQL=OFF
-DPOCO_ENABLE_TESTS=ON
-DPOCO_ENABLE_LONG_RUNNING_TESTS=OFF
-DPOCO_OLD_REDIS_VERSION=ON &&
/opt/android-sdk/cmake/3.10.2.4988404/bin/cmake --build cmake-build --target all #&&
#cd cmake-build && travis_wait 30 /opt/android-sdk/cmake/3.10.2.4988404/bin/ctest -E Foundation --output-on-failure FIXME Android emulator hangs
- env: test="android API level 24" - env: test="android API level 24 arm64-v8a"
language: android addons:
jdk: openjdk8 apt:
android: packages:
components: - openjdk-8-jdk
- tools
- platform-tools
- tools
- build-tools-23.0.3
- extra-android-support
- extra-android-m2repository
- android-24
- sys-img-armeabi-v7a-android-24
# Unfortunaly travis use the old android sdk tool instead of using the new sdkmanager.
# In this deprecated android sdk tool there is no ndk-bundle or cmake package!
licenses:
- '.+'
before_install: before_install:
- export TERM=dumb - export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
- sudo apt-get update -qq - wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip
# I don't understand why redis and mongodb are not installed although services added above ! - unzip -qq sdk-tools-linux-4333796.zip -d /opt/android-sdk
- sudo apt-get install -qq -y mongodb-server redis-server - rm sdk-tools-linux-4333796.zip
- /usr/bin/redis-server & - echo "y" | /opt/android-sdk/tools/bin/sdkmanager "platform-tools" "system-images;android-24;default;arm64-v8a" "platforms;android-24" "emulator" "ndk-bundle" "cmake;3.10.2.4988404" > /dev/null
- sudo /usr/bin/mongod --config /etc/mongodb.conf &
- touch ~/.android/repositories.cfg
- mkdir -p /usr/local/android-sdk/licenses
- echo -e "\n8933bad161af4178b1185d1a37fbf41ea5269c55" > /usr/local/android-sdk/licenses/android-sdk-license
- echo -e "\nd56f5187479451eabf01fb78af6dfcb131a6481e" >> /usr/local/android-sdk/licenses/android-sdk-license
- echo -e "\n24333f8a63b6825ea9c5514f83c2829b004d1fee" >> /usr/local/android-sdk/licenses/android-sdk-license
# Install NDK and cmake via android sdkmanager.
- /usr/local/android-sdk/tools/bin/sdkmanager --update > /dev/null
- /usr/local/android-sdk/tools/bin/sdkmanager "emulator" "ndk-bundle" "cmake;3.6.4111459" > /dev/null
- /usr/local/android-sdk/tools/bin/sdkmanager --list
before_script: before_script:
- export TERM=dumb - export TERM=dumb
- export _NO_CHECK_SIGNATURE=true - export _NO_CHECK_SIGNATURE=true
- echo no | /usr/local/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;armeabi-v7a" - export ANDROID_SDK_ROOT=/opt/android-sdk
- /usr/local/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 & - echo no | /opt/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;arm64-v8a"
- android-wait-for-emulator - /opt/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 &
- /usr/local/android-sdk/platform-tools/adb shell input keyevent 82 & #- android-wait-for-emulator || android-wait-for-emulator
- /opt/android-sdk/platform-tools/adb shell input keyevent 82 &
script: script:
# Mandatory cmake parameter to set API level and platform for the android toolchain: # Mandatory cmake parameter to set API level and platform for the android toolchain:
# /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22 # /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22
# See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake # See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
# Using the ninja build command. Is much faster then make build command. # Using the ninja build command. Is much faster then make build command.
- /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -H. -Bcmake-build -G'Android Gradle - Ninja' -DANDROID_ABI=armeabi-v7a -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-24 -DCMAKE_MAKE_PROGRAM=/usr/local/android-sdk/cmake/3.6.4111459/bin/ninja -DANDROID_STL="c++_static" -DANDROID_CPP_FEATURES="exceptions rtti" -DPOCO_ENABLE_APACHECONNECTOR=OFF -DPOCO_ENABLE_NETSSL=OFF -DPOCO_ENABLE_CRYPTO=OFF -DPOCO_ENABLE_SQL_MYSQL=OFF -DPOCO_ENABLE_SQL_POSTGRESQL=OFF -DPOCO_ENABLE_TESTS=ON -DPOCO_ENABLE_LONG_RUNNING_TESTS=OFF -DPOCO_OLD_REDIS_VERSION=ON && /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake --build cmake-build --target all && cd cmake-build && travis_wait 30 /usr/local/android-sdk/cmake/3.6.4111459/bin/ctest -E Foundation --output-on-failure - /opt/android-sdk/cmake/3.10.2.4988404/bin/cmake -H. -Bcmake-build -GNinja
-DANDROID_ABI=arm64-v8a
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
-DANDROID_PLATFORM=android-24
-DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.10.2.4988404/bin/ninja
-DANDROID_STL="c++_static"
-DANDROID_CPP_FEATURES="exceptions rtti"
-DPOCO_ENABLE_APACHECONNECTOR=OFF
-DPOCO_ENABLE_NETSSL=OFF
-DPOCO_ENABLE_CRYPTO=OFF
-DPOCO_ENABLE_SQL_MYSQL=OFF
-DPOCO_ENABLE_SQL_POSTGRESQL=OFF
-DPOCO_ENABLE_TESTS=ON
-DPOCO_ENABLE_LONG_RUNNING_TESTS=OFF
-DPOCO_OLD_REDIS_VERSION=ON &&
/opt/android-sdk/cmake/3.10.2.4988404/bin/cmake --build cmake-build --target all #&&
#cd cmake-build && travis_wait 30 /opt/android-sdk/cmake/3.10.2.4988404/bin/ctest -E Foundation --output-on-failure FIXME Android emulator hangs
- env: test="x86 (make) bundled" # - env: test="x86 (make) bundled"
os: osx # os: osx
compiler: clang # compiler: clang
script: # script:
- export CC="clang" # - export CC="clang"
- export CXX="clang++" # - export CXX="clang++"
- $CXX --version # - $CXX --version
- $CXX -x c++ /dev/null -dM -E # - $CXX -x c++ /dev/null -dM -E
- ./configure --config=Darwin32-clang-libc++ --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL # - ./configure --config=Darwin32-clang-libc++ --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL
- make all -s -j2 && sudo make install && export OSARCH=i386 && sudo -s ./travis/OSX/runtests.sh # - make all -s -j2 && sudo make install && export OSARCH=i386 && sudo -s ./travis/OSX/runtests.sh
- env: test="x64 (make) bundled" - env: test="x64 (make) bundled"
os: osx os: osx
@@ -187,15 +178,15 @@ matrix:
- ./configure --config=Darwin64-clang-libc++ --everything --omit=PDF,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL - ./configure --config=Darwin64-clang-libc++ --everything --omit=PDF,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL
- make all -s -j2 && sudo make install && sudo -s ./travis/OSX/runtests.sh - make all -s -j2 && sudo make install && sudo -s ./travis/OSX/runtests.sh
- env: test="5.4 x86 (make) bundled" # - env: test="5.4 x86 (make) bundled"
compiler: gcc # compiler: gcc
script: # script:
- sudo apt-get install -qq -y g++-5-multilib # - sudo apt-get install -qq -y g++-5-multilib
- export CC="gcc-5" # - export CC="gcc-5"
- export CXX="g++-5" # - export CXX="g++-5"
- $CXX --version # - $CXX --version
- ./configure --config=Linux32-gcc --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL # - ./configure --config=Linux32-gcc --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL
- make all -s -j2 && sudo make install && export OSARCH=x86 && sudo -s ./travis/Linux/runtests.sh # - make all -s -j2 && sudo make install && export OSARCH=x86 && sudo -s ./travis/Linux/runtests.sh
- env: test="5.4 x64 (make) bundled" - env: test="5.4 x64 (make) bundled"
compiler: gcc compiler: gcc
@@ -248,20 +239,20 @@ matrix:
- type ctest - type ctest
- source ./travis/ignored.sh - source ./travis/ignored.sh
- export POCO_BASE=`pwd` - export POCO_BASE=`pwd`
- cmake -H. -Bcmake-build -GNinja -DCMAKE_BUILD_TYPE=Debug -DPOCO_ENABLE_PDF=OFF -DPOCO_ENABLE_TESTS=ON -DPOCO_ENABLE_SAMPLES=ON && cmake --build cmake-build && cd cmake-build && sudo /usr/local/cmake-3.9.2/bin/ctest -VV && cd .. - cmake -H. -Bcmake-build -GNinja -DCMAKE_BUILD_TYPE=Debug -DPOCO_ENABLE_PDF=OFF -DPOCO_ENABLE_TESTS=ON -DPOCO_ENABLE_SAMPLES=ON && cmake --build cmake-build && cd cmake-build && sudo /usr/local/cmake-3.12.4/bin/ctest -VV && cd ..
- env: test="4.0 x86 (make) bundled" # - env: test="4.0 x86 (make) bundled"
compiler: clang # compiler: clang
script: # script:
- sudo apt-get install -qq -y clang-4.0 lldb-4.0 libc++-dev libc++abi-dev # - sudo apt-get install -qq -y clang-4.0 lldb-4.0 libc++-dev libc++abi-dev
- sudo apt-get install -qq -y g++-5-multilib # - sudo apt-get install -qq -y g++-5-multilib
- export CLANG_VERSTION="-4.0" # - export CLANG_VERSTION="-4.0"
- export CC="clang-4.0" # - export CC="clang-4.0"
- export CXX="clang++-4.0" # - export CXX="clang++-4.0"
- $CXX --version # - $CXX --version
- ./configure --config=Linux32-clang --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL # - ./configure --config=Linux32-clang --everything --omit=PDF,Crypto,NetSSL_OpenSSL,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL
- make all -s -j2 && sudo make install && export OSARCH=x86 && sudo -s ./travis/Linux/runtests.sh # - make all -s -j2 && sudo make install && export OSARCH=x86 && sudo -s ./travis/Linux/runtests.sh
- env: test="4.0 x64 (make) bundled" - env: test="4.0 x64 (make) bundled"
compiler: clang compiler: clang
@@ -274,31 +265,31 @@ matrix:
- ./configure --config=Linux64-clang --everything --omit=PDF - ./configure --config=Linux64-clang --everything --omit=PDF
- make all -s -j2 && sudo make install && sudo -s ./travis/Linux/runtests.sh - make all -s -j2 && sudo make install && sudo -s ./travis/Linux/runtests.sh
- env: test="5.0 x64 (make) bundled" - env: test="6.0 x64 (make) bundled"
compiler: clang compiler: clang
script: script:
- sudo apt-get install -qq -y clang-5.0 lldb-5.0 libc++-dev libc++abi-dev - sudo apt-get install -qq -y clang-6.0 lldb-6.0 libc++-dev libc++abi-dev
- export CLANG_VERSTION="-5.0" - export CLANG_VERSTION="-6.0"
- export CC="clang-5.0" - export CC="clang-6.0"
- export CXX="clang++-5.0" - export CXX="clang++-6.0"
- $CXX --version - $CXX --version
- ./configure --config=Linux64-clang --everything --omit=PDF - ./configure --config=Linux64-clang --everything --omit=PDF
- make all -s -j2 && sudo make install && sudo -s ./travis/Linux/runtests.sh - make all -s -j2 && sudo make install && sudo -s ./travis/Linux/runtests.sh
#- env: test="arm-linux-gnueabi-g++ (make)" - env: test="arm-linux-gnueabi-g++ (make)"
# compiler: gcc compiler: gcc
# script: script:
# - sudo apt-get install -qq -y g++-arm-linux-gnueabi g++-arm-linux-gnueabihf - sudo apt-get install -qq -y g++-arm-linux-gnueabi g++-arm-linux-gnueabihf
# - arm-linux-gnueabi-g++ --version - arm-linux-gnueabi-g++ --version
# - arm-linux-gnueabi-g++ -x c++ /dev/null -dM -E - arm-linux-gnueabi-g++ -x c++ /dev/null -dM -E
# - ./configure --omit=PDF,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL,Crypto,NetSSL,PageCompiler && make -s -j2 CROSS_COMPILE=arm-linux-gnueabi- POCO_TARGET_OSARCH=armv7l - ./configure --omit=PDF,SQL/ODBC,SQL/MySQL,SQL/PostgreSQL,Crypto,NetSSL,PageCompiler && make -s -j2 CROSS_COMPILE=arm-linux-gnueabi- POCO_TARGET_OSARCH=armv7l
#- env: test="(CMake)" #- env: test="(CMake)"
# compiler: clang # compiler: clang
# script: # script:
# - source ./travis/ignored.sh # - source ./travis/ignored.sh
# - export POCO_BASE=`pwd` # - export POCO_BASE=`pwd`
# - mkdir cmake-build && cd cmake-build && cmake -DENABLE_PDF=OFF -DENABLE_TESTS=ON .. && make -s -j2 && sudo /usr/local/cmake-3.9.2/bin/ctest -VV -E SQL && cd .. # - mkdir cmake-build && cd cmake-build && cmake -DENABLE_PDF=OFF -DENABLE_TESTS=ON .. && make -s -j2 && sudo /usr/local/cmake-3.12.4/bin/ctest -VV -E SQL && cd ..
#- env: test="arm-linux-gnueabi-g++ (CMake)" #- env: test="arm-linux-gnueabi-g++ (CMake)"
# ======================================= "arm-linux-gnueabi-g++: version 4.7.0: non compliant to c++11 # ======================================= "arm-linux-gnueabi-g++: version 4.7.0: non compliant to c++11

View File

@@ -30,9 +30,15 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
# Append our module directory to CMake # Append our module directory to CMake
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
if(${CMAKE_VERSION} VERSION_LESS "3.4") if(CMAKE_VERSION VERSION_LESS "3.4")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/V33) list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/V33)
endif() endif()
if(CMAKE_VERSION VERSION_LESS "3.10")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/V39)
endif()
if(CMAKE_VERSION VERSION_LESS "3.14")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/V313)
endif()
################################################################################# #################################################################################
# Setup C/C++ compiler options # Setup C/C++ compiler options
################################################################################# #################################################################################
@@ -486,6 +492,15 @@ install(
Devel Devel
) )
if(POCO_UNBUNDLED)
install(FILES cmake/FindPCRE.cmake
DESTINATION "${PocoConfigPackageLocation}")
install(FILES cmake/V39/FindEXPAT.cmake
DESTINATION "${PocoConfigPackageLocation}/V39")
install(FILES cmake/V313/FindSQLite3.cmake
DESTINATION "${PocoConfigPackageLocation}/V313")
endif()
# Install pkg-config files # Install pkg-config files
install(FILES ${POCO_PKG_CONFIG_FILES} install(FILES ${POCO_PKG_CONFIG_FILES}
DESTINATION lib${LIB_SUFFIX}/pkgconfig) DESTINATION lib${LIB_SUFFIX}/pkgconfig)

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(CppParser ${SRCS}) add_library(CppParser ${SRCS})
add_library(Poco::CppParser ALIAS CppParser) add_library(Poco::CppParser ALIAS CppParser)
set_target_properties(CppParser set_target_properties(CppParser

View File

@@ -7,8 +7,6 @@
#define Poco_CppUnit__CppUnitINCLUDED #define Poco_CppUnit__CppUnitINCLUDED
#include "Poco/Platform.h"
// //
// Ensure that POCO_DLL is default unless POCO_STATIC is defined // Ensure that POCO_DLL is default unless POCO_STATIC is defined
@@ -28,7 +26,7 @@
// CppUnit_API functions as being imported from a DLL, whereas this DLL sees symbols // CppUnit_API functions as being imported from a DLL, whereas this DLL sees symbols
// defined with this macro as being exported. // defined with this macro as being exported.
// //
#if defined(POCO_COMPILER_MSVC) && defined(POCO_DLL) #if defined(_WIN32) && defined(_MSC_VER) && defined(POCO_DLL)
#if defined(CppUnit_EXPORTS) #if defined(CppUnit_EXPORTS)
#define CppUnit_API __declspec(dllexport) #define CppUnit_API __declspec(dllexport)
#else #else
@@ -45,38 +43,10 @@
#endif #endif
#endif #endif
//
// Automatically link CppUnit library.
//
#if defined(POCO_COMPILER_MSVC)
#if defined(POCO_DLL)
#if defined(_DEBUG)
#define POCO_LIB_SUFFIX "d.lib"
#else
#define POCO_LIB_SUFFIX ".lib"
#endif
#elif defined(_DLL)
#if defined(_DEBUG)
#define POCO_LIB_SUFFIX "mdd.lib"
#else
#define POCO_LIB_SUFFIX "md.lib"
#endif
#else
#if defined(_DEBUG)
#define POCO_LIB_SUFFIX "mtd.lib"
#else
#define POCO_LIB_SUFFIX "mt.lib"
#endif
#endif
#if !defined(POCO_NO_AUTOMATIC_LIBS) && !defined(CppUnit_EXPORTS)
#pragma comment(lib, "PocoCppUnit" POCO_LIB_SUFFIX)
#endif
#endif
// Turn off some annoying warnings // Turn off some annoying warnings
#ifdef POCO_COMPILER_MSVC #ifdef _MSC_VER
#pragma warning(disable:4786) // identifier truncation warning #pragma warning(disable:4786) // identifier truncation warning
#pragma warning(disable:4503) // decorated name length exceeded - mainly a problem with STLPort #pragma warning(disable:4503) // decorated name length exceeded - mainly a problem with STLPort
#pragma warning(disable:4018) // signed/unsigned comparison #pragma warning(disable:4018) // signed/unsigned comparison

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(Crypto ${SRCS} ) add_library(Crypto ${SRCS} )
add_library(Poco::Crypto ALIAS Crypto) add_library(Poco::Crypto ALIAS Crypto)
set_target_properties(Crypto set_target_properties(Crypto
@@ -26,6 +32,9 @@ target_include_directories(Crypto
if(MSVC AND POCO_DISABLE_INTERNAL_OPENSSL) if(MSVC AND POCO_DISABLE_INTERNAL_OPENSSL)
target_compile_definitions(Crypto PUBLIC POCO_EXTERNAL_OPENSSL) target_compile_definitions(Crypto PUBLIC POCO_EXTERNAL_OPENSSL)
if(OPENSSL_USE_STATIC_LIBS)
target_link_libraries(Crypto PUBLIC ws2_32.lib Crypt32.lib)
endif()
endif() endif()
POCO_INSTALL(Crypto) POCO_INSTALL(Crypto)

View File

@@ -119,16 +119,31 @@ enum RSAPaddingMode
#elif defined(POCO_EXTERNAL_OPENSSL) #elif defined(POCO_EXTERNAL_OPENSSL)
#if POCO_EXTERNAL_OPENSSL == POCO_EXTERNAL_OPENSSL_SLPRO #if POCO_EXTERNAL_OPENSSL == POCO_EXTERNAL_OPENSSL_SLPRO
#if defined(POCO_DLL) #if defined(POCO_DLL)
#if OPENSSL_VERSION_PREREQ(1,1)
#pragma comment(lib, "libcrypto.lib")
#pragma comment(lib, "libssl.lib")
#else
#pragma comment(lib, "libeay32.lib") #pragma comment(lib, "libeay32.lib")
#pragma comment(lib, "ssleay32.lib") #pragma comment(lib, "ssleay32.lib")
#endif
#else
#if OPENSSL_VERSION_PREREQ(1,1)
#pragma comment(lib, "libcrypto" POCO_LIB_SUFFIX)
#pragma comment(lib, "libssl" POCO_LIB_SUFFIX)
#else #else
#pragma comment(lib, "libeay32" POCO_LIB_SUFFIX) #pragma comment(lib, "libeay32" POCO_LIB_SUFFIX)
#pragma comment(lib, "ssleay32" POCO_LIB_SUFFIX) #pragma comment(lib, "ssleay32" POCO_LIB_SUFFIX)
#endif
#endif #endif
#elif POCO_EXTERNAL_OPENSSL == POCO_EXTERNAL_OPENSSL_DEFAULT #elif POCO_EXTERNAL_OPENSSL == POCO_EXTERNAL_OPENSSL_DEFAULT
#if OPENSSL_VERSION_PREREQ(1,1)
#pragma comment(lib, "libcrypto.lib")
#pragma comment(lib, "libssl.lib")
#else
#pragma comment(lib, "libeay32.lib") #pragma comment(lib, "libeay32.lib")
#pragma comment(lib, "ssleay32.lib") #pragma comment(lib, "ssleay32.lib")
#endif #endif
#endif
#endif // POCO_INTERNAL_OPENSSL_MSVC_VER #endif // POCO_INTERNAL_OPENSSL_MSVC_VER
#if !defined(Crypto_EXPORTS) #if !defined(Crypto_EXPORTS)
#pragma comment(lib, "PocoCrypto" POCO_LIB_SUFFIX) #pragma comment(lib, "PocoCrypto" POCO_LIB_SUFFIX)

View File

@@ -151,6 +151,11 @@ public:
const X509* certificate() const; const X509* certificate() const;
/// Returns the underlying OpenSSL certificate. /// Returns the underlying OpenSSL certificate.
X509* dup() const;
/// Duplicates and returns the underlying OpenSSL certificate. Note that
/// the caller assumes responsibility for the lifecycle of the created
/// certificate.
std::string signatureAlgorithm() const; std::string signatureAlgorithm() const;
/// Returns the certificate signature algorithm long name. /// Returns the certificate signature algorithm long name.
@@ -231,6 +236,12 @@ inline const X509* X509Certificate::certificate() const
} }
inline X509* X509Certificate::dup() const
{
return X509_dup(_pCert);
}
} } // namespace Poco::Crypto } } // namespace Poco::Crypto

View File

@@ -6,6 +6,12 @@ POCO_SOURCES( SRCS Encodings ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS( SRCS Encodings ${HDRS_G}) POCO_HEADERS( SRCS Encodings ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(Encodings ${LIB_MODE} ${SRCS} ) add_library(Encodings ${LIB_MODE} ${SRCS} )
add_library(Poco::Encodings ALIAS Encodings) add_library(Poco::Encodings ALIAS Encodings)
set_target_properties(Encodings set_target_properties(Encodings

2
FAQ.md
View File

@@ -7,7 +7,7 @@
**A:** It depends on what exactly [xyz] is. POCO community is more than happy to help newcomers and experienced C++ programmers alike. There are, however, certain limitations as to how far we are willing to go as well as expectations we have for people asking questions: **A:** It depends on what exactly [xyz] is. POCO community is more than happy to help newcomers and experienced C++ programmers alike. There are, however, certain limitations as to how far we are willing to go as well as expectations we have for people asking questions:
- First and foremost, read the relevant [documentation](http://pocoproject.org/documentation/index.html) - First and foremost, read the relevant [documentation](http://pocoproject.org/documentation.html)
- Please be patient and respectful; we answer questions free of charge and our time is at least as valuable as yours. - Please be patient and respectful; we answer questions free of charge and our time is at least as valuable as yours.

View File

@@ -26,6 +26,12 @@ POCO_SOURCES_AUTO_PLAT( SRCS WIN32
) )
endif() endif()
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
# Messages # Messages
POCO_MESSAGES( SRCS Logging src/pocomsg.mc) POCO_MESSAGES( SRCS Logging src/pocomsg.mc)
@@ -97,7 +103,11 @@ set_target_properties(Foundation
DEFINE_SYMBOL Foundation_EXPORTS DEFINE_SYMBOL Foundation_EXPORTS
) )
target_link_libraries(Foundation PUBLIC ${PCRE_LIBRARIES} ${ZLIB_LIBRARIES}) if (POCO_UNBUNDLED)
target_link_libraries(Foundation PUBLIC Pcre::Pcre ZLIB::ZLIB)
target_compile_definitions(Foundation PUBLIC POCO_UNBUNDLED)
endif (POCO_UNBUNDLED)
target_include_directories(Foundation target_include_directories(Foundation
PUBLIC PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
@@ -111,7 +121,7 @@ target_compile_definitions(Foundation
$<$<NOT:$<BOOL:${POCO_DISABLE_CPP14}>>:POCO_ENABLE_CPP14> $<$<NOT:$<BOOL:${POCO_DISABLE_CPP14}>>:POCO_ENABLE_CPP14>
) )
target_compile_features(Foundation PUBLIC cxx_defaulted_move_initializers) target_compile_features(Foundation PUBLIC cxx_defaulted_move_initializers)
if(NOT DISABLE_CPP14 AND CMAKE_VERSION VERSION_GREATER 3.7) if(NOT DISABLE_CPP14 AND CMAKE_VERSION VERSION_GREATER "3.8")
target_compile_features(Foundation PUBLIC cxx_std_14) target_compile_features(Foundation PUBLIC cxx_std_14)
endif() endif()
@@ -231,11 +241,6 @@ if ((${CMAKE_CXX_COMPILER_ID} MATCHES "XL") AND (${CMAKE_SYSTEM} MATCHES "AIX"))
) )
endif() endif()
if(POCO_UNBUNDLED)
target_include_directories(Foundation PUBLIC "${PCRE_INCLUDE_DIRS}" "${ZLIB_INCLUDE_DIRS}")
target_compile_definitions(Foundation PUBLIC POCO_UNBUNDLED)
endif()
if (NOT POCO_ENABLE_WSTRING) if (NOT POCO_ENABLE_WSTRING)
target_compile_definitions(Foundation PUBLIC POCO_NO_WSTRING) target_compile_definitions(Foundation PUBLIC POCO_NO_WSTRING)
endif() endif()

View File

@@ -1 +1,8 @@
if(@POCO_UNBUNDLED@)
include(CMakeFindDependencyMacro)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")
find_dependency(ZLIB REQUIRED)
find_dependency(PCRE REQUIRED)
endif()
include("${CMAKE_CURRENT_LIST_DIR}/PocoFoundationTargets.cmake") include("${CMAKE_CURRENT_LIST_DIR}/PocoFoundationTargets.cmake")

View File

@@ -54,6 +54,8 @@ public:
// get triggers an update to the expiration time // get triggers an update to the expiration time
typename ExpireStrategy<TKey, TValue>::Iterator it = this->_keys.find(key); typename ExpireStrategy<TKey, TValue>::Iterator it = this->_keys.find(key);
if (it != this->_keys.end()) if (it != this->_keys.end())
{
if (!it->second->first.isElapsed(this->_expireTime)) // don't extend if already expired
{ {
this->_keyIndex.erase(it->second); this->_keyIndex.erase(it->second);
Timestamp now; Timestamp now;
@@ -62,6 +64,7 @@ public:
it->second = itIdx; it->second = itIdx;
} }
} }
}
}; };

View File

@@ -433,7 +433,7 @@ private:
// 'from' is greater than 'T' max value // 'from' is greater than 'T' max value
else if (!std::numeric_limits<F>::is_signed && else if (!std::numeric_limits<F>::is_signed &&
std::numeric_limits<T>::is_signed && std::numeric_limits<T>::is_signed &&
static_cast<Poco::UInt64>(from) > std::numeric_limits<T>::max()) static_cast<Poco::UInt64>(from) > static_cast<Poco::UInt64>(std::numeric_limits<T>::max()))
{ {
throw RangeException("Value too large."); throw RangeException("Value too large.");
} }

View File

@@ -12,7 +12,7 @@
// //
#include <Poco/Exception.h> #include "Poco/Exception.h"
#include "Poco/DateTimeFormat.h" #include "Poco/DateTimeFormat.h"
#include "Poco/RegularExpression.h" #include "Poco/RegularExpression.h"

View File

@@ -61,7 +61,7 @@ void EnvironmentImpl::setImpl(const std::string& name, const std::string& value)
std::string var = name; std::string var = name;
var.append("="); var.append("=");
var.append(value); var.append(value);
_map[name] = var; std::swap(_map[name], var);
if (putenv((char*) _map[name].c_str())) if (putenv((char*) _map[name].c_str()))
{ {
std::string msg = "cannot set environment variable: "; std::string msg = "cannot set environment variable: ";

View File

@@ -70,7 +70,7 @@ void EnvironmentImpl::setImpl(const std::string& name, const std::string& value)
std::string var = name; std::string var = name;
var.append("="); var.append("=");
var.append(value); var.append(value);
_map[name] = var; std::swap(_map[name], var);
if (putenv((char*) _map[name].c_str())) if (putenv((char*) _map[name].c_str()))
{ {
std::string msg = "cannot set environment variable: "; std::string msg = "cannot set environment variable: ";

View File

@@ -216,11 +216,29 @@ void KeccakP1600Round(UInt64 *state, unsigned int indexRound)
iota(state, indexRound); iota(state, indexRound);
} }
static void fromBytesToWords(UInt64 *stateAsWords, const unsigned char *state)
{
unsigned int i, j;
for (i = 0; i < 25; i++) {
stateAsWords[i] = 0;
for (j = 0; j < (64 / 8); j++)
stateAsWords[i] |= (UInt64)(state[i*(64 / 8) + j]) << (8 * j);
}
}
void KeccakP1600OnWords(UInt64 *state, unsigned int nrRounds) void KeccakP1600OnWords(UInt64 *state, unsigned int nrRounds)
{ {
for (unsigned int i = (24 - nrRounds); i < 24; i++) KeccakP1600Round(state, i); for (unsigned int i = (24 - nrRounds); i < 24; i++) KeccakP1600Round(state, i);
} }
static void fromWordsToBytes(unsigned char *state, const UInt64 *stateAsWords)
{
unsigned int i, j;
for (i = 0; i < 25; i++)
for (j = 0; j < (64 / 8); j++)
state[i*(64 / 8) + j] = (unsigned char)((stateAsWords[i] >> (8 * j)) & 0xFF);
}
void KeccakP1600_Permute_24rounds(void *state) void KeccakP1600_Permute_24rounds(void *state)
{ {
#ifndef POCO_ARCH_LITTLE_ENDIAN #ifndef POCO_ARCH_LITTLE_ENDIAN

View File

@@ -42,9 +42,9 @@ POSSIBILITY OF SUCH DAMAGE.
/* The current PCRE version information. */ /* The current PCRE version information. */
#define PCRE_MAJOR 8 #define PCRE_MAJOR 8
#define PCRE_MINOR 42 #define PCRE_MINOR 43
#define PCRE_PRERELEASE #define PCRE_PRERELEASE
#define PCRE_DATE 2018-03-20 #define PCRE_DATE 2019-02-23
/* When an application links to a PCRE DLL in Windows, the symbols that are /* When an application links to a PCRE DLL in Windows, the symbols that are
imported have to be identified as such. When building PCRE, the appropriate imported have to be identified as such. When building PCRE, the appropriate

View File

@@ -6,7 +6,7 @@
and semantics are as close as possible to those of the Perl 5 language. and semantics are as close as possible to those of the Perl 5 language.
Written by Philip Hazel Written by Philip Hazel
Copyright (c) 1997-2016 University of Cambridge Copyright (c) 1997-2018 University of Cambridge
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
@@ -7644,6 +7644,8 @@ for (;; ptr++)
/* Can't determine a first byte now */ /* Can't determine a first byte now */
if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE; if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
zerofirstchar = firstchar;
zerofirstcharflags = firstcharflags;
continue; continue;
@@ -8684,13 +8686,21 @@ do {
if (!is_anchored(scode, new_map, cd, atomcount)) return FALSE; if (!is_anchored(scode, new_map, cd, atomcount)) return FALSE;
} }
/* Positive forward assertions and conditions */ /* Positive forward assertion */
else if (op == OP_ASSERT || op == OP_COND) else if (op == OP_ASSERT)
{ {
if (!is_anchored(scode, bracket_map, cd, atomcount)) return FALSE; if (!is_anchored(scode, bracket_map, cd, atomcount)) return FALSE;
} }
/* Condition; not anchored if no second branch */
else if (op == OP_COND)
{
if (scode[GET(scode,1)] != OP_ALT) return FALSE;
if (!is_anchored(scode, bracket_map, cd, atomcount)) return FALSE;
}
/* Atomic groups */ /* Atomic groups */
else if (op == OP_ONCE || op == OP_ONCE_NC) else if (op == OP_ONCE || op == OP_ONCE_NC)

View File

@@ -10,7 +10,13 @@ config.h by the "configure" script. In environments that use CMake,
config-cmake.in is converted into config.h. If you are going to build PCRE "by config-cmake.in is converted into config.h. If you are going to build PCRE "by
hand" without using "configure" or CMake, you should copy the distributed hand" without using "configure" or CMake, you should copy the distributed
config.h.generic to config.h, and edit the macro definitions to be the way you config.h.generic to config.h, and edit the macro definitions to be the way you
need them. need them. You must then add -DHAVE_CONFIG_H to all of your compile commands,
so that config.h is included at the start of every source.
Alternatively, you can avoid editing by using -D on the compiler command line
to set the macro values. In this case, you do not have to set -DHAVE_CONFIG_H,
but if you do, default values will be taken from config.h for non-boolean
macros that are not defined on the command line.
Boolean macros such as HAVE_STDLIB_H and SUPPORT_PCRE8 should either be defined Boolean macros such as HAVE_STDLIB_H and SUPPORT_PCRE8 should either be defined
(conventionally to 1) for TRUE, and not defined at all for FALSE. All such (conventionally to 1) for TRUE, and not defined at all for FALSE. All such
@@ -283,7 +289,7 @@ sure both macros are undefined; an emulation function will then be used. */
#define PACKAGE_NAME "PCRE" #define PACKAGE_NAME "PCRE"
/* Define to the full name and version of this package. */ /* Define to the full name and version of this package. */
#define PACKAGE_STRING "PCRE 8.40" #define PACKAGE_STRING "PCRE 8.43"
/* Define to the one symbol short name of this package. */ /* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "pcre" #define PACKAGE_TARNAME "pcre"
@@ -292,7 +298,7 @@ sure both macros are undefined; an emulation function will then be used. */
#define PACKAGE_URL "" #define PACKAGE_URL ""
/* Define to the version of this package. */ /* Define to the version of this package. */
#define PACKAGE_VERSION "8.40" #define PACKAGE_VERSION "8.43"
/* The value of PARENS_NEST_LIMIT specifies the maximum depth of nested /* The value of PARENS_NEST_LIMIT specifies the maximum depth of nested
parentheses (of any kind) in a pattern. This limits the amount of system parentheses (of any kind) in a pattern. This limits the amount of system
@@ -394,7 +400,7 @@ sure both macros are undefined; an emulation function will then be used. */
/* #undef SUPPORT_VALGRIND */ /* #undef SUPPORT_VALGRIND */
/* Version number of package */ /* Version number of package */
#define VERSION "8.40" #define VERSION "8.43"
/* Define to empty if `const' does not conform to ANSI C. */ /* Define to empty if `const' does not conform to ANSI C. */
/* #undef const */ /* #undef const */

View File

@@ -9001,7 +9001,7 @@ if (exact > 1)
#ifdef SUPPORT_UTF #ifdef SUPPORT_UTF
&& !common->utf && !common->utf
#endif #endif
) && type != OP_ANYNL && type != OP_EXTUNI)
{ {
OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(exact)); OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(exact));
add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_GREATER, TMP1, 0, STR_END, 0)); add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_GREATER, TMP1, 0, STR_END, 0));

View File

@@ -187,6 +187,21 @@ void ExpireCacheTest::testExpireWithHas()
} }
void ExpireCacheTest::testAccessExpireGet()
{
AccessExpireCache<int, int> aCache(DURSLEEP);
aCache.add(1, 2); // 1
assertTrue (aCache.has(1));
SharedPtr<int> tmp = aCache.get(1);
assertTrue (!tmp.isNull());
assertTrue (*tmp == 2);
assertTrue (aCache.size() == 1);
Thread::sleep(DURWAIT);
tmp = aCache.get(1);
assertTrue (tmp.isNull());
}
void ExpireCacheTest::setUp() void ExpireCacheTest::setUp()
{ {
} }
@@ -207,6 +222,7 @@ CppUnit::Test* ExpireCacheTest::suite()
CppUnit_addTest(pSuite, ExpireCacheTest, testDuplicateAdd); CppUnit_addTest(pSuite, ExpireCacheTest, testDuplicateAdd);
CppUnit_addTest(pSuite, ExpireCacheTest, testAccessExpireN); CppUnit_addTest(pSuite, ExpireCacheTest, testAccessExpireN);
CppUnit_addTest(pSuite, ExpireCacheTest, testExpireWithHas); CppUnit_addTest(pSuite, ExpireCacheTest, testExpireWithHas);
CppUnit_addTest(pSuite, ExpireCacheTest, testAccessExpireGet);
return pSuite; return pSuite;
} }

View File

@@ -29,7 +29,7 @@ public:
void testExpireN(); void testExpireN();
void testAccessExpireN(); void testAccessExpireN();
void testExpireWithHas(); void testExpireWithHas();
void testAccessExpireGet();
void setUp(); void setUp();
void tearDown(); void tearDown();

View File

@@ -303,6 +303,20 @@ void ExpireLRUCacheTest::testDuplicateAdd()
} }
void ExpireLRUCacheTest::testAccessExpireGet()
{
ExpireLRUCache<int, int> aCache(3, DURSLEEP);
aCache.add(1, 2); // 1
assertTrue (aCache.has(1));
SharedPtr<int> tmp = aCache.get(1);
assertTrue (!tmp.isNull());
assertTrue (*tmp == 2);
Thread::sleep(DURWAIT);
tmp = aCache.get(1);
assertTrue (tmp.isNull());
}
void ExpireLRUCacheTest::setUp() void ExpireLRUCacheTest::setUp()
{ {
} }
@@ -326,6 +340,7 @@ CppUnit::Test* ExpireLRUCacheTest::suite()
CppUnit_addTest(pSuite, ExpireLRUCacheTest, testCacheSize2); CppUnit_addTest(pSuite, ExpireLRUCacheTest, testCacheSize2);
CppUnit_addTest(pSuite, ExpireLRUCacheTest, testCacheSizeN); CppUnit_addTest(pSuite, ExpireLRUCacheTest, testCacheSizeN);
CppUnit_addTest(pSuite, ExpireLRUCacheTest, testDuplicateAdd); CppUnit_addTest(pSuite, ExpireLRUCacheTest, testDuplicateAdd);
CppUnit_addTest(pSuite, ExpireLRUCacheTest, testAccessExpireGet);
return pSuite; return pSuite;
} }

View File

@@ -32,6 +32,7 @@ public:
void testCacheSize2(); void testCacheSize2();
void testCacheSizeN(); void testCacheSizeN();
void testDuplicateAdd(); void testDuplicateAdd();
void testAccessExpireGet();
void setUp(); void setUp();
void tearDown(); void tearDown();

View File

@@ -7,6 +7,12 @@ POCO_SOURCES(SRCS pdjson src/pdjson.c)
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(JSON ${SRCS} ) add_library(JSON ${SRCS} )
add_library(Poco::JSON ALIAS JSON) add_library(Poco::JSON ALIAS JSON)
set_target_properties(JSON set_target_properties(JSON

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(MongoDB ${SRCS} ) add_library(MongoDB ${SRCS} )
add_library(Poco::MongoDB ALIAS MongoDB) add_library(Poco::MongoDB ALIAS MongoDB)
set_target_properties(MongoDB set_target_properties(MongoDB

View File

@@ -69,6 +69,7 @@ std::string Binary::toString(int /*indent*/) const
Base64Encoder encoder(oss); Base64Encoder encoder(oss);
MemoryInputStream mis((const char*) _buffer.begin(), _buffer.size()); MemoryInputStream mis((const char*) _buffer.begin(), _buffer.size());
StreamCopier::copyStream(mis, encoder); StreamCopier::copyStream(mis, encoder);
encoder.close();
return oss.str(); return oss.str();
} }

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(Net ${SRCS} ) add_library(Net ${SRCS} )
add_library(Poco::Net ALIAS Net) add_library(Poco::Net ALIAS Net)
set_target_properties( Net set_target_properties( Net

View File

@@ -32,7 +32,8 @@ objects = \
RemoteSyslogChannel RemoteSyslogListener SMTPChannel \ RemoteSyslogChannel RemoteSyslogListener SMTPChannel \
WebSocket WebSocketImpl \ WebSocket WebSocketImpl \
OAuth10Credentials OAuth20Credentials \ OAuth10Credentials OAuth20Credentials \
PollSet UDPClient UDPServerParams PollSet UDPClient UDPServerParams \
NTLMCredentials SSPINTLMCredentials HTTPNTLMCredentials
target = PocoNet target = PocoNet
target_version = $(LIBVERSION) target_version = $(LIBVERSION)

View File

@@ -279,223 +279,229 @@
</Lib> </Lib>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\DatagramSocket.h"/> <ClInclude Include="include\Poco\Net\DatagramSocket.h" />
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h"/> <ClInclude Include="include\Poco\Net\DatagramSocketImpl.h" />
<ClInclude Include="include\Poco\Net\DialogSocket.h"/> <ClInclude Include="include\Poco\Net\DialogSocket.h" />
<ClInclude Include="include\Poco\Net\DNS.h"/> <ClInclude Include="include\Poco\Net\DNS.h" />
<ClInclude Include="include\Poco\Net\FilePartSource.h"/> <ClInclude Include="include\Poco\Net\FilePartSource.h" />
<ClInclude Include="include\Poco\Net\FTPClientSession.h"/> <ClInclude Include="include\Poco\Net\FTPClientSession.h" />
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\FTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\HostEntry.h"/> <ClInclude Include="include\Poco\Net\HostEntry.h" />
<ClInclude Include="include\Poco\Net\HTMLForm.h"/> <ClInclude Include="include\Poco\Net\HTMLForm.h" />
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h"/> <ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h" />
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h"/> <ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h" />
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h"/> <ClInclude Include="include\Poco\Net\HTTPChunkedStream.h" />
<ClInclude Include="include\Poco\Net\HTTPClientSession.h"/> <ClInclude Include="include\Poco\Net\HTTPClientSession.h" />
<ClInclude Include="include\Poco\Net\HTTPCookie.h"/> <ClInclude Include="include\Poco\Net\HTTPCookie.h" />
<ClInclude Include="include\Poco\Net\HTTPCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h"/> <ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h" />
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h"/> <ClInclude Include="include\Poco\Net\HTTPHeaderStream.h" />
<ClInclude Include="include\Poco\Net\HTTPIOStream.h"/> <ClInclude Include="include\Poco\Net\HTTPIOStream.h" />
<ClInclude Include="include\Poco\Net\HTTPMessage.h"/> <ClInclude Include="include\Poco\Net\HTTPMessage.h" />
<ClInclude Include="include\Poco\Net\HTTPRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\HTTPRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\HTTPResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServer.h"/> <ClInclude Include="include\Poco\Net\HTTPResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h"/> <ClInclude Include="include\Poco\Net\HTTPServer.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnection.h" />
<ClInclude Include="include\Poco\Net\HTTPServerParams.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPServerParams.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPStream.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h" />
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPStream.h" />
<ClInclude Include="include\Poco\Net\ICMPClient.h"/> <ClInclude Include="include\Poco\Net\HTTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h"/> <ClInclude Include="include\Poco\Net\ICMPClient.h" />
<ClInclude Include="include\Poco\Net\ICMPPacket.h"/> <ClInclude Include="include\Poco\Net\ICMPEventArgs.h" />
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPPacket.h" />
<ClInclude Include="include\Poco\Net\ICMPSocket.h"/> <ClInclude Include="include\Poco\Net\ICMPPacketImpl.h" />
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocket.h" />
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddress.h"/> <ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddressImpl.h"/> <ClInclude Include="include\Poco\Net\IPAddress.h" />
<ClInclude Include="include\Poco\Net\MailMessage.h"/> <ClInclude Include="include\Poco\Net\IPAddressImpl.h" />
<ClInclude Include="include\Poco\Net\MailRecipient.h"/> <ClInclude Include="include\Poco\Net\MailMessage.h" />
<ClInclude Include="include\Poco\Net\MailStream.h"/> <ClInclude Include="include\Poco\Net\MailRecipient.h" />
<ClInclude Include="include\Poco\Net\MediaType.h"/> <ClInclude Include="include\Poco\Net\MailStream.h" />
<ClInclude Include="include\Poco\Net\MessageHeader.h"/> <ClInclude Include="include\Poco\Net\MediaType.h" />
<ClInclude Include="include\Poco\Net\MulticastSocket.h"/> <ClInclude Include="include\Poco\Net\MessageHeader.h" />
<ClInclude Include="include\Poco\Net\MultipartReader.h"/> <ClInclude Include="include\Poco\Net\MulticastSocket.h" />
<ClInclude Include="include\Poco\Net\MultipartWriter.h"/> <ClInclude Include="include\Poco\Net\MultipartReader.h" />
<ClInclude Include="include\Poco\Net\MultiSocketPoller.h"/> <ClInclude Include="include\Poco\Net\MultipartWriter.h" />
<ClInclude Include="include\Poco\Net\NameValueCollection.h"/> <ClInclude Include="include\Poco\Net\MultiSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Net.h"/> <ClInclude Include="include\Poco\Net\NameValueCollection.h" />
<ClInclude Include="include\Poco\Net\NetException.h"/> <ClInclude Include="include\Poco\Net\Net.h" />
<ClInclude Include="include\Poco\Net\NetworkInterface.h"/> <ClInclude Include="include\Poco\Net\NetException.h" />
<ClInclude Include="include\Poco\Net\NTPClient.h"/> <ClInclude Include="include\Poco\Net\NetworkInterface.h" />
<ClInclude Include="include\Poco\Net\NTPEventArgs.h"/> <ClInclude Include="include\Poco\Net\NTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\NTPPacket.h"/> <ClInclude Include="include\Poco\Net\NTPClient.h" />
<ClInclude Include="include\Poco\Net\NullPartHandler.h"/> <ClInclude Include="include\Poco\Net\NTPEventArgs.h" />
<ClInclude Include="include\Poco\Net\OAuth10Credentials.h"/> <ClInclude Include="include\Poco\Net\NTPPacket.h" />
<ClInclude Include="include\Poco\Net\OAuth20Credentials.h"/> <ClInclude Include="include\Poco\Net\NullPartHandler.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\OAuth10Credentials.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketReactor.h"/> <ClInclude Include="include\Poco\Net\OAuth20Credentials.h" />
<ClInclude Include="include\Poco\Net\PartHandler.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\PartSource.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketReactor.h" />
<ClInclude Include="include\Poco\Net\PartStore.h"/> <ClInclude Include="include\Poco\Net\PartHandler.h" />
<ClInclude Include="include\Poco\Net\PollSet.h"/> <ClInclude Include="include\Poco\Net\PartSource.h" />
<ClInclude Include="include\Poco\Net\POP3ClientSession.h"/> <ClInclude Include="include\Poco\Net\PartStore.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h"/> <ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h"/> <ClInclude Include="include\Poco\Net\POP3ClientSession.h" />
<ClInclude Include="include\Poco\Net\RawSocket.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h" />
<ClInclude Include="include\Poco\Net\RawSocketImpl.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h"/> <ClInclude Include="include\Poco\Net\RawSocket.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h"/> <ClInclude Include="include\Poco\Net\RawSocketImpl.h" />
<ClInclude Include="include\Poco\Net\ServerSocket.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h" />
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogListener.h" />
<ClInclude Include="include\Poco\Net\SingleSocketPoller.h"/> <ClInclude Include="include\Poco\Net\ServerSocket.h" />
<ClInclude Include="include\Poco\Net\SMTPChannel.h"/> <ClInclude Include="include\Poco\Net\ServerSocketImpl.h" />
<ClInclude Include="include\Poco\Net\SMTPClientSession.h"/> <ClInclude Include="include\Poco\Net\SingleSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Socket.h"/> <ClInclude Include="include\Poco\Net\SMTPChannel.h" />
<ClInclude Include="include\Poco\Net\SocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\SMTPClientSession.h" />
<ClInclude Include="include\Poco\Net\SocketAddress.h"/> <ClInclude Include="include\Poco\Net\Socket.h" />
<ClInclude Include="include\Poco\Net\SocketAddressImpl.h"/> <ClInclude Include="include\Poco\Net\SocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\SocketConnector.h"/> <ClInclude Include="include\Poco\Net\SocketAddress.h" />
<ClInclude Include="include\Poco\Net\SocketDefs.h"/> <ClInclude Include="include\Poco\Net\SocketAddressImpl.h" />
<ClInclude Include="include\Poco\Net\SocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketConnector.h" />
<ClInclude Include="include\Poco\Net\SocketNotification.h"/> <ClInclude Include="include\Poco\Net\SocketDefs.h" />
<ClInclude Include="include\Poco\Net\SocketNotifier.h"/> <ClInclude Include="include\Poco\Net\SocketImpl.h" />
<ClInclude Include="include\Poco\Net\SocketReactor.h"/> <ClInclude Include="include\Poco\Net\SocketNotification.h" />
<ClInclude Include="include\Poco\Net\SocketStream.h"/> <ClInclude Include="include\Poco\Net\SocketNotifier.h" />
<ClInclude Include="include\Poco\Net\StreamSocket.h"/> <ClInclude Include="include\Poco\Net\SocketReactor.h" />
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketStream.h" />
<ClInclude Include="include\Poco\Net\StringPartSource.h"/> <ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\TCPServer.h"/> <ClInclude Include="include\Poco\Net\StreamSocket.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnection.h"/> <ClInclude Include="include\Poco\Net\StreamSocketImpl.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\StringPartSource.h" />
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h"/> <ClInclude Include="include\Poco\Net\TCPServer.h" />
<ClInclude Include="include\Poco\Net\TCPServerParams.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnection.h" />
<ClInclude Include="include\Poco\Net\UDPClient.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\UDPHandler.h"/> <ClInclude Include="include\Poco\Net\TCPServerDispatcher.h" />
<ClInclude Include="include\Poco\Net\UDPServer.h"/> <ClInclude Include="include\Poco\Net\TCPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPServerParams.h"/> <ClInclude Include="include\Poco\Net\UDPClient.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"/> <ClInclude Include="include\Poco\Net\UDPHandler.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h"/> <ClInclude Include="include\Poco\Net\UDPServer.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h"/> <ClInclude Include="include\Poco\Net\UDPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp"/> <ClCompile Include="src\AbstractHTTPRequestHandler.cpp" />
<ClCompile Include="src\DatagramSocket.cpp"/> <ClCompile Include="src\DatagramSocket.cpp" />
<ClCompile Include="src\DatagramSocketImpl.cpp"/> <ClCompile Include="src\DatagramSocketImpl.cpp" />
<ClCompile Include="src\DialogSocket.cpp"/> <ClCompile Include="src\DialogSocket.cpp" />
<ClCompile Include="src\DNS.cpp"/> <ClCompile Include="src\DNS.cpp" />
<ClCompile Include="src\FilePartSource.cpp"/> <ClCompile Include="src\FilePartSource.cpp" />
<ClCompile Include="src\FTPClientSession.cpp"/> <ClCompile Include="src\FTPClientSession.cpp" />
<ClCompile Include="src\FTPStreamFactory.cpp"/> <ClCompile Include="src\FTPStreamFactory.cpp" />
<ClCompile Include="src\HostEntry.cpp"/> <ClCompile Include="src\HostEntry.cpp" />
<ClCompile Include="src\HTMLForm.cpp"/> <ClCompile Include="src\HTMLForm.cpp" />
<ClCompile Include="src\HTTPAuthenticationParams.cpp"/> <ClCompile Include="src\HTTPAuthenticationParams.cpp" />
<ClCompile Include="src\HTTPBasicCredentials.cpp"/> <ClCompile Include="src\HTTPBasicCredentials.cpp" />
<ClCompile Include="src\HTTPBufferAllocator.cpp"/> <ClCompile Include="src\HTTPBufferAllocator.cpp" />
<ClCompile Include="src\HTTPChunkedStream.cpp"/> <ClCompile Include="src\HTTPChunkedStream.cpp" />
<ClCompile Include="src\HTTPClientSession.cpp"/> <ClCompile Include="src\HTTPClientSession.cpp" />
<ClCompile Include="src\HTTPCookie.cpp"/> <ClCompile Include="src\HTTPCookie.cpp" />
<ClCompile Include="src\HTTPCredentials.cpp"/> <ClCompile Include="src\HTTPCredentials.cpp" />
<ClCompile Include="src\HTTPDigestCredentials.cpp"/> <ClCompile Include="src\HTTPDigestCredentials.cpp" />
<ClCompile Include="src\HTTPFixedLengthStream.cpp"/> <ClCompile Include="src\HTTPFixedLengthStream.cpp" />
<ClCompile Include="src\HTTPHeaderStream.cpp"/> <ClCompile Include="src\HTTPHeaderStream.cpp" />
<ClCompile Include="src\HTTPIOStream.cpp"/> <ClCompile Include="src\HTTPIOStream.cpp" />
<ClCompile Include="src\HTTPMessage.cpp"/> <ClCompile Include="src\HTTPMessage.cpp" />
<ClCompile Include="src\HTTPRequest.cpp"/> <ClCompile Include="src\HTTPNTLMCredentials.cpp" />
<ClCompile Include="src\HTTPRequestHandler.cpp"/> <ClCompile Include="src\HTTPRequest.cpp" />
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp"/> <ClCompile Include="src\HTTPRequestHandler.cpp" />
<ClCompile Include="src\HTTPResponse.cpp"/> <ClCompile Include="src\HTTPRequestHandlerFactory.cpp" />
<ClCompile Include="src\HTTPServer.cpp"/> <ClCompile Include="src\HTTPResponse.cpp" />
<ClCompile Include="src\HTTPServerConnection.cpp"/> <ClCompile Include="src\HTTPServer.cpp" />
<ClCompile Include="src\HTTPServerConnectionFactory.cpp"/> <ClCompile Include="src\HTTPServerConnection.cpp" />
<ClCompile Include="src\HTTPServerParams.cpp"/> <ClCompile Include="src\HTTPServerConnectionFactory.cpp" />
<ClCompile Include="src\HTTPServerRequest.cpp"/> <ClCompile Include="src\HTTPServerParams.cpp" />
<ClCompile Include="src\HTTPServerRequestImpl.cpp"/> <ClCompile Include="src\HTTPServerRequest.cpp" />
<ClCompile Include="src\HTTPServerResponse.cpp"/> <ClCompile Include="src\HTTPServerRequestImpl.cpp" />
<ClCompile Include="src\HTTPServerResponseImpl.cpp"/> <ClCompile Include="src\HTTPServerResponse.cpp" />
<ClCompile Include="src\HTTPServerSession.cpp"/> <ClCompile Include="src\HTTPServerResponseImpl.cpp" />
<ClCompile Include="src\HTTPSession.cpp"/> <ClCompile Include="src\HTTPServerSession.cpp" />
<ClCompile Include="src\HTTPSessionFactory.cpp"/> <ClCompile Include="src\HTTPSession.cpp" />
<ClCompile Include="src\HTTPSessionInstantiator.cpp"/> <ClCompile Include="src\HTTPSessionFactory.cpp" />
<ClCompile Include="src\HTTPStream.cpp"/> <ClCompile Include="src\HTTPSessionInstantiator.cpp" />
<ClCompile Include="src\HTTPStreamFactory.cpp"/> <ClCompile Include="src\HTTPStream.cpp" />
<ClCompile Include="src\ICMPClient.cpp"/> <ClCompile Include="src\HTTPStreamFactory.cpp" />
<ClCompile Include="src\ICMPEventArgs.cpp"/> <ClCompile Include="src\ICMPClient.cpp" />
<ClCompile Include="src\ICMPPacket.cpp"/> <ClCompile Include="src\ICMPEventArgs.cpp" />
<ClCompile Include="src\ICMPPacketImpl.cpp"/> <ClCompile Include="src\ICMPPacket.cpp" />
<ClCompile Include="src\ICMPSocket.cpp"/> <ClCompile Include="src\ICMPPacketImpl.cpp" />
<ClCompile Include="src\ICMPSocketImpl.cpp"/> <ClCompile Include="src\ICMPSocket.cpp" />
<ClCompile Include="src\ICMPv4PacketImpl.cpp"/> <ClCompile Include="src\ICMPSocketImpl.cpp" />
<ClCompile Include="src\IPAddress.cpp"/> <ClCompile Include="src\ICMPv4PacketImpl.cpp" />
<ClCompile Include="src\IPAddressImpl.cpp"/> <ClCompile Include="src\IPAddress.cpp" />
<ClCompile Include="src\MailMessage.cpp"/> <ClCompile Include="src\IPAddressImpl.cpp" />
<ClCompile Include="src\MailRecipient.cpp"/> <ClCompile Include="src\MailMessage.cpp" />
<ClCompile Include="src\MailStream.cpp"/> <ClCompile Include="src\MailRecipient.cpp" />
<ClCompile Include="src\MediaType.cpp"/> <ClCompile Include="src\MailStream.cpp" />
<ClCompile Include="src\MessageHeader.cpp"/> <ClCompile Include="src\MediaType.cpp" />
<ClCompile Include="src\MulticastSocket.cpp"/> <ClCompile Include="src\MessageHeader.cpp" />
<ClCompile Include="src\MultipartReader.cpp"/> <ClCompile Include="src\MulticastSocket.cpp" />
<ClCompile Include="src\MultipartWriter.cpp"/> <ClCompile Include="src\MultipartReader.cpp" />
<ClCompile Include="src\NameValueCollection.cpp"/> <ClCompile Include="src\MultipartWriter.cpp" />
<ClCompile Include="src\Net.cpp"/> <ClCompile Include="src\NameValueCollection.cpp" />
<ClCompile Include="src\NetException.cpp"/> <ClCompile Include="src\Net.cpp" />
<ClCompile Include="src\NetworkInterface.cpp"/> <ClCompile Include="src\NetException.cpp" />
<ClCompile Include="src\NTPClient.cpp"/> <ClCompile Include="src\NetworkInterface.cpp" />
<ClCompile Include="src\NTPEventArgs.cpp"/> <ClCompile Include="src\NTLMCredentials.cpp" />
<ClCompile Include="src\NTPPacket.cpp"/> <ClCompile Include="src\NTPClient.cpp" />
<ClCompile Include="src\NullPartHandler.cpp"/> <ClCompile Include="src\NTPEventArgs.cpp" />
<ClCompile Include="src\OAuth10Credentials.cpp"/> <ClCompile Include="src\NTPPacket.cpp" />
<ClCompile Include="src\OAuth20Credentials.cpp"/> <ClCompile Include="src\NullPartHandler.cpp" />
<ClCompile Include="src\PartHandler.cpp"/> <ClCompile Include="src\OAuth10Credentials.cpp" />
<ClCompile Include="src\PartSource.cpp"/> <ClCompile Include="src\OAuth20Credentials.cpp" />
<ClCompile Include="src\PartStore.cpp"/> <ClCompile Include="src\PartHandler.cpp" />
<ClCompile Include="src\PollSet.cpp"/> <ClCompile Include="src\PartSource.cpp" />
<ClCompile Include="src\POP3ClientSession.cpp"/> <ClCompile Include="src\PartStore.cpp" />
<ClCompile Include="src\QuotedPrintableDecoder.cpp"/> <ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\QuotedPrintableEncoder.cpp"/> <ClCompile Include="src\POP3ClientSession.cpp" />
<ClCompile Include="src\RawSocket.cpp"/> <ClCompile Include="src\QuotedPrintableDecoder.cpp" />
<ClCompile Include="src\RawSocketImpl.cpp"/> <ClCompile Include="src\QuotedPrintableEncoder.cpp" />
<ClCompile Include="src\RemoteSyslogChannel.cpp"/> <ClCompile Include="src\RawSocket.cpp" />
<ClCompile Include="src\RemoteSyslogListener.cpp"/> <ClCompile Include="src\RawSocketImpl.cpp" />
<ClCompile Include="src\ServerSocket.cpp"/> <ClCompile Include="src\RemoteSyslogChannel.cpp" />
<ClCompile Include="src\ServerSocketImpl.cpp"/> <ClCompile Include="src\RemoteSyslogListener.cpp" />
<ClCompile Include="src\SMTPChannel.cpp"/> <ClCompile Include="src\ServerSocket.cpp" />
<ClCompile Include="src\SMTPClientSession.cpp"/> <ClCompile Include="src\ServerSocketImpl.cpp" />
<ClCompile Include="src\Socket.cpp"/> <ClCompile Include="src\SMTPChannel.cpp" />
<ClCompile Include="src\SocketAddress.cpp"/> <ClCompile Include="src\SMTPClientSession.cpp" />
<ClCompile Include="src\SocketAddressImpl.cpp"/> <ClCompile Include="src\Socket.cpp" />
<ClCompile Include="src\SocketImpl.cpp"/> <ClCompile Include="src\SocketAddress.cpp" />
<ClCompile Include="src\SocketNotification.cpp"/> <ClCompile Include="src\SocketAddressImpl.cpp" />
<ClCompile Include="src\SocketNotifier.cpp"/> <ClCompile Include="src\SocketImpl.cpp" />
<ClCompile Include="src\SocketReactor.cpp"/> <ClCompile Include="src\SocketNotification.cpp" />
<ClCompile Include="src\SocketStream.cpp"/> <ClCompile Include="src\SocketNotifier.cpp" />
<ClCompile Include="src\StreamSocket.cpp"/> <ClCompile Include="src\SocketReactor.cpp" />
<ClCompile Include="src\StreamSocketImpl.cpp"/> <ClCompile Include="src\SocketStream.cpp" />
<ClCompile Include="src\StringPartSource.cpp"/> <ClCompile Include="src\SSPINTLMCredentials.cpp" />
<ClCompile Include="src\TCPServer.cpp"/> <ClCompile Include="src\StreamSocket.cpp" />
<ClCompile Include="src\TCPServerConnection.cpp"/> <ClCompile Include="src\StreamSocketImpl.cpp" />
<ClCompile Include="src\TCPServerConnectionFactory.cpp"/> <ClCompile Include="src\StringPartSource.cpp" />
<ClCompile Include="src\TCPServerDispatcher.cpp"/> <ClCompile Include="src\TCPServer.cpp" />
<ClCompile Include="src\TCPServerParams.cpp"/> <ClCompile Include="src\TCPServerConnection.cpp" />
<ClCompile Include="src\UDPClient.cpp"/> <ClCompile Include="src\TCPServerConnectionFactory.cpp" />
<ClCompile Include="src\UDPServerParams.cpp"/> <ClCompile Include="src\TCPServerDispatcher.cpp" />
<ClCompile Include="src\WebSocket.cpp"/> <ClCompile Include="src\TCPServerParams.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp"/> <ClCompile Include="src\UDPClient.cpp" />
<ClCompile Include="src\UDPServerParams.cpp" />
<ClCompile Include="src\WebSocket.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc"> <ResourceCompile Include="..\DLLVersion.rc">

View File

@@ -154,6 +154,15 @@
<Filter Include="UDP\Header Files"> <Filter Include="UDP\Header Files">
<UniqueIdentifier>{3543e216-de43-4d98-88cd-f0a2da4d6925}</UniqueIdentifier> <UniqueIdentifier>{3543e216-de43-4d98-88cd-f0a2da4d6925}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="NTLM">
<UniqueIdentifier>{046c78a1-263f-4337-b6b1-ff9ec2306f3a}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Header Files">
<UniqueIdentifier>{ca314a28-271d-434d-a2d1-ff0a4b7985bc}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Source Files">
<UniqueIdentifier>{3142a0d0-e2ef-4abd-b446-4c5a5bb5626a}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\DNS.h"> <ClInclude Include="include\Poco\Net\DNS.h">
@@ -492,6 +501,16 @@
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"> <ClInclude Include="include\Poco\Net\UDPSocketReader.h">
<Filter>UDP\Header Files</Filter> <Filter>UDP\Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\NTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h">
<Filter>HTTP\Header Files</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\DNS.cpp"> <ClCompile Include="src\DNS.cpp">
@@ -797,6 +816,16 @@
<ClCompile Include="src\UDPServerParams.cpp"> <ClCompile Include="src\UDPServerParams.cpp">
<Filter>UDP\Source Files</Filter> <Filter>UDP\Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\HTTPNTLMCredentials.cpp">
<Filter>HTTP\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\NTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\SSPINTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc" /> <ResourceCompile Include="..\DLLVersion.rc" />

View File

@@ -279,223 +279,229 @@
</Lib> </Lib>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\DatagramSocket.h"/> <ClInclude Include="include\Poco\Net\DatagramSocket.h" />
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h"/> <ClInclude Include="include\Poco\Net\DatagramSocketImpl.h" />
<ClInclude Include="include\Poco\Net\DialogSocket.h"/> <ClInclude Include="include\Poco\Net\DialogSocket.h" />
<ClInclude Include="include\Poco\Net\DNS.h"/> <ClInclude Include="include\Poco\Net\DNS.h" />
<ClInclude Include="include\Poco\Net\FilePartSource.h"/> <ClInclude Include="include\Poco\Net\FilePartSource.h" />
<ClInclude Include="include\Poco\Net\FTPClientSession.h"/> <ClInclude Include="include\Poco\Net\FTPClientSession.h" />
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\FTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\HostEntry.h"/> <ClInclude Include="include\Poco\Net\HostEntry.h" />
<ClInclude Include="include\Poco\Net\HTMLForm.h"/> <ClInclude Include="include\Poco\Net\HTMLForm.h" />
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h"/> <ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h" />
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h"/> <ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h" />
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h"/> <ClInclude Include="include\Poco\Net\HTTPChunkedStream.h" />
<ClInclude Include="include\Poco\Net\HTTPClientSession.h"/> <ClInclude Include="include\Poco\Net\HTTPClientSession.h" />
<ClInclude Include="include\Poco\Net\HTTPCookie.h"/> <ClInclude Include="include\Poco\Net\HTTPCookie.h" />
<ClInclude Include="include\Poco\Net\HTTPCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h"/> <ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h" />
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h"/> <ClInclude Include="include\Poco\Net\HTTPHeaderStream.h" />
<ClInclude Include="include\Poco\Net\HTTPIOStream.h"/> <ClInclude Include="include\Poco\Net\HTTPIOStream.h" />
<ClInclude Include="include\Poco\Net\HTTPMessage.h"/> <ClInclude Include="include\Poco\Net\HTTPMessage.h" />
<ClInclude Include="include\Poco\Net\HTTPRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\HTTPRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\HTTPResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServer.h"/> <ClInclude Include="include\Poco\Net\HTTPResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h"/> <ClInclude Include="include\Poco\Net\HTTPServer.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnection.h" />
<ClInclude Include="include\Poco\Net\HTTPServerParams.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPServerParams.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPStream.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h" />
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPStream.h" />
<ClInclude Include="include\Poco\Net\ICMPClient.h"/> <ClInclude Include="include\Poco\Net\HTTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h"/> <ClInclude Include="include\Poco\Net\ICMPClient.h" />
<ClInclude Include="include\Poco\Net\ICMPPacket.h"/> <ClInclude Include="include\Poco\Net\ICMPEventArgs.h" />
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPPacket.h" />
<ClInclude Include="include\Poco\Net\ICMPSocket.h"/> <ClInclude Include="include\Poco\Net\ICMPPacketImpl.h" />
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocket.h" />
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddress.h"/> <ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddressImpl.h"/> <ClInclude Include="include\Poco\Net\IPAddress.h" />
<ClInclude Include="include\Poco\Net\MailMessage.h"/> <ClInclude Include="include\Poco\Net\IPAddressImpl.h" />
<ClInclude Include="include\Poco\Net\MailRecipient.h"/> <ClInclude Include="include\Poco\Net\MailMessage.h" />
<ClInclude Include="include\Poco\Net\MailStream.h"/> <ClInclude Include="include\Poco\Net\MailRecipient.h" />
<ClInclude Include="include\Poco\Net\MediaType.h"/> <ClInclude Include="include\Poco\Net\MailStream.h" />
<ClInclude Include="include\Poco\Net\MessageHeader.h"/> <ClInclude Include="include\Poco\Net\MediaType.h" />
<ClInclude Include="include\Poco\Net\MulticastSocket.h"/> <ClInclude Include="include\Poco\Net\MessageHeader.h" />
<ClInclude Include="include\Poco\Net\MultipartReader.h"/> <ClInclude Include="include\Poco\Net\MulticastSocket.h" />
<ClInclude Include="include\Poco\Net\MultipartWriter.h"/> <ClInclude Include="include\Poco\Net\MultipartReader.h" />
<ClInclude Include="include\Poco\Net\MultiSocketPoller.h"/> <ClInclude Include="include\Poco\Net\MultipartWriter.h" />
<ClInclude Include="include\Poco\Net\NameValueCollection.h"/> <ClInclude Include="include\Poco\Net\MultiSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Net.h"/> <ClInclude Include="include\Poco\Net\NameValueCollection.h" />
<ClInclude Include="include\Poco\Net\NetException.h"/> <ClInclude Include="include\Poco\Net\Net.h" />
<ClInclude Include="include\Poco\Net\NetworkInterface.h"/> <ClInclude Include="include\Poco\Net\NetException.h" />
<ClInclude Include="include\Poco\Net\NTPClient.h"/> <ClInclude Include="include\Poco\Net\NetworkInterface.h" />
<ClInclude Include="include\Poco\Net\NTPEventArgs.h"/> <ClInclude Include="include\Poco\Net\NTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\NTPPacket.h"/> <ClInclude Include="include\Poco\Net\NTPClient.h" />
<ClInclude Include="include\Poco\Net\NullPartHandler.h"/> <ClInclude Include="include\Poco\Net\NTPEventArgs.h" />
<ClInclude Include="include\Poco\Net\OAuth10Credentials.h"/> <ClInclude Include="include\Poco\Net\NTPPacket.h" />
<ClInclude Include="include\Poco\Net\OAuth20Credentials.h"/> <ClInclude Include="include\Poco\Net\NullPartHandler.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\OAuth10Credentials.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketReactor.h"/> <ClInclude Include="include\Poco\Net\OAuth20Credentials.h" />
<ClInclude Include="include\Poco\Net\PartHandler.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\PartSource.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketReactor.h" />
<ClInclude Include="include\Poco\Net\PartStore.h"/> <ClInclude Include="include\Poco\Net\PartHandler.h" />
<ClInclude Include="include\Poco\Net\PollSet.h"/> <ClInclude Include="include\Poco\Net\PartSource.h" />
<ClInclude Include="include\Poco\Net\POP3ClientSession.h"/> <ClInclude Include="include\Poco\Net\PartStore.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h"/> <ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h"/> <ClInclude Include="include\Poco\Net\POP3ClientSession.h" />
<ClInclude Include="include\Poco\Net\RawSocket.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h" />
<ClInclude Include="include\Poco\Net\RawSocketImpl.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h"/> <ClInclude Include="include\Poco\Net\RawSocket.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h"/> <ClInclude Include="include\Poco\Net\RawSocketImpl.h" />
<ClInclude Include="include\Poco\Net\ServerSocket.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h" />
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogListener.h" />
<ClInclude Include="include\Poco\Net\SingleSocketPoller.h"/> <ClInclude Include="include\Poco\Net\ServerSocket.h" />
<ClInclude Include="include\Poco\Net\SMTPChannel.h"/> <ClInclude Include="include\Poco\Net\ServerSocketImpl.h" />
<ClInclude Include="include\Poco\Net\SMTPClientSession.h"/> <ClInclude Include="include\Poco\Net\SingleSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Socket.h"/> <ClInclude Include="include\Poco\Net\SMTPChannel.h" />
<ClInclude Include="include\Poco\Net\SocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\SMTPClientSession.h" />
<ClInclude Include="include\Poco\Net\SocketAddress.h"/> <ClInclude Include="include\Poco\Net\Socket.h" />
<ClInclude Include="include\Poco\Net\SocketAddressImpl.h"/> <ClInclude Include="include\Poco\Net\SocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\SocketConnector.h"/> <ClInclude Include="include\Poco\Net\SocketAddress.h" />
<ClInclude Include="include\Poco\Net\SocketDefs.h"/> <ClInclude Include="include\Poco\Net\SocketAddressImpl.h" />
<ClInclude Include="include\Poco\Net\SocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketConnector.h" />
<ClInclude Include="include\Poco\Net\SocketNotification.h"/> <ClInclude Include="include\Poco\Net\SocketDefs.h" />
<ClInclude Include="include\Poco\Net\SocketNotifier.h"/> <ClInclude Include="include\Poco\Net\SocketImpl.h" />
<ClInclude Include="include\Poco\Net\SocketReactor.h"/> <ClInclude Include="include\Poco\Net\SocketNotification.h" />
<ClInclude Include="include\Poco\Net\SocketStream.h"/> <ClInclude Include="include\Poco\Net\SocketNotifier.h" />
<ClInclude Include="include\Poco\Net\StreamSocket.h"/> <ClInclude Include="include\Poco\Net\SocketReactor.h" />
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketStream.h" />
<ClInclude Include="include\Poco\Net\StringPartSource.h"/> <ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\TCPServer.h"/> <ClInclude Include="include\Poco\Net\StreamSocket.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnection.h"/> <ClInclude Include="include\Poco\Net\StreamSocketImpl.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\StringPartSource.h" />
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h"/> <ClInclude Include="include\Poco\Net\TCPServer.h" />
<ClInclude Include="include\Poco\Net\TCPServerParams.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnection.h" />
<ClInclude Include="include\Poco\Net\UDPClient.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\UDPHandler.h"/> <ClInclude Include="include\Poco\Net\TCPServerDispatcher.h" />
<ClInclude Include="include\Poco\Net\UDPServer.h"/> <ClInclude Include="include\Poco\Net\TCPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPServerParams.h"/> <ClInclude Include="include\Poco\Net\UDPClient.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"/> <ClInclude Include="include\Poco\Net\UDPHandler.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h"/> <ClInclude Include="include\Poco\Net\UDPServer.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h"/> <ClInclude Include="include\Poco\Net\UDPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp"/> <ClCompile Include="src\AbstractHTTPRequestHandler.cpp" />
<ClCompile Include="src\DatagramSocket.cpp"/> <ClCompile Include="src\DatagramSocket.cpp" />
<ClCompile Include="src\DatagramSocketImpl.cpp"/> <ClCompile Include="src\DatagramSocketImpl.cpp" />
<ClCompile Include="src\DialogSocket.cpp"/> <ClCompile Include="src\DialogSocket.cpp" />
<ClCompile Include="src\DNS.cpp"/> <ClCompile Include="src\DNS.cpp" />
<ClCompile Include="src\FilePartSource.cpp"/> <ClCompile Include="src\FilePartSource.cpp" />
<ClCompile Include="src\FTPClientSession.cpp"/> <ClCompile Include="src\FTPClientSession.cpp" />
<ClCompile Include="src\FTPStreamFactory.cpp"/> <ClCompile Include="src\FTPStreamFactory.cpp" />
<ClCompile Include="src\HostEntry.cpp"/> <ClCompile Include="src\HostEntry.cpp" />
<ClCompile Include="src\HTMLForm.cpp"/> <ClCompile Include="src\HTMLForm.cpp" />
<ClCompile Include="src\HTTPAuthenticationParams.cpp"/> <ClCompile Include="src\HTTPAuthenticationParams.cpp" />
<ClCompile Include="src\HTTPBasicCredentials.cpp"/> <ClCompile Include="src\HTTPBasicCredentials.cpp" />
<ClCompile Include="src\HTTPBufferAllocator.cpp"/> <ClCompile Include="src\HTTPBufferAllocator.cpp" />
<ClCompile Include="src\HTTPChunkedStream.cpp"/> <ClCompile Include="src\HTTPChunkedStream.cpp" />
<ClCompile Include="src\HTTPClientSession.cpp"/> <ClCompile Include="src\HTTPClientSession.cpp" />
<ClCompile Include="src\HTTPCookie.cpp"/> <ClCompile Include="src\HTTPCookie.cpp" />
<ClCompile Include="src\HTTPCredentials.cpp"/> <ClCompile Include="src\HTTPCredentials.cpp" />
<ClCompile Include="src\HTTPDigestCredentials.cpp"/> <ClCompile Include="src\HTTPDigestCredentials.cpp" />
<ClCompile Include="src\HTTPFixedLengthStream.cpp"/> <ClCompile Include="src\HTTPFixedLengthStream.cpp" />
<ClCompile Include="src\HTTPHeaderStream.cpp"/> <ClCompile Include="src\HTTPHeaderStream.cpp" />
<ClCompile Include="src\HTTPIOStream.cpp"/> <ClCompile Include="src\HTTPIOStream.cpp" />
<ClCompile Include="src\HTTPMessage.cpp"/> <ClCompile Include="src\HTTPMessage.cpp" />
<ClCompile Include="src\HTTPRequest.cpp"/> <ClCompile Include="src\HTTPNTLMCredentials.cpp" />
<ClCompile Include="src\HTTPRequestHandler.cpp"/> <ClCompile Include="src\HTTPRequest.cpp" />
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp"/> <ClCompile Include="src\HTTPRequestHandler.cpp" />
<ClCompile Include="src\HTTPResponse.cpp"/> <ClCompile Include="src\HTTPRequestHandlerFactory.cpp" />
<ClCompile Include="src\HTTPServer.cpp"/> <ClCompile Include="src\HTTPResponse.cpp" />
<ClCompile Include="src\HTTPServerConnection.cpp"/> <ClCompile Include="src\HTTPServer.cpp" />
<ClCompile Include="src\HTTPServerConnectionFactory.cpp"/> <ClCompile Include="src\HTTPServerConnection.cpp" />
<ClCompile Include="src\HTTPServerParams.cpp"/> <ClCompile Include="src\HTTPServerConnectionFactory.cpp" />
<ClCompile Include="src\HTTPServerRequest.cpp"/> <ClCompile Include="src\HTTPServerParams.cpp" />
<ClCompile Include="src\HTTPServerRequestImpl.cpp"/> <ClCompile Include="src\HTTPServerRequest.cpp" />
<ClCompile Include="src\HTTPServerResponse.cpp"/> <ClCompile Include="src\HTTPServerRequestImpl.cpp" />
<ClCompile Include="src\HTTPServerResponseImpl.cpp"/> <ClCompile Include="src\HTTPServerResponse.cpp" />
<ClCompile Include="src\HTTPServerSession.cpp"/> <ClCompile Include="src\HTTPServerResponseImpl.cpp" />
<ClCompile Include="src\HTTPSession.cpp"/> <ClCompile Include="src\HTTPServerSession.cpp" />
<ClCompile Include="src\HTTPSessionFactory.cpp"/> <ClCompile Include="src\HTTPSession.cpp" />
<ClCompile Include="src\HTTPSessionInstantiator.cpp"/> <ClCompile Include="src\HTTPSessionFactory.cpp" />
<ClCompile Include="src\HTTPStream.cpp"/> <ClCompile Include="src\HTTPSessionInstantiator.cpp" />
<ClCompile Include="src\HTTPStreamFactory.cpp"/> <ClCompile Include="src\HTTPStream.cpp" />
<ClCompile Include="src\ICMPClient.cpp"/> <ClCompile Include="src\HTTPStreamFactory.cpp" />
<ClCompile Include="src\ICMPEventArgs.cpp"/> <ClCompile Include="src\ICMPClient.cpp" />
<ClCompile Include="src\ICMPPacket.cpp"/> <ClCompile Include="src\ICMPEventArgs.cpp" />
<ClCompile Include="src\ICMPPacketImpl.cpp"/> <ClCompile Include="src\ICMPPacket.cpp" />
<ClCompile Include="src\ICMPSocket.cpp"/> <ClCompile Include="src\ICMPPacketImpl.cpp" />
<ClCompile Include="src\ICMPSocketImpl.cpp"/> <ClCompile Include="src\ICMPSocket.cpp" />
<ClCompile Include="src\ICMPv4PacketImpl.cpp"/> <ClCompile Include="src\ICMPSocketImpl.cpp" />
<ClCompile Include="src\IPAddress.cpp"/> <ClCompile Include="src\ICMPv4PacketImpl.cpp" />
<ClCompile Include="src\IPAddressImpl.cpp"/> <ClCompile Include="src\IPAddress.cpp" />
<ClCompile Include="src\MailMessage.cpp"/> <ClCompile Include="src\IPAddressImpl.cpp" />
<ClCompile Include="src\MailRecipient.cpp"/> <ClCompile Include="src\MailMessage.cpp" />
<ClCompile Include="src\MailStream.cpp"/> <ClCompile Include="src\MailRecipient.cpp" />
<ClCompile Include="src\MediaType.cpp"/> <ClCompile Include="src\MailStream.cpp" />
<ClCompile Include="src\MessageHeader.cpp"/> <ClCompile Include="src\MediaType.cpp" />
<ClCompile Include="src\MulticastSocket.cpp"/> <ClCompile Include="src\MessageHeader.cpp" />
<ClCompile Include="src\MultipartReader.cpp"/> <ClCompile Include="src\MulticastSocket.cpp" />
<ClCompile Include="src\MultipartWriter.cpp"/> <ClCompile Include="src\MultipartReader.cpp" />
<ClCompile Include="src\NameValueCollection.cpp"/> <ClCompile Include="src\MultipartWriter.cpp" />
<ClCompile Include="src\Net.cpp"/> <ClCompile Include="src\NameValueCollection.cpp" />
<ClCompile Include="src\NetException.cpp"/> <ClCompile Include="src\Net.cpp" />
<ClCompile Include="src\NetworkInterface.cpp"/> <ClCompile Include="src\NetException.cpp" />
<ClCompile Include="src\NTPClient.cpp"/> <ClCompile Include="src\NetworkInterface.cpp" />
<ClCompile Include="src\NTPEventArgs.cpp"/> <ClCompile Include="src\NTLMCredentials.cpp" />
<ClCompile Include="src\NTPPacket.cpp"/> <ClCompile Include="src\NTPClient.cpp" />
<ClCompile Include="src\NullPartHandler.cpp"/> <ClCompile Include="src\NTPEventArgs.cpp" />
<ClCompile Include="src\OAuth10Credentials.cpp"/> <ClCompile Include="src\NTPPacket.cpp" />
<ClCompile Include="src\OAuth20Credentials.cpp"/> <ClCompile Include="src\NullPartHandler.cpp" />
<ClCompile Include="src\PartHandler.cpp"/> <ClCompile Include="src\OAuth10Credentials.cpp" />
<ClCompile Include="src\PartSource.cpp"/> <ClCompile Include="src\OAuth20Credentials.cpp" />
<ClCompile Include="src\PartStore.cpp"/> <ClCompile Include="src\PartHandler.cpp" />
<ClCompile Include="src\PollSet.cpp"/> <ClCompile Include="src\PartSource.cpp" />
<ClCompile Include="src\POP3ClientSession.cpp"/> <ClCompile Include="src\PartStore.cpp" />
<ClCompile Include="src\QuotedPrintableDecoder.cpp"/> <ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\QuotedPrintableEncoder.cpp"/> <ClCompile Include="src\POP3ClientSession.cpp" />
<ClCompile Include="src\RawSocket.cpp"/> <ClCompile Include="src\QuotedPrintableDecoder.cpp" />
<ClCompile Include="src\RawSocketImpl.cpp"/> <ClCompile Include="src\QuotedPrintableEncoder.cpp" />
<ClCompile Include="src\RemoteSyslogChannel.cpp"/> <ClCompile Include="src\RawSocket.cpp" />
<ClCompile Include="src\RemoteSyslogListener.cpp"/> <ClCompile Include="src\RawSocketImpl.cpp" />
<ClCompile Include="src\ServerSocket.cpp"/> <ClCompile Include="src\RemoteSyslogChannel.cpp" />
<ClCompile Include="src\ServerSocketImpl.cpp"/> <ClCompile Include="src\RemoteSyslogListener.cpp" />
<ClCompile Include="src\SMTPChannel.cpp"/> <ClCompile Include="src\ServerSocket.cpp" />
<ClCompile Include="src\SMTPClientSession.cpp"/> <ClCompile Include="src\ServerSocketImpl.cpp" />
<ClCompile Include="src\Socket.cpp"/> <ClCompile Include="src\SMTPChannel.cpp" />
<ClCompile Include="src\SocketAddress.cpp"/> <ClCompile Include="src\SMTPClientSession.cpp" />
<ClCompile Include="src\SocketAddressImpl.cpp"/> <ClCompile Include="src\Socket.cpp" />
<ClCompile Include="src\SocketImpl.cpp"/> <ClCompile Include="src\SocketAddress.cpp" />
<ClCompile Include="src\SocketNotification.cpp"/> <ClCompile Include="src\SocketAddressImpl.cpp" />
<ClCompile Include="src\SocketNotifier.cpp"/> <ClCompile Include="src\SocketImpl.cpp" />
<ClCompile Include="src\SocketReactor.cpp"/> <ClCompile Include="src\SocketNotification.cpp" />
<ClCompile Include="src\SocketStream.cpp"/> <ClCompile Include="src\SocketNotifier.cpp" />
<ClCompile Include="src\StreamSocket.cpp"/> <ClCompile Include="src\SocketReactor.cpp" />
<ClCompile Include="src\StreamSocketImpl.cpp"/> <ClCompile Include="src\SocketStream.cpp" />
<ClCompile Include="src\StringPartSource.cpp"/> <ClCompile Include="src\SSPINTLMCredentials.cpp" />
<ClCompile Include="src\TCPServer.cpp"/> <ClCompile Include="src\StreamSocket.cpp" />
<ClCompile Include="src\TCPServerConnection.cpp"/> <ClCompile Include="src\StreamSocketImpl.cpp" />
<ClCompile Include="src\TCPServerConnectionFactory.cpp"/> <ClCompile Include="src\StringPartSource.cpp" />
<ClCompile Include="src\TCPServerDispatcher.cpp"/> <ClCompile Include="src\TCPServer.cpp" />
<ClCompile Include="src\TCPServerParams.cpp"/> <ClCompile Include="src\TCPServerConnection.cpp" />
<ClCompile Include="src\UDPClient.cpp"/> <ClCompile Include="src\TCPServerConnectionFactory.cpp" />
<ClCompile Include="src\UDPServerParams.cpp"/> <ClCompile Include="src\TCPServerDispatcher.cpp" />
<ClCompile Include="src\WebSocket.cpp"/> <ClCompile Include="src\TCPServerParams.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp"/> <ClCompile Include="src\UDPClient.cpp" />
<ClCompile Include="src\UDPServerParams.cpp" />
<ClCompile Include="src\WebSocket.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc"> <ResourceCompile Include="..\DLLVersion.rc">

View File

@@ -154,6 +154,15 @@
<Filter Include="UDP\Header Files"> <Filter Include="UDP\Header Files">
<UniqueIdentifier>{2f7bbb60-4d9d-4671-b5cc-f1b6164f745b}</UniqueIdentifier> <UniqueIdentifier>{2f7bbb60-4d9d-4671-b5cc-f1b6164f745b}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="NTLM">
<UniqueIdentifier>{ecca1179-127e-4fa2-8bbf-255f58439ff9}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Header Files">
<UniqueIdentifier>{f58c8c2d-a26e-4be9-9ec2-dcd11366c237}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Source Files">
<UniqueIdentifier>{793f44fe-1301-4744-985c-a371eea90422}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\DNS.h"> <ClInclude Include="include\Poco\Net\DNS.h">
@@ -492,6 +501,16 @@
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"> <ClInclude Include="include\Poco\Net\UDPSocketReader.h">
<Filter>UDP\Header Files</Filter> <Filter>UDP\Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h">
<Filter>HTTP\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\NTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\DNS.cpp"> <ClCompile Include="src\DNS.cpp">
@@ -797,6 +816,16 @@
<ClCompile Include="src\UDPServerParams.cpp"> <ClCompile Include="src\UDPServerParams.cpp">
<Filter>UDP\Source Files</Filter> <Filter>UDP\Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\HTTPNTLMCredentials.cpp">
<Filter>HTTP\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\NTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\SSPINTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc" /> <ResourceCompile Include="..\DLLVersion.rc" />

View File

@@ -277,223 +277,229 @@
</Lib> </Lib>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\DatagramSocket.h"/> <ClInclude Include="include\Poco\Net\DatagramSocket.h" />
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h"/> <ClInclude Include="include\Poco\Net\DatagramSocketImpl.h" />
<ClInclude Include="include\Poco\Net\DialogSocket.h"/> <ClInclude Include="include\Poco\Net\DialogSocket.h" />
<ClInclude Include="include\Poco\Net\DNS.h"/> <ClInclude Include="include\Poco\Net\DNS.h" />
<ClInclude Include="include\Poco\Net\FilePartSource.h"/> <ClInclude Include="include\Poco\Net\FilePartSource.h" />
<ClInclude Include="include\Poco\Net\FTPClientSession.h"/> <ClInclude Include="include\Poco\Net\FTPClientSession.h" />
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\FTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\HostEntry.h"/> <ClInclude Include="include\Poco\Net\HostEntry.h" />
<ClInclude Include="include\Poco\Net\HTMLForm.h"/> <ClInclude Include="include\Poco\Net\HTMLForm.h" />
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h"/> <ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h" />
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h"/> <ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h" />
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h"/> <ClInclude Include="include\Poco\Net\HTTPChunkedStream.h" />
<ClInclude Include="include\Poco\Net\HTTPClientSession.h"/> <ClInclude Include="include\Poco\Net\HTTPClientSession.h" />
<ClInclude Include="include\Poco\Net\HTTPCookie.h"/> <ClInclude Include="include\Poco\Net\HTTPCookie.h" />
<ClInclude Include="include\Poco\Net\HTTPCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h"/> <ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h" />
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h"/> <ClInclude Include="include\Poco\Net\HTTPHeaderStream.h" />
<ClInclude Include="include\Poco\Net\HTTPIOStream.h"/> <ClInclude Include="include\Poco\Net\HTTPIOStream.h" />
<ClInclude Include="include\Poco\Net\HTTPMessage.h"/> <ClInclude Include="include\Poco\Net\HTTPMessage.h" />
<ClInclude Include="include\Poco\Net\HTTPRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\HTTPRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\HTTPResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServer.h"/> <ClInclude Include="include\Poco\Net\HTTPResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h"/> <ClInclude Include="include\Poco\Net\HTTPServer.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnection.h" />
<ClInclude Include="include\Poco\Net\HTTPServerParams.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPServerParams.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPStream.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h" />
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPStream.h" />
<ClInclude Include="include\Poco\Net\ICMPClient.h"/> <ClInclude Include="include\Poco\Net\HTTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h"/> <ClInclude Include="include\Poco\Net\ICMPClient.h" />
<ClInclude Include="include\Poco\Net\ICMPPacket.h"/> <ClInclude Include="include\Poco\Net\ICMPEventArgs.h" />
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPPacket.h" />
<ClInclude Include="include\Poco\Net\ICMPSocket.h"/> <ClInclude Include="include\Poco\Net\ICMPPacketImpl.h" />
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocket.h" />
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddress.h"/> <ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddressImpl.h"/> <ClInclude Include="include\Poco\Net\IPAddress.h" />
<ClInclude Include="include\Poco\Net\MailMessage.h"/> <ClInclude Include="include\Poco\Net\IPAddressImpl.h" />
<ClInclude Include="include\Poco\Net\MailRecipient.h"/> <ClInclude Include="include\Poco\Net\MailMessage.h" />
<ClInclude Include="include\Poco\Net\MailStream.h"/> <ClInclude Include="include\Poco\Net\MailRecipient.h" />
<ClInclude Include="include\Poco\Net\MediaType.h"/> <ClInclude Include="include\Poco\Net\MailStream.h" />
<ClInclude Include="include\Poco\Net\MessageHeader.h"/> <ClInclude Include="include\Poco\Net\MediaType.h" />
<ClInclude Include="include\Poco\Net\MulticastSocket.h"/> <ClInclude Include="include\Poco\Net\MessageHeader.h" />
<ClInclude Include="include\Poco\Net\MultipartReader.h"/> <ClInclude Include="include\Poco\Net\MulticastSocket.h" />
<ClInclude Include="include\Poco\Net\MultipartWriter.h"/> <ClInclude Include="include\Poco\Net\MultipartReader.h" />
<ClInclude Include="include\Poco\Net\MultiSocketPoller.h"/> <ClInclude Include="include\Poco\Net\MultipartWriter.h" />
<ClInclude Include="include\Poco\Net\NameValueCollection.h"/> <ClInclude Include="include\Poco\Net\MultiSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Net.h"/> <ClInclude Include="include\Poco\Net\NameValueCollection.h" />
<ClInclude Include="include\Poco\Net\NetException.h"/> <ClInclude Include="include\Poco\Net\Net.h" />
<ClInclude Include="include\Poco\Net\NetworkInterface.h"/> <ClInclude Include="include\Poco\Net\NetException.h" />
<ClInclude Include="include\Poco\Net\NTPClient.h"/> <ClInclude Include="include\Poco\Net\NetworkInterface.h" />
<ClInclude Include="include\Poco\Net\NTPEventArgs.h"/> <ClInclude Include="include\Poco\Net\NTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\NTPPacket.h"/> <ClInclude Include="include\Poco\Net\NTPClient.h" />
<ClInclude Include="include\Poco\Net\NullPartHandler.h"/> <ClInclude Include="include\Poco\Net\NTPEventArgs.h" />
<ClInclude Include="include\Poco\Net\OAuth10Credentials.h"/> <ClInclude Include="include\Poco\Net\NTPPacket.h" />
<ClInclude Include="include\Poco\Net\OAuth20Credentials.h"/> <ClInclude Include="include\Poco\Net\NullPartHandler.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\OAuth10Credentials.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketReactor.h"/> <ClInclude Include="include\Poco\Net\OAuth20Credentials.h" />
<ClInclude Include="include\Poco\Net\PartHandler.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\PartSource.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketReactor.h" />
<ClInclude Include="include\Poco\Net\PartStore.h"/> <ClInclude Include="include\Poco\Net\PartHandler.h" />
<ClInclude Include="include\Poco\Net\PollSet.h"/> <ClInclude Include="include\Poco\Net\PartSource.h" />
<ClInclude Include="include\Poco\Net\POP3ClientSession.h"/> <ClInclude Include="include\Poco\Net\PartStore.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h"/> <ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h"/> <ClInclude Include="include\Poco\Net\POP3ClientSession.h" />
<ClInclude Include="include\Poco\Net\RawSocket.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h" />
<ClInclude Include="include\Poco\Net\RawSocketImpl.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h"/> <ClInclude Include="include\Poco\Net\RawSocket.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h"/> <ClInclude Include="include\Poco\Net\RawSocketImpl.h" />
<ClInclude Include="include\Poco\Net\ServerSocket.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h" />
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogListener.h" />
<ClInclude Include="include\Poco\Net\SingleSocketPoller.h"/> <ClInclude Include="include\Poco\Net\ServerSocket.h" />
<ClInclude Include="include\Poco\Net\SMTPChannel.h"/> <ClInclude Include="include\Poco\Net\ServerSocketImpl.h" />
<ClInclude Include="include\Poco\Net\SMTPClientSession.h"/> <ClInclude Include="include\Poco\Net\SingleSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Socket.h"/> <ClInclude Include="include\Poco\Net\SMTPChannel.h" />
<ClInclude Include="include\Poco\Net\SocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\SMTPClientSession.h" />
<ClInclude Include="include\Poco\Net\SocketAddress.h"/> <ClInclude Include="include\Poco\Net\Socket.h" />
<ClInclude Include="include\Poco\Net\SocketAddressImpl.h"/> <ClInclude Include="include\Poco\Net\SocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\SocketConnector.h"/> <ClInclude Include="include\Poco\Net\SocketAddress.h" />
<ClInclude Include="include\Poco\Net\SocketDefs.h"/> <ClInclude Include="include\Poco\Net\SocketAddressImpl.h" />
<ClInclude Include="include\Poco\Net\SocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketConnector.h" />
<ClInclude Include="include\Poco\Net\SocketNotification.h"/> <ClInclude Include="include\Poco\Net\SocketDefs.h" />
<ClInclude Include="include\Poco\Net\SocketNotifier.h"/> <ClInclude Include="include\Poco\Net\SocketImpl.h" />
<ClInclude Include="include\Poco\Net\SocketReactor.h"/> <ClInclude Include="include\Poco\Net\SocketNotification.h" />
<ClInclude Include="include\Poco\Net\SocketStream.h"/> <ClInclude Include="include\Poco\Net\SocketNotifier.h" />
<ClInclude Include="include\Poco\Net\StreamSocket.h"/> <ClInclude Include="include\Poco\Net\SocketReactor.h" />
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketStream.h" />
<ClInclude Include="include\Poco\Net\StringPartSource.h"/> <ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\TCPServer.h"/> <ClInclude Include="include\Poco\Net\StreamSocket.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnection.h"/> <ClInclude Include="include\Poco\Net\StreamSocketImpl.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\StringPartSource.h" />
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h"/> <ClInclude Include="include\Poco\Net\TCPServer.h" />
<ClInclude Include="include\Poco\Net\TCPServerParams.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnection.h" />
<ClInclude Include="include\Poco\Net\UDPClient.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\UDPHandler.h"/> <ClInclude Include="include\Poco\Net\TCPServerDispatcher.h" />
<ClInclude Include="include\Poco\Net\UDPServer.h"/> <ClInclude Include="include\Poco\Net\TCPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPServerParams.h"/> <ClInclude Include="include\Poco\Net\UDPClient.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"/> <ClInclude Include="include\Poco\Net\UDPHandler.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h"/> <ClInclude Include="include\Poco\Net\UDPServer.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h"/> <ClInclude Include="include\Poco\Net\UDPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp"/> <ClCompile Include="src\AbstractHTTPRequestHandler.cpp" />
<ClCompile Include="src\DatagramSocket.cpp"/> <ClCompile Include="src\DatagramSocket.cpp" />
<ClCompile Include="src\DatagramSocketImpl.cpp"/> <ClCompile Include="src\DatagramSocketImpl.cpp" />
<ClCompile Include="src\DialogSocket.cpp"/> <ClCompile Include="src\DialogSocket.cpp" />
<ClCompile Include="src\DNS.cpp"/> <ClCompile Include="src\DNS.cpp" />
<ClCompile Include="src\FilePartSource.cpp"/> <ClCompile Include="src\FilePartSource.cpp" />
<ClCompile Include="src\FTPClientSession.cpp"/> <ClCompile Include="src\FTPClientSession.cpp" />
<ClCompile Include="src\FTPStreamFactory.cpp"/> <ClCompile Include="src\FTPStreamFactory.cpp" />
<ClCompile Include="src\HostEntry.cpp"/> <ClCompile Include="src\HostEntry.cpp" />
<ClCompile Include="src\HTMLForm.cpp"/> <ClCompile Include="src\HTMLForm.cpp" />
<ClCompile Include="src\HTTPAuthenticationParams.cpp"/> <ClCompile Include="src\HTTPAuthenticationParams.cpp" />
<ClCompile Include="src\HTTPBasicCredentials.cpp"/> <ClCompile Include="src\HTTPBasicCredentials.cpp" />
<ClCompile Include="src\HTTPBufferAllocator.cpp"/> <ClCompile Include="src\HTTPBufferAllocator.cpp" />
<ClCompile Include="src\HTTPChunkedStream.cpp"/> <ClCompile Include="src\HTTPChunkedStream.cpp" />
<ClCompile Include="src\HTTPClientSession.cpp"/> <ClCompile Include="src\HTTPClientSession.cpp" />
<ClCompile Include="src\HTTPCookie.cpp"/> <ClCompile Include="src\HTTPCookie.cpp" />
<ClCompile Include="src\HTTPCredentials.cpp"/> <ClCompile Include="src\HTTPCredentials.cpp" />
<ClCompile Include="src\HTTPDigestCredentials.cpp"/> <ClCompile Include="src\HTTPDigestCredentials.cpp" />
<ClCompile Include="src\HTTPFixedLengthStream.cpp"/> <ClCompile Include="src\HTTPFixedLengthStream.cpp" />
<ClCompile Include="src\HTTPHeaderStream.cpp"/> <ClCompile Include="src\HTTPHeaderStream.cpp" />
<ClCompile Include="src\HTTPIOStream.cpp"/> <ClCompile Include="src\HTTPIOStream.cpp" />
<ClCompile Include="src\HTTPMessage.cpp"/> <ClCompile Include="src\HTTPMessage.cpp" />
<ClCompile Include="src\HTTPRequest.cpp"/> <ClCompile Include="src\HTTPNTLMCredentials.cpp" />
<ClCompile Include="src\HTTPRequestHandler.cpp"/> <ClCompile Include="src\HTTPRequest.cpp" />
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp"/> <ClCompile Include="src\HTTPRequestHandler.cpp" />
<ClCompile Include="src\HTTPResponse.cpp"/> <ClCompile Include="src\HTTPRequestHandlerFactory.cpp" />
<ClCompile Include="src\HTTPServer.cpp"/> <ClCompile Include="src\HTTPResponse.cpp" />
<ClCompile Include="src\HTTPServerConnection.cpp"/> <ClCompile Include="src\HTTPServer.cpp" />
<ClCompile Include="src\HTTPServerConnectionFactory.cpp"/> <ClCompile Include="src\HTTPServerConnection.cpp" />
<ClCompile Include="src\HTTPServerParams.cpp"/> <ClCompile Include="src\HTTPServerConnectionFactory.cpp" />
<ClCompile Include="src\HTTPServerRequest.cpp"/> <ClCompile Include="src\HTTPServerParams.cpp" />
<ClCompile Include="src\HTTPServerRequestImpl.cpp"/> <ClCompile Include="src\HTTPServerRequest.cpp" />
<ClCompile Include="src\HTTPServerResponse.cpp"/> <ClCompile Include="src\HTTPServerRequestImpl.cpp" />
<ClCompile Include="src\HTTPServerResponseImpl.cpp"/> <ClCompile Include="src\HTTPServerResponse.cpp" />
<ClCompile Include="src\HTTPServerSession.cpp"/> <ClCompile Include="src\HTTPServerResponseImpl.cpp" />
<ClCompile Include="src\HTTPSession.cpp"/> <ClCompile Include="src\HTTPServerSession.cpp" />
<ClCompile Include="src\HTTPSessionFactory.cpp"/> <ClCompile Include="src\HTTPSession.cpp" />
<ClCompile Include="src\HTTPSessionInstantiator.cpp"/> <ClCompile Include="src\HTTPSessionFactory.cpp" />
<ClCompile Include="src\HTTPStream.cpp"/> <ClCompile Include="src\HTTPSessionInstantiator.cpp" />
<ClCompile Include="src\HTTPStreamFactory.cpp"/> <ClCompile Include="src\HTTPStream.cpp" />
<ClCompile Include="src\ICMPClient.cpp"/> <ClCompile Include="src\HTTPStreamFactory.cpp" />
<ClCompile Include="src\ICMPEventArgs.cpp"/> <ClCompile Include="src\ICMPClient.cpp" />
<ClCompile Include="src\ICMPPacket.cpp"/> <ClCompile Include="src\ICMPEventArgs.cpp" />
<ClCompile Include="src\ICMPPacketImpl.cpp"/> <ClCompile Include="src\ICMPPacket.cpp" />
<ClCompile Include="src\ICMPSocket.cpp"/> <ClCompile Include="src\ICMPPacketImpl.cpp" />
<ClCompile Include="src\ICMPSocketImpl.cpp"/> <ClCompile Include="src\ICMPSocket.cpp" />
<ClCompile Include="src\ICMPv4PacketImpl.cpp"/> <ClCompile Include="src\ICMPSocketImpl.cpp" />
<ClCompile Include="src\IPAddress.cpp"/> <ClCompile Include="src\ICMPv4PacketImpl.cpp" />
<ClCompile Include="src\IPAddressImpl.cpp"/> <ClCompile Include="src\IPAddress.cpp" />
<ClCompile Include="src\MailMessage.cpp"/> <ClCompile Include="src\IPAddressImpl.cpp" />
<ClCompile Include="src\MailRecipient.cpp"/> <ClCompile Include="src\MailMessage.cpp" />
<ClCompile Include="src\MailStream.cpp"/> <ClCompile Include="src\MailRecipient.cpp" />
<ClCompile Include="src\MediaType.cpp"/> <ClCompile Include="src\MailStream.cpp" />
<ClCompile Include="src\MessageHeader.cpp"/> <ClCompile Include="src\MediaType.cpp" />
<ClCompile Include="src\MulticastSocket.cpp"/> <ClCompile Include="src\MessageHeader.cpp" />
<ClCompile Include="src\MultipartReader.cpp"/> <ClCompile Include="src\MulticastSocket.cpp" />
<ClCompile Include="src\MultipartWriter.cpp"/> <ClCompile Include="src\MultipartReader.cpp" />
<ClCompile Include="src\NameValueCollection.cpp"/> <ClCompile Include="src\MultipartWriter.cpp" />
<ClCompile Include="src\Net.cpp"/> <ClCompile Include="src\NameValueCollection.cpp" />
<ClCompile Include="src\NetException.cpp"/> <ClCompile Include="src\Net.cpp" />
<ClCompile Include="src\NetworkInterface.cpp"/> <ClCompile Include="src\NetException.cpp" />
<ClCompile Include="src\NTPClient.cpp"/> <ClCompile Include="src\NetworkInterface.cpp" />
<ClCompile Include="src\NTPEventArgs.cpp"/> <ClCompile Include="src\NTLMCredentials.cpp" />
<ClCompile Include="src\NTPPacket.cpp"/> <ClCompile Include="src\NTPClient.cpp" />
<ClCompile Include="src\NullPartHandler.cpp"/> <ClCompile Include="src\NTPEventArgs.cpp" />
<ClCompile Include="src\OAuth10Credentials.cpp"/> <ClCompile Include="src\NTPPacket.cpp" />
<ClCompile Include="src\OAuth20Credentials.cpp"/> <ClCompile Include="src\NullPartHandler.cpp" />
<ClCompile Include="src\PartHandler.cpp"/> <ClCompile Include="src\OAuth10Credentials.cpp" />
<ClCompile Include="src\PartSource.cpp"/> <ClCompile Include="src\OAuth20Credentials.cpp" />
<ClCompile Include="src\PartStore.cpp"/> <ClCompile Include="src\PartHandler.cpp" />
<ClCompile Include="src\PollSet.cpp"/> <ClCompile Include="src\PartSource.cpp" />
<ClCompile Include="src\POP3ClientSession.cpp"/> <ClCompile Include="src\PartStore.cpp" />
<ClCompile Include="src\QuotedPrintableDecoder.cpp"/> <ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\QuotedPrintableEncoder.cpp"/> <ClCompile Include="src\POP3ClientSession.cpp" />
<ClCompile Include="src\RawSocket.cpp"/> <ClCompile Include="src\QuotedPrintableDecoder.cpp" />
<ClCompile Include="src\RawSocketImpl.cpp"/> <ClCompile Include="src\QuotedPrintableEncoder.cpp" />
<ClCompile Include="src\RemoteSyslogChannel.cpp"/> <ClCompile Include="src\RawSocket.cpp" />
<ClCompile Include="src\RemoteSyslogListener.cpp"/> <ClCompile Include="src\RawSocketImpl.cpp" />
<ClCompile Include="src\ServerSocket.cpp"/> <ClCompile Include="src\RemoteSyslogChannel.cpp" />
<ClCompile Include="src\ServerSocketImpl.cpp"/> <ClCompile Include="src\RemoteSyslogListener.cpp" />
<ClCompile Include="src\SMTPChannel.cpp"/> <ClCompile Include="src\ServerSocket.cpp" />
<ClCompile Include="src\SMTPClientSession.cpp"/> <ClCompile Include="src\ServerSocketImpl.cpp" />
<ClCompile Include="src\Socket.cpp"/> <ClCompile Include="src\SMTPChannel.cpp" />
<ClCompile Include="src\SocketAddress.cpp"/> <ClCompile Include="src\SMTPClientSession.cpp" />
<ClCompile Include="src\SocketAddressImpl.cpp"/> <ClCompile Include="src\Socket.cpp" />
<ClCompile Include="src\SocketImpl.cpp"/> <ClCompile Include="src\SocketAddress.cpp" />
<ClCompile Include="src\SocketNotification.cpp"/> <ClCompile Include="src\SocketAddressImpl.cpp" />
<ClCompile Include="src\SocketNotifier.cpp"/> <ClCompile Include="src\SocketImpl.cpp" />
<ClCompile Include="src\SocketReactor.cpp"/> <ClCompile Include="src\SocketNotification.cpp" />
<ClCompile Include="src\SocketStream.cpp"/> <ClCompile Include="src\SocketNotifier.cpp" />
<ClCompile Include="src\StreamSocket.cpp"/> <ClCompile Include="src\SocketReactor.cpp" />
<ClCompile Include="src\StreamSocketImpl.cpp"/> <ClCompile Include="src\SocketStream.cpp" />
<ClCompile Include="src\StringPartSource.cpp"/> <ClCompile Include="src\SSPINTLMCredentials.cpp" />
<ClCompile Include="src\TCPServer.cpp"/> <ClCompile Include="src\StreamSocket.cpp" />
<ClCompile Include="src\TCPServerConnection.cpp"/> <ClCompile Include="src\StreamSocketImpl.cpp" />
<ClCompile Include="src\TCPServerConnectionFactory.cpp"/> <ClCompile Include="src\StringPartSource.cpp" />
<ClCompile Include="src\TCPServerDispatcher.cpp"/> <ClCompile Include="src\TCPServer.cpp" />
<ClCompile Include="src\TCPServerParams.cpp"/> <ClCompile Include="src\TCPServerConnection.cpp" />
<ClCompile Include="src\UDPClient.cpp"/> <ClCompile Include="src\TCPServerConnectionFactory.cpp" />
<ClCompile Include="src\UDPServerParams.cpp"/> <ClCompile Include="src\TCPServerDispatcher.cpp" />
<ClCompile Include="src\WebSocket.cpp"/> <ClCompile Include="src\TCPServerParams.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp"/> <ClCompile Include="src\UDPClient.cpp" />
<ClCompile Include="src\UDPServerParams.cpp" />
<ClCompile Include="src\WebSocket.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc"> <ResourceCompile Include="..\DLLVersion.rc">

View File

@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup> <ItemGroup>
<Filter Include="NetCore"> <Filter Include="NetCore">
@@ -154,6 +154,15 @@
<Filter Include="UDP\Header Files"> <Filter Include="UDP\Header Files">
<UniqueIdentifier>{828714c4-311d-4f1d-a8b7-055e63091653}</UniqueIdentifier> <UniqueIdentifier>{828714c4-311d-4f1d-a8b7-055e63091653}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="NTLM">
<UniqueIdentifier>{d3a8a0c8-9a27-451c-bfcd-6b7e4073e27b}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Header Files">
<UniqueIdentifier>{3e88da3b-8e4f-46f9-b3c2-1cec6ea4091d}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Source Files">
<UniqueIdentifier>{c70b5e46-03ca-49e3-885d-87dadff67111}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\DNS.h"> <ClInclude Include="include\Poco\Net\DNS.h">
@@ -492,6 +501,16 @@
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"> <ClInclude Include="include\Poco\Net\UDPSocketReader.h">
<Filter>UDP\Header Files</Filter> <Filter>UDP\Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h">
<Filter>HTTP\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\NTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\DNS.cpp"> <ClCompile Include="src\DNS.cpp">
@@ -797,6 +816,16 @@
<ClCompile Include="src\UDPServerParams.cpp"> <ClCompile Include="src\UDPServerParams.cpp">
<Filter>UDP\Source Files</Filter> <Filter>UDP\Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\NTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\SSPINTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\HTTPNTLMCredentials.cpp">
<Filter>HTTP\Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc" /> <ResourceCompile Include="..\DLLVersion.rc" />

View File

@@ -278,223 +278,229 @@
</Lib> </Lib>
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\AbstractHTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\DatagramSocket.h"/> <ClInclude Include="include\Poco\Net\DatagramSocket.h" />
<ClInclude Include="include\Poco\Net\DatagramSocketImpl.h"/> <ClInclude Include="include\Poco\Net\DatagramSocketImpl.h" />
<ClInclude Include="include\Poco\Net\DialogSocket.h"/> <ClInclude Include="include\Poco\Net\DialogSocket.h" />
<ClInclude Include="include\Poco\Net\DNS.h"/> <ClInclude Include="include\Poco\Net\DNS.h" />
<ClInclude Include="include\Poco\Net\FilePartSource.h"/> <ClInclude Include="include\Poco\Net\FilePartSource.h" />
<ClInclude Include="include\Poco\Net\FTPClientSession.h"/> <ClInclude Include="include\Poco\Net\FTPClientSession.h" />
<ClInclude Include="include\Poco\Net\FTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\FTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\HostEntry.h"/> <ClInclude Include="include\Poco\Net\HostEntry.h" />
<ClInclude Include="include\Poco\Net\HTMLForm.h"/> <ClInclude Include="include\Poco\Net\HTMLForm.h" />
<ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h"/> <ClInclude Include="include\Poco\Net\HTTPAuthenticationParams.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h"/> <ClInclude Include="include\Poco\Net\HTTPBasicStreamBuf.h" />
<ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h"/> <ClInclude Include="include\Poco\Net\HTTPBufferAllocator.h" />
<ClInclude Include="include\Poco\Net\HTTPChunkedStream.h"/> <ClInclude Include="include\Poco\Net\HTTPChunkedStream.h" />
<ClInclude Include="include\Poco\Net\HTTPClientSession.h"/> <ClInclude Include="include\Poco\Net\HTTPClientSession.h" />
<ClInclude Include="include\Poco\Net\HTTPCookie.h"/> <ClInclude Include="include\Poco\Net\HTTPCookie.h" />
<ClInclude Include="include\Poco\Net\HTTPCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h"/> <ClInclude Include="include\Poco\Net\HTTPDigestCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h"/> <ClInclude Include="include\Poco\Net\HTTPFixedLengthStream.h" />
<ClInclude Include="include\Poco\Net\HTTPHeaderStream.h"/> <ClInclude Include="include\Poco\Net\HTTPHeaderStream.h" />
<ClInclude Include="include\Poco\Net\HTTPIOStream.h"/> <ClInclude Include="include\Poco\Net\HTTPIOStream.h" />
<ClInclude Include="include\Poco\Net\HTTPMessage.h"/> <ClInclude Include="include\Poco\Net\HTTPMessage.h" />
<ClInclude Include="include\Poco\Net\HTTPRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandler.h"/> <ClInclude Include="include\Poco\Net\HTTPRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandler.h" />
<ClInclude Include="include\Poco\Net\HTTPResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPRequestHandlerFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServer.h"/> <ClInclude Include="include\Poco\Net\HTTPResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnection.h"/> <ClInclude Include="include\Poco\Net\HTTPServer.h" />
<ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnection.h" />
<ClInclude Include="include\Poco\Net\HTTPServerParams.h"/> <ClInclude Include="include\Poco\Net\HTTPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequest.h"/> <ClInclude Include="include\Poco\Net\HTTPServerParams.h" />
<ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequest.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponse.h"/> <ClInclude Include="include\Poco\Net\HTTPServerRequestImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponse.h" />
<ClInclude Include="include\Poco\Net\HTTPServerSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerResponseImpl.h" />
<ClInclude Include="include\Poco\Net\HTTPSession.h"/> <ClInclude Include="include\Poco\Net\HTTPServerSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPSession.h" />
<ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionFactory.h" />
<ClInclude Include="include\Poco\Net\HTTPStream.h"/> <ClInclude Include="include\Poco\Net\HTTPSessionInstantiator.h" />
<ClInclude Include="include\Poco\Net\HTTPStreamFactory.h"/> <ClInclude Include="include\Poco\Net\HTTPStream.h" />
<ClInclude Include="include\Poco\Net\ICMPClient.h"/> <ClInclude Include="include\Poco\Net\HTTPStreamFactory.h" />
<ClInclude Include="include\Poco\Net\ICMPEventArgs.h"/> <ClInclude Include="include\Poco\Net\ICMPClient.h" />
<ClInclude Include="include\Poco\Net\ICMPPacket.h"/> <ClInclude Include="include\Poco\Net\ICMPEventArgs.h" />
<ClInclude Include="include\Poco\Net\ICMPPacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPPacket.h" />
<ClInclude Include="include\Poco\Net\ICMPSocket.h"/> <ClInclude Include="include\Poco\Net\ICMPPacketImpl.h" />
<ClInclude Include="include\Poco\Net\ICMPSocketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocket.h" />
<ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h"/> <ClInclude Include="include\Poco\Net\ICMPSocketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddress.h"/> <ClInclude Include="include\Poco\Net\ICMPv4PacketImpl.h" />
<ClInclude Include="include\Poco\Net\IPAddressImpl.h"/> <ClInclude Include="include\Poco\Net\IPAddress.h" />
<ClInclude Include="include\Poco\Net\MailMessage.h"/> <ClInclude Include="include\Poco\Net\IPAddressImpl.h" />
<ClInclude Include="include\Poco\Net\MailRecipient.h"/> <ClInclude Include="include\Poco\Net\MailMessage.h" />
<ClInclude Include="include\Poco\Net\MailStream.h"/> <ClInclude Include="include\Poco\Net\MailRecipient.h" />
<ClInclude Include="include\Poco\Net\MediaType.h"/> <ClInclude Include="include\Poco\Net\MailStream.h" />
<ClInclude Include="include\Poco\Net\MessageHeader.h"/> <ClInclude Include="include\Poco\Net\MediaType.h" />
<ClInclude Include="include\Poco\Net\MulticastSocket.h"/> <ClInclude Include="include\Poco\Net\MessageHeader.h" />
<ClInclude Include="include\Poco\Net\MultipartReader.h"/> <ClInclude Include="include\Poco\Net\MulticastSocket.h" />
<ClInclude Include="include\Poco\Net\MultipartWriter.h"/> <ClInclude Include="include\Poco\Net\MultipartReader.h" />
<ClInclude Include="include\Poco\Net\MultiSocketPoller.h"/> <ClInclude Include="include\Poco\Net\MultipartWriter.h" />
<ClInclude Include="include\Poco\Net\NameValueCollection.h"/> <ClInclude Include="include\Poco\Net\MultiSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Net.h"/> <ClInclude Include="include\Poco\Net\NameValueCollection.h" />
<ClInclude Include="include\Poco\Net\NetException.h"/> <ClInclude Include="include\Poco\Net\Net.h" />
<ClInclude Include="include\Poco\Net\NetworkInterface.h"/> <ClInclude Include="include\Poco\Net\NetException.h" />
<ClInclude Include="include\Poco\Net\NTPClient.h"/> <ClInclude Include="include\Poco\Net\NetworkInterface.h" />
<ClInclude Include="include\Poco\Net\NTPEventArgs.h"/> <ClInclude Include="include\Poco\Net\NTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\NTPPacket.h"/> <ClInclude Include="include\Poco\Net\NTPClient.h" />
<ClInclude Include="include\Poco\Net\NullPartHandler.h"/> <ClInclude Include="include\Poco\Net\NTPEventArgs.h" />
<ClInclude Include="include\Poco\Net\OAuth10Credentials.h"/> <ClInclude Include="include\Poco\Net\NTPPacket.h" />
<ClInclude Include="include\Poco\Net\OAuth20Credentials.h"/> <ClInclude Include="include\Poco\Net\NullPartHandler.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\OAuth10Credentials.h" />
<ClInclude Include="include\Poco\Net\ParallelSocketReactor.h"/> <ClInclude Include="include\Poco\Net\OAuth20Credentials.h" />
<ClInclude Include="include\Poco\Net\PartHandler.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\PartSource.h"/> <ClInclude Include="include\Poco\Net\ParallelSocketReactor.h" />
<ClInclude Include="include\Poco\Net\PartStore.h"/> <ClInclude Include="include\Poco\Net\PartHandler.h" />
<ClInclude Include="include\Poco\Net\PollSet.h"/> <ClInclude Include="include\Poco\Net\PartSource.h" />
<ClInclude Include="include\Poco\Net\POP3ClientSession.h"/> <ClInclude Include="include\Poco\Net\PartStore.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h"/> <ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h"/> <ClInclude Include="include\Poco\Net\POP3ClientSession.h" />
<ClInclude Include="include\Poco\Net\RawSocket.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableDecoder.h" />
<ClInclude Include="include\Poco\Net\RawSocketImpl.h"/> <ClInclude Include="include\Poco\Net\QuotedPrintableEncoder.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h"/> <ClInclude Include="include\Poco\Net\RawSocket.h" />
<ClInclude Include="include\Poco\Net\RemoteSyslogListener.h"/> <ClInclude Include="include\Poco\Net\RawSocketImpl.h" />
<ClInclude Include="include\Poco\Net\ServerSocket.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogChannel.h" />
<ClInclude Include="include\Poco\Net\ServerSocketImpl.h"/> <ClInclude Include="include\Poco\Net\RemoteSyslogListener.h" />
<ClInclude Include="include\Poco\Net\SingleSocketPoller.h"/> <ClInclude Include="include\Poco\Net\ServerSocket.h" />
<ClInclude Include="include\Poco\Net\SMTPChannel.h"/> <ClInclude Include="include\Poco\Net\ServerSocketImpl.h" />
<ClInclude Include="include\Poco\Net\SMTPClientSession.h"/> <ClInclude Include="include\Poco\Net\SingleSocketPoller.h" />
<ClInclude Include="include\Poco\Net\Socket.h"/> <ClInclude Include="include\Poco\Net\SMTPChannel.h" />
<ClInclude Include="include\Poco\Net\SocketAcceptor.h"/> <ClInclude Include="include\Poco\Net\SMTPClientSession.h" />
<ClInclude Include="include\Poco\Net\SocketAddress.h"/> <ClInclude Include="include\Poco\Net\Socket.h" />
<ClInclude Include="include\Poco\Net\SocketAddressImpl.h"/> <ClInclude Include="include\Poco\Net\SocketAcceptor.h" />
<ClInclude Include="include\Poco\Net\SocketConnector.h"/> <ClInclude Include="include\Poco\Net\SocketAddress.h" />
<ClInclude Include="include\Poco\Net\SocketDefs.h"/> <ClInclude Include="include\Poco\Net\SocketAddressImpl.h" />
<ClInclude Include="include\Poco\Net\SocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketConnector.h" />
<ClInclude Include="include\Poco\Net\SocketNotification.h"/> <ClInclude Include="include\Poco\Net\SocketDefs.h" />
<ClInclude Include="include\Poco\Net\SocketNotifier.h"/> <ClInclude Include="include\Poco\Net\SocketImpl.h" />
<ClInclude Include="include\Poco\Net\SocketReactor.h"/> <ClInclude Include="include\Poco\Net\SocketNotification.h" />
<ClInclude Include="include\Poco\Net\SocketStream.h"/> <ClInclude Include="include\Poco\Net\SocketNotifier.h" />
<ClInclude Include="include\Poco\Net\StreamSocket.h"/> <ClInclude Include="include\Poco\Net\SocketReactor.h" />
<ClInclude Include="include\Poco\Net\StreamSocketImpl.h"/> <ClInclude Include="include\Poco\Net\SocketStream.h" />
<ClInclude Include="include\Poco\Net\StringPartSource.h"/> <ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h" />
<ClInclude Include="include\Poco\Net\TCPServer.h"/> <ClInclude Include="include\Poco\Net\StreamSocket.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnection.h"/> <ClInclude Include="include\Poco\Net\StreamSocketImpl.h" />
<ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h"/> <ClInclude Include="include\Poco\Net\StringPartSource.h" />
<ClInclude Include="include\Poco\Net\TCPServerDispatcher.h"/> <ClInclude Include="include\Poco\Net\TCPServer.h" />
<ClInclude Include="include\Poco\Net\TCPServerParams.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnection.h" />
<ClInclude Include="include\Poco\Net\UDPClient.h"/> <ClInclude Include="include\Poco\Net\TCPServerConnectionFactory.h" />
<ClInclude Include="include\Poco\Net\UDPHandler.h"/> <ClInclude Include="include\Poco\Net\TCPServerDispatcher.h" />
<ClInclude Include="include\Poco\Net\UDPServer.h"/> <ClInclude Include="include\Poco\Net\TCPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPServerParams.h"/> <ClInclude Include="include\Poco\Net\UDPClient.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"/> <ClInclude Include="include\Poco\Net\UDPHandler.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h"/> <ClInclude Include="include\Poco\Net\UDPServer.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h"/> <ClInclude Include="include\Poco\Net\UDPServerParams.h" />
<ClInclude Include="include\Poco\Net\UDPSocketReader.h" />
<ClInclude Include="include\Poco\Net\WebSocket.h" />
<ClInclude Include="include\Poco\Net\WebSocketImpl.h" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\AbstractHTTPRequestHandler.cpp"/> <ClCompile Include="src\AbstractHTTPRequestHandler.cpp" />
<ClCompile Include="src\DatagramSocket.cpp"/> <ClCompile Include="src\DatagramSocket.cpp" />
<ClCompile Include="src\DatagramSocketImpl.cpp"/> <ClCompile Include="src\DatagramSocketImpl.cpp" />
<ClCompile Include="src\DialogSocket.cpp"/> <ClCompile Include="src\DialogSocket.cpp" />
<ClCompile Include="src\DNS.cpp"/> <ClCompile Include="src\DNS.cpp" />
<ClCompile Include="src\FilePartSource.cpp"/> <ClCompile Include="src\FilePartSource.cpp" />
<ClCompile Include="src\FTPClientSession.cpp"/> <ClCompile Include="src\FTPClientSession.cpp" />
<ClCompile Include="src\FTPStreamFactory.cpp"/> <ClCompile Include="src\FTPStreamFactory.cpp" />
<ClCompile Include="src\HostEntry.cpp"/> <ClCompile Include="src\HostEntry.cpp" />
<ClCompile Include="src\HTMLForm.cpp"/> <ClCompile Include="src\HTMLForm.cpp" />
<ClCompile Include="src\HTTPAuthenticationParams.cpp"/> <ClCompile Include="src\HTTPAuthenticationParams.cpp" />
<ClCompile Include="src\HTTPBasicCredentials.cpp"/> <ClCompile Include="src\HTTPBasicCredentials.cpp" />
<ClCompile Include="src\HTTPBufferAllocator.cpp"/> <ClCompile Include="src\HTTPBufferAllocator.cpp" />
<ClCompile Include="src\HTTPChunkedStream.cpp"/> <ClCompile Include="src\HTTPChunkedStream.cpp" />
<ClCompile Include="src\HTTPClientSession.cpp"/> <ClCompile Include="src\HTTPClientSession.cpp" />
<ClCompile Include="src\HTTPCookie.cpp"/> <ClCompile Include="src\HTTPCookie.cpp" />
<ClCompile Include="src\HTTPCredentials.cpp"/> <ClCompile Include="src\HTTPCredentials.cpp" />
<ClCompile Include="src\HTTPDigestCredentials.cpp"/> <ClCompile Include="src\HTTPDigestCredentials.cpp" />
<ClCompile Include="src\HTTPFixedLengthStream.cpp"/> <ClCompile Include="src\HTTPFixedLengthStream.cpp" />
<ClCompile Include="src\HTTPHeaderStream.cpp"/> <ClCompile Include="src\HTTPHeaderStream.cpp" />
<ClCompile Include="src\HTTPIOStream.cpp"/> <ClCompile Include="src\HTTPIOStream.cpp" />
<ClCompile Include="src\HTTPMessage.cpp"/> <ClCompile Include="src\HTTPMessage.cpp" />
<ClCompile Include="src\HTTPRequest.cpp"/> <ClCompile Include="src\HTTPNTLMCredentials.cpp" />
<ClCompile Include="src\HTTPRequestHandler.cpp"/> <ClCompile Include="src\HTTPRequest.cpp" />
<ClCompile Include="src\HTTPRequestHandlerFactory.cpp"/> <ClCompile Include="src\HTTPRequestHandler.cpp" />
<ClCompile Include="src\HTTPResponse.cpp"/> <ClCompile Include="src\HTTPRequestHandlerFactory.cpp" />
<ClCompile Include="src\HTTPServer.cpp"/> <ClCompile Include="src\HTTPResponse.cpp" />
<ClCompile Include="src\HTTPServerConnection.cpp"/> <ClCompile Include="src\HTTPServer.cpp" />
<ClCompile Include="src\HTTPServerConnectionFactory.cpp"/> <ClCompile Include="src\HTTPServerConnection.cpp" />
<ClCompile Include="src\HTTPServerParams.cpp"/> <ClCompile Include="src\HTTPServerConnectionFactory.cpp" />
<ClCompile Include="src\HTTPServerRequest.cpp"/> <ClCompile Include="src\HTTPServerParams.cpp" />
<ClCompile Include="src\HTTPServerRequestImpl.cpp"/> <ClCompile Include="src\HTTPServerRequest.cpp" />
<ClCompile Include="src\HTTPServerResponse.cpp"/> <ClCompile Include="src\HTTPServerRequestImpl.cpp" />
<ClCompile Include="src\HTTPServerResponseImpl.cpp"/> <ClCompile Include="src\HTTPServerResponse.cpp" />
<ClCompile Include="src\HTTPServerSession.cpp"/> <ClCompile Include="src\HTTPServerResponseImpl.cpp" />
<ClCompile Include="src\HTTPSession.cpp"/> <ClCompile Include="src\HTTPServerSession.cpp" />
<ClCompile Include="src\HTTPSessionFactory.cpp"/> <ClCompile Include="src\HTTPSession.cpp" />
<ClCompile Include="src\HTTPSessionInstantiator.cpp"/> <ClCompile Include="src\HTTPSessionFactory.cpp" />
<ClCompile Include="src\HTTPStream.cpp"/> <ClCompile Include="src\HTTPSessionInstantiator.cpp" />
<ClCompile Include="src\HTTPStreamFactory.cpp"/> <ClCompile Include="src\HTTPStream.cpp" />
<ClCompile Include="src\ICMPClient.cpp"/> <ClCompile Include="src\HTTPStreamFactory.cpp" />
<ClCompile Include="src\ICMPEventArgs.cpp"/> <ClCompile Include="src\ICMPClient.cpp" />
<ClCompile Include="src\ICMPPacket.cpp"/> <ClCompile Include="src\ICMPEventArgs.cpp" />
<ClCompile Include="src\ICMPPacketImpl.cpp"/> <ClCompile Include="src\ICMPPacket.cpp" />
<ClCompile Include="src\ICMPSocket.cpp"/> <ClCompile Include="src\ICMPPacketImpl.cpp" />
<ClCompile Include="src\ICMPSocketImpl.cpp"/> <ClCompile Include="src\ICMPSocket.cpp" />
<ClCompile Include="src\ICMPv4PacketImpl.cpp"/> <ClCompile Include="src\ICMPSocketImpl.cpp" />
<ClCompile Include="src\IPAddress.cpp"/> <ClCompile Include="src\ICMPv4PacketImpl.cpp" />
<ClCompile Include="src\IPAddressImpl.cpp"/> <ClCompile Include="src\IPAddress.cpp" />
<ClCompile Include="src\MailMessage.cpp"/> <ClCompile Include="src\IPAddressImpl.cpp" />
<ClCompile Include="src\MailRecipient.cpp"/> <ClCompile Include="src\MailMessage.cpp" />
<ClCompile Include="src\MailStream.cpp"/> <ClCompile Include="src\MailRecipient.cpp" />
<ClCompile Include="src\MediaType.cpp"/> <ClCompile Include="src\MailStream.cpp" />
<ClCompile Include="src\MessageHeader.cpp"/> <ClCompile Include="src\MediaType.cpp" />
<ClCompile Include="src\MulticastSocket.cpp"/> <ClCompile Include="src\MessageHeader.cpp" />
<ClCompile Include="src\MultipartReader.cpp"/> <ClCompile Include="src\MulticastSocket.cpp" />
<ClCompile Include="src\MultipartWriter.cpp"/> <ClCompile Include="src\MultipartReader.cpp" />
<ClCompile Include="src\NameValueCollection.cpp"/> <ClCompile Include="src\MultipartWriter.cpp" />
<ClCompile Include="src\Net.cpp"/> <ClCompile Include="src\NameValueCollection.cpp" />
<ClCompile Include="src\NetException.cpp"/> <ClCompile Include="src\Net.cpp" />
<ClCompile Include="src\NetworkInterface.cpp"/> <ClCompile Include="src\NetException.cpp" />
<ClCompile Include="src\NTPClient.cpp"/> <ClCompile Include="src\NetworkInterface.cpp" />
<ClCompile Include="src\NTPEventArgs.cpp"/> <ClCompile Include="src\NTLMCredentials.cpp" />
<ClCompile Include="src\NTPPacket.cpp"/> <ClCompile Include="src\NTPClient.cpp" />
<ClCompile Include="src\NullPartHandler.cpp"/> <ClCompile Include="src\NTPEventArgs.cpp" />
<ClCompile Include="src\OAuth10Credentials.cpp"/> <ClCompile Include="src\NTPPacket.cpp" />
<ClCompile Include="src\OAuth20Credentials.cpp"/> <ClCompile Include="src\NullPartHandler.cpp" />
<ClCompile Include="src\PartHandler.cpp"/> <ClCompile Include="src\OAuth10Credentials.cpp" />
<ClCompile Include="src\PartSource.cpp"/> <ClCompile Include="src\OAuth20Credentials.cpp" />
<ClCompile Include="src\PartStore.cpp"/> <ClCompile Include="src\PartHandler.cpp" />
<ClCompile Include="src\PollSet.cpp"/> <ClCompile Include="src\PartSource.cpp" />
<ClCompile Include="src\POP3ClientSession.cpp"/> <ClCompile Include="src\PartStore.cpp" />
<ClCompile Include="src\QuotedPrintableDecoder.cpp"/> <ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\QuotedPrintableEncoder.cpp"/> <ClCompile Include="src\POP3ClientSession.cpp" />
<ClCompile Include="src\RawSocket.cpp"/> <ClCompile Include="src\QuotedPrintableDecoder.cpp" />
<ClCompile Include="src\RawSocketImpl.cpp"/> <ClCompile Include="src\QuotedPrintableEncoder.cpp" />
<ClCompile Include="src\RemoteSyslogChannel.cpp"/> <ClCompile Include="src\RawSocket.cpp" />
<ClCompile Include="src\RemoteSyslogListener.cpp"/> <ClCompile Include="src\RawSocketImpl.cpp" />
<ClCompile Include="src\ServerSocket.cpp"/> <ClCompile Include="src\RemoteSyslogChannel.cpp" />
<ClCompile Include="src\ServerSocketImpl.cpp"/> <ClCompile Include="src\RemoteSyslogListener.cpp" />
<ClCompile Include="src\SMTPChannel.cpp"/> <ClCompile Include="src\ServerSocket.cpp" />
<ClCompile Include="src\SMTPClientSession.cpp"/> <ClCompile Include="src\ServerSocketImpl.cpp" />
<ClCompile Include="src\Socket.cpp"/> <ClCompile Include="src\SMTPChannel.cpp" />
<ClCompile Include="src\SocketAddress.cpp"/> <ClCompile Include="src\SMTPClientSession.cpp" />
<ClCompile Include="src\SocketAddressImpl.cpp"/> <ClCompile Include="src\Socket.cpp" />
<ClCompile Include="src\SocketImpl.cpp"/> <ClCompile Include="src\SocketAddress.cpp" />
<ClCompile Include="src\SocketNotification.cpp"/> <ClCompile Include="src\SocketAddressImpl.cpp" />
<ClCompile Include="src\SocketNotifier.cpp"/> <ClCompile Include="src\SocketImpl.cpp" />
<ClCompile Include="src\SocketReactor.cpp"/> <ClCompile Include="src\SocketNotification.cpp" />
<ClCompile Include="src\SocketStream.cpp"/> <ClCompile Include="src\SocketNotifier.cpp" />
<ClCompile Include="src\StreamSocket.cpp"/> <ClCompile Include="src\SocketReactor.cpp" />
<ClCompile Include="src\StreamSocketImpl.cpp"/> <ClCompile Include="src\SocketStream.cpp" />
<ClCompile Include="src\StringPartSource.cpp"/> <ClCompile Include="src\SSPINTLMCredentials.cpp" />
<ClCompile Include="src\TCPServer.cpp"/> <ClCompile Include="src\StreamSocket.cpp" />
<ClCompile Include="src\TCPServerConnection.cpp"/> <ClCompile Include="src\StreamSocketImpl.cpp" />
<ClCompile Include="src\TCPServerConnectionFactory.cpp"/> <ClCompile Include="src\StringPartSource.cpp" />
<ClCompile Include="src\TCPServerDispatcher.cpp"/> <ClCompile Include="src\TCPServer.cpp" />
<ClCompile Include="src\TCPServerParams.cpp"/> <ClCompile Include="src\TCPServerConnection.cpp" />
<ClCompile Include="src\UDPClient.cpp"/> <ClCompile Include="src\TCPServerConnectionFactory.cpp" />
<ClCompile Include="src\UDPServerParams.cpp"/> <ClCompile Include="src\TCPServerDispatcher.cpp" />
<ClCompile Include="src\WebSocket.cpp"/> <ClCompile Include="src\TCPServerParams.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp"/> <ClCompile Include="src\UDPClient.cpp" />
<ClCompile Include="src\UDPServerParams.cpp" />
<ClCompile Include="src\WebSocket.cpp" />
<ClCompile Include="src\WebSocketImpl.cpp" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc"> <ResourceCompile Include="..\DLLVersion.rc">

View File

@@ -154,6 +154,15 @@
<Filter Include="UDP\Header Files"> <Filter Include="UDP\Header Files">
<UniqueIdentifier>{e8126c7b-f7eb-4fd0-8405-a25686a2eb43}</UniqueIdentifier> <UniqueIdentifier>{e8126c7b-f7eb-4fd0-8405-a25686a2eb43}</UniqueIdentifier>
</Filter> </Filter>
<Filter Include="NTLM">
<UniqueIdentifier>{57d7abd7-70c6-4539-9d72-63ab4a67d98d}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Header Files">
<UniqueIdentifier>{e928b626-0ca2-41a2-8c4b-2d1634b3c882}</UniqueIdentifier>
</Filter>
<Filter Include="NTLM\Source Files">
<UniqueIdentifier>{6863df41-5426-405b-a51d-21c53bcfe45f}</UniqueIdentifier>
</Filter>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="include\Poco\Net\DNS.h"> <ClInclude Include="include\Poco\Net\DNS.h">
@@ -492,6 +501,16 @@
<ClInclude Include="include\Poco\Net\UDPSocketReader.h"> <ClInclude Include="include\Poco\Net\UDPSocketReader.h">
<Filter>UDP\Header Files</Filter> <Filter>UDP\Header Files</Filter>
</ClInclude> </ClInclude>
<ClInclude Include="include\Poco\Net\PollSet.h" />
<ClInclude Include="include\Poco\Net\HTTPNTLMCredentials.h">
<Filter>HTTP\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\NTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
<ClInclude Include="include\Poco\Net\SSPINTLMCredentials.h">
<Filter>NTLM\Header Files</Filter>
</ClInclude>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="src\DNS.cpp"> <ClCompile Include="src\DNS.cpp">
@@ -797,6 +816,16 @@
<ClCompile Include="src\UDPServerParams.cpp"> <ClCompile Include="src\UDPServerParams.cpp">
<Filter>UDP\Source Files</Filter> <Filter>UDP\Source Files</Filter>
</ClCompile> </ClCompile>
<ClCompile Include="src\PollSet.cpp" />
<ClCompile Include="src\NTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\SSPINTLMCredentials.cpp">
<Filter>NTLM\Source Files</Filter>
</ClCompile>
<ClCompile Include="src\HTTPNTLMCredentials.cpp">
<Filter>HTTP\Source Files</Filter>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ResourceCompile Include="..\DLLVersion.rc" /> <ResourceCompile Include="..\DLLVersion.rc" />

View File

@@ -33,6 +33,9 @@ class HTTPResponse;
class Net_API HTTPAuthenticationParams: public NameValueCollection class Net_API HTTPAuthenticationParams: public NameValueCollection
/// Collection of name-value pairs of HTTP authentication header (i.e. /// Collection of name-value pairs of HTTP authentication header (i.e.
/// "realm", "qop", "nonce" in case of digest authentication header). /// "realm", "qop", "nonce" in case of digest authentication header).
///
/// For NTLM, the base64-encoded NTLM message is available from
/// the "NTLM" property.
{ {
public: public:
HTTPAuthenticationParams(); HTTPAuthenticationParams();
@@ -89,6 +92,7 @@ public:
/// request or response authentication header. /// request or response authentication header.
static const std::string REALM; static const std::string REALM;
static const std::string NTLM;
static const std::string WWW_AUTHENTICATE; static const std::string WWW_AUTHENTICATE;
static const std::string PROXY_AUTHENTICATE; static const std::string PROXY_AUTHENTICATE;

View File

@@ -55,6 +55,9 @@ public:
~HTTPBasicCredentials(); ~HTTPBasicCredentials();
/// Destroys the HTTPBasicCredentials. /// Destroys the HTTPBasicCredentials.
void clear();
/// Clears both username and password.
void setUsername(const std::string& username); void setUsername(const std::string& username);
/// Sets the username. /// Sets the username.
@@ -67,6 +70,9 @@ public:
const std::string& getPassword() const; const std::string& getPassword() const;
/// Returns the password. /// Returns the password.
bool empty() const;
/// Returns true if both username and password are empty, otherwise false.
void authenticate(HTTPRequest& request) const; void authenticate(HTTPRequest& request) const;
/// Adds authentication information to the given HTTPRequest. /// Adds authentication information to the given HTTPRequest.
@@ -105,6 +111,12 @@ inline const std::string& HTTPBasicCredentials::getPassword() const
} }
inline bool HTTPBasicCredentials::empty() const
{
return _username.empty() && _password.empty();
}
} } // namespace Poco::Net } } // namespace Poco::Net

View File

@@ -20,6 +20,9 @@
#include "Poco/Net/Net.h" #include "Poco/Net/Net.h"
#include "Poco/Net/HTTPSession.h" #include "Poco/Net/HTTPSession.h"
#include "Poco/Net/HTTPBasicCredentials.h"
#include "Poco/Net/HTTPDigestCredentials.h"
#include "Poco/Net/HTTPNTLMCredentials.h"
#include "Poco/Net/SocketAddress.h" #include "Poco/Net/SocketAddress.h"
#include "Poco/SharedPtr.h" #include "Poco/SharedPtr.h"
#include <istream> #include <istream>
@@ -62,11 +65,20 @@ class Net_API HTTPClientSession: public HTTPSession
/// set up a session through a proxy. /// set up a session through a proxy.
{ {
public: public:
enum ProxyAuthentication
{
PROXY_AUTH_NONE, /// No proxy authentication
PROXY_AUTH_HTTP_BASIC, /// HTTP Basic proxy authentication (default, if username and password are supplied)
PROXY_AUTH_HTTP_DIGEST, /// HTTP Digest proxy authentication
PROXY_AUTH_NTLM /// NTLMv2 proxy authentication
};
struct ProxyConfig struct ProxyConfig
/// HTTP proxy server configuration. /// HTTP proxy server configuration.
{ {
ProxyConfig(): ProxyConfig():
port(HTTP_PORT) port(HTTP_PORT),
authMethod(PROXY_AUTH_HTTP_BASIC)
{ {
} }
@@ -82,6 +94,9 @@ public:
/// A regular expression defining hosts for which the proxy should be bypassed, /// A regular expression defining hosts for which the proxy should be bypassed,
/// e.g. "localhost|127\.0\.0\.1|192\.168\.0\.\d+". Can also be an empty /// e.g. "localhost|127\.0\.0\.1|192\.168\.0\.\d+". Can also be an empty
/// string to disable proxy bypassing. /// string to disable proxy bypassing.
ProxyAuthentication authMethod;
/// The authentication method to use - HTTP Basic or NTLM.
}; };
HTTPClientSession(); HTTPClientSession();
@@ -273,6 +288,14 @@ public:
/// This method should only be called if the request contains /// This method should only be called if the request contains
/// a "Expect: 100-continue" header. /// a "Expect: 100-continue" header.
void flushRequest();
/// Flushes the request stream.
///
/// Normally this method does not need to be called.
/// It can be used to ensure the request has been
/// fully sent if receiveResponse() is not called, e.g.,
/// because the underlying socket will be detached.
void reset(); void reset();
/// Resets the session and closes the socket. /// Resets the session and closes the socket.
/// ///
@@ -305,6 +328,9 @@ protected:
int write(const char* buffer, std::streamsize length); int write(const char* buffer, std::streamsize length);
/// Tries to re-connect if keep-alive is on. /// Tries to re-connect if keep-alive is on.
std::ostream& sendRequestImpl(const HTTPRequest& request);
/// Sends the given HTTPRequest over an existing connection.
virtual std::string proxyRequestPrefix() const; virtual std::string proxyRequestPrefix() const;
/// Returns the prefix prepended to the URI for proxy requests /// Returns the prefix prepended to the URI for proxy requests
/// (e.g., "http://myhost.com"). /// (e.g., "http://myhost.com").
@@ -316,10 +342,20 @@ protected:
/// Sets the proxy credentials (Proxy-Authorization header), if /// Sets the proxy credentials (Proxy-Authorization header), if
/// proxy username and password have been set. /// proxy username and password have been set.
void proxyAuthenticateImpl(HTTPRequest& request); void proxyAuthenticateImpl(HTTPRequest& request, const ProxyConfig& proxyConfig);
/// Sets the proxy credentials (Proxy-Authorization header), if /// Sets the proxy credentials (Proxy-Authorization header), if
/// proxy username and password have been set. /// proxy username and password have been set.
void proxyAuthenticateDigest(HTTPRequest& request);
/// Initiates a HTTP Digest authentication handshake with the proxy.
void proxyAuthenticateNTLM(HTTPRequest& request);
/// Initiates a HTTP NTLM authentication handshake with the proxy.
void sendChallengeRequest(const HTTPRequest& request, HTTPResponse& response);
/// Sends a probe request for Digest and NTLM authentication
/// to obtain the server challenge.
StreamSocket proxyConnect(); StreamSocket proxyConnect();
/// Sends a CONNECT request to the proxy server and returns /// Sends a CONNECT request to the proxy server and returns
/// a StreamSocket for the resulting connection. /// a StreamSocket for the resulting connection.
@@ -343,6 +379,10 @@ private:
bool _responseReceived; bool _responseReceived;
Poco::SharedPtr<std::ostream> _pRequestStream; Poco::SharedPtr<std::ostream> _pRequestStream;
Poco::SharedPtr<std::istream> _pResponseStream; Poco::SharedPtr<std::istream> _pResponseStream;
HTTPBasicCredentials _proxyBasicCreds;
HTTPDigestCredentials _proxyDigestCreds;
HTTPNTLMCredentials _proxyNTLMCreds;
bool _ntlmProxyAuthenticated;
static ProxyConfig _globalProxyConfig; static ProxyConfig _globalProxyConfig;

View File

@@ -20,6 +20,7 @@
#include "Poco/Net/HTTPDigestCredentials.h" #include "Poco/Net/HTTPDigestCredentials.h"
#include "Poco/Net/HTTPNTLMCredentials.h"
namespace Poco { namespace Poco {
@@ -37,7 +38,7 @@ class HTTPResponse;
class Net_API HTTPCredentials class Net_API HTTPCredentials
/// This is a utility class for working with HTTP /// This is a utility class for working with HTTP
/// authentication (basic or digest) in HTTPRequest objects. /// authentication (Basic, Digest or NTLM) in HTTPRequest objects.
/// ///
/// Usage is as follows: /// Usage is as follows:
/// First, create a HTTPCredentials object containing /// First, create a HTTPCredentials object containing
@@ -48,7 +49,7 @@ class Net_API HTTPCredentials
/// Poco::Net::HTTPClientSession session("pocoproject.org"); /// Poco::Net::HTTPClientSession session("pocoproject.org");
/// Poco::Net::HTTPRequest request(HTTPRequest::HTTP_GET, "/index.html", HTTPMessage::HTTP_1_1); /// Poco::Net::HTTPRequest request(HTTPRequest::HTTP_GET, "/index.html", HTTPMessage::HTTP_1_1);
/// session.sendRequest(request); /// session.sendRequest(request);
/// Poco::Net::HTTPResponse; /// Poco::Net::HTTPResponse response;
/// std::istream& istr = session.receiveResponse(response); /// std::istream& istr = session.receiveResponse(response);
/// ///
/// If the server responds with a 401 status, authenticate the /// If the server responds with a 401 status, authenticate the
@@ -90,6 +91,9 @@ public:
/// and password of the credentials object. /// and password of the credentials object.
/// Does nothing if URI has no user info part. /// Does nothing if URI has no user info part.
void clear();
/// Clears username, password and host.
void setUsername(const std::string& username); void setUsername(const std::string& username);
/// Sets the username. /// Sets the username.
@@ -102,6 +106,17 @@ public:
const std::string& getPassword() const; const std::string& getPassword() const;
/// Returns the password. /// Returns the password.
void setHost(const std::string& host);
/// Sets the target host. Only used for SSPI-based NTLM authentication using
/// the credentials of the currently logged-in user on Windows.
const std::string& getHost() const;
/// Returns the target host. Only used for SSPI-based NTLM authentication using
/// the credentials of the currently logged-in user on Windows.
bool empty() const;
/// Returns true if both username and password are empty, otherwise false.
void authenticate(HTTPRequest& request, const HTTPResponse& response); void authenticate(HTTPRequest& request, const HTTPResponse& response);
/// Inspects WWW-Authenticate header of the response, initializes /// Inspects WWW-Authenticate header of the response, initializes
/// the internal state (in case of digest authentication) and /// the internal state (in case of digest authentication) and
@@ -132,17 +147,26 @@ public:
static bool isDigestCredentials(const std::string& header); static bool isDigestCredentials(const std::string& header);
/// Returns true if authentication header is for Digest authentication. /// Returns true if authentication header is for Digest authentication.
static bool isNTLMCredentials(const std::string& header);
/// Returns true if authentication header is for NTLM authentication.
static bool hasBasicCredentials(const HTTPRequest& request); static bool hasBasicCredentials(const HTTPRequest& request);
/// Returns true if Authorization with Basic credentials header is present in the request. /// Returns true if an Authorization header with Basic credentials is present in the request.
static bool hasDigestCredentials(const HTTPRequest& request); static bool hasDigestCredentials(const HTTPRequest& request);
/// Returns true if Authorization with Digest credentials header is present in the request. /// Returns true if an Authorization header with Digest credentials is present in the request.
static bool hasNTLMCredentials(const HTTPRequest& request);
/// Returns true if an Authorization header with NTLM credentials is present in the request.
static bool hasProxyBasicCredentials(const HTTPRequest& request); static bool hasProxyBasicCredentials(const HTTPRequest& request);
/// Returns true if Authorization with Basic credentials header is present in the request. /// Returns true if a Proxy-Authorization header with Basic credentials is present in the request.
static bool hasProxyDigestCredentials(const HTTPRequest& request); static bool hasProxyDigestCredentials(const HTTPRequest& request);
/// Returns true if Authorization with Digest credentials header is present in the request. /// Returns true if a Proxy-Authorization header with Digest credentials is present in the request.
static bool hasProxyNTLMCredentials(const HTTPRequest& request);
/// Returns true if a Proxy-Authorization header with Digest credentials is present in the request.
static void extractCredentials(const std::string& userInfo, std::string& username, std::string& password); static void extractCredentials(const std::string& userInfo, std::string& username, std::string& password);
/// Extracts username and password from user:password information string. /// Extracts username and password from user:password information string.
@@ -155,6 +179,7 @@ private:
HTTPCredentials& operator = (const HTTPCredentials&); HTTPCredentials& operator = (const HTTPCredentials&);
HTTPDigestCredentials _digest; HTTPDigestCredentials _digest;
HTTPNTLMCredentials _ntlm;
}; };
@@ -185,6 +210,24 @@ inline const std::string& HTTPCredentials::getPassword() const
} }
inline void HTTPCredentials::setHost(const std::string& host)
{
_ntlm.setHost(host);
}
inline const std::string& HTTPCredentials::getHost() const
{
return _ntlm.getHost();
}
inline bool HTTPCredentials::empty() const
{
return _digest.empty();
}
} } // namespace Poco::Net } } // namespace Poco::Net

View File

@@ -52,6 +52,10 @@ public:
void reset(); void reset();
/// Resets the HTTPDigestCredentials object to a clean state. /// Resets the HTTPDigestCredentials object to a clean state.
/// Does not clear username and password.
void clear();
/// Clears both username and password.
void setUsername(const std::string& username); void setUsername(const std::string& username);
/// Sets the username. /// Sets the username.
@@ -65,6 +69,9 @@ public:
const std::string& getPassword() const; const std::string& getPassword() const;
/// Returns the password. /// Returns the password.
bool empty() const;
/// Returns true if both username and password are empty, otherwise false.
void authenticate(HTTPRequest& request, const HTTPResponse& response); void authenticate(HTTPRequest& request, const HTTPResponse& response);
/// Parses WWW-Authenticate header of the HTTPResponse, initializes /// Parses WWW-Authenticate header of the HTTPResponse, initializes
/// internal state, and adds authentication information to the given HTTPRequest. /// internal state, and adds authentication information to the given HTTPRequest.
@@ -167,6 +174,12 @@ inline const std::string& HTTPDigestCredentials::getPassword() const
} }
inline bool HTTPDigestCredentials::empty() const
{
return _username.empty() && _password.empty();
}
} } // namespace Poco::Net } } // namespace Poco::Net

View File

@@ -139,6 +139,7 @@ public:
static const std::string CONTENT_TYPE; static const std::string CONTENT_TYPE;
static const std::string TRANSFER_ENCODING; static const std::string TRANSFER_ENCODING;
static const std::string CONNECTION; static const std::string CONNECTION;
static const std::string PROXY_CONNECTION;
static const std::string CONNECTION_KEEP_ALIVE; static const std::string CONNECTION_KEEP_ALIVE;
static const std::string CONNECTION_CLOSE; static const std::string CONNECTION_CLOSE;
@@ -153,13 +154,16 @@ protected:
/// Creates the HTTPMessage and sets /// Creates the HTTPMessage and sets
/// the version. /// the version.
HTTPMessage(const HTTPMessage& other);
/// Copy constructor.
HTTPMessage& operator = (const HTTPMessage& other);
/// Assignment operator.
virtual ~HTTPMessage(); virtual ~HTTPMessage();
/// Destroys the HTTPMessage. /// Destroys the HTTPMessage.
private: private:
HTTPMessage(const HTTPMessage&);
HTTPMessage& operator = (const HTTPMessage&);
std::string _version; std::string _version;
}; };

View File

@@ -0,0 +1,168 @@
//
// HTTPNTLMCredentials.h
//
// Library: Net
// Package: HTTP
// Module: HTTPNTLMCredentials
//
// Definition of the HTTPNTLMCredentials class.
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#ifndef Net_HTTPNTLMCredentials_INCLUDED
#define Net_HTTPNTLMCredentials_INCLUDED
#include "Poco/Net/Net.h"
#include "Poco/Net/SSPINTLMCredentials.h"
#include <vector>
namespace Poco {
namespace Net {
class HTTPRequest;
class HTTPResponse;
class Net_API HTTPNTLMCredentials
/// This is a utility class for working with
/// HTTP NTLMv2 Authentication in HTTPRequest
/// objects.
{
public:
HTTPNTLMCredentials();
/// Creates an empty HTTPNTLMCredentials object.
HTTPNTLMCredentials(const std::string& username, const std::string& password);
/// Creates a HTTPNTLMCredentials object with the given username and password.
HTTPNTLMCredentials(const std::string& username, const std::string& password, const std::string& host);
/// Creates a HTTPNTLMCredentials object with the given username, password and target host.
~HTTPNTLMCredentials();
/// Destroys the HTTPNTLMCredentials.
void reset();
/// Resets the HTTPNTLMCredentials object to a clean state.
/// Does not clear username and password.
void clear();
/// Clears username, password and host.
void setUsername(const std::string& username);
/// Sets the username.
const std::string& getUsername() const;
/// Returns the username.
void setPassword(const std::string& password);
/// Sets the password.
const std::string& getPassword() const;
/// Returns the password.
bool empty() const;
/// Returns true if both username and password are empty, otherwise false.
void setHost(const std::string& host);
/// Sets the target host.\
///
/// Used for SSPI-based NTLM authentication only.
const std::string& getHost() const;
/// Returns the target host.
void authenticate(HTTPRequest& request, const HTTPResponse& response);
/// Parses WWW-Authenticate header of the HTTPResponse, initializes
/// internal state, and adds authentication information to the given HTTPRequest.
void authenticate(HTTPRequest& request, const std::string& ntlmChallengeBase64);
/// Initializes internal state according to information from the
/// ntlmChallengeBase64, and adds authentication
/// information to the given HTTPRequest.
///
/// Throws InvalidArgumentException if responseAuthParams is
/// invalid.
void updateAuthInfo(HTTPRequest& request);
/// Updates internal state and adds authentication information to
/// the given HTTPRequest.
void proxyAuthenticate(HTTPRequest& request, const HTTPResponse& response);
/// Parses Proxy-Authenticate header of the HTTPResponse, initializes
/// internal state, and adds proxy authentication information to the given HTTPRequest.
void proxyAuthenticate(HTTPRequest& request, const std::string& ntlmChallengeBase64);
/// Initializes internal state according to information from the
/// HTTPAuthenticationParams of the response, and adds proxy authentication
/// information to the given HTTPRequest.
///
/// Throws InvalidArgumentException if HTTPAuthenticationParams is
/// invalid or some required parameter is missing.
/// Throws NotImplementedException in case of unsupported digest
/// algorithm or quality of protection method.
void updateProxyAuthInfo(HTTPRequest& request);
/// Updates internal state and adds proxy authentication information to
/// the given HTTPRequest.
static const std::string SCHEME;
private:
HTTPNTLMCredentials(const HTTPNTLMCredentials&);
HTTPNTLMCredentials& operator = (const HTTPNTLMCredentials&);
std::string createNTLMMessage(const std::string& ntlmChallengeBase64);
bool useSSPINTLM() const;
std::string _username;
std::string _password;
std::string _host;
Poco::SharedPtr<NTLMContext> _pNTLMContext;
};
//
// inlines
//
inline const std::string& HTTPNTLMCredentials::getUsername() const
{
return _username;
}
inline const std::string& HTTPNTLMCredentials::getPassword() const
{
return _password;
}
inline const std::string& HTTPNTLMCredentials::getHost() const
{
return _host;
}
inline bool HTTPNTLMCredentials::useSSPINTLM() const
{
return _username.empty() && _password.empty() && SSPINTLMCredentials::available();
}
inline bool HTTPNTLMCredentials::empty() const
{
return _username.empty() && _password.empty();
}
} } // namespace Poco::Net
#endif // Net_HTTPNTLMCredentials_INCLUDED

View File

@@ -39,7 +39,7 @@ public:
HTTPRequest(); HTTPRequest();
/// Creates a GET / HTTP/1.0 HTTP request. /// Creates a GET / HTTP/1.0 HTTP request.
HTTPRequest(const std::string& version); explicit HTTPRequest(const std::string& version);
/// Creates a GET / HTTP/1.x request with /// Creates a GET / HTTP/1.x request with
/// the given version (HTTP/1.0 or HTTP/1.1). /// the given version (HTTP/1.0 or HTTP/1.1).
@@ -49,9 +49,15 @@ public:
HTTPRequest(const std::string& method, const std::string& uri, const std::string& version); HTTPRequest(const std::string& method, const std::string& uri, const std::string& version);
/// Creates a HTTP request with the given method, URI and version. /// Creates a HTTP request with the given method, URI and version.
HTTPRequest(const HTTPRequest& other);
/// Creates a HTTP request by copying another one.
virtual ~HTTPRequest(); virtual ~HTTPRequest();
/// Destroys the HTTPRequest. /// Destroys the HTTPRequest.
HTTPRequest& operator = (const HTTPRequest&);
/// Assignment operator.
void setMethod(const std::string& method); void setMethod(const std::string& method);
/// Sets the method. /// Sets the method.
@@ -103,6 +109,9 @@ public:
/// Sets the authentication scheme and information for /// Sets the authentication scheme and information for
/// this request. /// this request.
void removeCredentials();
/// Removes any credentials from the request.
bool getExpectContinue() const; bool getExpectContinue() const;
/// Returns true if the request contains an /// Returns true if the request contains an
/// "Expect: 100-continue" header. /// "Expect: 100-continue" header.
@@ -126,6 +135,9 @@ public:
/// Sets the proxy authentication scheme and information for /// Sets the proxy authentication scheme and information for
/// this request. /// this request.
void removeProxyCredentials();
/// Removes any proxy credentials from the request.
void write(std::ostream& ostr) const; void write(std::ostream& ostr) const;
/// Writes the HTTP request to the given /// Writes the HTTP request to the given
/// output stream. /// output stream.
@@ -173,9 +185,6 @@ private:
std::string _method; std::string _method;
std::string _uri; std::string _uri;
HTTPRequest(const HTTPRequest&);
HTTPRequest& operator = (const HTTPRequest&);
}; };

View File

@@ -122,17 +122,23 @@ public:
/// Creates the HTTPResponse with the given version, status /// Creates the HTTPResponse with the given version, status
/// and reason phrase. /// and reason phrase.
HTTPResponse(HTTPStatus status); explicit HTTPResponse(HTTPStatus status);
/// Creates the HTTPResponse with the given status /// Creates the HTTPResponse with the given status
/// an an appropriate reason phrase. /// and an appropriate reason phrase.
HTTPResponse(const std::string& version, HTTPStatus status); HTTPResponse(const std::string& version, HTTPStatus status);
/// Creates the HTTPResponse with the given version, status /// Creates the HTTPResponse with the given version, status
/// an an appropriate reason phrase. /// and an appropriate reason phrase.
HTTPResponse(const HTTPResponse& other);
/// Creates the HTTPResponse by copying another one.
virtual ~HTTPResponse(); virtual ~HTTPResponse();
/// Destroys the HTTPResponse. /// Destroys the HTTPResponse.
HTTPResponse& operator = (const HTTPResponse& other);
/// Assignment operator.
void setStatus(HTTPStatus status); void setStatus(HTTPStatus status);
/// Sets the HTTP status code. /// Sets the HTTP status code.
/// ///
@@ -268,9 +274,6 @@ private:
HTTPStatus _status; HTTPStatus _status;
std::string _reason; std::string _reason;
HTTPResponse(const HTTPResponse&);
HTTPResponse& operator = (const HTTPResponse&);
}; };

View File

@@ -0,0 +1,181 @@
//
// NTLMCredentials.h
//
// Library: Net
// Package: NTLM
// Module: NTLMCredentials
//
// Definition of the NTLMCredentials class.
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#ifndef Net_NTLMCredentials_INCLUDED
#define Net_NTLMCredentials_INCLUDED
#include "Poco/Net/Net.h"
#include "Poco/BinaryReader.h"
#include "Poco/BinaryWriter.h"
#include <vector>
namespace Poco {
namespace Net {
class Net_API NTLMCredentials
/// This is a utility class for working with
/// NTLMv2 Authentication.
///
/// Note: This implementation is based on the
/// "The NTLM Authentication Protocol and Security Support Provider"
/// document written by Eric Glass and avilable from
/// http://davenport.sourceforge.net/ntlm.html
/// and the NT LAN Manager (NTLM) Authentication Protocol
/// [MS-NLMP] document by Microsoft.
{
public:
enum
{
NTLM_MESSAGE_TYPE_NEGOTIATE = 0x01,
NTLM_MESSAGE_TYPE_CHALLENGE = 0x02,
NTLM_MESSAGE_TYPE_AUTHENTICATE = 0x03
};
enum
{
NTLM_FLAG_NEGOTIATE_UNICODE = 0x00000001,
NTLM_FLAG_NEGOTIATE_OEM = 0x00000002,
NTLM_FLAG_REQUEST_TARGET = 0x00000004,
NTLM_FLAG_NEGOTIATE_NTLM = 0x00000200,
NTLM_FLAG_DOMAIN_SUPPLIED = 0x00001000,
NTLM_FLAG_WORKST_SUPPLIED = 0x00002000,
NTLM_FLAG_NEGOTIATE_LOCAL = 0x00004000,
NTLM_FLAG_NEGOTIATE_ALWAYS_SIGN = 0x00008000,
NTLM_FLAG_NEGOTIATE_NTLM2_KEY = 0x00080000,
NTLM_FLAG_TARGET_DOMAIN = 0x00010000,
NTLM_FLAG_TARGET_SERVER = 0x00020000,
NTLM_FLAG_TARGET_SHARE = 0x00040000,
NTLM_FLAG_NEGOTIATE_TARGET = 0x00800000,
NTLM_FLAG_NEGOTIATE_128 = 0x20000000,
NTLM_FLAG_NEGOTIATE_56 = 0x80000000
};
struct NegotiateMessage
/// This message is sent from the client to initiate NTLM authentication.
{
NegotiateMessage(): flags(0) {}
Poco::UInt32 flags;
std::string domain;
std::string workstation;
};
struct ChallengeMessage
/// This message is sent back by the server and contains the NTLM challenge.
{
ChallengeMessage(): flags(0) {}
Poco::UInt32 flags;
std::vector<unsigned char> challenge;
std::string target;
std::vector<unsigned char> targetInfo;
};
struct AuthenticateMessage
/// This message is sent from the client to authenticate itself by providing
/// a response to the server challenge.
{
AuthenticateMessage(): flags(0) {}
Poco::UInt32 flags;
std::vector<unsigned char> lmResponse;
std::vector<unsigned char> ntlmResponse;
std::string target;
std::string username;
std::string workstation;
};
struct BufferDesc
{
BufferDesc():
length(0),
reserved(0),
offset(0)
{
}
BufferDesc(Poco::UInt16 len, Poco::UInt32 off):
length(len),
reserved(len),
offset(off)
{
}
Poco::UInt16 length;
Poco::UInt16 reserved;
Poco::UInt32 offset;
};
static std::vector<unsigned char> createNonce();
/// Creates an 8-byte client nonce for NTLM authentication.
static Poco::UInt64 createTimestamp();
/// Creates the NTLM timestamp in tenths of a microsecond since January 1, 1601,
/// using the current system time.
static std::vector<unsigned char> createPasswordHash(const std::string& password);
/// Creates the NTLM password hash (MD4 of UTF-16-converted password).
static std::vector<unsigned char> createNTLMv2Hash(const std::string& username, const std::string& target, const std::string& password);
/// Creates the NTLMv2 hash, which is the HMAC-MD5 of the concatenated UTF-16 uppercase username and target,
/// using the password hash as HMAC passphrase.
static std::vector<unsigned char> createLMv2Response(const std::vector<unsigned char>& ntlm2Hash, const std::vector<unsigned char>& challenge, const std::vector<unsigned char>& nonce);
/// Creates the LMv2 response by computing the HMAC-MD5 of the challenge and nonce, using the
/// ntlm2Hash (see createNTLMv2Hash()) as HMAC passphrase.
static std::vector<unsigned char> createNTLMv2Response(const std::vector<unsigned char>& ntlm2Hash, const std::vector<unsigned char>& challenge, const std::vector<unsigned char>& nonce, const std::vector<unsigned char>& targetInfo, Poco::UInt64 timestamp);
/// Creates the NTLMv2 response by creating the "blob" and prepending its HMAC-MD5, using the ntlm2Hash as HMAC passphrase.
static std::vector<unsigned char> formatNegotiateMessage(const NegotiateMessage& message);
/// Creates the NTLM Type 1 Negotiate message used for initiating NTLM authentication from the client.
static bool parseChallengeMessage(const unsigned char* buffer, std::size_t size, ChallengeMessage& message);
/// Parses a NTLM Type 2 Challenge message.
///
/// Returns true if the message was parsed successfully, otherwise false.
static std::vector<unsigned char> formatAuthenticateMessage(const AuthenticateMessage& message);
/// Creates the NTLM Type 3 Authenticate message used for sending the response to the challenge.
static void readBufferDesc(Poco::BinaryReader& reader, BufferDesc& desc);
/// Reads a buffer descriptor.
static void writeBufferDesc(Poco::BinaryWriter& writer, const BufferDesc& desc);
/// Writes a buffer descriptor.
static void splitUsername(const std::string& usernameAndDomain, std::string& username, std::string& domain);
/// Splits a username containing a domain into plain username and domain.
/// Supported formats are <DOMAIN>\<username> and <username>@<DOMAIN>.
static std::string toBase64(const std::vector<unsigned char>& buffer);
/// Converts the buffer to a base64-encoded string.
static std::vector<unsigned char> fromBase64(const std::string& base64);
/// Decodes the given base64-encoded string.
static const std::string NTLMSSP;
/// Message signature string.
};
} } // namespace Poco::Net
#endif // Net_NTLMCredentials_INCLUDED

View File

@@ -51,7 +51,8 @@ public:
AUTH_CRAM_SHA1, AUTH_CRAM_SHA1,
AUTH_LOGIN, AUTH_LOGIN,
AUTH_PLAIN, AUTH_PLAIN,
AUTH_XOAUTH2 AUTH_XOAUTH2,
AUTH_NTLM
}; };
explicit SMTPClientSession(const StreamSocket& socket); explicit SMTPClientSession(const StreamSocket& socket);
@@ -184,12 +185,15 @@ protected:
void loginUsingLogin(const std::string& username, const std::string& password); void loginUsingLogin(const std::string& username, const std::string& password);
void loginUsingPlain(const std::string& username, const std::string& password); void loginUsingPlain(const std::string& username, const std::string& password);
void loginUsingXOAUTH2(const std::string& username, const std::string& password); void loginUsingXOAUTH2(const std::string& username, const std::string& password);
void loginUsingNTLM(const std::string& username, const std::string& password);
DialogSocket& socket(); DialogSocket& socket();
const std::string& host() const;
private: private:
void sendCommands(const MailMessage& message, const Recipients* pRecipients = 0); void sendCommands(const MailMessage& message, const Recipients* pRecipients = 0);
void transportMessage(const MailMessage& message); void transportMessage(const MailMessage& message);
std::string _host;
DialogSocket _socket; DialogSocket _socket;
bool _isOpen; bool _isOpen;
}; };
@@ -228,6 +232,12 @@ inline DialogSocket& SMTPClientSession::socket()
} }
inline const std::string& SMTPClientSession::host() const
{
return _host;
}
} } // namespace Poco::Net } } // namespace Poco::Net

View File

@@ -0,0 +1,83 @@
//
// SSPINTLMCredentials.h
//
// Library: Net
// Package: NTLM
// Module: SSPINTLMCredentials
//
// Definition of the SSPINTLMCredentials class.
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#include "Poco/Net/Net.h"
#include <vector>
#ifndef Net_SSPINTLMCredentials_INCLUDED
#define Net_SSPINTLMCredentials_INCLUDED
#include "Poco/Net/Net.h"
#include "Poco/Net/NTLMCredentials.h"
#include "Poco/SharedPtr.h"
namespace Poco {
namespace Net {
struct NTLMContextImpl;
class NTLMContext
/// An opaque context class for working with SSPI NTLM authentication.
{
public:
~NTLMContext();
protected:
NTLMContext(NTLMContextImpl* pImpl);
private:
NTLMContextImpl* _pImpl;
NTLMContext();
NTLMContext(const NTLMContext&);
NTLMContext& operator = (const NTLMContext&);
friend class SSPINTLMProvider;
};
class Net_API SSPINTLMCredentials
/// Support for NTLM authentication using credentials of the currently
/// logged in user via SSPI.
{
public:
static bool available();
/// Returns true if SSPI NTLM support is available.
static Poco::SharedPtr<NTLMContext> createNTLMContext(const std::string& host, const std::string& service);
/// Creates an NTLMContext structure for use with negotiate()
/// and authenticate().
static std::vector<unsigned char> negotiate(NTLMContext& context);
/// Creates the NTLM Type 1 Negotiate message used for initiating NTLM authentication from the client.
static std::vector<unsigned char> authenticate(NTLMContext& context, const std::vector<unsigned char>& challenge);
/// Creates the NTLM Type 3 Authenticate message used for sending the response to the challenge.
static const std::string SERVICE_HTTP;
static const std::string SERVICE_SMTP;
};
} } // namespace Poco::Net
#endif // Net_SSPINTLMCredentials_INCLUDED

View File

@@ -209,6 +209,15 @@ public:
/// is thrown and the WebSocket connection must be /// is thrown and the WebSocket connection must be
/// terminated. /// terminated.
/// ///
/// The frame's payload size must not exceed the
/// maximum payload size set with setMaxPayloadSize().
/// If it does, a WebSocketException (WS_ERR_PAYLOAD_TOO_BIG)
/// is thrown and the WebSocket connection must be
/// terminated.
///
/// A WebSocketException will also be thrown if a malformed
/// or incomplete frame is received.
///
/// Returns the number of bytes received. /// Returns the number of bytes received.
/// A return value of 0 means that the peer has /// A return value of 0 means that the peer has
/// shut down or closed the connection. /// shut down or closed the connection.
@@ -223,6 +232,21 @@ public:
int receiveFrame(Poco::Buffer<char>& buffer, int& flags); int receiveFrame(Poco::Buffer<char>& buffer, int& flags);
/// Receives a frame from the socket and stores it /// Receives a frame from the socket and stores it
/// after any previous content in buffer. /// after any previous content in buffer.
/// The buffer will be grown as necessary.
///
/// The frame's payload size must not exceed the
/// maximum payload size set with setMaxPayloadSize().
/// If it does, a WebSocketException (WS_ERR_PAYLOAD_TOO_BIG)
/// is thrown and the WebSocket connection must be
/// terminated.
///
/// A WebSocketException will also be thrown if a malformed
/// or incomplete frame is received.
///
/// If this method is used, a reasonable maximum payload size should
/// be set with setMaxPayloadSize() to prevent a potential
/// DoS attack (memory exhaustion) by sending a WebSocket frame
/// header with a huge payload size.
/// ///
/// Returns the number of bytes received. /// Returns the number of bytes received.
/// A return value of 0 means that the peer has /// A return value of 0 means that the peer has
@@ -239,6 +263,16 @@ public:
/// Returns WS_SERVER if the WebSocket is a server-side /// Returns WS_SERVER if the WebSocket is a server-side
/// WebSocket, or WS_CLIENT otherwise. /// WebSocket, or WS_CLIENT otherwise.
void setMaxPayloadSize(int maxPayloadSize);
/// Sets the maximum payload size for receiveFrame().
///
/// The default is std::numeric_limits<int>::max().
int getMaxPayloadSize() const;
/// Returns the maximum payload size for receiveFrame().
///
/// The default is std::numeric_limits<int>::max().
static const std::string WEBSOCKET_VERSION; static const std::string WEBSOCKET_VERSION;
/// The WebSocket protocol version supported (13). /// The WebSocket protocol version supported (13).

View File

@@ -21,6 +21,7 @@
#include "Poco/Net/StreamSocketImpl.h" #include "Poco/Net/StreamSocketImpl.h"
#include "Poco/Buffer.h" #include "Poco/Buffer.h"
#include "Poco/Random.h" #include "Poco/Random.h"
#include "Poco/Buffer.h"
namespace Poco { namespace Poco {
@@ -78,6 +79,16 @@ public:
bool mustMaskPayload() const; bool mustMaskPayload() const;
/// Returns true if the payload must be masked. /// Returns true if the payload must be masked.
void setMaxPayloadSize(int maxPayloadSize);
/// Sets the maximum payload size for receiveFrame().
///
/// The default is std::numeric_limits<int>::max().
int getMaxPayloadSize() const;
/// Returns the maximum payload size for receiveFrame().
///
/// The default is std::numeric_limits<int>::max().
protected: protected:
enum enum
{ {
@@ -95,6 +106,7 @@ private:
WebSocketImpl(); WebSocketImpl();
StreamSocketImpl* _pStreamSocketImpl; StreamSocketImpl* _pStreamSocketImpl;
int _maxPayloadSize;
Poco::Buffer<char> _buffer; Poco::Buffer<char> _buffer;
int _bufferOffset; int _bufferOffset;
int _frameFlags; int _frameFlags;
@@ -118,6 +130,12 @@ inline bool WebSocketImpl::mustMaskPayload() const
} }
inline int WebSocketImpl::getMaxPayloadSize() const
{
return _maxPayloadSize;
}
} } // namespace Poco::Net } } // namespace Poco::Net

View File

@@ -13,7 +13,7 @@
#include "Poco/Net/HTTPClientSession.h" #include "Poco/Net/HTTPClientSession.h"
#include "Poco/Net/HTTPRequest.h" #include "Poco/Net/HTTPRequest.h"
#include "Poco/Net/HTTPResponse.h" #include "Poco/Net/HTTPResponse.h"
#include <Poco/Net/HTTPCredentials.h> #include "Poco/Net/HTTPCredentials.h"
#include "Poco/StreamCopier.h" #include "Poco/StreamCopier.h"
#include "Poco/NullStream.h" #include "Poco/NullStream.h"
#include "Poco/Path.h" #include "Poco/Path.h"

View File

@@ -13,13 +13,13 @@
// //
#include "Poco/Exception.h"
#include "Poco/Net/HTTPAuthenticationParams.h" #include "Poco/Net/HTTPAuthenticationParams.h"
#include "Poco/Net/HTTPRequest.h" #include "Poco/Net/HTTPRequest.h"
#include "Poco/Net/HTTPResponse.h" #include "Poco/Net/HTTPResponse.h"
#include "Poco/Net/NetException.h" #include "Poco/Net/NetException.h"
#include "Poco/String.h" #include "Poco/String.h"
#include "Poco/Ascii.h" #include "Poco/Ascii.h"
#include "Poco/Exception.h"
using Poco::icompare; using Poco::icompare;
@@ -66,6 +66,7 @@ namespace Net {
const std::string HTTPAuthenticationParams::REALM("realm"); const std::string HTTPAuthenticationParams::REALM("realm");
const std::string HTTPAuthenticationParams::NTLM("NTLM");
const std::string HTTPAuthenticationParams::WWW_AUTHENTICATE("WWW-Authenticate"); const std::string HTTPAuthenticationParams::WWW_AUTHENTICATE("WWW-Authenticate");
const std::string HTTPAuthenticationParams::PROXY_AUTHENTICATE("Proxy-Authenticate"); const std::string HTTPAuthenticationParams::PROXY_AUTHENTICATE("Proxy-Authenticate");
@@ -135,20 +136,25 @@ void HTTPAuthenticationParams::fromResponse(const HTTPResponse& response, const
bool found = false; bool found = false;
while (!found && it != response.end() && icompare(it->first, header) == 0) while (!found && it != response.end() && icompare(it->first, header) == 0)
{ {
const std::string& header2 = it->second; const std::string& headerValue = it->second;
if (icompare(header2, 0, 6, "Basic ") == 0) if (icompare(headerValue, 0, 6, "Basic ") == 0)
{ {
parse(header2.begin() + 6, header2.end()); parse(headerValue.begin() + 6, headerValue.end());
found = true; found = true;
} }
else if (icompare(header2, 0, 7, "Digest ") == 0) else if (icompare(headerValue, 0, 7, "Digest ") == 0)
{ {
parse(header2.begin() + 7, header2.end()); parse(headerValue.begin() + 7, headerValue.end());
found = true;
}
else if (icompare(headerValue, 0, 5, "NTLM ") == 0)
{
set(NTLM, headerValue.substr(5));
found = true; found = true;
} }
++it; ++it;
} }
if (!found) throw NotAuthenticatedException("No Basic or Digest authentication header found"); if (!found) throw NotAuthenticatedException("No Basic, Digest or NTLM authentication header found");
} }
@@ -166,8 +172,14 @@ void HTTPAuthenticationParams::setRealm(const std::string& realm)
std::string HTTPAuthenticationParams::toString() const std::string HTTPAuthenticationParams::toString() const
{ {
ConstIterator iter = begin();
std::string result; std::string result;
if (size() == 1 && find(NTLM) != end())
{
result = get(NTLM);
}
else
{
ConstIterator iter = begin();
if (iter != end()) if (iter != end())
{ {
@@ -180,7 +192,7 @@ std::string HTTPAuthenticationParams::toString() const
result.append(", "); result.append(", ");
formatParameter(result, iter->first, iter->second); formatParameter(result, iter->first, iter->second);
} }
}
return result; return result;
} }

View File

@@ -69,6 +69,13 @@ HTTPBasicCredentials::~HTTPBasicCredentials()
} }
void HTTPBasicCredentials::clear()
{
_username.clear();
_password.clear();
}
void HTTPBasicCredentials::setUsername(const std::string& username) void HTTPBasicCredentials::setUsername(const std::string& username)
{ {
_username = username; _username = username;

View File

@@ -19,7 +19,7 @@
#include "Poco/Net/HTTPStream.h" #include "Poco/Net/HTTPStream.h"
#include "Poco/Net/HTTPFixedLengthStream.h" #include "Poco/Net/HTTPFixedLengthStream.h"
#include "Poco/Net/HTTPChunkedStream.h" #include "Poco/Net/HTTPChunkedStream.h"
#include "Poco/Net/HTTPBasicCredentials.h" #include "Poco/Net/HTTPCredentials.h"
#include "Poco/Net/NetException.h" #include "Poco/Net/NetException.h"
#include "Poco/NumberFormatter.h" #include "Poco/NumberFormatter.h"
#include "Poco/CountingStream.h" #include "Poco/CountingStream.h"
@@ -47,7 +47,8 @@ HTTPClientSession::HTTPClientSession():
_reconnect(false), _reconnect(false),
_mustReconnect(false), _mustReconnect(false),
_expectResponseBody(false), _expectResponseBody(false),
_responseReceived(false) _responseReceived(false),
_ntlmProxyAuthenticated(false)
{ {
} }
@@ -62,7 +63,8 @@ HTTPClientSession::HTTPClientSession(const StreamSocket& socket):
_reconnect(false), _reconnect(false),
_mustReconnect(false), _mustReconnect(false),
_expectResponseBody(false), _expectResponseBody(false),
_responseReceived(false) _responseReceived(false),
_ntlmProxyAuthenticated(false)
{ {
setKeepAlive(true); setKeepAlive(true);
} }
@@ -78,7 +80,8 @@ HTTPClientSession::HTTPClientSession(const SocketAddress& address):
_reconnect(false), _reconnect(false),
_mustReconnect(false), _mustReconnect(false),
_expectResponseBody(false), _expectResponseBody(false),
_responseReceived(false) _responseReceived(false),
_ntlmProxyAuthenticated(false)
{ {
} }
@@ -93,7 +96,8 @@ HTTPClientSession::HTTPClientSession(const std::string& host, Poco::UInt16 port)
_reconnect(false), _reconnect(false),
_mustReconnect(false), _mustReconnect(false),
_expectResponseBody(false), _expectResponseBody(false),
_responseReceived(false) _responseReceived(false),
_ntlmProxyAuthenticated(false)
{ {
} }
@@ -255,8 +259,6 @@ std::ostream& HTTPClientSession::sendRequest(HTTPRequest& request)
{ {
_pRequestStream = 0; _pRequestStream = 0;
_pResponseStream = 0; _pResponseStream = 0;
clearException();
_responseReceived = false;
bool keepAlive = getKeepAlive(); bool keepAlive = getKeepAlive();
if (((connected() && !keepAlive) || mustReconnect()) && !_host.empty()) if (((connected() && !keepAlive) || mustReconnect()) && !_host.empty())
@@ -267,17 +269,43 @@ std::ostream& HTTPClientSession::sendRequest(HTTPRequest& request)
try try
{ {
if (!connected()) if (!connected())
{
_ntlmProxyAuthenticated = false;
reconnect(); reconnect();
}
if (!keepAlive) if (!keepAlive)
{
request.setKeepAlive(false); request.setKeepAlive(false);
}
if (!request.has(HTTPRequest::HOST) && !_host.empty()) if (!request.has(HTTPRequest::HOST) && !_host.empty())
{
request.setHost(_host, _port); request.setHost(_host, _port);
}
if (!_proxyConfig.host.empty() && !bypassProxy()) if (!_proxyConfig.host.empty() && !bypassProxy())
{ {
request.setURI(proxyRequestPrefix() + request.getURI()); std::string prefix = proxyRequestPrefix();
if (!prefix.empty() && request.getURI().compare(0, 7, "http://") != 0 && request.getURI().compare(0, 8, "https://") != 0)
request.setURI(prefix + request.getURI());
if (keepAlive) request.set(HTTPMessage::PROXY_CONNECTION, HTTPMessage::CONNECTION_KEEP_ALIVE);
proxyAuthenticate(request); proxyAuthenticate(request);
} }
_reconnect = keepAlive; _reconnect = keepAlive;
return sendRequestImpl(request);
}
catch (Exception&)
{
close();
throw;
}
}
std::ostream& HTTPClientSession::sendRequestImpl(const HTTPRequest& request)
{
_pRequestStream = 0;
_pResponseStream = 0;
clearException();
_responseReceived = false;
_expectResponseBody = request.getMethod() != HTTPRequest::HTTP_HEAD; _expectResponseBody = request.getMethod() != HTTPRequest::HTTP_HEAD;
const std::string& method = request.getMethod(); const std::string& method = request.getMethod();
if (request.getChunkedTransferEncoding()) if (request.getChunkedTransferEncoding())
@@ -312,19 +340,18 @@ std::ostream& HTTPClientSession::sendRequest(HTTPRequest& request)
_lastRequest.update(); _lastRequest.update();
return *_pRequestStream; return *_pRequestStream;
} }
catch (Exception&)
{
close(); void HTTPClientSession::flushRequest()
throw; {
} _pRequestStream = 0;
if (networkException()) networkException()->rethrow();
} }
std::istream& HTTPClientSession::receiveResponse(HTTPResponse& response) std::istream& HTTPClientSession::receiveResponse(HTTPResponse& response)
{ {
_pRequestStream = 0; flushRequest();
if (networkException()) networkException()->rethrow();
if (!_responseReceived) if (!_responseReceived)
{ {
do do
@@ -475,17 +502,87 @@ bool HTTPClientSession::mustReconnect() const
void HTTPClientSession::proxyAuthenticate(HTTPRequest& request) void HTTPClientSession::proxyAuthenticate(HTTPRequest& request)
{ {
proxyAuthenticateImpl(request); proxyAuthenticateImpl(request, _proxyConfig);
} }
void HTTPClientSession::proxyAuthenticateImpl(HTTPRequest& request) void HTTPClientSession::proxyAuthenticateImpl(HTTPRequest& request, const ProxyConfig& proxyConfig)
{ {
if (!_proxyConfig.username.empty()) switch (proxyConfig.authMethod)
{ {
HTTPBasicCredentials creds(_proxyConfig.username, _proxyConfig.password); case PROXY_AUTH_NONE:
creds.proxyAuthenticate(request); break;
case PROXY_AUTH_HTTP_BASIC:
_proxyBasicCreds.setUsername(proxyConfig.username);
_proxyBasicCreds.setPassword(proxyConfig.password);
_proxyBasicCreds.proxyAuthenticate(request);
break;
case PROXY_AUTH_HTTP_DIGEST:
if (HTTPCredentials::hasDigestCredentials(request))
{
_proxyDigestCreds.updateProxyAuthInfo(request);
} }
else
{
_proxyDigestCreds.setUsername(proxyConfig.username);
_proxyDigestCreds.setPassword(proxyConfig.password);
proxyAuthenticateDigest(request);
}
case PROXY_AUTH_NTLM:
if (_ntlmProxyAuthenticated)
{
_proxyNTLMCreds.updateProxyAuthInfo(request);
}
else
{
_proxyNTLMCreds.setUsername(proxyConfig.username);
_proxyNTLMCreds.setPassword(proxyConfig.password);
_proxyNTLMCreds.setHost(proxyConfig.host);
proxyAuthenticateNTLM(request);
_ntlmProxyAuthenticated = true;
}
}
}
void HTTPClientSession::proxyAuthenticateDigest(HTTPRequest& request)
{
HTTPResponse response;
request.set(HTTPMessage::PROXY_CONNECTION, HTTPMessage::CONNECTION_KEEP_ALIVE);
sendChallengeRequest(request, response);
_proxyDigestCreds.proxyAuthenticate(request, response);
}
void HTTPClientSession::proxyAuthenticateNTLM(HTTPRequest& request)
{
HTTPResponse response;
request.set(HTTPMessage::PROXY_CONNECTION, HTTPMessage::CONNECTION_KEEP_ALIVE);
_proxyNTLMCreds.proxyAuthenticate(request, std::string());
sendChallengeRequest(request, response);
_proxyNTLMCreds.proxyAuthenticate(request, response);
}
void HTTPClientSession::sendChallengeRequest(const HTTPRequest& request, HTTPResponse& response)
{
if (!connected())
{
reconnect();
}
HTTPRequest challengeRequest(request);
if (challengeRequest.hasContentLength())
{
challengeRequest.setContentLength(0);
}
sendRequestImpl(challengeRequest);
std::istream& istr = receiveResponse(response);
while (istr.good()) istr.get();
} }
@@ -499,9 +596,9 @@ StreamSocket HTTPClientSession::proxyConnect()
NumberFormatter::append(targetAddress, _port); NumberFormatter::append(targetAddress, _port);
HTTPRequest proxyRequest(HTTPRequest::HTTP_CONNECT, targetAddress, HTTPMessage::HTTP_1_1); HTTPRequest proxyRequest(HTTPRequest::HTTP_CONNECT, targetAddress, HTTPMessage::HTTP_1_1);
HTTPResponse proxyResponse; HTTPResponse proxyResponse;
proxyRequest.set("Proxy-Connection", "keep-alive"); proxyRequest.set(HTTPMessage::PROXY_CONNECTION, HTTPMessage::CONNECTION_KEEP_ALIVE);
proxyRequest.set("Host", getHost()); proxyRequest.set(HTTPRequest::HOST, getHost());
proxyAuthenticateImpl(proxyRequest); proxySession.proxyAuthenticateImpl(proxyRequest, _proxyConfig);
proxySession.setKeepAlive(true); proxySession.setKeepAlive(true);
proxySession.setSourceAddress(_sourceAddress4); proxySession.setSourceAddress(_sourceAddress4);
proxySession.setSourceAddress(_sourceAddress6); proxySession.setSourceAddress(_sourceAddress6);

View File

@@ -47,6 +47,13 @@ HTTPCredentials::~HTTPCredentials()
} }
void HTTPCredentials::clear()
{
_digest.clear();
_ntlm.clear();
}
void HTTPCredentials::fromUserInfo(const std::string& userInfo) void HTTPCredentials::fromUserInfo(const std::string& userInfo)
{ {
std::string username; std::string username;
@@ -67,6 +74,7 @@ void HTTPCredentials::fromURI(const URI& uri)
extractCredentials(uri, username, password); extractCredentials(uri, username, password);
setUsername(username); setUsername(username);
setPassword(password); setPassword(password);
setHost(uri.getHost());
_digest.reset(); _digest.reset();
} }
@@ -85,6 +93,17 @@ void HTTPCredentials::authenticate(HTTPRequest& request, const HTTPResponse& res
_digest.authenticate(request, HTTPAuthenticationParams(iter->second.substr(7))); _digest.authenticate(request, HTTPAuthenticationParams(iter->second.substr(7)));
return; return;
} }
else if (isNTLMCredentials(iter->second))
{
_ntlm.setUsername(_digest.getUsername());
_ntlm.setPassword(_digest.getPassword());
if (_ntlm.getHost().empty())
{
_ntlm.setHost(request.getHost());
}
_ntlm.authenticate(request, iter->second.substr(5));
return;
}
} }
} }
@@ -103,6 +122,10 @@ void HTTPCredentials::updateAuthInfo(HTTPRequest& request)
{ {
_digest.updateAuthInfo(request); _digest.updateAuthInfo(request);
} }
else if (isNTLMCredentials(authorization))
{
_ntlm.updateAuthInfo(request);
}
} }
} }
@@ -121,6 +144,13 @@ void HTTPCredentials::proxyAuthenticate(HTTPRequest& request, const HTTPResponse
_digest.proxyAuthenticate(request, HTTPAuthenticationParams(iter->second.substr(7))); _digest.proxyAuthenticate(request, HTTPAuthenticationParams(iter->second.substr(7)));
return; return;
} }
else if (isNTLMCredentials(iter->second))
{
_ntlm.setUsername(_digest.getUsername());
_ntlm.setPassword(_digest.getPassword());
_ntlm.proxyAuthenticate(request, iter->second.substr(5));
return;
}
} }
} }
@@ -139,6 +169,10 @@ void HTTPCredentials::updateProxyAuthInfo(HTTPRequest& request)
{ {
_digest.updateProxyAuthInfo(request); _digest.updateProxyAuthInfo(request);
} }
else if (isNTLMCredentials(authorization))
{
_ntlm.updateProxyAuthInfo(request);
}
} }
} }
@@ -155,6 +189,12 @@ bool HTTPCredentials::isDigestCredentials(const std::string& header)
} }
bool HTTPCredentials::isNTLMCredentials(const std::string& header)
{
return icompare(header, 0, 4, "NTLM") == 0 && (header.size() > 5 ? Poco::Ascii::isSpace(header[5]) : true);
}
bool HTTPCredentials::hasBasicCredentials(const HTTPRequest& request) bool HTTPCredentials::hasBasicCredentials(const HTTPRequest& request)
{ {
return request.has(HTTPRequest::AUTHORIZATION) && isBasicCredentials(request.get(HTTPRequest::AUTHORIZATION)); return request.has(HTTPRequest::AUTHORIZATION) && isBasicCredentials(request.get(HTTPRequest::AUTHORIZATION));
@@ -167,6 +207,12 @@ bool HTTPCredentials::hasDigestCredentials(const HTTPRequest& request)
} }
bool HTTPCredentials::hasNTLMCredentials(const HTTPRequest& request)
{
return request.has(HTTPRequest::AUTHORIZATION) && isNTLMCredentials(request.get(HTTPRequest::AUTHORIZATION));
}
bool HTTPCredentials::hasProxyBasicCredentials(const HTTPRequest& request) bool HTTPCredentials::hasProxyBasicCredentials(const HTTPRequest& request)
{ {
return request.has(HTTPRequest::PROXY_AUTHORIZATION) && isBasicCredentials(request.get(HTTPRequest::PROXY_AUTHORIZATION)); return request.has(HTTPRequest::PROXY_AUTHORIZATION) && isBasicCredentials(request.get(HTTPRequest::PROXY_AUTHORIZATION));
@@ -179,6 +225,12 @@ bool HTTPCredentials::hasProxyDigestCredentials(const HTTPRequest& request)
} }
bool HTTPCredentials::hasProxyNTLMCredentials(const HTTPRequest& request)
{
return request.has(HTTPRequest::PROXY_AUTHORIZATION) && isNTLMCredentials(request.get(HTTPRequest::PROXY_AUTHORIZATION));
}
void HTTPCredentials::extractCredentials(const std::string& userInfo, std::string& username, std::string& password) void HTTPCredentials::extractCredentials(const std::string& userInfo, std::string& username, std::string& password)
{ {
const std::string::size_type p = userInfo.find(':'); const std::string::size_type p = userInfo.find(':');

View File

@@ -121,6 +121,13 @@ void HTTPDigestCredentials::setPassword(const std::string& password)
} }
void HTTPDigestCredentials::clear()
{
_username.clear();
_password.clear();
}
void HTTPDigestCredentials::authenticate(HTTPRequest& request, const HTTPResponse& response) void HTTPDigestCredentials::authenticate(HTTPRequest& request, const HTTPResponse& response)
{ {
authenticate(request, HTTPAuthenticationParams(response)); authenticate(request, HTTPAuthenticationParams(response));

View File

@@ -38,6 +38,7 @@ const std::string HTTPMessage::CONTENT_LENGTH = "Content-Length";
const std::string HTTPMessage::CONTENT_TYPE = "Content-Type"; const std::string HTTPMessage::CONTENT_TYPE = "Content-Type";
const std::string HTTPMessage::TRANSFER_ENCODING = "Transfer-Encoding"; const std::string HTTPMessage::TRANSFER_ENCODING = "Transfer-Encoding";
const std::string HTTPMessage::CONNECTION = "Connection"; const std::string HTTPMessage::CONNECTION = "Connection";
const std::string HTTPMessage::PROXY_CONNECTION = "Proxy-Connection";
const std::string HTTPMessage::CONNECTION_KEEP_ALIVE = "Keep-Alive"; const std::string HTTPMessage::CONNECTION_KEEP_ALIVE = "Keep-Alive";
const std::string HTTPMessage::CONNECTION_CLOSE = "Close"; const std::string HTTPMessage::CONNECTION_CLOSE = "Close";
const std::string HTTPMessage::EMPTY; const std::string HTTPMessage::EMPTY;
@@ -55,11 +56,29 @@ HTTPMessage::HTTPMessage(const std::string& version):
} }
HTTPMessage::HTTPMessage(const HTTPMessage& other):
MessageHeader(other),
_version(other._version)
{
}
HTTPMessage::~HTTPMessage() HTTPMessage::~HTTPMessage()
{ {
} }
HTTPMessage& HTTPMessage::operator = (const HTTPMessage& other)
{
if (this != &other)
{
MessageHeader::operator = (other);
_version = other._version;
}
return *this;
}
void HTTPMessage::setVersion(const std::string& version) void HTTPMessage::setVersion(const std::string& version)
{ {
_version = version; _version = version;

View File

@@ -0,0 +1,185 @@
//
// HTTPNTLMCredentials.cpp
//
// Library: Net
// Package: HTTP
// Module: HTTPNTLMCredentials
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#include "Poco/Net/HTTPNTLMCredentials.h"
#include "Poco/Net/NTLMCredentials.h"
#include "Poco/Net/HTTPAuthenticationParams.h"
#include "Poco/Net/HTTPRequest.h"
#include "Poco/Net/HTTPResponse.h"
#include "Poco/Net/NetException.h"
#include "Poco/DateTime.h"
#include "Poco/NumberFormatter.h"
#include "Poco/Exception.h"
namespace Poco {
namespace Net {
const std::string HTTPNTLMCredentials::SCHEME = "NTLM";
HTTPNTLMCredentials::HTTPNTLMCredentials()
{
}
HTTPNTLMCredentials::HTTPNTLMCredentials(const std::string& username, const std::string& password):
_username(username),
_password(password)
{
}
HTTPNTLMCredentials::~HTTPNTLMCredentials()
{
}
void HTTPNTLMCredentials::reset()
{
}
void HTTPNTLMCredentials::clear()
{
_username.clear();
_password.clear();
_host.clear();
}
void HTTPNTLMCredentials::setUsername(const std::string& username)
{
_username = username;
}
void HTTPNTLMCredentials::setPassword(const std::string& password)
{
_password = password;
}
void HTTPNTLMCredentials::setHost(const std::string& host)
{
_host = host;
}
void HTTPNTLMCredentials::authenticate(HTTPRequest& request, const HTTPResponse& response)
{
HTTPAuthenticationParams params(response);
authenticate(request, params.get(HTTPAuthenticationParams::NTLM, ""));
}
void HTTPNTLMCredentials::authenticate(HTTPRequest& request, const std::string& ntlmChallengeBase64)
{
std::string ntlmMessage = createNTLMMessage(ntlmChallengeBase64);
request.setCredentials(SCHEME, ntlmMessage);
}
void HTTPNTLMCredentials::updateAuthInfo(HTTPRequest& request)
{
request.removeCredentials();
}
void HTTPNTLMCredentials::proxyAuthenticate(HTTPRequest& request, const HTTPResponse& response)
{
HTTPAuthenticationParams params(response, HTTPAuthenticationParams::PROXY_AUTHENTICATE);
proxyAuthenticate(request, params.get(HTTPAuthenticationParams::NTLM, ""));
}
void HTTPNTLMCredentials::proxyAuthenticate(HTTPRequest& request, const std::string& ntlmChallengeBase64)
{
std::string ntlmMessage = createNTLMMessage(ntlmChallengeBase64);
request.setProxyCredentials(SCHEME, ntlmMessage);
}
void HTTPNTLMCredentials::updateProxyAuthInfo(HTTPRequest& request)
{
request.removeProxyCredentials();
}
std::string HTTPNTLMCredentials::createNTLMMessage(const std::string& responseAuthParams)
{
if (responseAuthParams.empty())
{
std::vector<unsigned char> negotiateBuf;
if (useSSPINTLM())
{
_pNTLMContext = SSPINTLMCredentials::createNTLMContext(_host, SSPINTLMCredentials::SERVICE_HTTP);
negotiateBuf = SSPINTLMCredentials::negotiate(*_pNTLMContext);
}
else
{
NTLMCredentials::NegotiateMessage negotiateMsg;
std::string username;
NTLMCredentials::splitUsername(_username, username, negotiateMsg.domain);
negotiateBuf = NTLMCredentials::formatNegotiateMessage(negotiateMsg);
}
return NTLMCredentials::toBase64(negotiateBuf);
}
else
{
std::vector<unsigned char> buffer = NTLMCredentials::fromBase64(responseAuthParams);
if (buffer.empty()) throw HTTPException("Invalid NTLM challenge");
std::vector<unsigned char> authenticateBuf;
if (useSSPINTLM() && _pNTLMContext)
{
authenticateBuf = SSPINTLMCredentials::authenticate(*_pNTLMContext, buffer);
}
else
{
NTLMCredentials::ChallengeMessage challengeMsg;
if (NTLMCredentials::parseChallengeMessage(&buffer[0], buffer.size(), challengeMsg))
{
if ((challengeMsg.flags & NTLMCredentials::NTLM_FLAG_NEGOTIATE_NTLM2_KEY) == 0)
{
throw HTTPException("Proxy does not support NTLMv2 authentication");
}
std::string username;
std::string domain;
NTLMCredentials::splitUsername(_username, username, domain);
NTLMCredentials::AuthenticateMessage authenticateMsg;
authenticateMsg.flags = challengeMsg.flags;
authenticateMsg.target = challengeMsg.target;
authenticateMsg.username = username;
std::vector<unsigned char> lmNonce = NTLMCredentials::createNonce();
std::vector<unsigned char> ntlmNonce = NTLMCredentials::createNonce();
Poco::UInt64 timestamp = NTLMCredentials::createTimestamp();
std::vector<unsigned char> ntlm2Hash = NTLMCredentials::createNTLMv2Hash(username, challengeMsg.target, _password);
authenticateMsg.lmResponse = NTLMCredentials::createLMv2Response(ntlm2Hash, challengeMsg.challenge, lmNonce);
authenticateMsg.ntlmResponse = NTLMCredentials::createNTLMv2Response(ntlm2Hash, challengeMsg.challenge, ntlmNonce, challengeMsg.targetInfo, timestamp);
authenticateBuf = NTLMCredentials::formatAuthenticateMessage(authenticateMsg);
}
else throw HTTPException("Invalid NTLM challenge");
}
return NTLMCredentials::toBase64(authenticateBuf);
}
}
} } // namespace Poco::Net

View File

@@ -74,11 +74,31 @@ HTTPRequest::HTTPRequest(const std::string& method, const std::string& uri, cons
} }
HTTPRequest::HTTPRequest(const HTTPRequest& other):
HTTPMessage(other),
_method(other._method),
_uri(other._uri)
{
}
HTTPRequest::~HTTPRequest() HTTPRequest::~HTTPRequest()
{ {
} }
HTTPRequest& HTTPRequest::operator = (const HTTPRequest& other)
{
if (this != &other)
{
HTTPMessage::operator = (other);
_method = other._method;
_uri = other._uri;
}
return *this;
}
void HTTPRequest::setMethod(const std::string& method) void HTTPRequest::setMethod(const std::string& method)
{ {
_method = method; _method = method;
@@ -172,6 +192,12 @@ void HTTPRequest::setCredentials(const std::string& scheme, const std::string& a
} }
void HTTPRequest::removeCredentials()
{
erase(AUTHORIZATION);
}
bool HTTPRequest::hasProxyCredentials() const bool HTTPRequest::hasProxyCredentials() const
{ {
return has(PROXY_AUTHORIZATION); return has(PROXY_AUTHORIZATION);
@@ -190,6 +216,12 @@ void HTTPRequest::setProxyCredentials(const std::string& scheme, const std::stri
} }
void HTTPRequest::removeProxyCredentials()
{
erase(PROXY_AUTHORIZATION);
}
void HTTPRequest::write(std::ostream& ostr) const void HTTPRequest::write(std::ostream& ostr) const
{ {
ostr << _method << " " << _uri << " " << getVersion() << "\r\n"; ostr << _method << " " << _uri << " " << getVersion() << "\r\n";

View File

@@ -140,11 +140,31 @@ HTTPResponse::HTTPResponse(const std::string& version, HTTPStatus status):
} }
HTTPResponse::HTTPResponse(const HTTPResponse& other):
HTTPMessage(other),
_status(other._status),
_reason(other._reason)
{
}
HTTPResponse::~HTTPResponse() HTTPResponse::~HTTPResponse()
{ {
} }
HTTPResponse& HTTPResponse::operator = (const HTTPResponse& other)
{
if (this != &other)
{
HTTPMessage::operator = (other);
_status = other._status;
_reason = other._reason;
}
return *this;
}
void HTTPResponse::setStatus(HTTPStatus status) void HTTPResponse::setStatus(HTTPStatus status)
{ {
_status = status; _status = status;

380
Net/src/NTLMCredentials.cpp Normal file
View File

@@ -0,0 +1,380 @@
//
// NTLMCredentials.cpp
//
// Library: Net
// Package: NTLM
// Module: NTLMCredentials
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#include "Poco/Net/NTLMCredentials.h"
#include "Poco/HMACEngine.h"
#include "Poco/MD4Engine.h"
#include "Poco/MD5Engine.h"
#include "Poco/DigestStream.h"
#include "Poco/StreamCopier.h"
#include "Poco/UTF8Encoding.h"
#include "Poco/UTF16Encoding.h"
#include "Poco/TextConverter.h"
#include "Poco/UTF8String.h"
#include "Poco/Random.h"
#include "Poco/Timestamp.h"
#include "Poco/MemoryStream.h"
#include "Poco/Base64Encoder.h"
#include "Poco/Base64Decoder.h"
#include <sstream>
#include <cstring>
namespace Poco {
namespace Net {
const std::string NTLMCredentials::NTLMSSP("NTLMSSP");
std::vector<unsigned char> NTLMCredentials::createNonce()
{
Poco::MD5Engine md5;
Poco::Random rnd;
rnd.seed();
Poco::UInt32 n = rnd.next();
md5.update(&n, sizeof(n));
Poco::Timestamp ts;
md5.update(&ts, sizeof(ts));
Poco::DigestEngine::Digest d = md5.digest();
d.resize(8);
return d;
}
Poco::UInt64 NTLMCredentials::createTimestamp()
{
const Poco::UInt64 EPOCH_DELTA_SECONDS = 11644473600; // seconds between January 1, 1970 and January 1, 1601
Poco::Timestamp now;
Poco::UInt64 ts = now.epochMicroseconds();
ts += EPOCH_DELTA_SECONDS*1000000; // since January 1, 1601
ts *= 10; // tenths of a microsecond
return ts;
}
std::vector<unsigned char> NTLMCredentials::createPasswordHash(const std::string& password)
{
Poco::UTF8Encoding utf8;
Poco::UTF16Encoding utf16(Poco::UTF16Encoding::LITTLE_ENDIAN_BYTE_ORDER);
Poco::TextConverter converter(utf8, utf16);
std::string utf16Password;
converter.convert(password, utf16Password);
Poco::MD4Engine md4;
md4.update(utf16Password);
return md4.digest();
}
std::vector<unsigned char> NTLMCredentials::createNTLMv2Hash(const std::string& username, const std::string& target, const std::string& password)
{
Poco::UTF8Encoding utf8;
Poco::UTF16Encoding utf16(Poco::UTF16Encoding::LITTLE_ENDIAN_BYTE_ORDER);
Poco::TextConverter converter(utf8, utf16);
std::vector<unsigned char> passwordHash = createPasswordHash(password);
std::string userDomain = Poco::UTF8::toUpper(username);
userDomain += target;
std::string utf16UserDomain;
converter.convert(userDomain, utf16UserDomain);
std::string passwordHashString(reinterpret_cast<const char*>(&passwordHash[0]), passwordHash.size());
Poco::HMACEngine<Poco::MD5Engine> hmac(passwordHashString);
hmac.update(utf16UserDomain);
return hmac.digest();
}
std::vector<unsigned char> NTLMCredentials::createLMv2Response(const std::vector<unsigned char>& ntlm2Hash, const std::vector<unsigned char>& challenge, const std::vector<unsigned char>& nonce)
{
poco_assert (challenge.size() == 8);
poco_assert (nonce.size() == 8);
std::vector<unsigned char> lm2Response;
std::string ntlm2HashString(reinterpret_cast<const char*>(&ntlm2Hash[0]), ntlm2Hash.size());
Poco::HMACEngine<Poco::MD5Engine> hmac2(ntlm2HashString);
hmac2.update(&challenge[0], challenge.size());
hmac2.update(&nonce[0], nonce.size());
lm2Response = hmac2.digest();
lm2Response.insert(lm2Response.end(), nonce.begin(), nonce.end());
return lm2Response;
}
std::vector<unsigned char> NTLMCredentials::createNTLMv2Response(const std::vector<unsigned char>& ntlm2Hash, const std::vector<unsigned char>& challenge, const std::vector<unsigned char>& nonce, const std::vector<unsigned char>& targetInfo, Poco::UInt64 timestamp)
{
poco_assert (challenge.size() == 8);
poco_assert (nonce.size() == 8);
std::vector<unsigned char> blob;
blob.resize(28 + targetInfo.size() + 4 + 16);
Poco::MemoryOutputStream blobStream(reinterpret_cast<char*>(&blob[16]), blob.size() - 16);
Poco::BinaryWriter writer(blobStream, Poco::BinaryWriter::LITTLE_ENDIAN_BYTE_ORDER);
writer << Poco::UInt32(0x0101);
writer << Poco::UInt32(0);
writer << timestamp;
writer.writeRaw(reinterpret_cast<const char*>(&nonce[0]), nonce.size());
writer << Poco::UInt32(0);
if (targetInfo.size() > 0)
{
writer.writeRaw(reinterpret_cast<const char*>(&targetInfo[0]), targetInfo.size());
}
writer << Poco::UInt32(0);
poco_assert_dbg (blobStream.charsWritten() == blob.size() - 16);
std::string ntlm2HashString(reinterpret_cast<const char*>(&ntlm2Hash[0]), ntlm2Hash.size());
Poco::HMACEngine<Poco::MD5Engine> hmac2(ntlm2HashString);
hmac2.update(&challenge[0], challenge.size());
hmac2.update(&blob[16], blob.size() - 16);
Poco::DigestEngine::Digest d = hmac2.digest();
poco_assert_dbg (d.size() == 16);
std::memcpy(&blob[0], &d[0], 16);
return blob;
}
std::vector<unsigned char> NTLMCredentials::formatNegotiateMessage(const NegotiateMessage& message)
{
Poco::UTF8Encoding utf8;
Poco::UTF16Encoding utf16(Poco::UTF16Encoding::LITTLE_ENDIAN_BYTE_ORDER);
Poco::TextConverter converter(utf8, utf16);
std::string utf16Domain;
converter.convert(message.domain, utf16Domain);
std::string utf16Workstation;
converter.convert(message.workstation, utf16Workstation);
std::size_t size = 8 // signature
+ 4 // type
+ 4 // flags
+ 8 + utf16Domain.size()
+ 8 + utf16Workstation.size();
Poco::UInt32 flags = message.flags | NTLM_FLAG_NEGOTIATE_UNICODE | NTLM_FLAG_REQUEST_TARGET | NTLM_FLAG_NEGOTIATE_NTLM | NTLM_FLAG_NEGOTIATE_NTLM2_KEY | NTLM_FLAG_NEGOTIATE_ALWAYS_SIGN;
if (!utf16Domain.empty()) flags |= NTLM_FLAG_DOMAIN_SUPPLIED;
if (!utf16Workstation.empty()) flags |= NTLM_FLAG_WORKST_SUPPLIED;
BufferDesc domainDesc(static_cast<Poco::UInt16>(utf16Domain.size()), 8 + 4 + 4 + 8);
BufferDesc workstDesc(static_cast<Poco::UInt16>(utf16Workstation.size()), domainDesc.offset + domainDesc.length);
std::vector<unsigned char> buffer(size);
Poco::MemoryOutputStream bufferStream(reinterpret_cast<char*>(&buffer[0]), buffer.size());
Poco::BinaryWriter writer(bufferStream, Poco::BinaryWriter::LITTLE_ENDIAN_BYTE_ORDER);
writer.writeRaw(NTLMSSP.c_str(), 8);
writer << Poco::UInt32(NTLM_MESSAGE_TYPE_NEGOTIATE);
writer << flags;
writeBufferDesc(writer, domainDesc);
writeBufferDesc(writer, workstDesc);
writer.writeRaw(utf16Domain);
writer.writeRaw(utf16Workstation);
return buffer;
}
bool NTLMCredentials::parseChallengeMessage(const unsigned char* buffer, std::size_t size, ChallengeMessage& message)
{
Poco::MemoryInputStream istr(reinterpret_cast<const char*>(buffer), size);
Poco::BinaryReader reader(istr, Poco::BinaryReader::LITTLE_ENDIAN_BYTE_ORDER);
std::string signature;
reader.readRaw(7, signature);
if (signature != NTLMSSP) return false;
Poco::UInt8 zero;
reader >> zero;
if (zero != 0) return false;
Poco::UInt32 type;
reader >> type;
if (type != NTLM_MESSAGE_TYPE_CHALLENGE) return false;
BufferDesc targetDesc;
readBufferDesc(reader, targetDesc);
if (targetDesc.offset + targetDesc.length > size) return false;
reader >> message.flags;
message.challenge.resize(8);
reader.readRaw(reinterpret_cast<char*>(&message.challenge[0]), 8);
if (message.flags & NTLM_FLAG_NEGOTIATE_TARGET)
{
Poco::UInt64 reserved;
reader >> reserved;
}
BufferDesc targetInfoDesc;
if (message.flags & NTLM_FLAG_NEGOTIATE_TARGET)
{
readBufferDesc(reader, targetInfoDesc);
if (targetInfoDesc.offset + targetInfoDesc.length > size) return false;
}
if (targetDesc.length > 0)
{
if (message.flags & NTLM_FLAG_NEGOTIATE_UNICODE)
{
Poco::UTF16Encoding utf16(Poco::UTF16Encoding::LITTLE_ENDIAN_BYTE_ORDER);
Poco::UTF8Encoding utf8;
Poco::TextConverter converter(utf16, utf8);
converter.convert(buffer + targetDesc.offset, targetDesc.length, message.target);
if (targetDesc.reserved == 0) message.target.resize(std::strlen(message.target.c_str()));
}
else
{
message.target.assign(buffer + targetDesc.offset, buffer + targetDesc.offset + targetDesc.length);
}
}
if (targetInfoDesc.length > 0)
{
message.targetInfo.assign(buffer + targetInfoDesc.offset, buffer + targetInfoDesc.offset + targetInfoDesc.length);
}
return true;
}
std::vector<unsigned char> NTLMCredentials::formatAuthenticateMessage(const AuthenticateMessage& message)
{
Poco::UTF8Encoding utf8;
Poco::UTF16Encoding utf16(Poco::UTF16Encoding::LITTLE_ENDIAN_BYTE_ORDER);
Poco::TextConverter converter(utf8, utf16);
std::string utf16Target;
converter.convert(message.target, utf16Target);
std::string utf16Username;
converter.convert(message.username, utf16Username);
std::string utf16Workstation;
converter.convert(message.workstation, utf16Workstation);
std::size_t size = 8 // signature
+ 4 // type
+ 8 + message.lmResponse.size()
+ 8 + message.ntlmResponse.size()
+ 8 + utf16Target.size()
+ 8 + utf16Username.size()
+ 8 + utf16Workstation.size()
+ 8 // session key
+ 4; // flags
Poco::UInt32 flags = message.flags | NTLM_FLAG_NEGOTIATE_UNICODE;
BufferDesc lmDesc(static_cast<Poco::UInt16>(message.lmResponse.size()), 64);
BufferDesc ntlmDesc(static_cast<Poco::UInt16>(message.ntlmResponse.size()), lmDesc.offset + lmDesc.length);
BufferDesc targetDesc(static_cast<Poco::UInt16>(utf16Target.size()), ntlmDesc.offset + ntlmDesc.length);
BufferDesc usernameDesc(static_cast<Poco::UInt16>(utf16Username.size()), targetDesc.offset + targetDesc.length);
BufferDesc workstDesc(static_cast<Poco::UInt16>(utf16Workstation.size()), usernameDesc.offset + usernameDesc.length);
BufferDesc sessionKeyDesc(0, workstDesc.offset + workstDesc.length);
std::vector<unsigned char> buffer(size);
Poco::MemoryOutputStream bufferStream(reinterpret_cast<char*>(&buffer[0]), buffer.size());
Poco::BinaryWriter writer(bufferStream, Poco::BinaryWriter::LITTLE_ENDIAN_BYTE_ORDER);
writer.writeRaw(NTLMSSP.c_str(), 8);
writer << Poco::UInt32(NTLM_MESSAGE_TYPE_AUTHENTICATE);
writeBufferDesc(writer, lmDesc);
writeBufferDesc(writer, ntlmDesc);
writeBufferDesc(writer, targetDesc);
writeBufferDesc(writer, usernameDesc);
writeBufferDesc(writer, workstDesc);
writeBufferDesc(writer, sessionKeyDesc);
writer << flags;
writer.writeRaw(reinterpret_cast<const char*>(&message.lmResponse[0]), message.lmResponse.size());
writer.writeRaw(reinterpret_cast<const char*>(&message.ntlmResponse[0]), message.ntlmResponse.size());
writer.writeRaw(utf16Target);
writer.writeRaw(utf16Username);
writer.writeRaw(utf16Workstation);
return buffer;
}
void NTLMCredentials::readBufferDesc(Poco::BinaryReader& reader, BufferDesc& desc)
{
reader >> desc.length >> desc.reserved >> desc.offset;
}
void NTLMCredentials::writeBufferDesc(Poco::BinaryWriter& writer, const BufferDesc& desc)
{
writer << desc.length << desc.reserved << desc.offset;
}
void NTLMCredentials::splitUsername(const std::string& usernameAndDomain, std::string& username, std::string& domain)
{
std::string::size_type pos = usernameAndDomain.find('\\');
if (pos != std::string::npos)
{
domain.assign(usernameAndDomain, 0, pos);
username.assign(usernameAndDomain, pos + 1, std::string::npos);
return;
}
else
{
pos = usernameAndDomain.find('@');
if (pos != std::string::npos)
{
username.assign(usernameAndDomain, 0, pos);
domain.assign(usernameAndDomain, pos + 1, std::string::npos);
return;
}
}
username = usernameAndDomain;
}
std::string NTLMCredentials::toBase64(const std::vector<unsigned char>& buffer)
{
std::ostringstream ostr;
Poco::Base64Encoder base64(ostr);
base64.rdbuf()->setLineLength(0);
base64.write(reinterpret_cast<const char*>(&buffer[0]), buffer.size());
base64.close();
return ostr.str();
}
std::vector<unsigned char> NTLMCredentials::fromBase64(const std::string& base64)
{
Poco::MemoryInputStream istr(base64.data(), base64.size());
Poco::Base64Decoder debase64(istr);
std::vector<unsigned char> buffer(base64.size());
debase64.read(reinterpret_cast<char*>(&buffer[0]), buffer.size());
buffer.resize(static_cast<std::size_t>(debase64.gcount()));
return buffer;
}
} } // namespace Poco::Net

View File

@@ -21,6 +21,8 @@
#include "Poco/Net/NetException.h" #include "Poco/Net/NetException.h"
#include "Poco/Environment.h" #include "Poco/Environment.h"
#include "Poco/Net/NetworkInterface.h" #include "Poco/Net/NetworkInterface.h"
#include "Poco/Net/NTLMCredentials.h"
#include "Poco/Environment.h"
#include "Poco/HMACEngine.h" #include "Poco/HMACEngine.h"
#include "Poco/MD5Engine.h" #include "Poco/MD5Engine.h"
#include "Poco/SHA1Engine.h" #include "Poco/SHA1Engine.h"
@@ -236,6 +238,57 @@ void SMTPClientSession::loginUsingXOAUTH2(const std::string& username, const std
} }
void SMTPClientSession::loginUsingNTLM(const std::string& username, const std::string& password)
{
// Implementation is based on:
// [MS-SMTPNTLM]: NT LAN Manager (NTLM) Authentication: Simple Mail Transfer Protocol (SMTP) Extension
// https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-smtpntlm/50c668f6-5ffc-4616-96df-b5a3f4b3311d
NTLMCredentials::NegotiateMessage negotiateMsg;
std::string user;
std::string domain;
NTLMCredentials::splitUsername(username, user, domain);
negotiateMsg.domain = domain;
std::vector<unsigned char> negotiateBuf = NTLMCredentials::formatNegotiateMessage(negotiateMsg);
std::string response;
int status = sendCommand("AUTH NTLM", NTLMCredentials::toBase64(negotiateBuf), response);
if (status == 334)
{
std::vector<unsigned char> buffer = NTLMCredentials::fromBase64(response.substr(4));
if (buffer.empty()) throw SMTPException("Invalid NTLM challenge");
NTLMCredentials::ChallengeMessage challengeMsg;
if (NTLMCredentials::parseChallengeMessage(&buffer[0], buffer.size(), challengeMsg))
{
if ((challengeMsg.flags & NTLMCredentials::NTLM_FLAG_NEGOTIATE_NTLM2_KEY) == 0)
{
throw SMTPException("Server does not support NTLMv2 authentication");
}
NTLMCredentials::AuthenticateMessage authenticateMsg;
authenticateMsg.flags = challengeMsg.flags;
authenticateMsg.target = challengeMsg.target;
authenticateMsg.username = user;
std::vector<unsigned char> lmNonce = NTLMCredentials::createNonce();
std::vector<unsigned char> ntlmNonce = NTLMCredentials::createNonce();
Poco::UInt64 timestamp = NTLMCredentials::createTimestamp();
std::vector<unsigned char> ntlm2Hash = NTLMCredentials::createNTLMv2Hash(user, challengeMsg.target, password);
authenticateMsg.lmResponse = NTLMCredentials::createLMv2Response(ntlm2Hash, challengeMsg.challenge, lmNonce);
authenticateMsg.ntlmResponse = NTLMCredentials::createNTLMv2Response(ntlm2Hash, challengeMsg.challenge, ntlmNonce, challengeMsg.targetInfo, timestamp);
std::vector<unsigned char> authenticateBuf = NTLMCredentials::formatAuthenticateMessage(authenticateMsg);
status = sendCommand(NTLMCredentials::toBase64(authenticateBuf), response);
if (status != 235) throw SMTPException("NTLM authentication failed", response, status);
}
else throw SMTPException("Invalid NTLM challenge");
}
else throw SMTPException("Server does not support NTLM authentication");
}
void SMTPClientSession::login(LoginMethod loginMethod, const std::string& username, const std::string& password) void SMTPClientSession::login(LoginMethod loginMethod, const std::string& username, const std::string& password)
{ {
login(Environment::nodeName(), loginMethod, username, password); login(Environment::nodeName(), loginMethod, username, password);
@@ -287,6 +340,14 @@ void SMTPClientSession::login(const std::string& hostname, LoginMethod loginMeth
} }
else throw SMTPException("The mail service does not support XOAUTH2 authentication", response); else throw SMTPException("The mail service does not support XOAUTH2 authentication", response);
} }
else if (loginMethod == AUTH_NTLM)
{
if (response.find("NTLM", 0) != std::string::npos)
{
loginUsingNTLM(username, password);
}
else throw SMTPException("The mail service does not support NTLM authentication", response);
}
else if (loginMethod != AUTH_NONE) else if (loginMethod != AUTH_NONE)
{ {
throw SMTPException("The autentication method is not supported"); throw SMTPException("The autentication method is not supported");

View File

@@ -0,0 +1,318 @@
//
// SSPINTLMCredentials.cpp
//
// Library: Net
// Package: NTLM
// Module: SSPINTLMCredentials
//
// Copyright (c) 2019, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
//
#include "Poco/Net/SSPINTLMCredentials.h"
#if POCO_OS == POCO_OS_WINDOWS_NT
#include "Poco/SharedLibrary.h"
#include "Poco/SingletonHolder.h"
#include "Poco/UnicodeConverter.h"
#include <vector>
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#define SECURITY_WIN32
#include <security.h>
namespace Poco {
namespace Net {
struct NTLMContextImpl
{
NTLMContextImpl():
maxTokenSize(0)
{
SecInvalidateHandle(&credentials);
SecInvalidateHandle(&context);
}
std::size_t maxTokenSize;
CredHandle credentials;
CtxtHandle context;
std::wstring spn;
};
class SSPINTLMProvider
{
public:
SSPINTLMProvider():
_securityLib("security.dll"),
_pSecFunTable(0)
{
InitSecurityInterfaceW pInitSecurityInterface = reinterpret_cast<InitSecurityInterfaceW>(_securityLib.getSymbol("InitSecurityInterfaceW"));
if (pInitSecurityInterface)
{
_pSecFunTable = pInitSecurityInterface();
}
if (!_pSecFunTable) throw Poco::SystemException("Failed to initialize SSPI");
}
~SSPINTLMProvider()
{
}
bool available()
{
PSecPkgInfoW pSecPkgInfo;
SECURITY_STATUS status = _pSecFunTable->QuerySecurityPackageInfoW(L"NTLM", &pSecPkgInfo);
if (status == SEC_E_OK)
{
_pSecFunTable->FreeContextBuffer(pSecPkgInfo);
return true;
}
else return false;
}
Poco::SharedPtr<NTLMContext> createNTLMContext(const std::string& host, const std::string& service)
{
PSecPkgInfoW pSecPkgInfo;
SECURITY_STATUS status = _pSecFunTable->QuerySecurityPackageInfoW(L"NTLM", &pSecPkgInfo);
if (status != SEC_E_OK) throw Poco::SystemException("NTLM SSPI not available", status);
std::size_t maxTokenSize = pSecPkgInfo->cbMaxToken;
_pSecFunTable->FreeContextBuffer(pSecPkgInfo);
Poco::SharedPtr<NTLMContext> pContext = new NTLMContext(new NTLMContextImpl);
pContext->_pImpl->maxTokenSize = maxTokenSize;
TimeStamp expiry;
status = _pSecFunTable->AcquireCredentialsHandleW(
NULL,
L"NTLM",
SECPKG_CRED_OUTBOUND,
NULL,
NULL,
NULL,
NULL,
&pContext->_pImpl->credentials,
&expiry);
if (status != SEC_E_OK) throw Poco::SystemException("Failed to acquire NTLM credentials", status);
std::string spn = service;
spn += '/';
spn += host;
Poco::UnicodeConverter::convert(spn, pContext->_pImpl->spn);
return pContext;
}
std::vector<unsigned char> negotiate(NTLMContext& context)
{
std::vector<unsigned char> buffer(context._pImpl->maxTokenSize);
SecBuffer msgBuffer;
msgBuffer.BufferType = SECBUFFER_TOKEN;
msgBuffer.pvBuffer = &buffer[0];
msgBuffer.cbBuffer = static_cast<unsigned long>(buffer.size());
SecBufferDesc msgBufferDesc;
msgBufferDesc.ulVersion = SECBUFFER_VERSION;
msgBufferDesc.cBuffers = 1;
msgBufferDesc.pBuffers = &msgBuffer;
unsigned long attrs;
TimeStamp expiry;
SECURITY_STATUS status = _pSecFunTable->InitializeSecurityContextW(
&context._pImpl->credentials,
NULL,
const_cast<SEC_WCHAR*>(context._pImpl->spn.c_str()),
0,
0,
SECURITY_NETWORK_DREP,
NULL,
0,
&context._pImpl->context,
&msgBufferDesc,
&attrs,
&expiry);
if (status == SEC_I_COMPLETE_NEEDED || status == SEC_I_COMPLETE_AND_CONTINUE)
{
_pSecFunTable->CompleteAuthToken(&context._pImpl->context, &msgBufferDesc);
}
else if (status != SEC_E_OK && status != SEC_I_CONTINUE_NEEDED)
{
throw Poco::SystemException("Failed to initialize NTLM security context", status);
}
buffer.resize(msgBuffer.cbBuffer);
return buffer;
}
std::vector<unsigned char> authenticate(NTLMContext& context, const std::vector<unsigned char>& challenge)
{
std::vector<unsigned char> response(context._pImpl->maxTokenSize);
SecBuffer responseBuffer;
responseBuffer.BufferType = SECBUFFER_TOKEN;
responseBuffer.pvBuffer = &response[0];
responseBuffer.cbBuffer = static_cast<unsigned long>(response.size());
SecBufferDesc responseBufferDesc;
responseBufferDesc.ulVersion = SECBUFFER_VERSION;
responseBufferDesc.cBuffers = 1;
responseBufferDesc.pBuffers = &responseBuffer;
SecBuffer challengeBuffer;
challengeBuffer.BufferType = SECBUFFER_TOKEN;
challengeBuffer.pvBuffer = const_cast<unsigned char*>(&challenge[0]);
challengeBuffer.cbBuffer = static_cast<unsigned long>(challenge.size());
SecBufferDesc challengeBufferDesc;
challengeBufferDesc.ulVersion = SECBUFFER_VERSION;
challengeBufferDesc.cBuffers = 1;
challengeBufferDesc.pBuffers = &challengeBuffer;
unsigned long attrs;
TimeStamp expiry;
SECURITY_STATUS status = _pSecFunTable->InitializeSecurityContextW(
&context._pImpl->credentials,
&context._pImpl->context,
const_cast<SEC_WCHAR*>(context._pImpl->spn.c_str()),
0,
0,
SECURITY_NETWORK_DREP,
&challengeBufferDesc,
0,
&context._pImpl->context,
&responseBufferDesc,
&attrs,
&expiry);
if (status != SEC_E_OK)
{
throw Poco::SystemException("Failed to create NTLM authenticate message", status);
}
response.resize(responseBuffer.cbBuffer);
return response;
}
void clearNTLMContext(NTLMContext& ctx)
{
if (SecIsValidHandle(&ctx._pImpl->context))
{
_pSecFunTable->DeleteSecurityContext(&ctx._pImpl->context);
}
if (SecIsValidHandle(&ctx._pImpl->credentials))
{
_pSecFunTable->FreeCredentialsHandle(&ctx._pImpl->credentials);
}
}
static SSPINTLMProvider& instance();
private:
typedef PSecurityFunctionTableW(APIENTRY *InitSecurityInterfaceW)(VOID);
Poco::SharedLibrary _securityLib;
PSecurityFunctionTableW _pSecFunTable;
};
namespace
{
static Poco::SingletonHolder<SSPINTLMProvider> sspintlmProviderHolder;
}
SSPINTLMProvider& SSPINTLMProvider::instance()
{
return *sspintlmProviderHolder.get();
}
} } // namespace Poco::Net
#endif // POCO_OS == POCO_OS_WINDOWS_NT
namespace Poco {
namespace Net {
const std::string SSPINTLMCredentials::SERVICE_HTTP("HTTP");
const std::string SSPINTLMCredentials::SERVICE_SMTP("SMTP");
NTLMContext::NTLMContext(NTLMContextImpl* pImpl):
_pImpl(pImpl)
{
}
NTLMContext::~NTLMContext()
{
#if POCO_OS == POCO_OS_WINDOWS_NT
SSPINTLMProvider::instance().clearNTLMContext(*this);
delete _pImpl;
#endif
}
bool SSPINTLMCredentials::available()
{
#if POCO_OS == POCO_OS_WINDOWS_NT
try
{
return SSPINTLMProvider::instance().available();
}
catch (...)
{
return false;
}
#else
return false;
#endif
}
Poco::SharedPtr<NTLMContext> SSPINTLMCredentials::createNTLMContext(const std::string& workstation, const std::string& service)
{
#if POCO_OS == POCO_OS_WINDOWS_NT
return SSPINTLMProvider::instance().createNTLMContext(workstation, service);
#else
throw Poco::NotImplementedException("SSPINTLMCredentials::createNTLMContext() is only available on Windows");
#endif
}
std::vector<unsigned char> SSPINTLMCredentials::negotiate(NTLMContext& context)
{
#if POCO_OS == POCO_OS_WINDOWS_NT
return SSPINTLMProvider::instance().negotiate(context);
#else
throw Poco::NotImplementedException("SSPINTLMCredentials::negotiate() is only available on Windows");
#endif
}
std::vector<unsigned char> SSPINTLMCredentials::authenticate(NTLMContext& context, const std::vector<unsigned char>& challenge)
{
#if POCO_OS == POCO_OS_WINDOWS_NT
return SSPINTLMProvider::instance().authenticate(context, challenge);
#else
throw Poco::NotImplementedException("SSPINTLMCredentials::authenticate() is only available on Windows");
#endif
}
} } // namespace Poco::Net

View File

@@ -689,7 +689,7 @@ bool SocketImpl::poll(const Poco::Timespan& timeout, int mode)
{ {
Poco::Timestamp start; Poco::Timestamp start;
#ifdef _WIN32 #ifdef _WIN32
rc = WSAPoll(&pollBuf, 1, static_cast<INT>(timeout.totalMilliseconds())); rc = WSAPoll(&pollBuf, 1, static_cast<INT>(remainingTime.totalMilliseconds()));
#else #else
rc = ::poll(&pollBuf, 1, remainingTime.totalMilliseconds()); rc = ::poll(&pollBuf, 1, remainingTime.totalMilliseconds());
#endif #endif

View File

@@ -126,6 +126,18 @@ WebSocket::Mode WebSocket::mode() const
} }
void WebSocket::setMaxPayloadSize(int maxPayloadSize)
{
static_cast<WebSocketImpl*>(impl())->setMaxPayloadSize(maxPayloadSize);
}
int WebSocket::getMaxPayloadSize() const
{
return static_cast<WebSocketImpl*>(impl())->getMaxPayloadSize();
}
WebSocketImpl* WebSocket::accept(HTTPServerRequest& request, HTTPServerResponse& response) WebSocketImpl* WebSocket::accept(HTTPServerRequest& request, HTTPServerResponse& response)
{ {
if (request.hasToken("Connection", "upgrade") && icompare(request.get("Upgrade", ""), "websocket") == 0) if (request.hasToken("Connection", "upgrade") && icompare(request.get("Upgrade", ""), "websocket") == 0)
@@ -141,7 +153,7 @@ WebSocketImpl* WebSocket::accept(HTTPServerRequest& request, HTTPServerResponse&
response.set("Upgrade", "websocket"); response.set("Upgrade", "websocket");
response.set("Connection", "Upgrade"); response.set("Connection", "Upgrade");
response.set("Sec-WebSocket-Accept", computeAccept(key)); response.set("Sec-WebSocket-Accept", computeAccept(key));
response.setContentLength(0); response.setContentLength(HTTPResponse::UNKNOWN_CONTENT_LENGTH);
response.send().flush(); response.send().flush();
HTTPServerRequestImpl& requestImpl = static_cast<HTTPServerRequestImpl&>(request); HTTPServerRequestImpl& requestImpl = static_cast<HTTPServerRequestImpl&>(request);
@@ -171,6 +183,8 @@ WebSocketImpl* WebSocket::connect(HTTPClientSession& cs, HTTPRequest& request, H
return completeHandshake(cs, response, key); return completeHandshake(cs, response, key);
} }
else if (response.getStatus() == HTTPResponse::HTTP_UNAUTHORIZED) else if (response.getStatus() == HTTPResponse::HTTP_UNAUTHORIZED)
{
if (!credentials.empty())
{ {
Poco::NullOutputStream null; Poco::NullOutputStream null;
Poco::StreamCopier::copyStream(istr, null); Poco::StreamCopier::copyStream(istr, null);
@@ -191,6 +205,8 @@ WebSocketImpl* WebSocket::connect(HTTPClientSession& cs, HTTPRequest& request, H
throw WebSocketException("Not authorized", WS_ERR_UNAUTHORIZED); throw WebSocketException("Not authorized", WS_ERR_UNAUTHORIZED);
} }
} }
else throw WebSocketException("Not authorized", WS_ERR_UNAUTHORIZED);
}
if (response.getStatus() == HTTPResponse::HTTP_OK) if (response.getStatus() == HTTPResponse::HTTP_OK)
{ {
throw WebSocketException("The server does not understand the WebSocket protocol", WS_ERR_NO_HANDSHAKE); throw WebSocketException("The server does not understand the WebSocket protocol", WS_ERR_NO_HANDSHAKE);

View File

@@ -12,6 +12,7 @@
// //
#define NOMINMAX
#include "Poco/Net/WebSocketImpl.h" #include "Poco/Net/WebSocketImpl.h"
#include "Poco/Net/NetException.h" #include "Poco/Net/NetException.h"
#include "Poco/Net/WebSocket.h" #include "Poco/Net/WebSocket.h"
@@ -21,6 +22,7 @@
#include "Poco/BinaryReader.h" #include "Poco/BinaryReader.h"
#include "Poco/MemoryStream.h" #include "Poco/MemoryStream.h"
#include "Poco/Format.h" #include "Poco/Format.h"
#include <limits>
#include <cstring> #include <cstring>
@@ -31,6 +33,7 @@ namespace Net {
WebSocketImpl::WebSocketImpl(StreamSocketImpl* pStreamSocketImpl, HTTPSession& session, bool mustMaskPayload): WebSocketImpl::WebSocketImpl(StreamSocketImpl* pStreamSocketImpl, HTTPSession& session, bool mustMaskPayload):
StreamSocketImpl(pStreamSocketImpl->sockfd()), StreamSocketImpl(pStreamSocketImpl->sockfd()),
_pStreamSocketImpl(pStreamSocketImpl), _pStreamSocketImpl(pStreamSocketImpl),
_maxPayloadSize(std::numeric_limits<int>::max()),
_buffer(0), _buffer(0),
_bufferOffset(0), _bufferOffset(0),
_frameFlags(0), _frameFlags(0),
@@ -134,6 +137,7 @@ int WebSocketImpl::receiveHeader(char mask[4], bool& useMask)
Poco::BinaryReader reader(istr, Poco::BinaryReader::NETWORK_BYTE_ORDER); Poco::BinaryReader reader(istr, Poco::BinaryReader::NETWORK_BYTE_ORDER);
Poco::UInt64 l; Poco::UInt64 l;
reader >> l; reader >> l;
if (l > _maxPayloadSize) throw WebSocketException("Payload too big", WebSocket::WS_ERR_PAYLOAD_TOO_BIG);
payloadLength = static_cast<int>(l); payloadLength = static_cast<int>(l);
} }
else if (lengthByte == 126) else if (lengthByte == 126)
@@ -148,10 +152,12 @@ int WebSocketImpl::receiveHeader(char mask[4], bool& useMask)
Poco::BinaryReader reader(istr, Poco::BinaryReader::NETWORK_BYTE_ORDER); Poco::BinaryReader reader(istr, Poco::BinaryReader::NETWORK_BYTE_ORDER);
Poco::UInt16 l; Poco::UInt16 l;
reader >> l; reader >> l;
if (l > _maxPayloadSize) throw WebSocketException("Payload too big", WebSocket::WS_ERR_PAYLOAD_TOO_BIG);
payloadLength = static_cast<int>(l); payloadLength = static_cast<int>(l);
} }
else else
{ {
if (lengthByte > _maxPayloadSize) throw WebSocketException("Payload too big", WebSocket::WS_ERR_PAYLOAD_TOO_BIG);
payloadLength = lengthByte; payloadLength = lengthByte;
} }
@@ -169,6 +175,14 @@ int WebSocketImpl::receiveHeader(char mask[4], bool& useMask)
} }
void WebSocketImpl::setMaxPayloadSize(int maxPayloadSize)
{
poco_assert (maxPayloadSize > 0);
_maxPayloadSize = maxPayloadSize;
}
int WebSocketImpl::receivePayload(char *buffer, int payloadLength, char mask[4], bool useMask) int WebSocketImpl::receivePayload(char *buffer, int payloadLength, char mask[4], bool useMask)
{ {
int received = receiveNBytes(reinterpret_cast<char*>(buffer), payloadLength); int received = receiveNBytes(reinterpret_cast<char*>(buffer), payloadLength);
@@ -205,7 +219,7 @@ int WebSocketImpl::receiveBytes(Poco::Buffer<char>& buffer, int, const Poco::Tim
int payloadLength = receiveHeader(mask, useMask); int payloadLength = receiveHeader(mask, useMask);
if (payloadLength <= 0) if (payloadLength <= 0)
return payloadLength; return payloadLength;
int oldSize = static_cast<int>(buffer.size()); std::size_t oldSize = buffer.size();
buffer.resize(oldSize + payloadLength); buffer.resize(oldSize + payloadLength);
return receivePayload(buffer.begin() + oldSize, payloadLength, mask, useMask); return receivePayload(buffer.begin() + oldSize, payloadLength, mask, useMask);
} }

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(NetSSL ${SRCS} ) add_library(NetSSL ${SRCS} )
add_library(Poco::NetSSL ALIAS NetSSL) add_library(Poco::NetSSL ALIAS NetSSL)
set_target_properties( NetSSL set_target_properties( NetSSL
@@ -23,6 +29,10 @@ target_include_directories(NetSSL
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src
) )
if(MSVC AND POCO_DISABLE_INTERNAL_OPENSSL AND OPENSSL_USE_STATIC_LIBS)
target_link_libraries(NetSSL PUBLIC ws2_32.lib Crypt32.lib)
endif()
POCO_INSTALL(NetSSL) POCO_INSTALL(NetSSL)
POCO_GENERATE_PACKAGE(NetSSL) POCO_GENERATE_PACKAGE(NetSSL)

View File

@@ -84,9 +84,6 @@ public:
/// ///
/// Returns true if the STARTTLS command was successful, /// Returns true if the STARTTLS command was successful,
/// false otherwise. /// false otherwise.
private:
std::string _host;
}; };

View File

@@ -31,7 +31,7 @@
<ProjectGuid>{F8DE5054-3EC1-3FB4-9FE6-38EE974745A9}</ProjectGuid> <ProjectGuid>{F8DE5054-3EC1-3FB4-9FE6-38EE974745A9}</ProjectGuid>
<RootNamespace>HTTPSTimeServer</RootNamespace> <RootNamespace>HTTPSTimeServer</RootNamespace>
<Keyword>Win32Proj</Keyword> <Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">

View File

@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations"> <ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="debug_shared|x64"> <ProjectConfiguration Include="debug_shared|x64">
@@ -31,7 +31,7 @@
<ProjectGuid>{BF75C029-EFC9-3A0F-A8F2-8001C11D1FBA}</ProjectGuid> <ProjectGuid>{BF75C029-EFC9-3A0F-A8F2-8001C11D1FBA}</ProjectGuid>
<RootNamespace>Mail</RootNamespace> <RootNamespace>Mail</RootNamespace>
<Keyword>Win32Proj</Keyword> <Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">

View File

@@ -1,4 +1,3 @@
// //
// SetSourceIP.cpp // SetSourceIP.cpp
// //
@@ -11,29 +10,29 @@
// //
#include <Poco/Net/SSLManager.h> #include "Poco/Net/SSLManager.h"
#include <Poco/Net/RejectCertificateHandler.h> #include "Poco/Net/RejectCertificateHandler.h"
#include <Poco/Net/KeyConsoleHandler.h> #include "Poco/Net/KeyConsoleHandler.h"
#include <Poco/Net/ConsoleCertificateHandler.h> #include "Poco/Net/ConsoleCertificateHandler.h"
#include <Poco/Net/Context.h> #include "Poco/Net/Context.h"
#include <Poco/Net/HTTPSClientSession.h> #include "Poco/Net/HTTPSClientSession.h"
#include <Poco/Net/HTTPRequest.h> #include "Poco/Net/HTTPRequest.h"
#include <Poco/Net/HTTPResponse.h> #include "Poco/Net/HTTPResponse.h"
#include <Poco/Net/SecureStreamSocket.h> #include "Poco/Net/SecureStreamSocket.h"
#include <Poco/Net/SocketImpl.h> #include "Poco/Net/SocketImpl.h"
#include <Poco/Path.h> #include "Poco/Path.h"
#include <Poco/URI.h> #include "Poco/URI.h"
#include <Poco/Exception.h> #include "Poco/Exception.h"
#include <Poco/SharedPtr.h> #include "Poco/SharedPtr.h"
#include <iostream> #include <iostream>
#include <sstream> #include <sstream>
#include <string> #include <string>
#include <map> #include <map>
Poco::Path programName; Poco::Path programName;
void usage(std::string errorMessage) void usage(std::string errorMessage)
{ {
std::cerr << "ERROR: " << errorMessage << std::endl; std::cerr << "ERROR: " << errorMessage << std::endl;

View File

@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations"> <ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="debug_shared|x64"> <ProjectConfiguration Include="debug_shared|x64">
@@ -31,7 +31,7 @@
<ProjectGuid>{CCDD82BC-680D-39C0-AE25-1FBC5B615F7E}</ProjectGuid> <ProjectGuid>{CCDD82BC-680D-39C0-AE25-1FBC5B615F7E}</ProjectGuid>
<RootNamespace>TwitterClient</RootNamespace> <RootNamespace>TwitterClient</RootNamespace>
<Keyword>Win32Proj</Keyword> <Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">

View File

@@ -31,7 +31,7 @@
<ProjectGuid>{D853F3D6-0D6F-3E8E-82C7-4216D7A21C4D}</ProjectGuid> <ProjectGuid>{D853F3D6-0D6F-3E8E-82C7-4216D7A21C4D}</ProjectGuid>
<RootNamespace>download</RootNamespace> <RootNamespace>download</RootNamespace>
<Keyword>Win32Proj</Keyword> <Keyword>Win32Proj</Keyword>
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion> <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">

View File

@@ -198,9 +198,11 @@ void Context::useCertificate(const Poco::Crypto::X509Certificate& certificate)
void Context::addChainCertificate(const Poco::Crypto::X509Certificate& certificate) void Context::addChainCertificate(const Poco::Crypto::X509Certificate& certificate)
{ {
int errCode = SSL_CTX_add_extra_chain_cert(_pSSLContext, certificate.certificate()); X509* pCert = certificate.dup();
int errCode = SSL_CTX_add_extra_chain_cert(_pSSLContext, pCert);
if (errCode != 1) if (errCode != 1)
{ {
X509_free(pCert);
std::string msg = Utility::getLastError(); std::string msg = Utility::getLastError();
throw SSLContextException("Cannot add chain certificate to Context", msg); throw SSLContextException("Cannot add chain certificate to Context", msg);
} }

View File

@@ -29,8 +29,7 @@ SecureSMTPClientSession::SecureSMTPClientSession(const StreamSocket& socket):
SecureSMTPClientSession::SecureSMTPClientSession(const std::string& host, Poco::UInt16 port): SecureSMTPClientSession::SecureSMTPClientSession(const std::string& host, Poco::UInt16 port):
SMTPClientSession(host, port), SMTPClientSession(host, port)
_host(host)
{ {
} }
@@ -54,7 +53,7 @@ bool SecureSMTPClientSession::startTLS(Context::Ptr pContext)
status = sendCommand("STARTTLS", response); status = sendCommand("STARTTLS", response);
if (!isPositiveCompletion(status)) return false; if (!isPositiveCompletion(status)) return false;
SecureStreamSocket sss(SecureStreamSocket::attach(socket(), _host, pContext)); SecureStreamSocket sss(SecureStreamSocket::attach(socket(), host(), pContext));
socket() = sss; socket() = sss;
return true; return true;

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(NetSSLWin ${SRCS}) add_library(NetSSLWin ${SRCS})
add_library(Poco::NetSSLWin ALIAS NetSSLWin) add_library(Poco::NetSSLWin ALIAS NetSSLWin)
set_target_properties(NetSSLWin set_target_properties(NetSSLWin

View File

@@ -84,9 +84,6 @@ public:
/// ///
/// Returns true if the STARTTLS command was successful, /// Returns true if the STARTTLS command was successful,
/// false otherwise. /// false otherwise.
private:
std::string _host;
}; };

View File

@@ -22,7 +22,7 @@
#include "Poco/DateTime.h" #include "Poco/DateTime.h"
#include <set> #include <set>
#include <istream> #include <istream>
#include <Poco/UnWindows.h> #include "Poco/UnWindows.h"
#include <wincrypt.h> #include <wincrypt.h>

View File

@@ -167,7 +167,7 @@ void Context::loadCertificate()
if (!_hCertStore) if (!_hCertStore)
{ {
if (_options & OPT_USE_MACHINE_STORE) if (_options & OPT_USE_MACHINE_STORE)
_hCertStore = CertOpenStore(CERT_STORE_PROV_SYSTEM, 0, 0, CERT_SYSTEM_STORE_LOCAL_MACHINE, _certStoreName.c_str()); _hCertStore = CertOpenStore(CERT_STORE_PROV_SYSTEM, 0, 0, CERT_SYSTEM_STORE_LOCAL_MACHINE, wcertStore.c_str());
else else
_hCertStore = CertOpenSystemStoreW(0, wcertStore.c_str()); _hCertStore = CertOpenSystemStoreW(0, wcertStore.c_str());
} }
@@ -193,7 +193,6 @@ void Context::importCertificate()
Poco::File certFile(_certNameOrPath); Poco::File certFile(_certNameOrPath);
if (!certFile.exists()) throw Poco::FileNotFoundException(_certNameOrPath); if (!certFile.exists()) throw Poco::FileNotFoundException(_certNameOrPath);
Poco::File::FileSize size = certFile.getSize(); Poco::File::FileSize size = certFile.getSize();
if (size > 4096) throw Poco::DataFormatException("PKCS #12 certificate file too large", _certNameOrPath);
Poco::Buffer<char> buffer(static_cast<std::size_t>(size)); Poco::Buffer<char> buffer(static_cast<std::size_t>(size));
Poco::FileInputStream istr(_certNameOrPath); Poco::FileInputStream istr(_certNameOrPath);
istr.read(buffer.begin(), buffer.size()); istr.read(buffer.begin(), buffer.size());
@@ -309,7 +308,7 @@ void Context::acquireSchannelCredentials(CredHandle& credHandle) const
schannelCred.dwFlags |= SCH_USE_STRONG_CRYPTO; schannelCred.dwFlags |= SCH_USE_STRONG_CRYPTO;
#endif #endif
schannelCred.hRootStore = _hCollectionCertStore; schannelCred.hRootStore = isForServerUse() ? _hCollectionCertStore : NULL;
TimeStamp tsExpiry; TimeStamp tsExpiry;
tsExpiry.LowPart = tsExpiry.HighPart = 0; tsExpiry.LowPart = tsExpiry.HighPart = 0;
@@ -336,18 +335,56 @@ DWORD Context::proto() const
switch (_usage) switch (_usage)
{ {
case Context::CLIENT_USE: case Context::CLIENT_USE:
return SP_PROT_SSL3_CLIENT | SP_PROT_TLS1_CLIENT; return SP_PROT_SSL3_CLIENT
| SP_PROT_TLS1_CLIENT
#if defined(SP_PROT_TLS1_1)
| SP_PROT_TLS1_1_CLIENT
#endif
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_CLIENT
#endif
;
case Context::SERVER_USE: case Context::SERVER_USE:
return SP_PROT_SSL3_SERVER | SP_PROT_TLS1_SERVER; return SP_PROT_SSL3_SERVER
| SP_PROT_TLS1_SERVER
#if defined(SP_PROT_TLS1_1)
| SP_PROT_TLS1_1_SERVER
#endif
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_SERVER
#endif
;
case Context::TLSV1_CLIENT_USE: case Context::TLSV1_CLIENT_USE:
return SP_PROT_TLS1_CLIENT; return SP_PROT_TLS1_CLIENT
#if defined(SP_PROT_TLS1_1)
| SP_PROT_TLS1_1_CLIENT
#endif
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_CLIENT
#endif
;
case Context::TLSV1_SERVER_USE: case Context::TLSV1_SERVER_USE:
return SP_PROT_TLS1_SERVER; return SP_PROT_TLS1_SERVER
#if defined(SP_PROT_TLS1_1)
| SP_PROT_TLS1_1_SERVER
#endif
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_SERVER
#endif
;
#if defined(SP_PROT_TLS1_1) #if defined(SP_PROT_TLS1_1)
case Context::TLSV1_1_CLIENT_USE: case Context::TLSV1_1_CLIENT_USE:
return SP_PROT_TLS1_1_CLIENT; return SP_PROT_TLS1_1_CLIENT
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_CLIENT
#endif
;
case Context::TLSV1_1_SERVER_USE: case Context::TLSV1_1_SERVER_USE:
return SP_PROT_TLS1_1_SERVER; return SP_PROT_TLS1_1_SERVER
#if defined(SP_PROT_TLS1_2)
| SP_PROT_TLS1_2_SERVER
#endif
;
#endif #endif
#if defined(SP_PROT_TLS1_2) #if defined(SP_PROT_TLS1_2)
case Context::TLSV1_2_CLIENT_USE: case Context::TLSV1_2_CLIENT_USE:

View File

@@ -29,8 +29,7 @@ SecureSMTPClientSession::SecureSMTPClientSession(const StreamSocket& socket):
SecureSMTPClientSession::SecureSMTPClientSession(const std::string& host, Poco::UInt16 port): SecureSMTPClientSession::SecureSMTPClientSession(const std::string& host, Poco::UInt16 port):
SMTPClientSession(host, port), SMTPClientSession(host, port)
_host(host)
{ {
} }
@@ -54,7 +53,7 @@ bool SecureSMTPClientSession::startTLS(Context::Ptr pContext)
status = sendCommand("STARTTLS", response); status = sendCommand("STARTTLS", response);
if (!isPositiveCompletion(status)) return false; if (!isPositiveCompletion(status)) return false;
SecureStreamSocket sss(SecureStreamSocket::attach(socket(), _host, pContext)); SecureStreamSocket sss(SecureStreamSocket::attach(socket(), host(), pContext));
socket() = sss; socket() = sss;
return true; return true;

View File

@@ -366,7 +366,7 @@ void X509Certificate::loadCertificate(const std::string& certName, const std::st
Poco::UnicodeConverter::convert(certStoreName, wcertStore); Poco::UnicodeConverter::convert(certStoreName, wcertStore);
HCERTSTORE hCertStore; HCERTSTORE hCertStore;
if (useMachineStore) if (useMachineStore)
hCertStore = CertOpenStore(CERT_STORE_PROV_SYSTEM, 0, 0, CERT_SYSTEM_STORE_LOCAL_MACHINE, certStoreName.c_str()); hCertStore = CertOpenStore(CERT_STORE_PROV_SYSTEM, 0, 0, CERT_SYSTEM_STORE_LOCAL_MACHINE, wcertStore.c_str());
else else
hCertStore = CertOpenSystemStoreW(0, wcertStore.c_str()); hCertStore = CertOpenSystemStoreW(0, wcertStore.c_str());
@@ -397,7 +397,6 @@ void X509Certificate::importCertificate(const std::string& certPath)
Poco::File certFile(certPath); Poco::File certFile(certPath);
if (!certFile.exists()) throw Poco::FileNotFoundException(certPath); if (!certFile.exists()) throw Poco::FileNotFoundException(certPath);
Poco::File::FileSize size = certFile.getSize(); Poco::File::FileSize size = certFile.getSize();
if (size > 4096) throw Poco::DataFormatException("certificate file too large", certPath);
if (size < 32) throw Poco::DataFormatException("certificate file too small", certPath); if (size < 32) throw Poco::DataFormatException("certificate file too small", certPath);
Poco::Buffer<char> buffer(static_cast<std::size_t>(size)); Poco::Buffer<char> buffer(static_cast<std::size_t>(size));
Poco::FileInputStream istr(certPath); Poco::FileInputStream istr(certPath);

View File

@@ -114,6 +114,12 @@ POCO_SOURCES( SRCS libpng
src/pngwutil.c src/pngwutil.c
) )
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
#TODO: Can we put this with the below includes? PRIVAT eg. #TODO: Can we put this with the below includes? PRIVAT eg.
include_directories( "include/Poco/PDF" ) # zip src include_directories( "include/Poco/PDF" ) # zip src
@@ -126,7 +132,11 @@ set_target_properties(PDF
DEFINE_SYMBOL PDF_EXPORTS DEFINE_SYMBOL PDF_EXPORTS
) )
target_link_libraries(PDF PUBLIC ${ZLIB_LIBRARIES} Poco::XML Poco::Util) if (POCO_UNBUNDLED)
target_link_libraries(PDF PUBLIC ZLIB::ZLIB)
target_compile_definitions(PDF PUBLIC POCO_UNBUNDLED)
endif (POCO_UNBUNDLED)
target_link_libraries(PDF PUBLIC Poco::XML Poco::Util)
target_include_directories(PDF target_include_directories(PDF
PUBLIC PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include> $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
@@ -138,11 +148,6 @@ if(MINGW)
target_compile_definitions(PDF PRIVATE HPDF_DLL_MAKE_CDECL) target_compile_definitions(PDF PRIVATE HPDF_DLL_MAKE_CDECL)
endif() endif()
if (POCO_UNBUNDLED)
target_include_directories(PDF PUBLIC "${ZLIB_INCLUDE_DIRS}")
target_compile_definitions(PDF PUBLIC POCO_UNBUNDLED)
endif()
POCO_INSTALL(PDF) POCO_INSTALL(PDF)
POCO_GENERATE_PACKAGE(PDF) POCO_GENERATE_PACKAGE(PDF)

View File

@@ -1,3 +1,7 @@
include(CMakeFindDependencyMacro) include(CMakeFindDependencyMacro)
find_dependency(PocoFoundation) find_dependency(PocoFoundation)
if(@POCO_UNBUNDLED@)
find_dependency(ZLIB REQUIRED)
endif()
include("${CMAKE_CURRENT_LIST_DIR}/PocoPDFTargets.cmake") include("${CMAKE_CURRENT_LIST_DIR}/PocoPDFTargets.cmake")

View File

@@ -1,138 +0,0 @@
<AppConfig>
<PocoDoc>
<files>
<include>
${PocoBuild}/*/include/Poco/*.h
${PocoBuild}/*/include/Poco/*/*.h
${PocoBuild}/*/include/Poco/*/*/*.h
${PocoBuild}/*/include/Poco/*/*.h
${PocoBuild}/*/*/include/Poco/*/*/*.h
</include>
<exclude>
*_*.h,
expat*.h,
zconf.h,
zlib.h,
Alignment.h,
QName.h,
CppUnitException.h,
Constants.h,
inffast.h,
PDF/include/*.h,
CppParser/include/*.h,
Data/include/*.h,
Data/*/include/*.h,
Data/*/*/include/*.h,
ratio
</exclude>
</files>
<pages>
${PocoBuild}/doc/*.page,
${PocoBuild}/*/doc/*.page
${PocoBuild}/*/*/doc/*.page
</pages>
<resources>
${PocoBase}/PocoDoc/resources/css,
${PocoBase}/PocoDoc/resources/js,
${PocoBase}/PocoDoc/resources/images,
${PocoBase}/PocoDoc/resources/index.thtml,
${PocoBuild}/*/doc/images
</resources>
<compiler>
<windows>
<exec>cl.exe</exec>
<options>
${Includes},
/I${PocoBase}/openssl/include
/I${VCH}/include,
/I${WDK}/shared
/I${WDK}/um
/I${WDK}/ucrt
/nologo,
/D_DEBUG,
/E,
/C,
/DPOCO_NO_GCC_API_ATTRIBUTE
</options>
<path>${CLP}</path>
<usePipe>true</usePipe>
</windows>
<unix>
<exec>${CXX} ${CXXFLAGS}</exec>
<options>
${Includes},
-I/usr/local/mysql/include,
-I/usr/include/mysql,
-I/usr/include/postgresql,
-D_DEBUG,
-E,
-C,
-DPOCO_NO_GCC_API_ATTRIBUTE,
-DPOCO_NO_WINDOWS_H
</options>
<path></path>
<usePipe>true</usePipe>
</unix>
</compiler>
<language>EN</language>
<charset>utf-8</charset>
<software>POCO C++ Libraries</software>
<company>Applied Informatics Software Engineering GmbH and Contributors</company>
<companyURI>http://pocoproject.org/</companyURI>
</PocoDoc>
<Translations>
<EN>
<All_Base_Classes>All Base Classes</All_Base_Classes>
<All_Symbols>All Symbols</All_Symbols>
<Anonymous>Anonymous</Anonymous>
<Constructors>Constructors</Constructors>
<Class>Class</Class>
<Deprecated>Deprecated</Deprecated>
<Description>Description</Description>
<Destructor>Destructor</Destructor>
<Direct_Base_Classes>Direct Base Classes</Direct_Base_Classes>
<Enumerations>Enumerations</Enumerations>
<Functions>Functions</Functions>
<Header>Header</Header>
<iff>if and only if</iff>
<Inheritance>Inheritance</Inheritance>
<Inherited_Functions>Inherited Functions</Inherited_Functions>
<is_deprecated>is deprecated and should no longer be used</is_deprecated>
<Known_Derived_Classes>Known Derived Classes</Known_Derived_Classes>
<Library>Library</Library>
<Member_Functions>Member Functions</Member_Functions>
<Member_Summary>Member Summary</Member_Summary>
<more>more...</more>
<Namespaces>Namespaces</Namespaces>
<Namespace>Namespace</Namespace>
<Nested_Classes>Nested Classes</Nested_Classes>
<Package>Package</Package>
<Packages>Packages</Packages>
<Package_Index>Package Index</Package_Index>
<See_also>See also</See_also>
<Struct>Struct</Struct>
<Symbol_Index>Symbol Index</Symbol_Index>
<This>This</This>
<Types>Types</Types>
<Variables>Variables</Variables>
<TOC>Contents</TOC>
<Guides>User Guides and Tutorials</Guides>
<AAAIntroduction>Introduction</AAAIntroduction>
</EN>
</Translations>
<logging>
<loggers>
<root>
<channel>c1</channel>
<level>warning</level>
</root>
</loggers>
<channels>
<c1>
<class>ConsoleChannel</class>
<pattern>%s: [%p] %t</pattern>
</c1>
</channels>
</logging>
</AppConfig>

View File

@@ -238,6 +238,8 @@ protected:
} }
if (include) if (include)
files.insert(*it); files.insert(*it);
else
logger().debug("excluded " + *it);
} }
} }

View File

@@ -6,6 +6,12 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( SRCS ${HDRS_G}) POCO_HEADERS_AUTO( SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(Redis ${SRCS} ) add_library(Redis ${SRCS} )
add_library(Poco::Redis ALIAS Redis) add_library(Poco::Redis ALIAS Redis)
set_target_properties(Redis set_target_properties(Redis

View File

@@ -16,6 +16,12 @@ if(MINGW)
PROPERTIES COMPILE_FLAGS "-Wa,-mbig-obj") PROPERTIES COMPILE_FLAGS "-Wa,-mbig-obj")
endif() endif()
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(SQL ${SRCS} ) add_library(SQL ${SRCS} )
add_library(Poco::SQL ALIAS SQL) add_library(Poco::SQL ALIAS SQL)
set_target_properties(SQL set_target_properties(SQL

View File

@@ -6,6 +6,11 @@ POCO_SOURCES_AUTO( MYSQL_SRCS ${SRCS_G})
file(GLOB_RECURSE HDRS_G "include/*.h" ) file(GLOB_RECURSE HDRS_G "include/*.h" )
POCO_HEADERS_AUTO( MYSQL_SRCS ${HDRS_G}) POCO_HEADERS_AUTO( MYSQL_SRCS ${HDRS_G})
# Version Resource
if(MSVC AND NOT POCO_STATIC)
source_group("Resources" FILES ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
list(APPEND MYSQL_SRCS ${CMAKE_SOURCE_DIR}/DLLVersion.rc)
endif()
add_library(SQLMySQL ${MYSQL_SRCS} ) add_library(SQLMySQL ${MYSQL_SRCS} )
add_library(Poco::SQLMySQL ALIAS SQLMySQL) add_library(Poco::SQLMySQL ALIAS SQLMySQL)

View File

@@ -1,7 +1,7 @@
// //
// Binder.h // Binder.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: Binder // Module: Binder
// //

View File

@@ -1,7 +1,7 @@
// //
// Connector.h // Connector.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: Connector // Module: Connector
// //

View File

@@ -1,7 +1,7 @@
// //
// Extractor.h // Extractor.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: Extractor // Module: Extractor
// //

View File

@@ -1,7 +1,7 @@
// //
// MySQL.h // MySQL.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: MySQL // Module: MySQL
// //

View File

@@ -1,7 +1,7 @@
// //
// MySQLException.h // MySQLException.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: MySQLException // Module: MySQLException
// //

View File

@@ -1,7 +1,7 @@
// //
// MySQLstatementImpl.h // MySQLstatementImpl.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: MySQLstatementImpl // Module: MySQLstatementImpl
// //

View File

@@ -1,7 +1,7 @@
// //
// ResultMetadata.h // ResultMetadata.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: ResultMetadata // Module: ResultMetadata
// //

View File

@@ -1,7 +1,7 @@
// //
// SesssionHandle.h // SesssionHandle.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: SessionHandle // Module: SessionHandle
// //

View File

@@ -1,7 +1,7 @@
// //
// SessionImpl.h // SessionImpl.h
// //
// Library: Data/MySQL // Library: SQL/MySQL
// Package: MySQL // Package: MySQL
// Module: SessionImpl // Module: SessionImpl
// //

Some files were not shown because too many files have changed in this diff Show More