N°9519 - Add proxy to Webhook Request#29
Conversation
|
Hi, I have uploaded the pull request with the proposed changes related to proxy support. PR: #29 Please let me know if you would like me to add more details or make any adjustments. Best regards, |
There was a problem hiding this comment.
Quick remark, please make the code comments in English so everyone can understand them.
Also, be aware that your changes make that these proxy settings are now applied by default for all new users!
And I guess the people from Combodo will require you to fill in the request template, You seem to have removed it all (in your initial post)
|
Hello, thank you for your PR ! We'll review your code in sprint 3.4, that should start at the end of summer (from September). |
|
Really useful contribution — thank you! 🙏 From a field perspective, this is critical in production: when the iTop server has no direct Internet access, webhooks can't go out at all, making the whole integration unusable. Native proxy support would unblock a common deployment scenario. Two small things to tidy up (besides the points already raised by the maintainers):
(Optional: making |
Symptom (bug) / Objective (enhancement)
In many enterprise environments, iTop servers do not have direct access to the Internet and must route all outbound HTTP/HTTPS traffic through a corporate proxy.
Currently, the webhook integration module does not provide any way to configure a proxy for outbound requests.
As a result, webhook calls fail in restricted networks, usually with DNS resolution or connection errors, making integrations with external services (Telegram, Slack, APIs, etc.) unusable.
The objective of this enhancement is to allow webhook HTTP requests to be routed through a configurable proxy, making the webhook integration usable in secured and restricted infrastructures.
Reproduction procedure (bug)
(Not applicable, this is an enhancement and not a bug.)
Cause (bug)
(Not applicable, this is an enhancement and not a bug.)
Proposed solution (bug and enhancement)
The solution adds optional HTTP proxy support to the webhook request sender:
The proxy configuration is read from the module settings:
host(mandatory)user(optional)password(optional)When a proxy is defined, the corresponding CURL options are injected into the request:
CURLOPT_PROXYCURLOPT_PROXYTYPECURLOPT_PROXYUSERPWD(if authentication is configured)When no proxy is defined, the behavior remains unchanged, ensuring full backward compatibility.
This allows webhook integrations to work transparently in environments where Internet access is only available through a proxy.
The change is limited to the webhook integration module and does not impact any other part of iTop.