Patent ID: 7668114

Claim:
A communication apparatus comprising: a communication unit configured to receive plural pieces of prefix information from a plurality of devices, and to transmit data; a memory unit configured to memorize a piece of prefix information which has been used in a last transmission to each of a plurality of communication destination addresses; a changing unit configured to change host information within source information indicating a source of transmission made by said communication unit; a determining unit configured to, when a first piece of prefix information is memorized in said memory unit as the prefix information which has been used in the last transmission to a first communication destination address, a second piece of prefix information is memorized in said memory unit as the prefix information which has been used in the last transmission to a second communication destination address, and the prefix information which has been used in the last transmission to a third communication destination address is not memorized in said memory unit, determine a new piece of prefix information to be used in a new transmission from the plural pieces of prefix information received by said communication unit other than the first piece of prefix information in a case where said communication unit transmits the data to the first communication destination address, determine a new piece of prefix information to be used in a new transmission from the plural pieces of prefix information received by said communication unit other than the second piece of prefix information in a case where said communication unit transmits the data to the second communication destination address, and determine a new piece of prefix information to be used in a new transmission from the plural pieces of prefix information received by said communication unit in a case where said communication unit transmits the data to the third communication destination address; and a setting unit configured to set the source information based on the host information changed by said changing unit and the new piece of prefix information determined in accordance with the communication destination address by said determining unit, and to set a transmission route indicating that the data transmitted from said communication unit passes a device which sent the new piece of prefix information.