basic tcp scripts