Currently proxy options are passed to make_curl_request() via the
`params` parameter, so they are sent to external services for no good
reason. This commit fixes it by adding proxy parameters to the
function.
The appropriate *_proxy environment variables aren't always detected properly
by libcurl. This allows manually setting the proxy when this happens, and
disabling SSL certificate verification if the proxy requires it.
This also moves the call to Base64Encode, which fixes#70 by
preventing a double-encoding of the auth string when building with
support for libcurl instead of csocket. The base64 encoding is now done
in the csocket request, where it is still required to operate correctly.
Loading as a user module will require either the webadmin or
controlpanel module, as ZNC Push will retain the current behavior
of loading as a network module by default.
Fixes#79
Pushbullet gives a misleading error if the client uses
www.pushbullet.com instead of api.pushbullet.com. Whatever
the reason, using the correct hostname fixes it.
When compiling with USE_CURL defined, znc push will use libcurl for
making http requests instead of ZNC's builtin CSocket library. This
enables some advanced features, such as supporting HTTP proxies for
outbound requests.
Currently, building with curl support requires running the following:
make curl=yes clean install
libcurl must already be installed and accessible by default. Otherwise,
it is up to the user to populate CXXFLAGS with the appropriate values so
that znc-buildmod can appropriately find and link libcurl to the module.
Notifo has finally died, so there's no reason to keep its code around
any longer. It's probably also safe to remove the section from the
readme about migrating from the old notifo module that has been gone for
over a year now.
When building znc-push with the makefile, it will modify the
PUSHVERSION define with version info from `git describe`, build the
module, and then reset PUSHVERSION back to "dev". When building
directly from znc-buildmod, this will ensure the version is always just
"dev".
A matching command -- `version` -- has been added to the module which
will simply echo the value of PUSHVERSION at the time of compilation.