  Linear complementary dual (LCD) codes is a class of linear codes introduced
by Massey in 1964. LCD codes have been extensively studied in literature
recently. In addition to their applications in data storage, communications
systems, and consumer electronics, LCD codes have been employed in
cryptography. More specifically, it has been shown that LCD codes can also help
improve the security of the information processed by sensitive devices,
especially against so-called side-channel attacks (SCA) and fault non-invasive
attacks. In this paper, we are interested in the construction of particular
algebraic geometry (AG) LCD codes which could be good candidates to be
resistant against SCA. We firstly provide a construction scheme for obtaining
LCD codes from elliptic curves. Then, some explicit LCD codes from elliptic
curve are presented. MDS codes are of the most importance in coding theory due
to their theoretical significance and practical interests. In this paper, all
the constructed LCD codes from elliptic curves are MDS or almost MDS. Some
infinite classes of LCD codes from elliptic curves are optimal due to the
Griesmer bound. Finally, we introduce a construction mechanism for obtaining
LCD codes from any algebraic curve and derive some explicit LCD codes from
hyperelliptic curves and Hermitian curves.
