Sync API TCP get request
#Check url /request get HTTP_SYNC_EOF_get hello world
- Check url /content-length get HTTP_SYNC_CONTENT_get hello world
+ Check url /request get HTTP_SYNC_CONTENT_get hello world
# Broken due to dummy_https issues, disable for now
#Sync API TCP post request
timeout = 20,
port = 18080,
}
+if not is_ok then
+ logger.errx(rspamd_config, 'connect error: %1', connection)
+ return
+end
local err
is_ok, err = connection:write(string.format('POST /request HTTP/1.1\r\nConnection: close\r\n\r\n'))
end
local value
- local header = header_line:gsub("([%w-]+): (.*)",
+ local header = header_line:gsub("([%w-]+): (.*)",
function (h, v) value = v; return h:lower() end)
logger.info('parsed header: %1 -> "%2"', header, value)