made curl timeout an optionally configurable parameter