cURL Varnish bindings by Varnish Software
C M4 Makefile Shell
Latest commit 4aebdeb Oct 7, 2016 @fgsch fgsch Switch to parallel tests
Failed to load latest commit information.
m4 Tweak previous Jul 3, 2016
src Switch to parallel tests Oct 7, 2016
.gitignore Manpage is now under src/ Oct 7, 2016
.travis.yml Add travis file. Oct 6, 2015
LICENSE Update copyright year. Mar 14, 2016 Generate man page from vcc file Sep 20, 2016
README.rst Document prefix/pkg-config build setup May 23, 2016 Make autogen and configure working again Oct 9, 2015 Switch to parallel tests Oct 7, 2016


Travis CI badge

This vmod provides cURL bindings for Varnish so you can use Varnish as an HTTP client and fetch headers and bodies from backends.

WARNING: Using vmod-curl to connect to HTTPS sites is currently unsupported and may lead to segmentation faults on VCL load/unload. (openssl library intricacies)


The source tree is based on autotools to configure the building, and does also have the necessary bits in place to do functional unit tests using the varnishtest tool.

If you have installed Varnish to a non-standard directory, call and configure with PKG_CONFIG_PATH pointing to the appropriate path. For instance, when varnishd configure was called with --prefix=$PREFIX, use


Make targets:

  • make - builds the vmod
  • make install - installs your vmod in VMODDIR
  • make check - runs the unit tests in src/tests/*.vtc

To use the vmod do something along the lines of:

import curl;

sub vcl_recv {
        if (curl.header("X-Foo") == "bar") {

See src/vmod_curl.vcc for the rest of the callable functions.

Development of this VMOD has been sponsored by the Norwegian company Aspiro Music AS for usage on their WiMP music streaming service.