network plugin: use size_t for length and offsets