1# Copyright (C) 2015 The Android Open Source Project 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of the License at 6# 7# http://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14 15crypto_sources := \ 16 android_compat_hacks.c\ 17 android_compat_keywrap.c\ 18 err_data.c\ 19 src/crypto/aes/aes.c\ 20 src/crypto/aes/mode_wrappers.c\ 21 src/crypto/asn1/a_bitstr.c\ 22 src/crypto/asn1/a_bool.c\ 23 src/crypto/asn1/a_bytes.c\ 24 src/crypto/asn1/a_d2i_fp.c\ 25 src/crypto/asn1/a_dup.c\ 26 src/crypto/asn1/a_enum.c\ 27 src/crypto/asn1/a_gentm.c\ 28 src/crypto/asn1/a_i2d_fp.c\ 29 src/crypto/asn1/a_int.c\ 30 src/crypto/asn1/a_mbstr.c\ 31 src/crypto/asn1/a_object.c\ 32 src/crypto/asn1/a_octet.c\ 33 src/crypto/asn1/a_print.c\ 34 src/crypto/asn1/a_strnid.c\ 35 src/crypto/asn1/a_time.c\ 36 src/crypto/asn1/a_type.c\ 37 src/crypto/asn1/a_utctm.c\ 38 src/crypto/asn1/a_utf8.c\ 39 src/crypto/asn1/asn1_lib.c\ 40 src/crypto/asn1/asn1_par.c\ 41 src/crypto/asn1/asn_pack.c\ 42 src/crypto/asn1/bio_asn1.c\ 43 src/crypto/asn1/bio_ndef.c\ 44 src/crypto/asn1/f_enum.c\ 45 src/crypto/asn1/f_int.c\ 46 src/crypto/asn1/f_string.c\ 47 src/crypto/asn1/t_bitst.c\ 48 src/crypto/asn1/t_pkey.c\ 49 src/crypto/asn1/tasn_dec.c\ 50 src/crypto/asn1/tasn_enc.c\ 51 src/crypto/asn1/tasn_fre.c\ 52 src/crypto/asn1/tasn_new.c\ 53 src/crypto/asn1/tasn_prn.c\ 54 src/crypto/asn1/tasn_typ.c\ 55 src/crypto/asn1/tasn_utl.c\ 56 src/crypto/asn1/x_bignum.c\ 57 src/crypto/asn1/x_long.c\ 58 src/crypto/base64/base64.c\ 59 src/crypto/bio/bio.c\ 60 src/crypto/bio/bio_mem.c\ 61 src/crypto/bio/buffer.c\ 62 src/crypto/bio/connect.c\ 63 src/crypto/bio/fd.c\ 64 src/crypto/bio/file.c\ 65 src/crypto/bio/hexdump.c\ 66 src/crypto/bio/pair.c\ 67 src/crypto/bio/printf.c\ 68 src/crypto/bio/socket.c\ 69 src/crypto/bio/socket_helper.c\ 70 src/crypto/bn/add.c\ 71 src/crypto/bn/asm/x86_64-gcc.c\ 72 src/crypto/bn/bn.c\ 73 src/crypto/bn/bn_asn1.c\ 74 src/crypto/bn/cmp.c\ 75 src/crypto/bn/convert.c\ 76 src/crypto/bn/ctx.c\ 77 src/crypto/bn/div.c\ 78 src/crypto/bn/exponentiation.c\ 79 src/crypto/bn/gcd.c\ 80 src/crypto/bn/generic.c\ 81 src/crypto/bn/kronecker.c\ 82 src/crypto/bn/montgomery.c\ 83 src/crypto/bn/mul.c\ 84 src/crypto/bn/prime.c\ 85 src/crypto/bn/random.c\ 86 src/crypto/bn/rsaz_exp.c\ 87 src/crypto/bn/shift.c\ 88 src/crypto/bn/sqrt.c\ 89 src/crypto/buf/buf.c\ 90 src/crypto/bytestring/ber.c\ 91 src/crypto/bytestring/cbb.c\ 92 src/crypto/bytestring/cbs.c\ 93 src/crypto/chacha/chacha_generic.c\ 94 src/crypto/chacha/chacha_vec.c\ 95 src/crypto/cipher/aead.c\ 96 src/crypto/cipher/cipher.c\ 97 src/crypto/cipher/derive_key.c\ 98 src/crypto/cipher/e_aes.c\ 99 src/crypto/cipher/e_chacha20poly1305.c\ 100 src/crypto/cipher/e_des.c\ 101 src/crypto/cipher/e_null.c\ 102 src/crypto/cipher/e_rc2.c\ 103 src/crypto/cipher/e_rc4.c\ 104 src/crypto/cipher/e_ssl3.c\ 105 src/crypto/cipher/e_tls.c\ 106 src/crypto/cipher/tls_cbc.c\ 107 src/crypto/cmac/cmac.c\ 108 src/crypto/conf/conf.c\ 109 src/crypto/cpu-arm.c\ 110 src/crypto/cpu-intel.c\ 111 src/crypto/crypto.c\ 112 src/crypto/curve25519/curve25519.c\ 113 src/crypto/curve25519/x25519-x86_64.c\ 114 src/crypto/des/des.c\ 115 src/crypto/dh/check.c\ 116 src/crypto/dh/dh.c\ 117 src/crypto/dh/dh_asn1.c\ 118 src/crypto/dh/params.c\ 119 src/crypto/digest/digest.c\ 120 src/crypto/digest/digests.c\ 121 src/crypto/directory_posix.c\ 122 src/crypto/directory_win.c\ 123 src/crypto/dsa/dsa.c\ 124 src/crypto/dsa/dsa_asn1.c\ 125 src/crypto/ec/ec.c\ 126 src/crypto/ec/ec_asn1.c\ 127 src/crypto/ec/ec_key.c\ 128 src/crypto/ec/ec_montgomery.c\ 129 src/crypto/ec/oct.c\ 130 src/crypto/ec/p224-64.c\ 131 src/crypto/ec/p256-64.c\ 132 src/crypto/ec/p256-x86_64.c\ 133 src/crypto/ec/simple.c\ 134 src/crypto/ec/util-64.c\ 135 src/crypto/ec/wnaf.c\ 136 src/crypto/ecdh/ecdh.c\ 137 src/crypto/ecdsa/ecdsa.c\ 138 src/crypto/ecdsa/ecdsa_asn1.c\ 139 src/crypto/engine/engine.c\ 140 src/crypto/err/err.c\ 141 src/crypto/evp/algorithm.c\ 142 src/crypto/evp/digestsign.c\ 143 src/crypto/evp/evp.c\ 144 src/crypto/evp/evp_asn1.c\ 145 src/crypto/evp/evp_ctx.c\ 146 src/crypto/evp/p_dsa_asn1.c\ 147 src/crypto/evp/p_ec.c\ 148 src/crypto/evp/p_ec_asn1.c\ 149 src/crypto/evp/p_rsa.c\ 150 src/crypto/evp/p_rsa_asn1.c\ 151 src/crypto/evp/pbkdf.c\ 152 src/crypto/evp/sign.c\ 153 src/crypto/ex_data.c\ 154 src/crypto/hkdf/hkdf.c\ 155 src/crypto/hmac/hmac.c\ 156 src/crypto/lhash/lhash.c\ 157 src/crypto/md4/md4.c\ 158 src/crypto/md5/md5.c\ 159 src/crypto/mem.c\ 160 src/crypto/modes/cbc.c\ 161 src/crypto/modes/cfb.c\ 162 src/crypto/modes/ctr.c\ 163 src/crypto/modes/gcm.c\ 164 src/crypto/modes/ofb.c\ 165 src/crypto/obj/obj.c\ 166 src/crypto/obj/obj_xref.c\ 167 src/crypto/pem/pem_all.c\ 168 src/crypto/pem/pem_info.c\ 169 src/crypto/pem/pem_lib.c\ 170 src/crypto/pem/pem_oth.c\ 171 src/crypto/pem/pem_pk8.c\ 172 src/crypto/pem/pem_pkey.c\ 173 src/crypto/pem/pem_x509.c\ 174 src/crypto/pem/pem_xaux.c\ 175 src/crypto/pkcs8/p5_pbe.c\ 176 src/crypto/pkcs8/p5_pbev2.c\ 177 src/crypto/pkcs8/p8_pkey.c\ 178 src/crypto/pkcs8/pkcs8.c\ 179 src/crypto/poly1305/poly1305.c\ 180 src/crypto/poly1305/poly1305_arm.c\ 181 src/crypto/poly1305/poly1305_vec.c\ 182 src/crypto/rand/rand.c\ 183 src/crypto/rand/urandom.c\ 184 src/crypto/rand/windows.c\ 185 src/crypto/rc4/rc4.c\ 186 src/crypto/refcount_c11.c\ 187 src/crypto/refcount_lock.c\ 188 src/crypto/rsa/blinding.c\ 189 src/crypto/rsa/padding.c\ 190 src/crypto/rsa/rsa.c\ 191 src/crypto/rsa/rsa_asn1.c\ 192 src/crypto/rsa/rsa_impl.c\ 193 src/crypto/sha/sha1.c\ 194 src/crypto/sha/sha256.c\ 195 src/crypto/sha/sha512.c\ 196 src/crypto/stack/stack.c\ 197 src/crypto/thread.c\ 198 src/crypto/thread_none.c\ 199 src/crypto/thread_pthread.c\ 200 src/crypto/thread_win.c\ 201 src/crypto/time_support.c\ 202 src/crypto/x509/a_digest.c\ 203 src/crypto/x509/a_sign.c\ 204 src/crypto/x509/a_strex.c\ 205 src/crypto/x509/a_verify.c\ 206 src/crypto/x509/asn1_gen.c\ 207 src/crypto/x509/by_dir.c\ 208 src/crypto/x509/by_file.c\ 209 src/crypto/x509/i2d_pr.c\ 210 src/crypto/x509/pkcs7.c\ 211 src/crypto/x509/t_crl.c\ 212 src/crypto/x509/t_req.c\ 213 src/crypto/x509/t_x509.c\ 214 src/crypto/x509/t_x509a.c\ 215 src/crypto/x509/x509.c\ 216 src/crypto/x509/x509_att.c\ 217 src/crypto/x509/x509_cmp.c\ 218 src/crypto/x509/x509_d2.c\ 219 src/crypto/x509/x509_def.c\ 220 src/crypto/x509/x509_ext.c\ 221 src/crypto/x509/x509_lu.c\ 222 src/crypto/x509/x509_obj.c\ 223 src/crypto/x509/x509_r2x.c\ 224 src/crypto/x509/x509_req.c\ 225 src/crypto/x509/x509_set.c\ 226 src/crypto/x509/x509_trs.c\ 227 src/crypto/x509/x509_txt.c\ 228 src/crypto/x509/x509_v3.c\ 229 src/crypto/x509/x509_vfy.c\ 230 src/crypto/x509/x509_vpm.c\ 231 src/crypto/x509/x509cset.c\ 232 src/crypto/x509/x509name.c\ 233 src/crypto/x509/x509rset.c\ 234 src/crypto/x509/x509spki.c\ 235 src/crypto/x509/x509type.c\ 236 src/crypto/x509/x_algor.c\ 237 src/crypto/x509/x_all.c\ 238 src/crypto/x509/x_attrib.c\ 239 src/crypto/x509/x_crl.c\ 240 src/crypto/x509/x_exten.c\ 241 src/crypto/x509/x_info.c\ 242 src/crypto/x509/x_name.c\ 243 src/crypto/x509/x_pkey.c\ 244 src/crypto/x509/x_pubkey.c\ 245 src/crypto/x509/x_req.c\ 246 src/crypto/x509/x_sig.c\ 247 src/crypto/x509/x_spki.c\ 248 src/crypto/x509/x_val.c\ 249 src/crypto/x509/x_x509.c\ 250 src/crypto/x509/x_x509a.c\ 251 src/crypto/x509v3/pcy_cache.c\ 252 src/crypto/x509v3/pcy_data.c\ 253 src/crypto/x509v3/pcy_lib.c\ 254 src/crypto/x509v3/pcy_map.c\ 255 src/crypto/x509v3/pcy_node.c\ 256 src/crypto/x509v3/pcy_tree.c\ 257 src/crypto/x509v3/v3_akey.c\ 258 src/crypto/x509v3/v3_akeya.c\ 259 src/crypto/x509v3/v3_alt.c\ 260 src/crypto/x509v3/v3_bcons.c\ 261 src/crypto/x509v3/v3_bitst.c\ 262 src/crypto/x509v3/v3_conf.c\ 263 src/crypto/x509v3/v3_cpols.c\ 264 src/crypto/x509v3/v3_crld.c\ 265 src/crypto/x509v3/v3_enum.c\ 266 src/crypto/x509v3/v3_extku.c\ 267 src/crypto/x509v3/v3_genn.c\ 268 src/crypto/x509v3/v3_ia5.c\ 269 src/crypto/x509v3/v3_info.c\ 270 src/crypto/x509v3/v3_int.c\ 271 src/crypto/x509v3/v3_lib.c\ 272 src/crypto/x509v3/v3_ncons.c\ 273 src/crypto/x509v3/v3_pci.c\ 274 src/crypto/x509v3/v3_pcia.c\ 275 src/crypto/x509v3/v3_pcons.c\ 276 src/crypto/x509v3/v3_pku.c\ 277 src/crypto/x509v3/v3_pmaps.c\ 278 src/crypto/x509v3/v3_prn.c\ 279 src/crypto/x509v3/v3_purp.c\ 280 src/crypto/x509v3/v3_skey.c\ 281 src/crypto/x509v3/v3_sxnet.c\ 282 src/crypto/x509v3/v3_utl.c\ 283 284ssl_sources := \ 285 src/ssl/custom_extensions.c\ 286 src/ssl/d1_both.c\ 287 src/ssl/d1_clnt.c\ 288 src/ssl/d1_lib.c\ 289 src/ssl/d1_meth.c\ 290 src/ssl/d1_pkt.c\ 291 src/ssl/d1_srtp.c\ 292 src/ssl/d1_srvr.c\ 293 src/ssl/dtls_record.c\ 294 src/ssl/pqueue/pqueue.c\ 295 src/ssl/s3_both.c\ 296 src/ssl/s3_clnt.c\ 297 src/ssl/s3_enc.c\ 298 src/ssl/s3_lib.c\ 299 src/ssl/s3_meth.c\ 300 src/ssl/s3_pkt.c\ 301 src/ssl/s3_srvr.c\ 302 src/ssl/ssl_aead_ctx.c\ 303 src/ssl/ssl_asn1.c\ 304 src/ssl/ssl_buffer.c\ 305 src/ssl/ssl_cert.c\ 306 src/ssl/ssl_cipher.c\ 307 src/ssl/ssl_ecdh.c\ 308 src/ssl/ssl_file.c\ 309 src/ssl/ssl_lib.c\ 310 src/ssl/ssl_rsa.c\ 311 src/ssl/ssl_session.c\ 312 src/ssl/ssl_stat.c\ 313 src/ssl/t1_enc.c\ 314 src/ssl/t1_lib.c\ 315 src/ssl/tls_record.c\ 316 317tool_sources := \ 318 src/tool/args.cc\ 319 src/tool/ciphers.cc\ 320 src/tool/client.cc\ 321 src/tool/const.cc\ 322 src/tool/digest.cc\ 323 src/tool/generate_ed25519.cc\ 324 src/tool/genrsa.cc\ 325 src/tool/pkcs12.cc\ 326 src/tool/rand.cc\ 327 src/tool/server.cc\ 328 src/tool/speed.cc\ 329 src/tool/tool.cc\ 330 src/tool/transport_common.cc\ 331 332linux_aarch64_sources := \ 333 linux-aarch64/crypto/aes/aesv8-armx64.S\ 334 linux-aarch64/crypto/bn/armv8-mont.S\ 335 linux-aarch64/crypto/modes/ghashv8-armx64.S\ 336 linux-aarch64/crypto/sha/sha1-armv8.S\ 337 linux-aarch64/crypto/sha/sha256-armv8.S\ 338 linux-aarch64/crypto/sha/sha512-armv8.S\ 339 340linux_arm_sources := \ 341 linux-arm/crypto/aes/aes-armv4.S\ 342 linux-arm/crypto/aes/aesv8-armx32.S\ 343 linux-arm/crypto/aes/bsaes-armv7.S\ 344 linux-arm/crypto/bn/armv4-mont.S\ 345 linux-arm/crypto/modes/ghash-armv4.S\ 346 linux-arm/crypto/modes/ghashv8-armx32.S\ 347 linux-arm/crypto/sha/sha1-armv4-large.S\ 348 linux-arm/crypto/sha/sha256-armv4.S\ 349 linux-arm/crypto/sha/sha512-armv4.S\ 350 src/crypto/chacha/chacha_vec_arm.S\ 351 src/crypto/cpu-arm-asm.S\ 352 src/crypto/curve25519/asm/x25519-asm-arm.S\ 353 src/crypto/poly1305/poly1305_arm_asm.S\ 354 355linux_x86_sources := \ 356 linux-x86/crypto/aes/aes-586.S\ 357 linux-x86/crypto/aes/aesni-x86.S\ 358 linux-x86/crypto/aes/vpaes-x86.S\ 359 linux-x86/crypto/bn/bn-586.S\ 360 linux-x86/crypto/bn/co-586.S\ 361 linux-x86/crypto/bn/x86-mont.S\ 362 linux-x86/crypto/md5/md5-586.S\ 363 linux-x86/crypto/modes/ghash-x86.S\ 364 linux-x86/crypto/rc4/rc4-586.S\ 365 linux-x86/crypto/sha/sha1-586.S\ 366 linux-x86/crypto/sha/sha256-586.S\ 367 linux-x86/crypto/sha/sha512-586.S\ 368 369linux_x86_64_sources := \ 370 linux-x86_64/crypto/aes/aes-x86_64.S\ 371 linux-x86_64/crypto/aes/aesni-x86_64.S\ 372 linux-x86_64/crypto/aes/bsaes-x86_64.S\ 373 linux-x86_64/crypto/aes/vpaes-x86_64.S\ 374 linux-x86_64/crypto/bn/rsaz-avx2.S\ 375 linux-x86_64/crypto/bn/rsaz-x86_64.S\ 376 linux-x86_64/crypto/bn/x86_64-mont.S\ 377 linux-x86_64/crypto/bn/x86_64-mont5.S\ 378 linux-x86_64/crypto/ec/p256-x86_64-asm.S\ 379 linux-x86_64/crypto/md5/md5-x86_64.S\ 380 linux-x86_64/crypto/modes/aesni-gcm-x86_64.S\ 381 linux-x86_64/crypto/modes/ghash-x86_64.S\ 382 linux-x86_64/crypto/rand/rdrand-x86_64.S\ 383 linux-x86_64/crypto/rc4/rc4-x86_64.S\ 384 linux-x86_64/crypto/sha/sha1-x86_64.S\ 385 linux-x86_64/crypto/sha/sha256-x86_64.S\ 386 linux-x86_64/crypto/sha/sha512-x86_64.S\ 387 388mac_x86_sources := \ 389 mac-x86/crypto/aes/aes-586.S\ 390 mac-x86/crypto/aes/aesni-x86.S\ 391 mac-x86/crypto/aes/vpaes-x86.S\ 392 mac-x86/crypto/bn/bn-586.S\ 393 mac-x86/crypto/bn/co-586.S\ 394 mac-x86/crypto/bn/x86-mont.S\ 395 mac-x86/crypto/md5/md5-586.S\ 396 mac-x86/crypto/modes/ghash-x86.S\ 397 mac-x86/crypto/rc4/rc4-586.S\ 398 mac-x86/crypto/sha/sha1-586.S\ 399 mac-x86/crypto/sha/sha256-586.S\ 400 mac-x86/crypto/sha/sha512-586.S\ 401 402mac_x86_64_sources := \ 403 mac-x86_64/crypto/aes/aes-x86_64.S\ 404 mac-x86_64/crypto/aes/aesni-x86_64.S\ 405 mac-x86_64/crypto/aes/bsaes-x86_64.S\ 406 mac-x86_64/crypto/aes/vpaes-x86_64.S\ 407 mac-x86_64/crypto/bn/rsaz-avx2.S\ 408 mac-x86_64/crypto/bn/rsaz-x86_64.S\ 409 mac-x86_64/crypto/bn/x86_64-mont.S\ 410 mac-x86_64/crypto/bn/x86_64-mont5.S\ 411 mac-x86_64/crypto/ec/p256-x86_64-asm.S\ 412 mac-x86_64/crypto/md5/md5-x86_64.S\ 413 mac-x86_64/crypto/modes/aesni-gcm-x86_64.S\ 414 mac-x86_64/crypto/modes/ghash-x86_64.S\ 415 mac-x86_64/crypto/rand/rdrand-x86_64.S\ 416 mac-x86_64/crypto/rc4/rc4-x86_64.S\ 417 mac-x86_64/crypto/sha/sha1-x86_64.S\ 418 mac-x86_64/crypto/sha/sha256-x86_64.S\ 419 mac-x86_64/crypto/sha/sha512-x86_64.S\ 420 421win_x86_sources := \ 422 win-x86/crypto/aes/aes-586.asm\ 423 win-x86/crypto/aes/aesni-x86.asm\ 424 win-x86/crypto/aes/vpaes-x86.asm\ 425 win-x86/crypto/bn/bn-586.asm\ 426 win-x86/crypto/bn/co-586.asm\ 427 win-x86/crypto/bn/x86-mont.asm\ 428 win-x86/crypto/md5/md5-586.asm\ 429 win-x86/crypto/modes/ghash-x86.asm\ 430 win-x86/crypto/rc4/rc4-586.asm\ 431 win-x86/crypto/sha/sha1-586.asm\ 432 win-x86/crypto/sha/sha256-586.asm\ 433 win-x86/crypto/sha/sha512-586.asm\ 434 435win_x86_64_sources := \ 436 win-x86_64/crypto/aes/aes-x86_64.asm\ 437 win-x86_64/crypto/aes/aesni-x86_64.asm\ 438 win-x86_64/crypto/aes/bsaes-x86_64.asm\ 439 win-x86_64/crypto/aes/vpaes-x86_64.asm\ 440 win-x86_64/crypto/bn/rsaz-avx2.asm\ 441 win-x86_64/crypto/bn/rsaz-x86_64.asm\ 442 win-x86_64/crypto/bn/x86_64-mont.asm\ 443 win-x86_64/crypto/bn/x86_64-mont5.asm\ 444 win-x86_64/crypto/ec/p256-x86_64-asm.asm\ 445 win-x86_64/crypto/md5/md5-x86_64.asm\ 446 win-x86_64/crypto/modes/aesni-gcm-x86_64.asm\ 447 win-x86_64/crypto/modes/ghash-x86_64.asm\ 448 win-x86_64/crypto/rand/rdrand-x86_64.asm\ 449 win-x86_64/crypto/rc4/rc4-x86_64.asm\ 450 win-x86_64/crypto/sha/sha1-x86_64.asm\ 451 win-x86_64/crypto/sha/sha256-x86_64.asm\ 452 win-x86_64/crypto/sha/sha512-x86_64.asm\ 453 454