A code generation apparatus to generate a plurality of spreading code sequences using block encryption processing to output a plurality of blocks as a spreading code sequence, the block encryption processing including process elements each to receive input data and to output output data, the code generation apparatus comprising: a parameter selection unit to select a sequence parameter uniquely corresponding to each spreading code sequence of the plurality of spreading code sequences; a secret key acquisition unit to acquire a secret key; and a code sequence generation unit to generate each spreading code sequence of the plurality of spreading code sequences by execution of the block encryption processing using the sequence parameter and the secret key, the code sequence generation unit changing the output data that is output from each of the process elements, using the sequence parameter, when the code sequence generation unit generates each spreading code sequence, wherein the block encryption processing includes, as each of the process elements, a substitution process of performing substitution for the input data, for each bit, based on a substitution table, and wherein the code sequence generation unit is configured to generate the plurality of spreading code sequences using only one type of the block encryption algorithm; characterized in that the code generation apparatus is applied to a satellite-mounted apparatus whose mounting scale is greatly constrained; wherein the block encryption processing holds provable security and wherein the code sequence generation unit is configured to mask the output data with at least a part of the sequence parameter, thereby changing the output data, wherein the code sequence generation unit is configured to generate each spreading code sequence of the plurality of spreading code sequences by execution of the block encryption processing in a CTR (Counter) mode, wherein the code generation apparatus comprises: a time calculation unit configured to count up the counter value used in the CTR mode and output the counter value to the code sequence generation unit for each threshold time, and wherein the code sequence generation unit is configured to generate each spreading code sequence of the plurality of spreading code sequences using the counter value, the secret key and the sequence parameter. a parameter selection unit to select a sequence parameter uniquely corresponding to each spreading code sequence of the plurality of spreading code sequences; a secret key acquisition unit to acquire a secret key; and a code sequence generation unit to generate each spreading code sequence of the plurality of spreading code sequences by execution of the block encryption processing using the sequence parameter and the secret key, the code sequence generation unit changing the output data that is output from each of the process elements, using the sequence parameter, when the code sequence generation unit generates each spreading code sequence, wherein the block encryption processing includes, as each of the process elements, a substitution process of performing substitution for the input data, for each bit, based on a substitution table, and wherein the code sequence generation unit is configured to generate the plurality of spreading code sequences using only one type of the block encryption algorithm; characterized in that the code generation apparatus is applied to a satellite-mounted apparatus whose mounting scale is greatly constrained; wherein the block encryption processing holds provable security and wherein the code sequence generation unit is configured to mask the output data with at least a part of the sequence parameter, thereby changing the output data, wherein the code sequence generation unit is configured to generate each spreading code sequence of the plurality of spreading code sequences by execution of the block encryption processing in a CTR (Counter) mode, wherein the code generation apparatus comprises: a time calculation unit configured to count up the counter value used in the CTR mode and output the counter value to the code sequence generation unit for each threshold time, and wherein the code sequence generation unit is configured to generate each spreading code sequence of the plurality of spreading code sequences using the counter value, the secret key and the sequence parameter. a time calculation unit configured to count up the counter value used in the CTR mode and output the counter value to the code sequence generation unit for each threshold time, and wherein the code sequence generation unit is configured to generate each spreading code sequence of the plurality of spreading code sequences using the counter value, the secret key and the sequence parameter.