Adding support for secure AMQP connections over TLS (amqps).
<!-- Kamailio Pull Request Template -->
<!-- IMPORTANT: - for detailed contributing guidelines, read: https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md - pull requests must be done to master branch, unless they are backports of fixes from master branch to a stable branch - backports to stable branches must be done with 'git cherry-pick -x ...' - code is contributed under BSD for core and main components (tm, sl, auth, tls) - code is contributed GPLv2 or a compatible license for the other components - GPL code is contributed with OpenSSL licensing exception -->
#### Pre-Submission Checklist <!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply --> <!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above--> <!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list --> - [x] Commit message has the format required by CONTRIBUTING guide - [x] Commits are split per component (core, individual modules, libs, utils, ...) - [x] Each component has a single commit (if not, squash them into one commit) - [ ] No commits to README files for modules (changes must be done to docbook files in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change - [ ] Small bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds new functionality) - [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist: <!-- Go over all points below, and after creating the PR, tick the checkboxes that apply --> - [ ] PR should be backported to stable branches - [ ] Tested changes locally - [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description <!-- Describe your changes in detail -->
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/3511
-- Commit Summary --
* rabbitmq: Adding amqps support
-- File Changes --
M src/modules/rabbitmq/rabbitmq.c (33) M src/modules/rabbitmq/rabbitmq.h (2)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/3511.patch https://github.com/kamailio/kamailio/pull/3511.diff
@joelbax pushed 2 commits.
233d40c6c65c2b24b675c9322885add60b09d75b rabbitmq: Adding amqps support d002428a5181f99b2e32a96d31f041aa6f3aaacd Merge branch 'rabbitmq_amqps' of https://github.com/joelbax/kamailio into rabbitmq_amqps
@joelbax pushed 1 commit.
1e31ac49677474eafaef7911e935728156d9e265 rabbitmq: Format fixes
@henningw Sorry to directly bug you but I see that the format check task is failing because a missing space at the end of one line that it's not there in my local file. Do you know how to fix that?
@henningw commented on this pull request.
Thanks for the PR. I only noticed on small spelling error in the log. Regarding the format check failure, no idea why this happens. Lets wait for eventual other comments and then it can be merged. I can fix eventual remaining errors in the formatting by manually executing the format tool.
@@ -557,25 +561,52 @@ static int rabbitmq_connect(amqp_connection_state_t *conn)
int ret; int log_ret; // amqp_rpc_reply_t reply; + + // amqp_ssl_init_called should only be called once + if(amqp_info.ssl && !amqp_ssl_init_called) { + amqp_set_initialize_ssl_library(1); + amqp_ssl_init_called = 1; + LM_DBG("AMQP SSL library inilialized\n");
Spelling
@joelbax pushed 1 commit.
f51d017a60b759b4b2f0c5e19d5cdc8efab3d166 rabbitmq: Typo fix
The PR can be squashed and merged, to get it as a single combined commit, without the branch merge message.
@joelbax commented on this pull request.
@@ -557,25 +561,52 @@ static int rabbitmq_connect(amqp_connection_state_t *conn)
int ret; int log_ret; // amqp_rpc_reply_t reply; + + // amqp_ssl_init_called should only be called once + if(amqp_info.ssl && !amqp_ssl_init_called) { + amqp_set_initialize_ssl_library(1); + amqp_ssl_init_called = 1; + LM_DBG("AMQP SSL library inilialized\n");
Fixed!
The PR can be squashed and merged, to get it as a single combined commit, without the branch merge message.
I'm sorry @miconda I don't know if you mean that this PR can be merged with "squash and merge" (I don't have the option) or if I can do that with the original commits in my repo fork. I've tried that but the original commits still appear listed here.
https://docs.github.com/en/get-started/using-git/using-git-rebase-on-the-com...
Merged #3511 into master.
@joelbax: the message was that the PR is fine for me and if someone considers to merge it should be done with squash option, which appears to the registered developers, not for you. @linuxmaniac's link is good for cli work, but you still can't commit yourself in the mainstream repo.
I just did the merge in that way.