redesigned free ports finding for FF binding