| CPC H04L 9/0825 (2013.01) [H04L 9/0869 (2013.01)] | 14 Claims |

|
1. An electronic device comprising:
a communicator;
a memory configured to store data for generating a key; and
a processor,
wherein the processor is configured to:
generate a secret key by randomly combining values within a preset range based on the data stored in the memory, generate a public key using the secret key and an error, and store the secret key and the public key in the memory,
transmit the public key to an external device using the communicator, and
wherein a sum of the number of remaining values other than zero (0), among the values within the preset range, corresponds to a Hamming weight.
|