To increase speed of cipher communication by utilizing a method of adaptively allocating a SA to a high-speed SRAM and a high-capacity system common memory considering a characteristic of generation and termination of communication.
An encryption processing device analyzes a SA having high possibility of being used subsequently and a SA having high possibility of being not used, on the basis of IP packet length. Specifically, when IP packets with the same IP packet length are continuously transmitted to the same communication partner, it is determined that a corresponding SA has high possibility of being used subsequently. And when a short IP packet is transmitted after IP packets with the same IP packet length are continuously transmitted to the same communication partner, it is determined that a corresponding SA has low possibility of being used for the time being.