summaryrefslogtreecommitdiff
path: root/librabbitmq
Commit message (Collapse)AuthorAgeFilesLines
* ssl: Limit SSL to only support TLSv1.2 and TLSv1.3HEADmasterAlan Antonuk2023-05-031-50/+39
| | | | | | | This also restructures the SSL code to use the modern OpenSSL equivalent of these functions simplifying internal code to be more readable. Signed-off-by: GitHub <noreply@github.com>
* ssl: Use OPENSSL_API_COMPAT v1.1.1Alan Antonuk2023-05-032-5/+5
| | | | | | | OpenSSL v1.1.1 is the minimum version that rabbitmq-c supports and the API that it's programmed against. Signed-off-by: GitHub <noreply@github.com>
* Correct library versions on Mach-O platformsAlan Antonuk2023-04-301-1/+16
| | | | | | | | | | | Set the compatibility and current version strings on Mach-O (Apple) platforms. The compatibility version remains the same as the SOVERSION, the current version is SOVERSION.AGE.REVISION, which matches the previous libtool semantics for this. Fixes #758 Signed-off-by: GitHub <noreply@github.com>
* fix: recursion when decoding arrays.Alan Antonuk2023-03-121-4/+4
| | | | | | | | | This corrects what was done in 903b6b5 to correctly limit array recursion in addition recursion within a table. Fixes: https://crbug.com/oss-fuzz/56949 Signed-off-by: GitHub <noreply@github.com>
* fix: limit recursion in table decodingAlan Antonuk2023-03-101-9/+25
| | | | | | | | | | | | Limit depth of table and arrays when decoding to 100. This is done to prevent stack overflows from potentially adversial input. 100 is picked as its high enough that its unlikely that a valid input would be that big. Fixes: https://crbug.com/oss-fuzz/56296 Fixes: https://crbug.com/oss-fuzz/56204 Signed-off-by: GitHub <noreply@github.com>
* fix: correct amqp_ssl_socket_set_key_buffer valueAlan Antonuk2023-02-021-0/+1
| | | | | | | | | | Make amqp_ssl_socket_set_key_buffer return AMQP_STATUS_OK on success. It currently returns the status of the underlying OpenSSL call, which isn't correct. Fixes: alanxz/rabbitmq-c#723 Signed-off-by: GitHub <noreply@github.com>
* Remove obsoleted OpenSSL init codeAlan Antonuk2023-02-021-133/+9
| | | | | | | | | | Starting with OpenSSL v1.1.0, library init/uninit is automatically handled by the library. This removes unnecessary code from rabbitmq-c and marks the initialization functions as deprecated. Fixed: alanxz/rabbitmq-c#737 Signed-off-by: GitHub <noreply@github.com>
* remove obsolete const workaround in ssl bioAlan Antonuk2023-02-021-12/+9
| | | | | | | This workaround was needed for OpenSSL v1.1.0 and older. rabbitmq-c requires v1.1.1 or newer, so this workaround can be removed. Signed-off-by: GitHub <noreply@github.com>
* add option to install or not the static libraryRemi Collet2023-02-011-3/+5
|
* Define OPENSSL_API_COMPAT to 1.1.0 version.Alan Antonuk2023-02-012-0/+6
| | | | | | | | | This should stop warnings about deprecated APIs. RabbitMQ-c will adopt OpenSSL 3.x APIs in a future version. Fixed: #729 Signed-off-by: GitHub <noreply@github.com>
* restore compatibility with old Microsoft compilersFabio Napoli2021-11-121-1/+2
|
* Fix no rabbitmq target when building static-onlyAlan Antonuk2021-09-291-1/+5
| | | | | Fixes: #708 Signed-off-by: GitHub <noreply@github.com>
* lib: compatibility with old Borland compilersFábio Machado de Oliveira2021-08-232-5/+13
|
* Update copyright & license header to use SPDX idAlan Antonuk2021-07-2722-658/+61
| | | | | | | This makes license detection machine-readable, and makes source files more concise and easier to read and understand. Signed-off-by: GitHub <noreply@github.com>
* lib: remove unused AMQP_PRIVATE macroAlan Antonuk2021-05-191-6/+0
| | | | Signed-off-by: GitHub <noreply@github.com>
* cmake: remove unused RMQ_LIBRARY_TARGET varAlan Antonuk2021-04-281-2/+0
| | | | Signed-off-by: GitHub <noreply@github.com>
* lib: fix clang-tidy finding in simple_rpc_innerAlan Antonuk2021-04-281-1/+1
| | | | | | | While this wasn't causing any errors, it did have the potential to cause a bug if the error codes ever were positive. Signed-off-by: GitHub <noreply@github.com>
* lib: remove unused store in amqp_urlAlan Antonuk2021-04-281-1/+1
| | | | | | Found using clang-tidy Signed-off-by: GitHub <noreply@github.com>
* lib: update framing regenerator to use python 3Alan Antonuk2021-04-201-96/+94
| | | | Signed-off-by: GitHub <noreply@github.com>
* lib: regenerate framing with codegen v3.8.14Alan Antonuk2021-04-201-0/+74
| | | | Signed-off-by: GitHub <noreply@github.com>
* cmake: remove framing generation from cmakeAlan Antonuk2021-04-201-48/+2
| | | | | | This will be replaced with some sort of shell script. Signed-off-by: GitHub <noreply@github.com>
* lib: Fix minor issues with codegenAlan Antonuk2021-04-202-0/+2
| | | | Signed-off-by: GitHub <noreply@github.com>
* cmake: delete unused LIBRABBITMQ_INCLUDE_DIRS and RMQ_LIBRARY_TARGETAlan Antonuk2021-04-191-9/+1
| | | | | | These have not been replaced with better alternatives. Signed-off-by: GitHub <noreply@github.com>
* cmake: use OpenSSL::SSL imported targetAlan Antonuk2021-04-191-4/+3
| | | | Signed-off-by: GitHub <noreply@github.com>
* cmake: add alias targets for library targetsAlan Antonuk2021-04-181-0/+4
| | | | | | | | Users using rabbitmq-c by using add_subdirectory on the project should use the rabbitmq::rabbitmq or rabbitmq::rabbitmq-static targets to use the rabbitmq-c library. Signed-off-by: GitHub <noreply@github.com>
* cmake: modernize lib target specificationAlan Antonuk2021-04-131-98/+126
| | | | | | | Use modern CMake idioms when defining rabbitmq and rabbitmq-static library targets. Signed-off-by: GitHub <noreply@github.com>
* cmake: remove unused -DAMQP_BUILD definitionAlan Antonuk2021-04-131-2/+0
| | | | Signed-off-by: GitHub <noreply@github.com>
* lib remove undefined func amqp_ssl_error_stringAlan Antonuk2021-04-132-5/+0
| | | | | | Then also remove unused -DWITH_SSL define when compiling the library. Signed-off-by: GitHub <noreply@github.com>
* lib: use $ORIGIN for installed rpath on non-MacOSAlan Antonuk2021-04-111-0/+4
| | | | | | | | This sets an rpath that makes it a bit more intuitive to use when the library is moved after installation. This matches the behavior on MacOS platform, which is why this is not changed for MacOS platforms. Signed-off-by: GitHub <noreply@github.com>
* cmake: specify COMPONENT on install commandsAlan Antonuk2021-04-111-1/+9
| | | | | | | | | | | | | | | | To help package managers cmake install commands now specify a COMPONENT. Components include: - rabbitmq-c-runtime: libraries necessary for running programs linked against rabbitmq-c. - rabbitmq-c-development: static libraries, headers necessary for building programs against rabbitmq-c - rabbitmq-c-tools: CLI tools for interacting with RabbitMQ broker - rabbitmq-c-tool-docs: man pages for CLI tools. This also updates the tool install directory to use GnuInstallDirs- compatible location Signed-off-by: GitHub <noreply@github.com>
* ssl: remove obsolete amqp_hostcheckAlan Antonuk2021-04-073-245/+0
| | | | | | This is dead code, obsoleted by #673 (setting minimum OpenSSL v1.1.1). Signed-off-by: GitHub <noreply@github.com>
* Add TLSv1.3 support and set min-version to TLSv1.2Alan Antonuk2021-04-061-8/+13
| | | | | | | | | Add support for TLSv1.3, and set the default supported versions to be TLSv1.2 and TLSv1.3. TLSv1.0 and TLSv1.1 both have security flaws that make them unsuitable as a default. If these versions are required, they can be explictly set by users to use these older versions. Signed-off-by: GitHub <noreply@github.com>
* ssl: drop support OpenSSL v1.1.0 and olderAlan Antonuk2021-04-066-285/+2
| | | | | | | | | | | | v1.1.0 and older is no longer supported by OpenSSL (https://www.openssl.org/policies/releasestrat.html). While there is the possibility that someone is paying for support for v1.0.2, this library is not regularly tested against these versions. As a side-effect older workarounds for hostname verification can be removed. Signed-off-by: GitHub <noreply@github.com>
* cmake: use GenerateExportHeader for AMQP_EXPORTAlan Antonuk2021-04-063-33/+43
| | | | | | | | | | Use cmake's GenerateExportHeader to define AMQP_EXPORT & AMQP_DEPRECATED over the one in amqp.h. This is likely to be more correct over time. Note this requires bumping the minimum required version from v3.10 to v3.12 to pick up support in CMake for C libraries. Signed-off-by: GitHub <noreply@github.com>
* Move official includes to rabbitmq-c/ directoryAlan Antonuk2021-04-058-15/+29
| | | | | | | | | | | | | | | Move official rabbitmq-c includes under the rabbitmq-c, thus new programs should use the following include paths: amqp.h -> rabbitmq-c/amqp.h amqp_tcp_socket.h -> rabbitmq-c/tcp_socket.h amqp_ssl_socket .h-> rabbitmq-c/ssl_socket.h amqp_framing.h -> rabbitmq-c/framing.h Existing include files are left with a warning message and including their new equivalents, so existing programs should compile without modification. Signed-off-by: GitHub <noreply@github.com>
* Move public header files to include directoryAlan Antonuk2021-04-055-4058/+11
| | | | Signed-off-by: GitHub <noreply@github.com>
* win32: remove obsolete msinttypes/stdint.hAlan Antonuk2021-04-052-254/+0
| | | | | | | | This was needed for versions of MSVC older than VS 2010. Both MSVC and the newest OS it runs on (Win 7) are no longer supported by Microsoft. Thus its safe to drop support for this. Signed-off-by: GitHub <noreply@github.com>
* cmake: use modern version of project() commandAlan Antonuk2021-04-011-2/+0
| | | | | | | This also gets rid of a non-top-level project command that probably shouldn't be used. Signed-off-by: GitHub <noreply@github.com>
* Bumping revision for development.Alan Antonuk2021-03-311-2/+2
| | | | Signed-off-by: GitHub <noreply@github.com>
* Preparation for v0.11.0 releasev0.11.0Alan Antonuk2021-03-311-1/+1
| | | | Signed-off-by: GitHub <noreply@github.com>
* ssl: correct since version on amqp_set_ssl_engine and ↵Alan Antonuk2021-03-311-2/+2
| | | | | amqp_ssl_socket_set_key_engine APIs (#662) Signed-off-by: GitHub <noreply@github.com>
* ssl: Support password protected keysFake2021-03-302-0/+21
|
* ssl: remove reference to FIPS_set_modeAlan Antonuk2021-03-041-4/+0
| | | | | | | | | | | | This was cargo-culted from the OpenSSL wiki for uninitializing OpenSSL. This API has been removed v3.x and newer of OpenSSL, additionally rabbitmq-c doesn't use FIPS mode, so this is likely a no-op even using older OpenSSL. Fixes #654 Fixes #627 Signed-off-by: GitHub <noreply@github.com>
* Format sources using clang-format-10Alan Antonuk2020-12-247-31/+33
| | | | This should allow the check-format step to work on Github Actions.
* docs: fix simple typo, throughly -> thoroughlyTim Gates2020-10-181-1/+1
| | | | | | There is a small typo in librabbitmq/amqp.h. Should read `thoroughly` rather than `throughly`.
* Support openssl engine settingHan Mai2020-06-254-3/+111
|
* lib: correct amqp_time_from_now behavior at {0, 0}Alan Antonuk2020-06-213-15/+4
| | | | | | | | | | | | Change behavior of amqp_time_from_now to set to the current timestamp when a struct timeval of {0, 0} is passed in instead of 0. This better aligns with how one would expect the function to work. As a byproduct this corrects an issue where amqp_consume_message would not return AMQP_STATUS_HEARTBEAT_TIMEOUT when a tv of {0, 0} and the heartbeat interval had passed. Fixes #557 in a more concise way.
* Allow use of pthreads with WindowsZane van Iperen2020-06-211-14/+3
|
* Add rabbitmq-c-config.cmake generationEric Huff2020-05-311-2/+2
| | | | | | Generating a -config.cmake or Config.cmake lets rabbitmq-c be discoverable via cmake's `find_package`, and allows easier use in the vcpkg ecosystem.
* Updating how openssl is configuredMichael D. Stemle, Jr2020-04-191-3/+1
| | | | | Per guidance from the openssl project, this seems like it might be the more correct way to configure openssl with the default configuration files. #603