port generation