Patent ID: 7886153

Claim:
A communication device which executes encryption communication using a public key certificate which attests that a public key corresponds to identification information of the communication device, comprising: an identification information storing unit configured to store identification information specifying the communication device used for communicating with a device on a network; a certificate storing unit configured to store a public key certificate which attests to the communication device and includes holder information; a certificate transmitting unit configured to transmit the public key certificate stored in the certificate storing unit to a terminal device; a communication unit configured to communicate with the terminal device using the public key certificate at least when it is judged by the terminal device that the holder information included in the public key certificate corresponds to the identification information; a detect unit configured to detect an instruction for changing identification information of the communication device stored in the identification storing unit through an interface; a judging unit configured to judge whether a type of the identification information corresponding to the instruction for changing is used as a type of the holder information included in the public key certificate stored in the certificate storing unit when the instruction for changing the identification information is detected by the detect unit; a certificate generate unit configured to generate a public key certificate, which attests that the public key corresponds to changed identification information of the communication device, with an electronic signature, using a private key that does not match the public key when the judging unit judges that the type of the identification information corresponding to the instruction for changing is used as the type of the holder information included in the public key certificate; and an identification information change unit configured to change the identification information stored in the identification information storing unit to the identification information corresponding to the instruction for changing identification information of the communication device detected by the detect unit, without updating the public key certificate stored in the certificate storing unit, when the judging unit judges that the type of the identification information is not included in the public key certificate, and to change the identification information stored in the identification information storing unit to the identification information corresponding to the instruction for changing identification information of the communication device detected by the detect unit after generating a new public key certificate with the certificate generate unit when the judging unit judges that the type of the identification information is used as the type of the holder information included in the public key certificate.