You may not open all ports, otherwise you are open for everything. This is a high security risk. Only open such ports you really need, but each port for a certain service. For SSH you must configure your system to tell your system which port is for SSH.