Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add firewall documentation for the Azure Logs integration #9158

Merged
merged 11 commits into from Feb 22, 2024

Conversation

zmoog
Copy link
Contributor

@zmoog zmoog commented Feb 14, 2024

Proposed commit message

Specify the TCP ports required to enable Azure Logs on an Agent behind a firewall.

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.

Related issues

@zmoog zmoog self-assigned this Feb 14, 2024
@elasticmachine
Copy link

elasticmachine commented Feb 14, 2024

🚀 Benchmarks report

To see the full report comment with /test benchmark fullreport

@zmoog zmoog added documentation Improvements or additions to documentation enhancement New feature or request labels Feb 14, 2024
@zmoog zmoog changed the title Add firewall documentation for the event hub Add firewall documentation for the Azure Logs integration Feb 14, 2024
@zmoog zmoog marked this pull request as ready for review February 14, 2024 21:59
@zmoog zmoog requested review from a team as code owners February 14, 2024 21:59
@zmoog zmoog requested a review from alaudazzi February 14, 2024 21:59
Copy link
Contributor

@alaudazzi alaudazzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left a few editing suggestions, otherwise LGTM.

packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
@willemdh
Copy link

willemdh commented Feb 15, 2024

@zmoog The only remark I have here is that 5672 is unencrypted AMQP traffic and should not be opened. I can confirm it is not needed, it works when only 5671 is allowed. I'd really advice to check

*.servicebus.windows.net:5671
*.blob.core.windows.net:443

Also when you nslookup the servicebus URL, you get 3 *.cloudapp.net Url's which Also need to be allowed.

When the *.cloudapp.net url's are not allowed, it does not work

@zmoog
Copy link
Contributor Author

zmoog commented Feb 15, 2024

The only remark I have here is that 5672 is unencrypted AMQP traffic and should not be opened. I can confirm it is not needed, it works when only 5671 is allowed. I'd really advice to check

When the *.cloudapp.net url's are not allowed, it does not work

Thank you @willemdh, I'll double check both the ports and the URLs.

@zmoog
Copy link
Contributor Author

zmoog commented Feb 15, 2024

According to the AMQP 1.0 in Azure Service Bus and Event Hubs protocol guide, is seems the service on port 5672 performs a mandatory upgrade of connection to TLS:

Azure Service Bus or Azure Event Hubs requires the use of TLS at all times. It supports connections over TCP port 5671, whereby the TCP connection is first overlaid with TLS before entering the AMQP protocol handshake, and also supports connections over TCP port 5672 whereby the server immediately offers a mandatory upgrade of connection to TLS using the AMQP-prescribed model.

In the same document, in the AMQP outbound port requirements section, it lists both ports:

Clients that use AMQP connections over TCP require ports 5671 and 5672 to be opened in the local firewall.

So my current understanding is that using both 5671 and 5672 ports is not insecure because the service requires a mandatory upgrade to TLS.

I also noticed the document mentions the need for additional ports the EnableLinkRedirect is enabled:

Along with these ports, it might be necessary to open additional ports if the EnableLinkRedirect feature is enabled. EnableLinkRedirect is a new messaging feature that helps skip one-hop while receiving messages, thus helping to boost throughput. The client would start communicating directly with the back-end service over port range 104XX [...]

Personally, I never enable this option, but I want to learn more.

zmoog and others added 6 commits February 22, 2024 15:46
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
@zmoog zmoog force-pushed the zmoog/eventhub-firewall-docs branch from b4f3816 to da0f072 Compare February 22, 2024 14:56
@zmoog zmoog force-pushed the zmoog/eventhub-firewall-docs branch from 39030b8 to fb1b99d Compare February 22, 2024 15:23
@zmoog
Copy link
Contributor Author

zmoog commented Feb 22, 2024

@alaudazzi, I made a few minor additions. Would you mind taking a final look? 🙇

Copy link
Contributor

@alaudazzi alaudazzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few editing suggestions. LGTM.

packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
packages/azure/_dev/build/docs/README.md Outdated Show resolved Hide resolved
zmoog and others added 3 commits February 22, 2024 16:39
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
@elasticmachine
Copy link

💚 Build Succeeded

History

cc @zmoog

Copy link

Quality Gate passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No Coverage information No data about Coverage
No Duplication information No data about Duplication

See analysis details on SonarQube

@zmoog zmoog merged commit 1be2af6 into elastic:main Feb 22, 2024
5 checks passed
@zmoog zmoog deleted the zmoog/eventhub-firewall-docs branch February 22, 2024 15:58
@elasticmachine
Copy link

Package azure - 1.9.2 containing this change is available at https://epr.elastic.co/search?package=azure

gizas pushed a commit that referenced this pull request Mar 13, 2024
* Add firewall documentation for the event hub


---------

Co-authored-by: Arianna Laudazzi <46651782+alaudazzi@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants