Read and write files instead of direct socket operation. Hopes to prevent the judgeapi from causing a swallowed exception.