diff options
author | beck <> | 2023-07-07 13:54:46 +0000 |
---|---|---|
committer | beck <> | 2023-07-07 13:54:46 +0000 |
commit | 6bba0b0cef45b790c7a98a818e6018c91de8af0b (patch) | |
tree | 8637b2fb4bca234d55b598e035f23335be46ce49 | |
parent | fcdb286fc308a6ce5c66d8a4653f2e2e6c4903ed (diff) | |
download | openbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.tar.gz openbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.tar.bz2 openbsd-6bba0b0cef45b790c7a98a818e6018c91de8af0b.zip |
Hide symbols in hkdf, evp, err, ecdsa, and ec
(part 2 of commit)
ok jsing@
81 files changed, 1345 insertions, 80 deletions
diff --git a/src/lib/libcrypto/Symbols.namespace b/src/lib/libcrypto/Symbols.namespace index ff5c1f6bd6..c266ee0aab 100644 --- a/src/lib/libcrypto/Symbols.namespace +++ b/src/lib/libcrypto/Symbols.namespace | |||
@@ -1477,6 +1477,640 @@ _libre_TS_CONF_set_ordering | |||
1477 | _libre_TS_CONF_set_tsa_name | 1477 | _libre_TS_CONF_set_tsa_name |
1478 | _libre_TS_CONF_set_ess_cert_id_chain | 1478 | _libre_TS_CONF_set_ess_cert_id_chain |
1479 | _libre_ERR_load_TS_strings | 1479 | _libre_ERR_load_TS_strings |
1480 | _libre_HKDF | ||
1481 | _libre_HKDF_extract | ||
1482 | _libre_HKDF_expand | ||
1483 | _libre_EVP_MD_type | ||
1484 | _libre_EVP_MD_pkey_type | ||
1485 | _libre_EVP_MD_size | ||
1486 | _libre_EVP_MD_block_size | ||
1487 | _libre_EVP_MD_flags | ||
1488 | _libre_EVP_MD_meth_new | ||
1489 | _libre_EVP_MD_meth_free | ||
1490 | _libre_EVP_MD_meth_dup | ||
1491 | _libre_EVP_MD_meth_set_input_blocksize | ||
1492 | _libre_EVP_MD_meth_set_result_size | ||
1493 | _libre_EVP_MD_meth_set_app_datasize | ||
1494 | _libre_EVP_MD_meth_set_flags | ||
1495 | _libre_EVP_MD_meth_set_init | ||
1496 | _libre_EVP_MD_meth_set_update | ||
1497 | _libre_EVP_MD_meth_set_final | ||
1498 | _libre_EVP_MD_meth_set_copy | ||
1499 | _libre_EVP_MD_meth_set_cleanup | ||
1500 | _libre_EVP_MD_meth_set_ctrl | ||
1501 | _libre_EVP_MD_CTX_md | ||
1502 | _libre_EVP_MD_CTX_md_data | ||
1503 | _libre_EVP_MD_CTX_pkey_ctx | ||
1504 | _libre_EVP_MD_CTX_set_pkey_ctx | ||
1505 | _libre_EVP_CIPHER_nid | ||
1506 | _libre_EVP_CIPHER_block_size | ||
1507 | _libre_EVP_CIPHER_key_length | ||
1508 | _libre_EVP_CIPHER_iv_length | ||
1509 | _libre_EVP_CIPHER_flags | ||
1510 | _libre_EVP_CIPHER_CTX_cipher | ||
1511 | _libre_EVP_CIPHER_CTX_encrypting | ||
1512 | _libre_EVP_CIPHER_CTX_nid | ||
1513 | _libre_EVP_CIPHER_CTX_block_size | ||
1514 | _libre_EVP_CIPHER_CTX_key_length | ||
1515 | _libre_EVP_CIPHER_CTX_iv_length | ||
1516 | _libre_EVP_CIPHER_CTX_get_iv | ||
1517 | _libre_EVP_CIPHER_CTX_set_iv | ||
1518 | _libre_EVP_CIPHER_CTX_copy | ||
1519 | _libre_EVP_CIPHER_CTX_get_app_data | ||
1520 | _libre_EVP_CIPHER_CTX_set_app_data | ||
1521 | _libre_EVP_CIPHER_CTX_get_cipher_data | ||
1522 | _libre_EVP_CIPHER_CTX_set_cipher_data | ||
1523 | _libre_EVP_CIPHER_CTX_buf_noconst | ||
1524 | _libre_EVP_CIPHER_CTX_flags | ||
1525 | _libre_EVP_CIPHER_meth_new | ||
1526 | _libre_EVP_CIPHER_meth_dup | ||
1527 | _libre_EVP_CIPHER_meth_free | ||
1528 | _libre_EVP_CIPHER_meth_set_iv_length | ||
1529 | _libre_EVP_CIPHER_meth_set_flags | ||
1530 | _libre_EVP_CIPHER_meth_set_impl_ctx_size | ||
1531 | _libre_EVP_CIPHER_meth_set_init | ||
1532 | _libre_EVP_CIPHER_meth_set_do_cipher | ||
1533 | _libre_EVP_CIPHER_meth_set_cleanup | ||
1534 | _libre_EVP_CIPHER_meth_set_set_asn1_params | ||
1535 | _libre_EVP_CIPHER_meth_set_get_asn1_params | ||
1536 | _libre_EVP_CIPHER_meth_set_ctrl | ||
1537 | _libre_EVP_PKEY_new_raw_private_key | ||
1538 | _libre_EVP_PKEY_new_raw_public_key | ||
1539 | _libre_EVP_PKEY_get_raw_private_key | ||
1540 | _libre_EVP_PKEY_get_raw_public_key | ||
1541 | _libre_EVP_Cipher | ||
1542 | _libre_EVP_MD_CTX_new | ||
1543 | _libre_EVP_MD_CTX_free | ||
1544 | _libre_EVP_MD_CTX_init | ||
1545 | _libre_EVP_MD_CTX_reset | ||
1546 | _libre_EVP_MD_CTX_create | ||
1547 | _libre_EVP_MD_CTX_destroy | ||
1548 | _libre_EVP_MD_CTX_cleanup | ||
1549 | _libre_EVP_MD_CTX_copy_ex | ||
1550 | _libre_EVP_MD_CTX_set_flags | ||
1551 | _libre_EVP_MD_CTX_clear_flags | ||
1552 | _libre_EVP_MD_CTX_ctrl | ||
1553 | _libre_EVP_MD_CTX_test_flags | ||
1554 | _libre_EVP_DigestInit_ex | ||
1555 | _libre_EVP_DigestUpdate | ||
1556 | _libre_EVP_DigestFinal_ex | ||
1557 | _libre_EVP_Digest | ||
1558 | _libre_EVP_MD_CTX_copy | ||
1559 | _libre_EVP_DigestInit | ||
1560 | _libre_EVP_DigestFinal | ||
1561 | _libre_EVP_read_pw_string | ||
1562 | _libre_EVP_read_pw_string_min | ||
1563 | _libre_EVP_set_pw_prompt | ||
1564 | _libre_EVP_get_pw_prompt | ||
1565 | _libre_EVP_BytesToKey | ||
1566 | _libre_EVP_CIPHER_CTX_set_flags | ||
1567 | _libre_EVP_CIPHER_CTX_clear_flags | ||
1568 | _libre_EVP_CIPHER_CTX_test_flags | ||
1569 | _libre_EVP_EncryptInit | ||
1570 | _libre_EVP_EncryptInit_ex | ||
1571 | _libre_EVP_EncryptUpdate | ||
1572 | _libre_EVP_EncryptFinal_ex | ||
1573 | _libre_EVP_EncryptFinal | ||
1574 | _libre_EVP_DecryptInit | ||
1575 | _libre_EVP_DecryptInit_ex | ||
1576 | _libre_EVP_DecryptUpdate | ||
1577 | _libre_EVP_DecryptFinal_ex | ||
1578 | _libre_EVP_DecryptFinal | ||
1579 | _libre_EVP_CipherInit | ||
1580 | _libre_EVP_CipherInit_ex | ||
1581 | _libre_EVP_CipherUpdate | ||
1582 | _libre_EVP_CipherFinal_ex | ||
1583 | _libre_EVP_CipherFinal | ||
1584 | _libre_EVP_SignFinal | ||
1585 | _libre_EVP_VerifyFinal | ||
1586 | _libre_EVP_DigestSignInit | ||
1587 | _libre_EVP_DigestSignFinal | ||
1588 | _libre_EVP_DigestSign | ||
1589 | _libre_EVP_DigestVerifyInit | ||
1590 | _libre_EVP_DigestVerifyFinal | ||
1591 | _libre_EVP_DigestVerify | ||
1592 | _libre_EVP_OpenInit | ||
1593 | _libre_EVP_OpenFinal | ||
1594 | _libre_EVP_SealInit | ||
1595 | _libre_EVP_SealFinal | ||
1596 | _libre_EVP_ENCODE_CTX_new | ||
1597 | _libre_EVP_ENCODE_CTX_free | ||
1598 | _libre_EVP_EncodeInit | ||
1599 | _libre_EVP_EncodeUpdate | ||
1600 | _libre_EVP_EncodeFinal | ||
1601 | _libre_EVP_EncodeBlock | ||
1602 | _libre_EVP_DecodeInit | ||
1603 | _libre_EVP_DecodeUpdate | ||
1604 | _libre_EVP_DecodeFinal | ||
1605 | _libre_EVP_DecodeBlock | ||
1606 | _libre_EVP_CIPHER_CTX_init | ||
1607 | _libre_EVP_CIPHER_CTX_cleanup | ||
1608 | _libre_EVP_CIPHER_CTX_new | ||
1609 | _libre_EVP_CIPHER_CTX_free | ||
1610 | _libre_EVP_CIPHER_CTX_reset | ||
1611 | _libre_EVP_CIPHER_CTX_set_key_length | ||
1612 | _libre_EVP_CIPHER_CTX_set_padding | ||
1613 | _libre_EVP_CIPHER_CTX_ctrl | ||
1614 | _libre_EVP_CIPHER_CTX_rand_key | ||
1615 | _libre_BIO_f_md | ||
1616 | _libre_BIO_f_base64 | ||
1617 | _libre_BIO_f_cipher | ||
1618 | _libre_BIO_set_cipher | ||
1619 | _libre_EVP_md_null | ||
1620 | _libre_EVP_md4 | ||
1621 | _libre_EVP_md5 | ||
1622 | _libre_EVP_md5_sha1 | ||
1623 | _libre_EVP_sha1 | ||
1624 | _libre_EVP_sha224 | ||
1625 | _libre_EVP_sha256 | ||
1626 | _libre_EVP_sha384 | ||
1627 | _libre_EVP_sha512 | ||
1628 | _libre_EVP_sha512_224 | ||
1629 | _libre_EVP_sha512_256 | ||
1630 | _libre_EVP_sha3_224 | ||
1631 | _libre_EVP_sha3_256 | ||
1632 | _libre_EVP_sha3_384 | ||
1633 | _libre_EVP_sha3_512 | ||
1634 | _libre_EVP_sm3 | ||
1635 | _libre_EVP_ripemd160 | ||
1636 | _libre_EVP_whirlpool | ||
1637 | _libre_EVP_gostr341194 | ||
1638 | _libre_EVP_gost2814789imit | ||
1639 | _libre_EVP_streebog256 | ||
1640 | _libre_EVP_streebog512 | ||
1641 | _libre_EVP_enc_null | ||
1642 | _libre_EVP_des_ecb | ||
1643 | _libre_EVP_des_ede | ||
1644 | _libre_EVP_des_ede3 | ||
1645 | _libre_EVP_des_ede_ecb | ||
1646 | _libre_EVP_des_ede3_ecb | ||
1647 | _libre_EVP_des_cfb64 | ||
1648 | _libre_EVP_des_cfb1 | ||
1649 | _libre_EVP_des_cfb8 | ||
1650 | _libre_EVP_des_ede_cfb64 | ||
1651 | _libre_EVP_des_ede3_cfb64 | ||
1652 | _libre_EVP_des_ede3_cfb1 | ||
1653 | _libre_EVP_des_ede3_cfb8 | ||
1654 | _libre_EVP_des_ofb | ||
1655 | _libre_EVP_des_ede_ofb | ||
1656 | _libre_EVP_des_ede3_ofb | ||
1657 | _libre_EVP_des_cbc | ||
1658 | _libre_EVP_des_ede_cbc | ||
1659 | _libre_EVP_des_ede3_cbc | ||
1660 | _libre_EVP_desx_cbc | ||
1661 | _libre_EVP_rc4 | ||
1662 | _libre_EVP_rc4_40 | ||
1663 | _libre_EVP_rc4_hmac_md5 | ||
1664 | _libre_EVP_idea_ecb | ||
1665 | _libre_EVP_idea_cfb64 | ||
1666 | _libre_EVP_idea_ofb | ||
1667 | _libre_EVP_idea_cbc | ||
1668 | _libre_EVP_rc2_ecb | ||
1669 | _libre_EVP_rc2_cbc | ||
1670 | _libre_EVP_rc2_40_cbc | ||
1671 | _libre_EVP_rc2_64_cbc | ||
1672 | _libre_EVP_rc2_cfb64 | ||
1673 | _libre_EVP_rc2_ofb | ||
1674 | _libre_EVP_bf_ecb | ||
1675 | _libre_EVP_bf_cbc | ||
1676 | _libre_EVP_bf_cfb64 | ||
1677 | _libre_EVP_bf_ofb | ||
1678 | _libre_EVP_cast5_ecb | ||
1679 | _libre_EVP_cast5_cbc | ||
1680 | _libre_EVP_cast5_cfb64 | ||
1681 | _libre_EVP_cast5_ofb | ||
1682 | _libre_EVP_aes_128_ecb | ||
1683 | _libre_EVP_aes_128_cbc | ||
1684 | _libre_EVP_aes_128_cfb1 | ||
1685 | _libre_EVP_aes_128_cfb8 | ||
1686 | _libre_EVP_aes_128_cfb128 | ||
1687 | _libre_EVP_aes_128_ofb | ||
1688 | _libre_EVP_aes_128_ctr | ||
1689 | _libre_EVP_aes_128_ccm | ||
1690 | _libre_EVP_aes_128_gcm | ||
1691 | _libre_EVP_aes_128_wrap | ||
1692 | _libre_EVP_aes_128_xts | ||
1693 | _libre_EVP_aes_192_ecb | ||
1694 | _libre_EVP_aes_192_cbc | ||
1695 | _libre_EVP_aes_192_cfb1 | ||
1696 | _libre_EVP_aes_192_cfb8 | ||
1697 | _libre_EVP_aes_192_cfb128 | ||
1698 | _libre_EVP_aes_192_ofb | ||
1699 | _libre_EVP_aes_192_ctr | ||
1700 | _libre_EVP_aes_192_ccm | ||
1701 | _libre_EVP_aes_192_gcm | ||
1702 | _libre_EVP_aes_192_wrap | ||
1703 | _libre_EVP_aes_256_ecb | ||
1704 | _libre_EVP_aes_256_cbc | ||
1705 | _libre_EVP_aes_256_cfb1 | ||
1706 | _libre_EVP_aes_256_cfb8 | ||
1707 | _libre_EVP_aes_256_cfb128 | ||
1708 | _libre_EVP_aes_256_ofb | ||
1709 | _libre_EVP_aes_256_ctr | ||
1710 | _libre_EVP_aes_256_ccm | ||
1711 | _libre_EVP_aes_256_gcm | ||
1712 | _libre_EVP_aes_256_wrap | ||
1713 | _libre_EVP_aes_256_xts | ||
1714 | _libre_EVP_chacha20_poly1305 | ||
1715 | _libre_EVP_aes_128_cbc_hmac_sha1 | ||
1716 | _libre_EVP_aes_256_cbc_hmac_sha1 | ||
1717 | _libre_EVP_camellia_128_ecb | ||
1718 | _libre_EVP_camellia_128_cbc | ||
1719 | _libre_EVP_camellia_128_cfb1 | ||
1720 | _libre_EVP_camellia_128_cfb8 | ||
1721 | _libre_EVP_camellia_128_cfb128 | ||
1722 | _libre_EVP_camellia_128_ofb | ||
1723 | _libre_EVP_camellia_192_ecb | ||
1724 | _libre_EVP_camellia_192_cbc | ||
1725 | _libre_EVP_camellia_192_cfb1 | ||
1726 | _libre_EVP_camellia_192_cfb8 | ||
1727 | _libre_EVP_camellia_192_cfb128 | ||
1728 | _libre_EVP_camellia_192_ofb | ||
1729 | _libre_EVP_camellia_256_ecb | ||
1730 | _libre_EVP_camellia_256_cbc | ||
1731 | _libre_EVP_camellia_256_cfb1 | ||
1732 | _libre_EVP_camellia_256_cfb8 | ||
1733 | _libre_EVP_camellia_256_cfb128 | ||
1734 | _libre_EVP_camellia_256_ofb | ||
1735 | _libre_EVP_chacha20 | ||
1736 | _libre_EVP_gost2814789_ecb | ||
1737 | _libre_EVP_gost2814789_cfb64 | ||
1738 | _libre_EVP_gost2814789_cnt | ||
1739 | _libre_EVP_sm4_ecb | ||
1740 | _libre_EVP_sm4_cbc | ||
1741 | _libre_EVP_sm4_cfb128 | ||
1742 | _libre_EVP_sm4_ofb | ||
1743 | _libre_EVP_sm4_ctr | ||
1744 | _libre_OPENSSL_add_all_algorithms_noconf | ||
1745 | _libre_OPENSSL_add_all_algorithms_conf | ||
1746 | _libre_OpenSSL_add_all_ciphers | ||
1747 | _libre_OpenSSL_add_all_digests | ||
1748 | _libre_EVP_add_cipher | ||
1749 | _libre_EVP_add_digest | ||
1750 | _libre_EVP_get_cipherbyname | ||
1751 | _libre_EVP_get_digestbyname | ||
1752 | _libre_EVP_cleanup | ||
1753 | _libre_EVP_CIPHER_do_all | ||
1754 | _libre_EVP_CIPHER_do_all_sorted | ||
1755 | _libre_EVP_MD_do_all | ||
1756 | _libre_EVP_MD_do_all_sorted | ||
1757 | _libre_EVP_PKEY_decrypt_old | ||
1758 | _libre_EVP_PKEY_encrypt_old | ||
1759 | _libre_EVP_PKEY_type | ||
1760 | _libre_EVP_PKEY_id | ||
1761 | _libre_EVP_PKEY_base_id | ||
1762 | _libre_EVP_PKEY_bits | ||
1763 | _libre_EVP_PKEY_security_bits | ||
1764 | _libre_EVP_PKEY_size | ||
1765 | _libre_EVP_PKEY_set_type | ||
1766 | _libre_EVP_PKEY_set_type_str | ||
1767 | _libre_EVP_PKEY_assign | ||
1768 | _libre_EVP_PKEY_get0 | ||
1769 | _libre_EVP_PKEY_get0_hmac | ||
1770 | _libre_EVP_PKEY_get0_RSA | ||
1771 | _libre_EVP_PKEY_get1_RSA | ||
1772 | _libre_EVP_PKEY_set1_RSA | ||
1773 | _libre_EVP_PKEY_get0_DSA | ||
1774 | _libre_EVP_PKEY_get1_DSA | ||
1775 | _libre_EVP_PKEY_set1_DSA | ||
1776 | _libre_EVP_PKEY_get0_DH | ||
1777 | _libre_EVP_PKEY_get1_DH | ||
1778 | _libre_EVP_PKEY_set1_DH | ||
1779 | _libre_EVP_PKEY_get0_EC_KEY | ||
1780 | _libre_EVP_PKEY_get1_EC_KEY | ||
1781 | _libre_EVP_PKEY_set1_EC_KEY | ||
1782 | _libre_EVP_PKEY_new | ||
1783 | _libre_EVP_PKEY_free | ||
1784 | _libre_EVP_PKEY_up_ref | ||
1785 | _libre_d2i_PublicKey | ||
1786 | _libre_i2d_PublicKey | ||
1787 | _libre_d2i_PrivateKey | ||
1788 | _libre_d2i_AutoPrivateKey | ||
1789 | _libre_i2d_PrivateKey | ||
1790 | _libre_EVP_PKEY_copy_parameters | ||
1791 | _libre_EVP_PKEY_missing_parameters | ||
1792 | _libre_EVP_PKEY_save_parameters | ||
1793 | _libre_EVP_PKEY_cmp_parameters | ||
1794 | _libre_EVP_PKEY_cmp | ||
1795 | _libre_EVP_PKEY_print_public | ||
1796 | _libre_EVP_PKEY_print_private | ||
1797 | _libre_EVP_PKEY_print_params | ||
1798 | _libre_EVP_PKEY_get_default_digest_nid | ||
1799 | _libre_EVP_CIPHER_type | ||
1800 | _libre_EVP_CIPHER_param_to_asn1 | ||
1801 | _libre_EVP_CIPHER_asn1_to_param | ||
1802 | _libre_EVP_CIPHER_set_asn1_iv | ||
1803 | _libre_EVP_CIPHER_get_asn1_iv | ||
1804 | _libre_PKCS5_PBE_keyivgen | ||
1805 | _libre_PKCS5_PBKDF2_HMAC_SHA1 | ||
1806 | _libre_PKCS5_PBKDF2_HMAC | ||
1807 | _libre_PKCS5_v2_PBE_keyivgen | ||
1808 | _libre_PKCS5_PBE_add | ||
1809 | _libre_EVP_PBE_CipherInit | ||
1810 | _libre_EVP_PBE_alg_add_type | ||
1811 | _libre_EVP_PBE_alg_add | ||
1812 | _libre_EVP_PBE_find | ||
1813 | _libre_EVP_PBE_cleanup | ||
1814 | _libre_EVP_PKEY_asn1_get_count | ||
1815 | _libre_EVP_PKEY_asn1_get0 | ||
1816 | _libre_EVP_PKEY_asn1_find | ||
1817 | _libre_EVP_PKEY_asn1_find_str | ||
1818 | _libre_EVP_PKEY_asn1_add0 | ||
1819 | _libre_EVP_PKEY_asn1_add_alias | ||
1820 | _libre_EVP_PKEY_asn1_get0_info | ||
1821 | _libre_EVP_PKEY_get0_asn1 | ||
1822 | _libre_EVP_PKEY_asn1_new | ||
1823 | _libre_EVP_PKEY_asn1_copy | ||
1824 | _libre_EVP_PKEY_asn1_free | ||
1825 | _libre_EVP_PKEY_asn1_set_public | ||
1826 | _libre_EVP_PKEY_asn1_set_private | ||
1827 | _libre_EVP_PKEY_asn1_set_param | ||
1828 | _libre_EVP_PKEY_asn1_set_free | ||
1829 | _libre_EVP_PKEY_asn1_set_ctrl | ||
1830 | _libre_EVP_PKEY_asn1_set_security_bits | ||
1831 | _libre_EVP_PKEY_asn1_set_check | ||
1832 | _libre_EVP_PKEY_asn1_set_public_check | ||
1833 | _libre_EVP_PKEY_asn1_set_param_check | ||
1834 | _libre_EVP_PKEY_meth_find | ||
1835 | _libre_EVP_PKEY_meth_new | ||
1836 | _libre_EVP_PKEY_meth_get0_info | ||
1837 | _libre_EVP_PKEY_meth_copy | ||
1838 | _libre_EVP_PKEY_meth_free | ||
1839 | _libre_EVP_PKEY_meth_add0 | ||
1840 | _libre_EVP_PKEY_CTX_new | ||
1841 | _libre_EVP_PKEY_CTX_new_id | ||
1842 | _libre_EVP_PKEY_CTX_dup | ||
1843 | _libre_EVP_PKEY_CTX_free | ||
1844 | _libre_EVP_PKEY_CTX_ctrl | ||
1845 | _libre_EVP_PKEY_CTX_ctrl_str | ||
1846 | _libre_EVP_PKEY_CTX_get_operation | ||
1847 | _libre_EVP_PKEY_CTX_set0_keygen_info | ||
1848 | _libre_EVP_PKEY_new_mac_key | ||
1849 | _libre_EVP_PKEY_new_CMAC_key | ||
1850 | _libre_EVP_PKEY_CTX_set_data | ||
1851 | _libre_EVP_PKEY_CTX_get_data | ||
1852 | _libre_EVP_PKEY_CTX_get0_pkey | ||
1853 | _libre_EVP_PKEY_CTX_get0_peerkey | ||
1854 | _libre_EVP_PKEY_CTX_set_app_data | ||
1855 | _libre_EVP_PKEY_CTX_get_app_data | ||
1856 | _libre_EVP_PKEY_sign_init | ||
1857 | _libre_EVP_PKEY_sign | ||
1858 | _libre_EVP_PKEY_verify_init | ||
1859 | _libre_EVP_PKEY_verify | ||
1860 | _libre_EVP_PKEY_verify_recover_init | ||
1861 | _libre_EVP_PKEY_verify_recover | ||
1862 | _libre_EVP_PKEY_encrypt_init | ||
1863 | _libre_EVP_PKEY_encrypt | ||
1864 | _libre_EVP_PKEY_decrypt_init | ||
1865 | _libre_EVP_PKEY_decrypt | ||
1866 | _libre_EVP_PKEY_derive_init | ||
1867 | _libre_EVP_PKEY_derive_set_peer | ||
1868 | _libre_EVP_PKEY_derive | ||
1869 | _libre_EVP_PKEY_paramgen_init | ||
1870 | _libre_EVP_PKEY_paramgen | ||
1871 | _libre_EVP_PKEY_keygen_init | ||
1872 | _libre_EVP_PKEY_keygen | ||
1873 | _libre_EVP_PKEY_check | ||
1874 | _libre_EVP_PKEY_public_check | ||
1875 | _libre_EVP_PKEY_param_check | ||
1876 | _libre_EVP_PKEY_CTX_set_cb | ||
1877 | _libre_EVP_PKEY_CTX_get_cb | ||
1878 | _libre_EVP_PKEY_CTX_get_keygen_info | ||
1879 | _libre_EVP_PKEY_meth_set_init | ||
1880 | _libre_EVP_PKEY_meth_set_copy | ||
1881 | _libre_EVP_PKEY_meth_set_cleanup | ||
1882 | _libre_EVP_PKEY_meth_set_paramgen | ||
1883 | _libre_EVP_PKEY_meth_set_keygen | ||
1884 | _libre_EVP_PKEY_meth_set_sign | ||
1885 | _libre_EVP_PKEY_meth_set_verify | ||
1886 | _libre_EVP_PKEY_meth_set_verify_recover | ||
1887 | _libre_EVP_PKEY_meth_set_signctx | ||
1888 | _libre_EVP_PKEY_meth_set_verifyctx | ||
1889 | _libre_EVP_PKEY_meth_set_encrypt | ||
1890 | _libre_EVP_PKEY_meth_set_decrypt | ||
1891 | _libre_EVP_PKEY_meth_set_derive | ||
1892 | _libre_EVP_PKEY_meth_set_ctrl | ||
1893 | _libre_EVP_PKEY_meth_set_check | ||
1894 | _libre_EVP_PKEY_meth_set_public_check | ||
1895 | _libre_EVP_PKEY_meth_set_param_check | ||
1896 | _libre_EVP_aead_aes_128_gcm | ||
1897 | _libre_EVP_aead_aes_256_gcm | ||
1898 | _libre_EVP_aead_chacha20_poly1305 | ||
1899 | _libre_EVP_aead_xchacha20_poly1305 | ||
1900 | _libre_EVP_AEAD_key_length | ||
1901 | _libre_EVP_AEAD_nonce_length | ||
1902 | _libre_EVP_AEAD_max_overhead | ||
1903 | _libre_EVP_AEAD_max_tag_len | ||
1904 | _libre_EVP_AEAD_CTX_new | ||
1905 | _libre_EVP_AEAD_CTX_free | ||
1906 | _libre_EVP_AEAD_CTX_init | ||
1907 | _libre_EVP_AEAD_CTX_cleanup | ||
1908 | _libre_EVP_AEAD_CTX_seal | ||
1909 | _libre_EVP_AEAD_CTX_open | ||
1910 | _libre_ERR_load_EVP_strings | ||
1911 | _libre_ERR_put_error | ||
1912 | _libre_ERR_set_error_data | ||
1913 | _libre_ERR_get_error | ||
1914 | _libre_ERR_get_error_line | ||
1915 | _libre_ERR_get_error_line_data | ||
1916 | _libre_ERR_peek_error | ||
1917 | _libre_ERR_peek_error_line | ||
1918 | _libre_ERR_peek_error_line_data | ||
1919 | _libre_ERR_peek_last_error | ||
1920 | _libre_ERR_peek_last_error_line | ||
1921 | _libre_ERR_peek_last_error_line_data | ||
1922 | _libre_ERR_clear_error | ||
1923 | _libre_ERR_error_string | ||
1924 | _libre_ERR_error_string_n | ||
1925 | _libre_ERR_lib_error_string | ||
1926 | _libre_ERR_func_error_string | ||
1927 | _libre_ERR_reason_error_string | ||
1928 | _libre_ERR_print_errors_cb | ||
1929 | _libre_ERR_print_errors_fp | ||
1930 | _libre_ERR_print_errors | ||
1931 | _libre_ERR_asprintf_error_data | ||
1932 | _libre_ERR_add_error_data | ||
1933 | _libre_ERR_add_error_vdata | ||
1934 | _libre_ERR_load_strings | ||
1935 | _libre_ERR_unload_strings | ||
1936 | _libre_ERR_load_ERR_strings | ||
1937 | _libre_ERR_load_crypto_strings | ||
1938 | _libre_ERR_free_strings | ||
1939 | _libre_ERR_remove_thread_state | ||
1940 | _libre_ERR_remove_state | ||
1941 | _libre_ERR_get_state | ||
1942 | _libre_ERR_get_string_table | ||
1943 | _libre_ERR_get_err_state_table | ||
1944 | _libre_ERR_release_err_state_table | ||
1945 | _libre_ERR_get_next_error_library | ||
1946 | _libre_ERR_set_mark | ||
1947 | _libre_ERR_pop_to_mark | ||
1948 | _libre_ERR_get_implementation | ||
1949 | _libre_ERR_set_implementation | ||
1950 | _libre_ECDSA_SIG_new | ||
1951 | _libre_ECDSA_SIG_free | ||
1952 | _libre_i2d_ECDSA_SIG | ||
1953 | _libre_d2i_ECDSA_SIG | ||
1954 | _libre_ECDSA_SIG_get0 | ||
1955 | _libre_ECDSA_SIG_get0_r | ||
1956 | _libre_ECDSA_SIG_get0_s | ||
1957 | _libre_ECDSA_SIG_set0 | ||
1958 | _libre_ECDSA_do_sign | ||
1959 | _libre_ECDSA_do_sign_ex | ||
1960 | _libre_ECDSA_do_verify | ||
1961 | _libre_ECDSA_OpenSSL | ||
1962 | _libre_ECDSA_set_default_method | ||
1963 | _libre_ECDSA_get_default_method | ||
1964 | _libre_ECDSA_set_method | ||
1965 | _libre_ECDSA_size | ||
1966 | _libre_ECDSA_sign_setup | ||
1967 | _libre_ECDSA_sign | ||
1968 | _libre_ECDSA_sign_ex | ||
1969 | _libre_ECDSA_verify | ||
1970 | _libre_ECDSA_get_ex_new_index | ||
1971 | _libre_ECDSA_set_ex_data | ||
1972 | _libre_ECDSA_get_ex_data | ||
1973 | _libre_EC_KEY_METHOD_set_sign | ||
1974 | _libre_EC_KEY_METHOD_set_verify | ||
1975 | _libre_EC_KEY_METHOD_get_sign | ||
1976 | _libre_EC_KEY_METHOD_get_verify | ||
1977 | _libre_ERR_load_ECDSA_strings | ||
1978 | _libre_ECDH_OpenSSL | ||
1979 | _libre_ECDH_set_default_method | ||
1980 | _libre_ECDH_get_default_method | ||
1981 | _libre_ECDH_set_method | ||
1982 | _libre_ECDH_size | ||
1983 | _libre_ECDH_compute_key | ||
1984 | _libre_ECDH_get_ex_new_index | ||
1985 | _libre_ECDH_set_ex_data | ||
1986 | _libre_ECDH_get_ex_data | ||
1987 | _libre_ERR_load_ECDH_strings | ||
1988 | _libre_EC_GFp_simple_method | ||
1989 | _libre_EC_GFp_mont_method | ||
1990 | _libre_EC_GROUP_new | ||
1991 | _libre_EC_GROUP_free | ||
1992 | _libre_EC_GROUP_clear_free | ||
1993 | _libre_EC_GROUP_copy | ||
1994 | _libre_EC_GROUP_dup | ||
1995 | _libre_EC_GROUP_method_of | ||
1996 | _libre_EC_METHOD_get_field_type | ||
1997 | _libre_EC_GROUP_set_generator | ||
1998 | _libre_EC_GROUP_get0_generator | ||
1999 | _libre_EC_GROUP_get_order | ||
2000 | _libre_EC_GROUP_order_bits | ||
2001 | _libre_EC_GROUP_get_cofactor | ||
2002 | _libre_EC_GROUP_set_curve_name | ||
2003 | _libre_EC_GROUP_get_curve_name | ||
2004 | _libre_EC_GROUP_set_asn1_flag | ||
2005 | _libre_EC_GROUP_get_asn1_flag | ||
2006 | _libre_EC_GROUP_set_point_conversion_form | ||
2007 | _libre_EC_GROUP_get_point_conversion_form | ||
2008 | _libre_EC_GROUP_get0_seed | ||
2009 | _libre_EC_GROUP_get_seed_len | ||
2010 | _libre_EC_GROUP_set_seed | ||
2011 | _libre_EC_GROUP_set_curve | ||
2012 | _libre_EC_GROUP_get_curve | ||
2013 | _libre_EC_GROUP_set_curve_GFp | ||
2014 | _libre_EC_GROUP_get_curve_GFp | ||
2015 | _libre_EC_GROUP_get_degree | ||
2016 | _libre_EC_GROUP_check | ||
2017 | _libre_EC_GROUP_check_discriminant | ||
2018 | _libre_EC_GROUP_cmp | ||
2019 | _libre_EC_GROUP_new_curve_GFp | ||
2020 | _libre_EC_GROUP_new_by_curve_name | ||
2021 | _libre_EC_get_builtin_curves | ||
2022 | _libre_EC_curve_nid2nist | ||
2023 | _libre_EC_curve_nist2nid | ||
2024 | _libre_EC_POINT_new | ||
2025 | _libre_EC_POINT_free | ||
2026 | _libre_EC_POINT_clear_free | ||
2027 | _libre_EC_POINT_copy | ||
2028 | _libre_EC_POINT_dup | ||
2029 | _libre_EC_POINT_method_of | ||
2030 | _libre_EC_POINT_set_to_infinity | ||
2031 | _libre_EC_POINT_set_affine_coordinates | ||
2032 | _libre_EC_POINT_get_affine_coordinates | ||
2033 | _libre_EC_POINT_set_compressed_coordinates | ||
2034 | _libre_EC_POINT_set_Jprojective_coordinates_GFp | ||
2035 | _libre_EC_POINT_get_Jprojective_coordinates_GFp | ||
2036 | _libre_EC_POINT_set_affine_coordinates_GFp | ||
2037 | _libre_EC_POINT_get_affine_coordinates_GFp | ||
2038 | _libre_EC_POINT_set_compressed_coordinates_GFp | ||
2039 | _libre_EC_POINT_point2oct | ||
2040 | _libre_EC_POINT_oct2point | ||
2041 | _libre_EC_POINT_point2bn | ||
2042 | _libre_EC_POINT_bn2point | ||
2043 | _libre_EC_POINT_point2hex | ||
2044 | _libre_EC_POINT_hex2point | ||
2045 | _libre_EC_POINT_add | ||
2046 | _libre_EC_POINT_dbl | ||
2047 | _libre_EC_POINT_invert | ||
2048 | _libre_EC_POINT_is_at_infinity | ||
2049 | _libre_EC_POINT_is_on_curve | ||
2050 | _libre_EC_POINT_cmp | ||
2051 | _libre_EC_POINT_make_affine | ||
2052 | _libre_EC_POINTs_make_affine | ||
2053 | _libre_EC_POINTs_mul | ||
2054 | _libre_EC_POINT_mul | ||
2055 | _libre_EC_GROUP_precompute_mult | ||
2056 | _libre_EC_GROUP_have_precompute_mult | ||
2057 | _libre_EC_GROUP_get_basis_type | ||
2058 | _libre_d2i_ECPKParameters | ||
2059 | _libre_i2d_ECPKParameters | ||
2060 | _libre_ECPKParameters_print | ||
2061 | _libre_ECPKParameters_print_fp | ||
2062 | _libre_EC_KEY_new | ||
2063 | _libre_EC_KEY_get_flags | ||
2064 | _libre_EC_KEY_set_flags | ||
2065 | _libre_EC_KEY_clear_flags | ||
2066 | _libre_EC_KEY_new_by_curve_name | ||
2067 | _libre_EC_KEY_free | ||
2068 | _libre_EC_KEY_copy | ||
2069 | _libre_EC_KEY_dup | ||
2070 | _libre_EC_KEY_up_ref | ||
2071 | _libre_EC_KEY_get0_group | ||
2072 | _libre_EC_KEY_set_group | ||
2073 | _libre_EC_KEY_get0_private_key | ||
2074 | _libre_EC_KEY_set_private_key | ||
2075 | _libre_EC_KEY_get0_public_key | ||
2076 | _libre_EC_KEY_set_public_key | ||
2077 | _libre_EC_KEY_get_enc_flags | ||
2078 | _libre_EC_KEY_set_enc_flags | ||
2079 | _libre_EC_KEY_get_conv_form | ||
2080 | _libre_EC_KEY_set_conv_form | ||
2081 | _libre_EC_KEY_set_asn1_flag | ||
2082 | _libre_EC_KEY_precompute_mult | ||
2083 | _libre_EC_KEY_generate_key | ||
2084 | _libre_EC_KEY_check_key | ||
2085 | _libre_EC_KEY_set_public_key_affine_coordinates | ||
2086 | _libre_d2i_ECPrivateKey | ||
2087 | _libre_i2d_ECPrivateKey | ||
2088 | _libre_d2i_ECParameters | ||
2089 | _libre_i2d_ECParameters | ||
2090 | _libre_o2i_ECPublicKey | ||
2091 | _libre_i2o_ECPublicKey | ||
2092 | _libre_ECParameters_print | ||
2093 | _libre_EC_KEY_print | ||
2094 | _libre_ECParameters_print_fp | ||
2095 | _libre_EC_KEY_print_fp | ||
2096 | _libre_EC_KEY_set_ex_data | ||
2097 | _libre_EC_KEY_get_ex_data | ||
2098 | _libre_EC_KEY_OpenSSL | ||
2099 | _libre_EC_KEY_get_default_method | ||
2100 | _libre_EC_KEY_set_default_method | ||
2101 | _libre_EC_KEY_get_method | ||
2102 | _libre_EC_KEY_set_method | ||
2103 | _libre_EC_KEY_new_method | ||
2104 | _libre_EC_KEY_METHOD_new | ||
2105 | _libre_EC_KEY_METHOD_free | ||
2106 | _libre_EC_KEY_METHOD_set_init | ||
2107 | _libre_EC_KEY_METHOD_set_keygen | ||
2108 | _libre_EC_KEY_METHOD_set_compute_key | ||
2109 | _libre_EC_KEY_METHOD_get_init | ||
2110 | _libre_EC_KEY_METHOD_get_keygen | ||
2111 | _libre_EC_KEY_METHOD_get_compute_key | ||
2112 | _libre_ECParameters_dup | ||
2113 | _libre_ERR_load_EC_strings | ||
1480 | _libre_RC2_set_key | 2114 | _libre_RC2_set_key |
1481 | _libre_RC2_ecb_encrypt | 2115 | _libre_RC2_ecb_encrypt |
1482 | _libre_RC2_encrypt | 2116 | _libre_RC2_encrypt |
diff --git a/src/lib/libcrypto/ec/ec_asn1.c b/src/lib/libcrypto/ec/ec_asn1.c index 6aedab9774..0435f0a75f 100644 --- a/src/lib/libcrypto/ec/ec_asn1.c +++ b/src/lib/libcrypto/ec/ec_asn1.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_asn1.c,v 1.46 2023/06/27 07:28:57 tb Exp $ */ | 1 | /* $OpenBSD: ec_asn1.c,v 1.47 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -72,6 +72,7 @@ EC_GROUP_get_basis_type(const EC_GROUP *group) | |||
72 | { | 72 | { |
73 | return 0; | 73 | return 0; |
74 | } | 74 | } |
75 | LCRYPTO_ALIAS(EC_GROUP_get_basis_type); | ||
75 | 76 | ||
76 | /* some structures needed for the asn1 encoding */ | 77 | /* some structures needed for the asn1 encoding */ |
77 | typedef struct x9_62_pentanomial_st { | 78 | typedef struct x9_62_pentanomial_st { |
@@ -184,12 +185,14 @@ X9_62_PENTANOMIAL_new(void) | |||
184 | { | 185 | { |
185 | return (X9_62_PENTANOMIAL*)ASN1_item_new(&X9_62_PENTANOMIAL_it); | 186 | return (X9_62_PENTANOMIAL*)ASN1_item_new(&X9_62_PENTANOMIAL_it); |
186 | } | 187 | } |
188 | LCRYPTO_ALIAS(X9_62_PENTANOMIAL_new); | ||
187 | 189 | ||
188 | void | 190 | void |
189 | X9_62_PENTANOMIAL_free(X9_62_PENTANOMIAL *a) | 191 | X9_62_PENTANOMIAL_free(X9_62_PENTANOMIAL *a) |
190 | { | 192 | { |
191 | ASN1_item_free((ASN1_VALUE *)a, &X9_62_PENTANOMIAL_it); | 193 | ASN1_item_free((ASN1_VALUE *)a, &X9_62_PENTANOMIAL_it); |
192 | } | 194 | } |
195 | LCRYPTO_ALIAS(X9_62_PENTANOMIAL_free); | ||
193 | 196 | ||
194 | static const ASN1_TEMPLATE char_two_def_tt = { | 197 | static const ASN1_TEMPLATE char_two_def_tt = { |
195 | .flags = 0, | 198 | .flags = 0, |
@@ -284,12 +287,14 @@ X9_62_CHARACTERISTIC_TWO_new(void) | |||
284 | { | 287 | { |
285 | return (X9_62_CHARACTERISTIC_TWO*)ASN1_item_new(&X9_62_CHARACTERISTIC_TWO_it); | 288 | return (X9_62_CHARACTERISTIC_TWO*)ASN1_item_new(&X9_62_CHARACTERISTIC_TWO_it); |
286 | } | 289 | } |
290 | LCRYPTO_ALIAS(X9_62_CHARACTERISTIC_TWO_new); | ||
287 | 291 | ||
288 | void | 292 | void |
289 | X9_62_CHARACTERISTIC_TWO_free(X9_62_CHARACTERISTIC_TWO *a) | 293 | X9_62_CHARACTERISTIC_TWO_free(X9_62_CHARACTERISTIC_TWO *a) |
290 | { | 294 | { |
291 | ASN1_item_free((ASN1_VALUE *)a, &X9_62_CHARACTERISTIC_TWO_it); | 295 | ASN1_item_free((ASN1_VALUE *)a, &X9_62_CHARACTERISTIC_TWO_it); |
292 | } | 296 | } |
297 | LCRYPTO_ALIAS(X9_62_CHARACTERISTIC_TWO_free); | ||
293 | 298 | ||
294 | static const ASN1_TEMPLATE fieldID_def_tt = { | 299 | static const ASN1_TEMPLATE fieldID_def_tt = { |
295 | .flags = 0, | 300 | .flags = 0, |
@@ -455,12 +460,14 @@ ECPARAMETERS_new(void) | |||
455 | { | 460 | { |
456 | return (ECPARAMETERS*)ASN1_item_new(&ECPARAMETERS_it); | 461 | return (ECPARAMETERS*)ASN1_item_new(&ECPARAMETERS_it); |
457 | } | 462 | } |
463 | LCRYPTO_ALIAS(ECPARAMETERS_new); | ||
458 | 464 | ||
459 | void | 465 | void |
460 | ECPARAMETERS_free(ECPARAMETERS *a) | 466 | ECPARAMETERS_free(ECPARAMETERS *a) |
461 | { | 467 | { |
462 | ASN1_item_free((ASN1_VALUE *)a, &ECPARAMETERS_it); | 468 | ASN1_item_free((ASN1_VALUE *)a, &ECPARAMETERS_it); |
463 | } | 469 | } |
470 | LCRYPTO_ALIAS(ECPARAMETERS_free); | ||
464 | 471 | ||
465 | static const ASN1_TEMPLATE ECPKPARAMETERS_ch_tt[] = { | 472 | static const ASN1_TEMPLATE ECPKPARAMETERS_ch_tt[] = { |
466 | { | 473 | { |
@@ -507,24 +514,28 @@ d2i_ECPKPARAMETERS(ECPKPARAMETERS **a, const unsigned char **in, long len) | |||
507 | return (ECPKPARAMETERS *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, | 514 | return (ECPKPARAMETERS *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, |
508 | &ECPKPARAMETERS_it); | 515 | &ECPKPARAMETERS_it); |
509 | } | 516 | } |
517 | LCRYPTO_ALIAS(d2i_ECPKPARAMETERS); | ||
510 | 518 | ||
511 | int | 519 | int |
512 | i2d_ECPKPARAMETERS(const ECPKPARAMETERS *a, unsigned char **out) | 520 | i2d_ECPKPARAMETERS(const ECPKPARAMETERS *a, unsigned char **out) |
513 | { | 521 | { |
514 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &ECPKPARAMETERS_it); | 522 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &ECPKPARAMETERS_it); |
515 | } | 523 | } |
524 | LCRYPTO_ALIAS(i2d_ECPKPARAMETERS); | ||
516 | 525 | ||
517 | ECPKPARAMETERS * | 526 | ECPKPARAMETERS * |
518 | ECPKPARAMETERS_new(void) | 527 | ECPKPARAMETERS_new(void) |
519 | { | 528 | { |
520 | return (ECPKPARAMETERS *)ASN1_item_new(&ECPKPARAMETERS_it); | 529 | return (ECPKPARAMETERS *)ASN1_item_new(&ECPKPARAMETERS_it); |
521 | } | 530 | } |
531 | LCRYPTO_ALIAS(ECPKPARAMETERS_new); | ||
522 | 532 | ||
523 | void | 533 | void |
524 | ECPKPARAMETERS_free(ECPKPARAMETERS *a) | 534 | ECPKPARAMETERS_free(ECPKPARAMETERS *a) |
525 | { | 535 | { |
526 | ASN1_item_free((ASN1_VALUE *)a, &ECPKPARAMETERS_it); | 536 | ASN1_item_free((ASN1_VALUE *)a, &ECPKPARAMETERS_it); |
527 | } | 537 | } |
538 | LCRYPTO_ALIAS(ECPKPARAMETERS_free); | ||
528 | 539 | ||
529 | static const ASN1_TEMPLATE EC_PRIVATEKEY_seq_tt[] = { | 540 | static const ASN1_TEMPLATE EC_PRIVATEKEY_seq_tt[] = { |
530 | { | 541 | { |
@@ -578,24 +589,28 @@ d2i_EC_PRIVATEKEY(EC_PRIVATEKEY **a, const unsigned char **in, long len) | |||
578 | return (EC_PRIVATEKEY *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, | 589 | return (EC_PRIVATEKEY *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, |
579 | &EC_PRIVATEKEY_it); | 590 | &EC_PRIVATEKEY_it); |
580 | } | 591 | } |
592 | LCRYPTO_ALIAS(d2i_EC_PRIVATEKEY); | ||
581 | 593 | ||
582 | int | 594 | int |
583 | i2d_EC_PRIVATEKEY(const EC_PRIVATEKEY *a, unsigned char **out) | 595 | i2d_EC_PRIVATEKEY(const EC_PRIVATEKEY *a, unsigned char **out) |
584 | { | 596 | { |
585 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &EC_PRIVATEKEY_it); | 597 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &EC_PRIVATEKEY_it); |
586 | } | 598 | } |
599 | LCRYPTO_ALIAS(i2d_EC_PRIVATEKEY); | ||
587 | 600 | ||
588 | EC_PRIVATEKEY * | 601 | EC_PRIVATEKEY * |
589 | EC_PRIVATEKEY_new(void) | 602 | EC_PRIVATEKEY_new(void) |
590 | { | 603 | { |
591 | return (EC_PRIVATEKEY *)ASN1_item_new(&EC_PRIVATEKEY_it); | 604 | return (EC_PRIVATEKEY *)ASN1_item_new(&EC_PRIVATEKEY_it); |
592 | } | 605 | } |
606 | LCRYPTO_ALIAS(EC_PRIVATEKEY_new); | ||
593 | 607 | ||
594 | void | 608 | void |
595 | EC_PRIVATEKEY_free(EC_PRIVATEKEY *a) | 609 | EC_PRIVATEKEY_free(EC_PRIVATEKEY *a) |
596 | { | 610 | { |
597 | ASN1_item_free((ASN1_VALUE *)a, &EC_PRIVATEKEY_it); | 611 | ASN1_item_free((ASN1_VALUE *)a, &EC_PRIVATEKEY_it); |
598 | } | 612 | } |
613 | LCRYPTO_ALIAS(EC_PRIVATEKEY_free); | ||
599 | 614 | ||
600 | /* some declarations of internal function */ | 615 | /* some declarations of internal function */ |
601 | 616 | ||
@@ -1101,6 +1116,7 @@ d2i_ECPKParameters(EC_GROUP **a, const unsigned char **in, long len) | |||
1101 | ECPKPARAMETERS_free(params); | 1116 | ECPKPARAMETERS_free(params); |
1102 | return (group); | 1117 | return (group); |
1103 | } | 1118 | } |
1119 | LCRYPTO_ALIAS(d2i_ECPKParameters); | ||
1104 | 1120 | ||
1105 | int | 1121 | int |
1106 | i2d_ECPKParameters(const EC_GROUP *a, unsigned char **out) | 1122 | i2d_ECPKParameters(const EC_GROUP *a, unsigned char **out) |
@@ -1119,6 +1135,7 @@ i2d_ECPKParameters(const EC_GROUP *a, unsigned char **out) | |||
1119 | ECPKPARAMETERS_free(tmp); | 1135 | ECPKPARAMETERS_free(tmp); |
1120 | return (ret); | 1136 | return (ret); |
1121 | } | 1137 | } |
1138 | LCRYPTO_ALIAS(i2d_ECPKParameters); | ||
1122 | 1139 | ||
1123 | /* some EC_KEY functions */ | 1140 | /* some EC_KEY functions */ |
1124 | 1141 | ||
@@ -1213,6 +1230,7 @@ d2i_ECPrivateKey(EC_KEY **a, const unsigned char **in, long len) | |||
1213 | 1230 | ||
1214 | return (NULL); | 1231 | return (NULL); |
1215 | } | 1232 | } |
1233 | LCRYPTO_ALIAS(d2i_ECPrivateKey); | ||
1216 | 1234 | ||
1217 | int | 1235 | int |
1218 | i2d_ECPrivateKey(EC_KEY *a, unsigned char **out) | 1236 | i2d_ECPrivateKey(EC_KEY *a, unsigned char **out) |
@@ -1297,6 +1315,7 @@ i2d_ECPrivateKey(EC_KEY *a, unsigned char **out) | |||
1297 | EC_PRIVATEKEY_free(priv_key); | 1315 | EC_PRIVATEKEY_free(priv_key); |
1298 | return (ok ? ret : 0); | 1316 | return (ok ? ret : 0); |
1299 | } | 1317 | } |
1318 | LCRYPTO_ALIAS(i2d_ECPrivateKey); | ||
1300 | 1319 | ||
1301 | int | 1320 | int |
1302 | i2d_ECParameters(EC_KEY *a, unsigned char **out) | 1321 | i2d_ECParameters(EC_KEY *a, unsigned char **out) |
@@ -1307,6 +1326,7 @@ i2d_ECParameters(EC_KEY *a, unsigned char **out) | |||
1307 | } | 1326 | } |
1308 | return i2d_ECPKParameters(a->group, out); | 1327 | return i2d_ECPKParameters(a->group, out); |
1309 | } | 1328 | } |
1329 | LCRYPTO_ALIAS(i2d_ECParameters); | ||
1310 | 1330 | ||
1311 | EC_KEY * | 1331 | EC_KEY * |
1312 | d2i_ECParameters(EC_KEY **a, const unsigned char **in, long len) | 1332 | d2i_ECParameters(EC_KEY **a, const unsigned char **in, long len) |
@@ -1336,6 +1356,7 @@ d2i_ECParameters(EC_KEY **a, const unsigned char **in, long len) | |||
1336 | *a = ret; | 1356 | *a = ret; |
1337 | return ret; | 1357 | return ret; |
1338 | } | 1358 | } |
1359 | LCRYPTO_ALIAS(d2i_ECParameters); | ||
1339 | 1360 | ||
1340 | EC_KEY * | 1361 | EC_KEY * |
1341 | o2i_ECPublicKey(EC_KEY **a, const unsigned char **in, long len) | 1362 | o2i_ECPublicKey(EC_KEY **a, const unsigned char **in, long len) |
@@ -1362,6 +1383,7 @@ o2i_ECPublicKey(EC_KEY **a, const unsigned char **in, long len) | |||
1362 | *in += len; | 1383 | *in += len; |
1363 | return ret; | 1384 | return ret; |
1364 | } | 1385 | } |
1386 | LCRYPTO_ALIAS(o2i_ECPublicKey); | ||
1365 | 1387 | ||
1366 | int | 1388 | int |
1367 | i2o_ECPublicKey(const EC_KEY *a, unsigned char **out) | 1389 | i2o_ECPublicKey(const EC_KEY *a, unsigned char **out) |
@@ -1400,3 +1422,4 @@ i2o_ECPublicKey(const EC_KEY *a, unsigned char **out) | |||
1400 | *out += buf_len; | 1422 | *out += buf_len; |
1401 | return buf_len; | 1423 | return buf_len; |
1402 | } | 1424 | } |
1425 | LCRYPTO_ALIAS(i2o_ECPublicKey); | ||
diff --git a/src/lib/libcrypto/ec/ec_check.c b/src/lib/libcrypto/ec/ec_check.c index 4a38dec539..0f98ef613c 100644 --- a/src/lib/libcrypto/ec/ec_check.c +++ b/src/lib/libcrypto/ec/ec_check.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_check.c,v 1.14 2023/07/03 09:29:55 tb Exp $ */ | 1 | /* $OpenBSD: ec_check.c,v 1.15 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -109,3 +109,4 @@ EC_GROUP_check(const EC_GROUP *group, BN_CTX *ctx_in) | |||
109 | 109 | ||
110 | return ret; | 110 | return ret; |
111 | } | 111 | } |
112 | LCRYPTO_ALIAS(EC_GROUP_check); | ||
diff --git a/src/lib/libcrypto/ec/ec_curve.c b/src/lib/libcrypto/ec/ec_curve.c index a8a1e4d522..9d19628b3e 100644 --- a/src/lib/libcrypto/ec/ec_curve.c +++ b/src/lib/libcrypto/ec/ec_curve.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_curve.c,v 1.41 2023/05/02 13:01:57 tb Exp $ */ | 1 | /* $OpenBSD: ec_curve.c,v 1.42 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -3122,6 +3122,7 @@ EC_GROUP_new_by_curve_name(int nid) | |||
3122 | ECerror(EC_R_UNKNOWN_GROUP); | 3122 | ECerror(EC_R_UNKNOWN_GROUP); |
3123 | return NULL; | 3123 | return NULL; |
3124 | } | 3124 | } |
3125 | LCRYPTO_ALIAS(EC_GROUP_new_by_curve_name); | ||
3125 | 3126 | ||
3126 | size_t | 3127 | size_t |
3127 | EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems) | 3128 | EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems) |
@@ -3140,6 +3141,7 @@ EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems) | |||
3140 | 3141 | ||
3141 | return CURVE_LIST_LENGTH; | 3142 | return CURVE_LIST_LENGTH; |
3142 | } | 3143 | } |
3144 | LCRYPTO_ALIAS(EC_get_builtin_curves); | ||
3143 | 3145 | ||
3144 | static const struct { | 3146 | static const struct { |
3145 | const char *name; | 3147 | const char *name; |
@@ -3174,6 +3176,7 @@ EC_curve_nid2nist(int nid) | |||
3174 | 3176 | ||
3175 | return NULL; | 3177 | return NULL; |
3176 | } | 3178 | } |
3179 | LCRYPTO_ALIAS(EC_curve_nid2nist); | ||
3177 | 3180 | ||
3178 | int | 3181 | int |
3179 | EC_curve_nist2nid(const char *name) | 3182 | EC_curve_nist2nid(const char *name) |
@@ -3187,3 +3190,4 @@ EC_curve_nist2nid(const char *name) | |||
3187 | 3190 | ||
3188 | return NID_undef; | 3191 | return NID_undef; |
3189 | } | 3192 | } |
3193 | LCRYPTO_ALIAS(EC_curve_nist2nid); | ||
diff --git a/src/lib/libcrypto/ec/ec_cvt.c b/src/lib/libcrypto/ec/ec_cvt.c index 90e7400739..5b196dd671 100644 --- a/src/lib/libcrypto/ec/ec_cvt.c +++ b/src/lib/libcrypto/ec/ec_cvt.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_cvt.c,v 1.11 2023/04/25 19:53:30 tb Exp $ */ | 1 | /* $OpenBSD: ec_cvt.c,v 1.12 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Originally written by Bodo Moeller for the OpenSSL project. | 3 | * Originally written by Bodo Moeller for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -100,3 +100,4 @@ EC_GROUP_new_curve_GFp(const BIGNUM *p, const BIGNUM *a, const BIGNUM *b, | |||
100 | { | 100 | { |
101 | return ec_group_new_curve(EC_GFp_mont_method(), p, a, b, ctx); | 101 | return ec_group_new_curve(EC_GFp_mont_method(), p, a, b, ctx); |
102 | } | 102 | } |
103 | LCRYPTO_ALIAS(EC_GROUP_new_curve_GFp); | ||
diff --git a/src/lib/libcrypto/ec/ec_err.c b/src/lib/libcrypto/ec/ec_err.c index d10b8e6f7d..d797b937c2 100644 --- a/src/lib/libcrypto/ec/ec_err.c +++ b/src/lib/libcrypto/ec/ec_err.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_err.c,v 1.16 2023/07/05 17:10:10 tb Exp $ */ | 1 | /* $OpenBSD: ec_err.c,v 1.17 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -147,3 +147,4 @@ ERR_load_EC_strings(void) | |||
147 | } | 147 | } |
148 | #endif | 148 | #endif |
149 | } | 149 | } |
150 | LCRYPTO_ALIAS(ERR_load_EC_strings); | ||
diff --git a/src/lib/libcrypto/ec/ec_key.c b/src/lib/libcrypto/ec/ec_key.c index a15d06b019..e5ff189803 100644 --- a/src/lib/libcrypto/ec/ec_key.c +++ b/src/lib/libcrypto/ec/ec_key.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_key.c,v 1.35 2023/07/05 08:39:40 tb Exp $ */ | 1 | /* $OpenBSD: ec_key.c,v 1.36 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -78,6 +78,7 @@ EC_KEY_new(void) | |||
78 | { | 78 | { |
79 | return EC_KEY_new_method(NULL); | 79 | return EC_KEY_new_method(NULL); |
80 | } | 80 | } |
81 | LCRYPTO_ALIAS(EC_KEY_new); | ||
81 | 82 | ||
82 | EC_KEY * | 83 | EC_KEY * |
83 | EC_KEY_new_by_curve_name(int nid) | 84 | EC_KEY_new_by_curve_name(int nid) |
@@ -97,6 +98,7 @@ EC_KEY_new_by_curve_name(int nid) | |||
97 | } | 98 | } |
98 | return ret; | 99 | return ret; |
99 | } | 100 | } |
101 | LCRYPTO_ALIAS(EC_KEY_new_by_curve_name); | ||
100 | 102 | ||
101 | void | 103 | void |
102 | EC_KEY_free(EC_KEY *r) | 104 | EC_KEY_free(EC_KEY *r) |
@@ -124,6 +126,7 @@ EC_KEY_free(EC_KEY *r) | |||
124 | 126 | ||
125 | freezero(r, sizeof(EC_KEY)); | 127 | freezero(r, sizeof(EC_KEY)); |
126 | } | 128 | } |
129 | LCRYPTO_ALIAS(EC_KEY_free); | ||
127 | 130 | ||
128 | EC_KEY * | 131 | EC_KEY * |
129 | EC_KEY_copy(EC_KEY *dest, const EC_KEY *src) | 132 | EC_KEY_copy(EC_KEY *dest, const EC_KEY *src) |
@@ -197,6 +200,7 @@ EC_KEY_copy(EC_KEY *dest, const EC_KEY *src) | |||
197 | 200 | ||
198 | return dest; | 201 | return dest; |
199 | } | 202 | } |
203 | LCRYPTO_ALIAS(EC_KEY_copy); | ||
200 | 204 | ||
201 | EC_KEY * | 205 | EC_KEY * |
202 | EC_KEY_dup(const EC_KEY *ec_key) | 206 | EC_KEY_dup(const EC_KEY *ec_key) |
@@ -211,6 +215,7 @@ EC_KEY_dup(const EC_KEY *ec_key) | |||
211 | } | 215 | } |
212 | return ret; | 216 | return ret; |
213 | } | 217 | } |
218 | LCRYPTO_ALIAS(EC_KEY_dup); | ||
214 | 219 | ||
215 | int | 220 | int |
216 | EC_KEY_up_ref(EC_KEY *r) | 221 | EC_KEY_up_ref(EC_KEY *r) |
@@ -218,18 +223,21 @@ EC_KEY_up_ref(EC_KEY *r) | |||
218 | int i = CRYPTO_add(&r->references, 1, CRYPTO_LOCK_EC); | 223 | int i = CRYPTO_add(&r->references, 1, CRYPTO_LOCK_EC); |
219 | return ((i > 1) ? 1 : 0); | 224 | return ((i > 1) ? 1 : 0); |
220 | } | 225 | } |
226 | LCRYPTO_ALIAS(EC_KEY_up_ref); | ||
221 | 227 | ||
222 | int | 228 | int |
223 | EC_KEY_set_ex_data(EC_KEY *r, int idx, void *arg) | 229 | EC_KEY_set_ex_data(EC_KEY *r, int idx, void *arg) |
224 | { | 230 | { |
225 | return CRYPTO_set_ex_data(&r->ex_data, idx, arg); | 231 | return CRYPTO_set_ex_data(&r->ex_data, idx, arg); |
226 | } | 232 | } |
233 | LCRYPTO_ALIAS(EC_KEY_set_ex_data); | ||
227 | 234 | ||
228 | void * | 235 | void * |
229 | EC_KEY_get_ex_data(const EC_KEY *r, int idx) | 236 | EC_KEY_get_ex_data(const EC_KEY *r, int idx) |
230 | { | 237 | { |
231 | return CRYPTO_get_ex_data(&r->ex_data, idx); | 238 | return CRYPTO_get_ex_data(&r->ex_data, idx); |
232 | } | 239 | } |
240 | LCRYPTO_ALIAS(EC_KEY_get_ex_data); | ||
233 | 241 | ||
234 | int | 242 | int |
235 | EC_KEY_generate_key(EC_KEY *eckey) | 243 | EC_KEY_generate_key(EC_KEY *eckey) |
@@ -239,6 +247,7 @@ EC_KEY_generate_key(EC_KEY *eckey) | |||
239 | ECerror(EC_R_NOT_IMPLEMENTED); | 247 | ECerror(EC_R_NOT_IMPLEMENTED); |
240 | return 0; | 248 | return 0; |
241 | } | 249 | } |
250 | LCRYPTO_ALIAS(EC_KEY_generate_key); | ||
242 | 251 | ||
243 | int | 252 | int |
244 | ec_key_gen(EC_KEY *eckey) | 253 | ec_key_gen(EC_KEY *eckey) |
@@ -355,6 +364,7 @@ EC_KEY_check_key(const EC_KEY *eckey) | |||
355 | 364 | ||
356 | return ret; | 365 | return ret; |
357 | } | 366 | } |
367 | LCRYPTO_ALIAS(EC_KEY_check_key); | ||
358 | 368 | ||
359 | int | 369 | int |
360 | EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y) | 370 | EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y) |
@@ -409,12 +419,14 @@ EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y) | |||
409 | 419 | ||
410 | return ret; | 420 | return ret; |
411 | } | 421 | } |
422 | LCRYPTO_ALIAS(EC_KEY_set_public_key_affine_coordinates); | ||
412 | 423 | ||
413 | const EC_GROUP * | 424 | const EC_GROUP * |
414 | EC_KEY_get0_group(const EC_KEY *key) | 425 | EC_KEY_get0_group(const EC_KEY *key) |
415 | { | 426 | { |
416 | return key->group; | 427 | return key->group; |
417 | } | 428 | } |
429 | LCRYPTO_ALIAS(EC_KEY_get0_group); | ||
418 | 430 | ||
419 | int | 431 | int |
420 | EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group) | 432 | EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group) |
@@ -426,12 +438,14 @@ EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group) | |||
426 | key->group = EC_GROUP_dup(group); | 438 | key->group = EC_GROUP_dup(group); |
427 | return (key->group == NULL) ? 0 : 1; | 439 | return (key->group == NULL) ? 0 : 1; |
428 | } | 440 | } |
441 | LCRYPTO_ALIAS(EC_KEY_set_group); | ||
429 | 442 | ||
430 | const BIGNUM * | 443 | const BIGNUM * |
431 | EC_KEY_get0_private_key(const EC_KEY *key) | 444 | EC_KEY_get0_private_key(const EC_KEY *key) |
432 | { | 445 | { |
433 | return key->priv_key; | 446 | return key->priv_key; |
434 | } | 447 | } |
448 | LCRYPTO_ALIAS(EC_KEY_get0_private_key); | ||
435 | 449 | ||
436 | int | 450 | int |
437 | EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key) | 451 | EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key) |
@@ -446,12 +460,14 @@ EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key) | |||
446 | 460 | ||
447 | return 1; | 461 | return 1; |
448 | } | 462 | } |
463 | LCRYPTO_ALIAS(EC_KEY_set_private_key); | ||
449 | 464 | ||
450 | const EC_POINT * | 465 | const EC_POINT * |
451 | EC_KEY_get0_public_key(const EC_KEY *key) | 466 | EC_KEY_get0_public_key(const EC_KEY *key) |
452 | { | 467 | { |
453 | return key->pub_key; | 468 | return key->pub_key; |
454 | } | 469 | } |
470 | LCRYPTO_ALIAS(EC_KEY_get0_public_key); | ||
455 | 471 | ||
456 | int | 472 | int |
457 | EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key) | 473 | EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key) |
@@ -466,24 +482,28 @@ EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub_key) | |||
466 | 482 | ||
467 | return 1; | 483 | return 1; |
468 | } | 484 | } |
485 | LCRYPTO_ALIAS(EC_KEY_set_public_key); | ||
469 | 486 | ||
470 | unsigned int | 487 | unsigned int |
471 | EC_KEY_get_enc_flags(const EC_KEY *key) | 488 | EC_KEY_get_enc_flags(const EC_KEY *key) |
472 | { | 489 | { |
473 | return key->enc_flag; | 490 | return key->enc_flag; |
474 | } | 491 | } |
492 | LCRYPTO_ALIAS(EC_KEY_get_enc_flags); | ||
475 | 493 | ||
476 | void | 494 | void |
477 | EC_KEY_set_enc_flags(EC_KEY *key, unsigned int flags) | 495 | EC_KEY_set_enc_flags(EC_KEY *key, unsigned int flags) |
478 | { | 496 | { |
479 | key->enc_flag = flags; | 497 | key->enc_flag = flags; |
480 | } | 498 | } |
499 | LCRYPTO_ALIAS(EC_KEY_set_enc_flags); | ||
481 | 500 | ||
482 | point_conversion_form_t | 501 | point_conversion_form_t |
483 | EC_KEY_get_conv_form(const EC_KEY *key) | 502 | EC_KEY_get_conv_form(const EC_KEY *key) |
484 | { | 503 | { |
485 | return key->conv_form; | 504 | return key->conv_form; |
486 | } | 505 | } |
506 | LCRYPTO_ALIAS(EC_KEY_get_conv_form); | ||
487 | 507 | ||
488 | void | 508 | void |
489 | EC_KEY_set_conv_form(EC_KEY *key, point_conversion_form_t cform) | 509 | EC_KEY_set_conv_form(EC_KEY *key, point_conversion_form_t cform) |
@@ -492,6 +512,7 @@ EC_KEY_set_conv_form(EC_KEY *key, point_conversion_form_t cform) | |||
492 | if (key->group != NULL) | 512 | if (key->group != NULL) |
493 | EC_GROUP_set_point_conversion_form(key->group, cform); | 513 | EC_GROUP_set_point_conversion_form(key->group, cform); |
494 | } | 514 | } |
515 | LCRYPTO_ALIAS(EC_KEY_set_conv_form); | ||
495 | 516 | ||
496 | void | 517 | void |
497 | EC_KEY_set_asn1_flag(EC_KEY *key, int flag) | 518 | EC_KEY_set_asn1_flag(EC_KEY *key, int flag) |
@@ -499,6 +520,7 @@ EC_KEY_set_asn1_flag(EC_KEY *key, int flag) | |||
499 | if (key->group != NULL) | 520 | if (key->group != NULL) |
500 | EC_GROUP_set_asn1_flag(key->group, flag); | 521 | EC_GROUP_set_asn1_flag(key->group, flag); |
501 | } | 522 | } |
523 | LCRYPTO_ALIAS(EC_KEY_set_asn1_flag); | ||
502 | 524 | ||
503 | int | 525 | int |
504 | EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx) | 526 | EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx) |
@@ -507,21 +529,25 @@ EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx) | |||
507 | return 0; | 529 | return 0; |
508 | return EC_GROUP_precompute_mult(key->group, ctx); | 530 | return EC_GROUP_precompute_mult(key->group, ctx); |
509 | } | 531 | } |
532 | LCRYPTO_ALIAS(EC_KEY_precompute_mult); | ||
510 | 533 | ||
511 | int | 534 | int |
512 | EC_KEY_get_flags(const EC_KEY *key) | 535 | EC_KEY_get_flags(const EC_KEY *key) |
513 | { | 536 | { |
514 | return key->flags; | 537 | return key->flags; |
515 | } | 538 | } |
539 | LCRYPTO_ALIAS(EC_KEY_get_flags); | ||
516 | 540 | ||
517 | void | 541 | void |
518 | EC_KEY_set_flags(EC_KEY *key, int flags) | 542 | EC_KEY_set_flags(EC_KEY *key, int flags) |
519 | { | 543 | { |
520 | key->flags |= flags; | 544 | key->flags |= flags; |
521 | } | 545 | } |
546 | LCRYPTO_ALIAS(EC_KEY_set_flags); | ||
522 | 547 | ||
523 | void | 548 | void |
524 | EC_KEY_clear_flags(EC_KEY *key, int flags) | 549 | EC_KEY_clear_flags(EC_KEY *key, int flags) |
525 | { | 550 | { |
526 | key->flags &= ~flags; | 551 | key->flags &= ~flags; |
527 | } | 552 | } |
553 | LCRYPTO_ALIAS(EC_KEY_clear_flags); | ||
diff --git a/src/lib/libcrypto/ec/ec_kmeth.c b/src/lib/libcrypto/ec/ec_kmeth.c index ec45e679d9..3e997f8a5e 100644 --- a/src/lib/libcrypto/ec/ec_kmeth.c +++ b/src/lib/libcrypto/ec/ec_kmeth.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_kmeth.c,v 1.10 2023/07/05 11:37:46 tb Exp $ */ | 1 | /* $OpenBSD: ec_kmeth.c,v 1.11 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 3 | * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
4 | * project. | 4 | * project. |
@@ -92,12 +92,14 @@ EC_KEY_OpenSSL(void) | |||
92 | { | 92 | { |
93 | return &openssl_ec_key_method; | 93 | return &openssl_ec_key_method; |
94 | } | 94 | } |
95 | LCRYPTO_ALIAS(EC_KEY_OpenSSL); | ||
95 | 96 | ||
96 | const EC_KEY_METHOD * | 97 | const EC_KEY_METHOD * |
97 | EC_KEY_get_default_method(void) | 98 | EC_KEY_get_default_method(void) |
98 | { | 99 | { |
99 | return default_ec_key_meth; | 100 | return default_ec_key_meth; |
100 | } | 101 | } |
102 | LCRYPTO_ALIAS(EC_KEY_get_default_method); | ||
101 | 103 | ||
102 | void | 104 | void |
103 | EC_KEY_set_default_method(const EC_KEY_METHOD *meth) | 105 | EC_KEY_set_default_method(const EC_KEY_METHOD *meth) |
@@ -107,12 +109,14 @@ EC_KEY_set_default_method(const EC_KEY_METHOD *meth) | |||
107 | else | 109 | else |
108 | default_ec_key_meth = meth; | 110 | default_ec_key_meth = meth; |
109 | } | 111 | } |
112 | LCRYPTO_ALIAS(EC_KEY_set_default_method); | ||
110 | 113 | ||
111 | const EC_KEY_METHOD * | 114 | const EC_KEY_METHOD * |
112 | EC_KEY_get_method(const EC_KEY *key) | 115 | EC_KEY_get_method(const EC_KEY *key) |
113 | { | 116 | { |
114 | return key->meth; | 117 | return key->meth; |
115 | } | 118 | } |
119 | LCRYPTO_ALIAS(EC_KEY_get_method); | ||
116 | 120 | ||
117 | int | 121 | int |
118 | EC_KEY_set_method(EC_KEY *key, const EC_KEY_METHOD *meth) | 122 | EC_KEY_set_method(EC_KEY *key, const EC_KEY_METHOD *meth) |
@@ -132,6 +136,7 @@ EC_KEY_set_method(EC_KEY *key, const EC_KEY_METHOD *meth) | |||
132 | return meth->init(key); | 136 | return meth->init(key); |
133 | return 1; | 137 | return 1; |
134 | } | 138 | } |
139 | LCRYPTO_ALIAS(EC_KEY_set_method); | ||
135 | 140 | ||
136 | EC_KEY * | 141 | EC_KEY * |
137 | EC_KEY_new_method(ENGINE *engine) | 142 | EC_KEY_new_method(ENGINE *engine) |
@@ -180,6 +185,7 @@ EC_KEY_new_method(ENGINE *engine) | |||
180 | EC_KEY_free(ret); | 185 | EC_KEY_free(ret); |
181 | return NULL; | 186 | return NULL; |
182 | } | 187 | } |
188 | LCRYPTO_ALIAS(EC_KEY_new_method); | ||
183 | 189 | ||
184 | EC_KEY_METHOD * | 190 | EC_KEY_METHOD * |
185 | EC_KEY_METHOD_new(const EC_KEY_METHOD *meth) | 191 | EC_KEY_METHOD_new(const EC_KEY_METHOD *meth) |
@@ -193,6 +199,7 @@ EC_KEY_METHOD_new(const EC_KEY_METHOD *meth) | |||
193 | ret->flags |= EC_KEY_METHOD_DYNAMIC; | 199 | ret->flags |= EC_KEY_METHOD_DYNAMIC; |
194 | return ret; | 200 | return ret; |
195 | } | 201 | } |
202 | LCRYPTO_ALIAS(EC_KEY_METHOD_new); | ||
196 | 203 | ||
197 | void | 204 | void |
198 | EC_KEY_METHOD_free(EC_KEY_METHOD *meth) | 205 | EC_KEY_METHOD_free(EC_KEY_METHOD *meth) |
@@ -202,6 +209,7 @@ EC_KEY_METHOD_free(EC_KEY_METHOD *meth) | |||
202 | if (meth->flags & EC_KEY_METHOD_DYNAMIC) | 209 | if (meth->flags & EC_KEY_METHOD_DYNAMIC) |
203 | free(meth); | 210 | free(meth); |
204 | } | 211 | } |
212 | LCRYPTO_ALIAS(EC_KEY_METHOD_free); | ||
205 | 213 | ||
206 | void | 214 | void |
207 | EC_KEY_METHOD_set_init(EC_KEY_METHOD *meth, | 215 | EC_KEY_METHOD_set_init(EC_KEY_METHOD *meth, |
@@ -219,12 +227,14 @@ EC_KEY_METHOD_set_init(EC_KEY_METHOD *meth, | |||
219 | meth->set_private = set_private; | 227 | meth->set_private = set_private; |
220 | meth->set_public = set_public; | 228 | meth->set_public = set_public; |
221 | } | 229 | } |
230 | LCRYPTO_ALIAS(EC_KEY_METHOD_set_init); | ||
222 | 231 | ||
223 | void | 232 | void |
224 | EC_KEY_METHOD_set_keygen(EC_KEY_METHOD *meth, int (*keygen)(EC_KEY *key)) | 233 | EC_KEY_METHOD_set_keygen(EC_KEY_METHOD *meth, int (*keygen)(EC_KEY *key)) |
225 | { | 234 | { |
226 | meth->keygen = keygen; | 235 | meth->keygen = keygen; |
227 | } | 236 | } |
237 | LCRYPTO_ALIAS(EC_KEY_METHOD_set_keygen); | ||
228 | 238 | ||
229 | void | 239 | void |
230 | EC_KEY_METHOD_set_compute_key(EC_KEY_METHOD *meth, | 240 | EC_KEY_METHOD_set_compute_key(EC_KEY_METHOD *meth, |
@@ -233,6 +243,7 @@ EC_KEY_METHOD_set_compute_key(EC_KEY_METHOD *meth, | |||
233 | { | 243 | { |
234 | meth->compute_key = ckey; | 244 | meth->compute_key = ckey; |
235 | } | 245 | } |
246 | LCRYPTO_ALIAS(EC_KEY_METHOD_set_compute_key); | ||
236 | 247 | ||
237 | void | 248 | void |
238 | EC_KEY_METHOD_set_sign(EC_KEY_METHOD *meth, | 249 | EC_KEY_METHOD_set_sign(EC_KEY_METHOD *meth, |
@@ -249,6 +260,7 @@ EC_KEY_METHOD_set_sign(EC_KEY_METHOD *meth, | |||
249 | meth->sign_setup = sign_setup; | 260 | meth->sign_setup = sign_setup; |
250 | meth->sign_sig = sign_sig; | 261 | meth->sign_sig = sign_sig; |
251 | } | 262 | } |
263 | LCRYPTO_ALIAS(EC_KEY_METHOD_set_sign); | ||
252 | 264 | ||
253 | void | 265 | void |
254 | EC_KEY_METHOD_set_verify(EC_KEY_METHOD *meth, | 266 | EC_KEY_METHOD_set_verify(EC_KEY_METHOD *meth, |
@@ -260,6 +272,7 @@ EC_KEY_METHOD_set_verify(EC_KEY_METHOD *meth, | |||
260 | meth->verify = verify; | 272 | meth->verify = verify; |
261 | meth->verify_sig = verify_sig; | 273 | meth->verify_sig = verify_sig; |
262 | } | 274 | } |
275 | LCRYPTO_ALIAS(EC_KEY_METHOD_set_verify); | ||
263 | 276 | ||
264 | 277 | ||
265 | void | 278 | void |
@@ -284,6 +297,7 @@ EC_KEY_METHOD_get_init(const EC_KEY_METHOD *meth, | |||
284 | if (pset_public != NULL) | 297 | if (pset_public != NULL) |
285 | *pset_public = meth->set_public; | 298 | *pset_public = meth->set_public; |
286 | } | 299 | } |
300 | LCRYPTO_ALIAS(EC_KEY_METHOD_get_init); | ||
287 | 301 | ||
288 | void | 302 | void |
289 | EC_KEY_METHOD_get_keygen(const EC_KEY_METHOD *meth, | 303 | EC_KEY_METHOD_get_keygen(const EC_KEY_METHOD *meth, |
@@ -292,6 +306,7 @@ EC_KEY_METHOD_get_keygen(const EC_KEY_METHOD *meth, | |||
292 | if (pkeygen != NULL) | 306 | if (pkeygen != NULL) |
293 | *pkeygen = meth->keygen; | 307 | *pkeygen = meth->keygen; |
294 | } | 308 | } |
309 | LCRYPTO_ALIAS(EC_KEY_METHOD_get_keygen); | ||
295 | 310 | ||
296 | void | 311 | void |
297 | EC_KEY_METHOD_get_compute_key(const EC_KEY_METHOD *meth, | 312 | EC_KEY_METHOD_get_compute_key(const EC_KEY_METHOD *meth, |
@@ -301,6 +316,7 @@ EC_KEY_METHOD_get_compute_key(const EC_KEY_METHOD *meth, | |||
301 | if (pck != NULL) | 316 | if (pck != NULL) |
302 | *pck = meth->compute_key; | 317 | *pck = meth->compute_key; |
303 | } | 318 | } |
319 | LCRYPTO_ALIAS(EC_KEY_METHOD_get_compute_key); | ||
304 | 320 | ||
305 | void | 321 | void |
306 | EC_KEY_METHOD_get_sign(const EC_KEY_METHOD *meth, | 322 | EC_KEY_METHOD_get_sign(const EC_KEY_METHOD *meth, |
@@ -320,6 +336,7 @@ EC_KEY_METHOD_get_sign(const EC_KEY_METHOD *meth, | |||
320 | if (psign_sig != NULL) | 336 | if (psign_sig != NULL) |
321 | *psign_sig = meth->sign_sig; | 337 | *psign_sig = meth->sign_sig; |
322 | } | 338 | } |
339 | LCRYPTO_ALIAS(EC_KEY_METHOD_get_sign); | ||
323 | 340 | ||
324 | void | 341 | void |
325 | EC_KEY_METHOD_get_verify(const EC_KEY_METHOD *meth, | 342 | EC_KEY_METHOD_get_verify(const EC_KEY_METHOD *meth, |
@@ -333,3 +350,4 @@ EC_KEY_METHOD_get_verify(const EC_KEY_METHOD *meth, | |||
333 | if (pverify_sig != NULL) | 350 | if (pverify_sig != NULL) |
334 | *pverify_sig = meth->verify_sig; | 351 | *pverify_sig = meth->verify_sig; |
335 | } | 352 | } |
353 | LCRYPTO_ALIAS(EC_KEY_METHOD_get_verify); | ||
diff --git a/src/lib/libcrypto/ec/ec_lib.c b/src/lib/libcrypto/ec/ec_lib.c index 8cea0bb95b..3db1ca2f07 100644 --- a/src/lib/libcrypto/ec/ec_lib.c +++ b/src/lib/libcrypto/ec/ec_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_lib.c,v 1.62 2023/07/03 07:26:40 tb Exp $ */ | 1 | /* $OpenBSD: ec_lib.c,v 1.63 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Originally written by Bodo Moeller for the OpenSSL project. | 3 | * Originally written by Bodo Moeller for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -110,6 +110,7 @@ EC_GROUP_new(const EC_METHOD *meth) | |||
110 | } | 110 | } |
111 | return ret; | 111 | return ret; |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EC_GROUP_new); | ||
113 | 114 | ||
114 | 115 | ||
115 | void | 116 | void |
@@ -128,12 +129,14 @@ EC_GROUP_free(EC_GROUP *group) | |||
128 | freezero(group->seed, group->seed_len); | 129 | freezero(group->seed, group->seed_len); |
129 | freezero(group, sizeof *group); | 130 | freezero(group, sizeof *group); |
130 | } | 131 | } |
132 | LCRYPTO_ALIAS(EC_GROUP_free); | ||
131 | 133 | ||
132 | void | 134 | void |
133 | EC_GROUP_clear_free(EC_GROUP *group) | 135 | EC_GROUP_clear_free(EC_GROUP *group) |
134 | { | 136 | { |
135 | EC_GROUP_free(group); | 137 | EC_GROUP_free(group); |
136 | } | 138 | } |
139 | LCRYPTO_ALIAS(EC_GROUP_clear_free); | ||
137 | 140 | ||
138 | int | 141 | int |
139 | EC_GROUP_copy(EC_GROUP *dest, const EC_GROUP *src) | 142 | EC_GROUP_copy(EC_GROUP *dest, const EC_GROUP *src) |
@@ -188,6 +191,7 @@ EC_GROUP_copy(EC_GROUP *dest, const EC_GROUP *src) | |||
188 | 191 | ||
189 | return dest->meth->group_copy(dest, src); | 192 | return dest->meth->group_copy(dest, src); |
190 | } | 193 | } |
194 | LCRYPTO_ALIAS(EC_GROUP_copy); | ||
191 | 195 | ||
192 | 196 | ||
193 | EC_GROUP * | 197 | EC_GROUP * |
@@ -202,6 +206,7 @@ EC_GROUP_dup(const EC_GROUP *a) | |||
202 | } | 206 | } |
203 | return t; | 207 | return t; |
204 | } | 208 | } |
209 | LCRYPTO_ALIAS(EC_GROUP_dup); | ||
205 | 210 | ||
206 | 211 | ||
207 | const EC_METHOD * | 212 | const EC_METHOD * |
@@ -209,6 +214,7 @@ EC_GROUP_method_of(const EC_GROUP *group) | |||
209 | { | 214 | { |
210 | return group->meth; | 215 | return group->meth; |
211 | } | 216 | } |
217 | LCRYPTO_ALIAS(EC_GROUP_method_of); | ||
212 | 218 | ||
213 | 219 | ||
214 | int | 220 | int |
@@ -216,6 +222,7 @@ EC_METHOD_get_field_type(const EC_METHOD *meth) | |||
216 | { | 222 | { |
217 | return meth->field_type; | 223 | return meth->field_type; |
218 | } | 224 | } |
225 | LCRYPTO_ALIAS(EC_METHOD_get_field_type); | ||
219 | 226 | ||
220 | /* | 227 | /* |
221 | * If there is a user-provided cofactor, sanity check and use it. Otherwise | 228 | * If there is a user-provided cofactor, sanity check and use it. Otherwise |
@@ -349,6 +356,7 @@ EC_GROUP_set_generator(EC_GROUP *group, const EC_POINT *generator, | |||
349 | 356 | ||
350 | return 1; | 357 | return 1; |
351 | } | 358 | } |
359 | LCRYPTO_ALIAS(EC_GROUP_set_generator); | ||
352 | 360 | ||
353 | 361 | ||
354 | const EC_POINT * | 362 | const EC_POINT * |
@@ -356,6 +364,7 @@ EC_GROUP_get0_generator(const EC_GROUP *group) | |||
356 | { | 364 | { |
357 | return group->generator; | 365 | return group->generator; |
358 | } | 366 | } |
367 | LCRYPTO_ALIAS(EC_GROUP_get0_generator); | ||
359 | 368 | ||
360 | int | 369 | int |
361 | EC_GROUP_get_order(const EC_GROUP *group, BIGNUM *order, BN_CTX *ctx) | 370 | EC_GROUP_get_order(const EC_GROUP *group, BIGNUM *order, BN_CTX *ctx) |
@@ -365,6 +374,7 @@ EC_GROUP_get_order(const EC_GROUP *group, BIGNUM *order, BN_CTX *ctx) | |||
365 | 374 | ||
366 | return !BN_is_zero(order); | 375 | return !BN_is_zero(order); |
367 | } | 376 | } |
377 | LCRYPTO_ALIAS(EC_GROUP_get_order); | ||
368 | 378 | ||
369 | const BIGNUM * | 379 | const BIGNUM * |
370 | EC_GROUP_get0_order(const EC_GROUP *group) | 380 | EC_GROUP_get0_order(const EC_GROUP *group) |
@@ -377,6 +387,7 @@ EC_GROUP_order_bits(const EC_GROUP *group) | |||
377 | { | 387 | { |
378 | return group->meth->group_order_bits(group); | 388 | return group->meth->group_order_bits(group); |
379 | } | 389 | } |
390 | LCRYPTO_ALIAS(EC_GROUP_order_bits); | ||
380 | 391 | ||
381 | int | 392 | int |
382 | EC_GROUP_get_cofactor(const EC_GROUP *group, BIGNUM *cofactor, BN_CTX *ctx) | 393 | EC_GROUP_get_cofactor(const EC_GROUP *group, BIGNUM *cofactor, BN_CTX *ctx) |
@@ -386,6 +397,7 @@ EC_GROUP_get_cofactor(const EC_GROUP *group, BIGNUM *cofactor, BN_CTX *ctx) | |||
386 | 397 | ||
387 | return !BN_is_zero(&group->cofactor); | 398 | return !BN_is_zero(&group->cofactor); |
388 | } | 399 | } |
400 | LCRYPTO_ALIAS(EC_GROUP_get_cofactor); | ||
389 | 401 | ||
390 | 402 | ||
391 | void | 403 | void |
@@ -393,6 +405,7 @@ EC_GROUP_set_curve_name(EC_GROUP *group, int nid) | |||
393 | { | 405 | { |
394 | group->curve_name = nid; | 406 | group->curve_name = nid; |
395 | } | 407 | } |
408 | LCRYPTO_ALIAS(EC_GROUP_set_curve_name); | ||
396 | 409 | ||
397 | 410 | ||
398 | int | 411 | int |
@@ -400,6 +413,7 @@ EC_GROUP_get_curve_name(const EC_GROUP *group) | |||
400 | { | 413 | { |
401 | return group->curve_name; | 414 | return group->curve_name; |
402 | } | 415 | } |
416 | LCRYPTO_ALIAS(EC_GROUP_get_curve_name); | ||
403 | 417 | ||
404 | 418 | ||
405 | void | 419 | void |
@@ -407,6 +421,7 @@ EC_GROUP_set_asn1_flag(EC_GROUP *group, int flag) | |||
407 | { | 421 | { |
408 | group->asn1_flag = flag; | 422 | group->asn1_flag = flag; |
409 | } | 423 | } |
424 | LCRYPTO_ALIAS(EC_GROUP_set_asn1_flag); | ||
410 | 425 | ||
411 | 426 | ||
412 | int | 427 | int |
@@ -414,6 +429,7 @@ EC_GROUP_get_asn1_flag(const EC_GROUP *group) | |||
414 | { | 429 | { |
415 | return group->asn1_flag; | 430 | return group->asn1_flag; |
416 | } | 431 | } |
432 | LCRYPTO_ALIAS(EC_GROUP_get_asn1_flag); | ||
417 | 433 | ||
418 | 434 | ||
419 | void | 435 | void |
@@ -422,6 +438,7 @@ EC_GROUP_set_point_conversion_form(EC_GROUP *group, | |||
422 | { | 438 | { |
423 | group->asn1_form = form; | 439 | group->asn1_form = form; |
424 | } | 440 | } |
441 | LCRYPTO_ALIAS(EC_GROUP_set_point_conversion_form); | ||
425 | 442 | ||
426 | 443 | ||
427 | point_conversion_form_t | 444 | point_conversion_form_t |
@@ -429,6 +446,7 @@ EC_GROUP_get_point_conversion_form(const EC_GROUP *group) | |||
429 | { | 446 | { |
430 | return group->asn1_form; | 447 | return group->asn1_form; |
431 | } | 448 | } |
449 | LCRYPTO_ALIAS(EC_GROUP_get_point_conversion_form); | ||
432 | 450 | ||
433 | 451 | ||
434 | size_t | 452 | size_t |
@@ -449,6 +467,7 @@ EC_GROUP_set_seed(EC_GROUP *group, const unsigned char *p, size_t len) | |||
449 | 467 | ||
450 | return len; | 468 | return len; |
451 | } | 469 | } |
470 | LCRYPTO_ALIAS(EC_GROUP_set_seed); | ||
452 | 471 | ||
453 | 472 | ||
454 | unsigned char * | 473 | unsigned char * |
@@ -456,6 +475,7 @@ EC_GROUP_get0_seed(const EC_GROUP *group) | |||
456 | { | 475 | { |
457 | return group->seed; | 476 | return group->seed; |
458 | } | 477 | } |
478 | LCRYPTO_ALIAS(EC_GROUP_get0_seed); | ||
459 | 479 | ||
460 | 480 | ||
461 | size_t | 481 | size_t |
@@ -463,6 +483,7 @@ EC_GROUP_get_seed_len(const EC_GROUP *group) | |||
463 | { | 483 | { |
464 | return group->seed_len; | 484 | return group->seed_len; |
465 | } | 485 | } |
486 | LCRYPTO_ALIAS(EC_GROUP_get_seed_len); | ||
466 | 487 | ||
467 | int | 488 | int |
468 | EC_GROUP_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, | 489 | EC_GROUP_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, |
@@ -488,6 +509,7 @@ EC_GROUP_set_curve(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, | |||
488 | 509 | ||
489 | return ret; | 510 | return ret; |
490 | } | 511 | } |
512 | LCRYPTO_ALIAS(EC_GROUP_set_curve); | ||
491 | 513 | ||
492 | int | 514 | int |
493 | EC_GROUP_get_curve(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, | 515 | EC_GROUP_get_curve(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, |
@@ -513,6 +535,7 @@ EC_GROUP_get_curve(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, | |||
513 | 535 | ||
514 | return ret; | 536 | return ret; |
515 | } | 537 | } |
538 | LCRYPTO_ALIAS(EC_GROUP_get_curve); | ||
516 | 539 | ||
517 | int | 540 | int |
518 | EC_GROUP_set_curve_GFp(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, | 541 | EC_GROUP_set_curve_GFp(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, |
@@ -520,6 +543,7 @@ EC_GROUP_set_curve_GFp(EC_GROUP *group, const BIGNUM *p, const BIGNUM *a, | |||
520 | { | 543 | { |
521 | return EC_GROUP_set_curve(group, p, a, b, ctx); | 544 | return EC_GROUP_set_curve(group, p, a, b, ctx); |
522 | } | 545 | } |
546 | LCRYPTO_ALIAS(EC_GROUP_set_curve_GFp); | ||
523 | 547 | ||
524 | int | 548 | int |
525 | EC_GROUP_get_curve_GFp(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, | 549 | EC_GROUP_get_curve_GFp(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, |
@@ -527,6 +551,7 @@ EC_GROUP_get_curve_GFp(const EC_GROUP *group, BIGNUM *p, BIGNUM *a, BIGNUM *b, | |||
527 | { | 551 | { |
528 | return EC_GROUP_get_curve(group, p, a, b, ctx); | 552 | return EC_GROUP_get_curve(group, p, a, b, ctx); |
529 | } | 553 | } |
554 | LCRYPTO_ALIAS(EC_GROUP_get_curve_GFp); | ||
530 | 555 | ||
531 | int | 556 | int |
532 | EC_GROUP_get_degree(const EC_GROUP *group) | 557 | EC_GROUP_get_degree(const EC_GROUP *group) |
@@ -537,6 +562,7 @@ EC_GROUP_get_degree(const EC_GROUP *group) | |||
537 | } | 562 | } |
538 | return group->meth->group_get_degree(group); | 563 | return group->meth->group_get_degree(group); |
539 | } | 564 | } |
565 | LCRYPTO_ALIAS(EC_GROUP_get_degree); | ||
540 | 566 | ||
541 | 567 | ||
542 | int | 568 | int |
@@ -562,6 +588,7 @@ EC_GROUP_check_discriminant(const EC_GROUP *group, BN_CTX *ctx_in) | |||
562 | 588 | ||
563 | return ret; | 589 | return ret; |
564 | } | 590 | } |
591 | LCRYPTO_ALIAS(EC_GROUP_check_discriminant); | ||
565 | 592 | ||
566 | 593 | ||
567 | int | 594 | int |
@@ -637,6 +664,7 @@ EC_GROUP_cmp(const EC_GROUP *a, const EC_GROUP *b, BN_CTX *ctx) | |||
637 | BN_CTX_free(ctx); | 664 | BN_CTX_free(ctx); |
638 | return -1; | 665 | return -1; |
639 | } | 666 | } |
667 | LCRYPTO_ALIAS(EC_GROUP_cmp); | ||
640 | 668 | ||
641 | /* | 669 | /* |
642 | * Coordinate blinding for EC_POINT. | 670 | * Coordinate blinding for EC_POINT. |
@@ -682,6 +710,7 @@ EC_POINT_new(const EC_GROUP *group) | |||
682 | } | 710 | } |
683 | return ret; | 711 | return ret; |
684 | } | 712 | } |
713 | LCRYPTO_ALIAS(EC_POINT_new); | ||
685 | 714 | ||
686 | void | 715 | void |
687 | EC_POINT_free(EC_POINT *point) | 716 | EC_POINT_free(EC_POINT *point) |
@@ -694,12 +723,14 @@ EC_POINT_free(EC_POINT *point) | |||
694 | 723 | ||
695 | freezero(point, sizeof *point); | 724 | freezero(point, sizeof *point); |
696 | } | 725 | } |
726 | LCRYPTO_ALIAS(EC_POINT_free); | ||
697 | 727 | ||
698 | void | 728 | void |
699 | EC_POINT_clear_free(EC_POINT *point) | 729 | EC_POINT_clear_free(EC_POINT *point) |
700 | { | 730 | { |
701 | EC_POINT_free(point); | 731 | EC_POINT_free(point); |
702 | } | 732 | } |
733 | LCRYPTO_ALIAS(EC_POINT_clear_free); | ||
703 | 734 | ||
704 | int | 735 | int |
705 | EC_POINT_copy(EC_POINT *dest, const EC_POINT *src) | 736 | EC_POINT_copy(EC_POINT *dest, const EC_POINT *src) |
@@ -716,6 +747,7 @@ EC_POINT_copy(EC_POINT *dest, const EC_POINT *src) | |||
716 | return 1; | 747 | return 1; |
717 | return dest->meth->point_copy(dest, src); | 748 | return dest->meth->point_copy(dest, src); |
718 | } | 749 | } |
750 | LCRYPTO_ALIAS(EC_POINT_copy); | ||
719 | 751 | ||
720 | EC_POINT * | 752 | EC_POINT * |
721 | EC_POINT_dup(const EC_POINT *a, const EC_GROUP *group) | 753 | EC_POINT_dup(const EC_POINT *a, const EC_GROUP *group) |
@@ -736,12 +768,14 @@ EC_POINT_dup(const EC_POINT *a, const EC_GROUP *group) | |||
736 | } else | 768 | } else |
737 | return t; | 769 | return t; |
738 | } | 770 | } |
771 | LCRYPTO_ALIAS(EC_POINT_dup); | ||
739 | 772 | ||
740 | const EC_METHOD * | 773 | const EC_METHOD * |
741 | EC_POINT_method_of(const EC_POINT *point) | 774 | EC_POINT_method_of(const EC_POINT *point) |
742 | { | 775 | { |
743 | return point->meth; | 776 | return point->meth; |
744 | } | 777 | } |
778 | LCRYPTO_ALIAS(EC_POINT_method_of); | ||
745 | 779 | ||
746 | int | 780 | int |
747 | EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point) | 781 | EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point) |
@@ -756,6 +790,7 @@ EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point) | |||
756 | } | 790 | } |
757 | return group->meth->point_set_to_infinity(group, point); | 791 | return group->meth->point_set_to_infinity(group, point); |
758 | } | 792 | } |
793 | LCRYPTO_ALIAS(EC_POINT_set_to_infinity); | ||
759 | 794 | ||
760 | int | 795 | int |
761 | EC_POINT_set_Jprojective_coordinates(const EC_GROUP *group, EC_POINT *point, | 796 | EC_POINT_set_Jprojective_coordinates(const EC_GROUP *group, EC_POINT *point, |
@@ -831,6 +866,7 @@ EC_POINT_set_Jprojective_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, | |||
831 | { | 866 | { |
832 | return EC_POINT_set_Jprojective_coordinates(group, point, x, y, z, ctx); | 867 | return EC_POINT_set_Jprojective_coordinates(group, point, x, y, z, ctx); |
833 | } | 868 | } |
869 | LCRYPTO_ALIAS(EC_POINT_set_Jprojective_coordinates_GFp); | ||
834 | 870 | ||
835 | int | 871 | int |
836 | EC_POINT_get_Jprojective_coordinates_GFp(const EC_GROUP *group, | 872 | EC_POINT_get_Jprojective_coordinates_GFp(const EC_GROUP *group, |
@@ -838,6 +874,7 @@ EC_POINT_get_Jprojective_coordinates_GFp(const EC_GROUP *group, | |||
838 | { | 874 | { |
839 | return EC_POINT_get_Jprojective_coordinates(group, point, x, y, z, ctx); | 875 | return EC_POINT_get_Jprojective_coordinates(group, point, x, y, z, ctx); |
840 | } | 876 | } |
877 | LCRYPTO_ALIAS(EC_POINT_get_Jprojective_coordinates_GFp); | ||
841 | 878 | ||
842 | int | 879 | int |
843 | EC_POINT_set_affine_coordinates(const EC_GROUP *group, EC_POINT *point, | 880 | EC_POINT_set_affine_coordinates(const EC_GROUP *group, EC_POINT *point, |
@@ -875,6 +912,7 @@ EC_POINT_set_affine_coordinates(const EC_GROUP *group, EC_POINT *point, | |||
875 | 912 | ||
876 | return ret; | 913 | return ret; |
877 | } | 914 | } |
915 | LCRYPTO_ALIAS(EC_POINT_set_affine_coordinates); | ||
878 | 916 | ||
879 | int | 917 | int |
880 | EC_POINT_set_affine_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, | 918 | EC_POINT_set_affine_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, |
@@ -882,6 +920,7 @@ EC_POINT_set_affine_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, | |||
882 | { | 920 | { |
883 | return EC_POINT_set_affine_coordinates(group, point, x, y, ctx); | 921 | return EC_POINT_set_affine_coordinates(group, point, x, y, ctx); |
884 | } | 922 | } |
923 | LCRYPTO_ALIAS(EC_POINT_set_affine_coordinates_GFp); | ||
885 | 924 | ||
886 | int | 925 | int |
887 | EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *point, | 926 | EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *point, |
@@ -911,6 +950,7 @@ EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *point, | |||
911 | 950 | ||
912 | return ret; | 951 | return ret; |
913 | } | 952 | } |
953 | LCRYPTO_ALIAS(EC_POINT_get_affine_coordinates); | ||
914 | 954 | ||
915 | int | 955 | int |
916 | EC_POINT_get_affine_coordinates_GFp(const EC_GROUP *group, const EC_POINT *point, | 956 | EC_POINT_get_affine_coordinates_GFp(const EC_GROUP *group, const EC_POINT *point, |
@@ -918,6 +958,7 @@ EC_POINT_get_affine_coordinates_GFp(const EC_GROUP *group, const EC_POINT *point | |||
918 | { | 958 | { |
919 | return EC_POINT_get_affine_coordinates(group, point, x, y, ctx); | 959 | return EC_POINT_get_affine_coordinates(group, point, x, y, ctx); |
920 | } | 960 | } |
961 | LCRYPTO_ALIAS(EC_POINT_get_affine_coordinates_GFp); | ||
921 | 962 | ||
922 | int | 963 | int |
923 | EC_POINT_add(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, | 964 | EC_POINT_add(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, |
@@ -948,6 +989,7 @@ EC_POINT_add(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, | |||
948 | 989 | ||
949 | return ret; | 990 | return ret; |
950 | } | 991 | } |
992 | LCRYPTO_ALIAS(EC_POINT_add); | ||
951 | 993 | ||
952 | int | 994 | int |
953 | EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, | 995 | EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, |
@@ -977,6 +1019,7 @@ EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, | |||
977 | 1019 | ||
978 | return ret; | 1020 | return ret; |
979 | } | 1021 | } |
1022 | LCRYPTO_ALIAS(EC_POINT_dbl); | ||
980 | 1023 | ||
981 | int | 1024 | int |
982 | EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx_in) | 1025 | EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx_in) |
@@ -1005,6 +1048,7 @@ EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx_in) | |||
1005 | 1048 | ||
1006 | return ret; | 1049 | return ret; |
1007 | } | 1050 | } |
1051 | LCRYPTO_ALIAS(EC_POINT_invert); | ||
1008 | 1052 | ||
1009 | int | 1053 | int |
1010 | EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *point) | 1054 | EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *point) |
@@ -1019,6 +1063,7 @@ EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *point) | |||
1019 | } | 1063 | } |
1020 | return group->meth->is_at_infinity(group, point); | 1064 | return group->meth->is_at_infinity(group, point); |
1021 | } | 1065 | } |
1066 | LCRYPTO_ALIAS(EC_POINT_is_at_infinity); | ||
1022 | 1067 | ||
1023 | int | 1068 | int |
1024 | EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point, | 1069 | EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point, |
@@ -1048,6 +1093,7 @@ EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point, | |||
1048 | 1093 | ||
1049 | return ret; | 1094 | return ret; |
1050 | } | 1095 | } |
1096 | LCRYPTO_ALIAS(EC_POINT_is_on_curve); | ||
1051 | 1097 | ||
1052 | int | 1098 | int |
1053 | EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b, | 1099 | EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b, |
@@ -1077,6 +1123,7 @@ EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b, | |||
1077 | 1123 | ||
1078 | return ret; | 1124 | return ret; |
1079 | } | 1125 | } |
1126 | LCRYPTO_ALIAS(EC_POINT_cmp); | ||
1080 | 1127 | ||
1081 | int | 1128 | int |
1082 | EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx_in) | 1129 | EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx_in) |
@@ -1105,6 +1152,7 @@ EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx_in) | |||
1105 | 1152 | ||
1106 | return ret; | 1153 | return ret; |
1107 | } | 1154 | } |
1155 | LCRYPTO_ALIAS(EC_POINT_make_affine); | ||
1108 | 1156 | ||
1109 | int | 1157 | int |
1110 | EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[], | 1158 | EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[], |
@@ -1137,6 +1185,7 @@ EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[], | |||
1137 | 1185 | ||
1138 | return ret; | 1186 | return ret; |
1139 | } | 1187 | } |
1188 | LCRYPTO_ALIAS(EC_POINTs_make_affine); | ||
1140 | 1189 | ||
1141 | int | 1190 | int |
1142 | EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar, | 1191 | EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar, |
@@ -1178,6 +1227,7 @@ EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar, | |||
1178 | 1227 | ||
1179 | return ret; | 1228 | return ret; |
1180 | } | 1229 | } |
1230 | LCRYPTO_ALIAS(EC_POINTs_mul); | ||
1181 | 1231 | ||
1182 | int | 1232 | int |
1183 | EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar, | 1233 | EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar, |
@@ -1239,18 +1289,21 @@ EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *g_scalar, | |||
1239 | 1289 | ||
1240 | return ret; | 1290 | return ret; |
1241 | } | 1291 | } |
1292 | LCRYPTO_ALIAS(EC_POINT_mul); | ||
1242 | 1293 | ||
1243 | int | 1294 | int |
1244 | EC_GROUP_precompute_mult(EC_GROUP *group, BN_CTX *ctx_in) | 1295 | EC_GROUP_precompute_mult(EC_GROUP *group, BN_CTX *ctx_in) |
1245 | { | 1296 | { |
1246 | return 1; | 1297 | return 1; |
1247 | } | 1298 | } |
1299 | LCRYPTO_ALIAS(EC_GROUP_precompute_mult); | ||
1248 | 1300 | ||
1249 | int | 1301 | int |
1250 | EC_GROUP_have_precompute_mult(const EC_GROUP *group) | 1302 | EC_GROUP_have_precompute_mult(const EC_GROUP *group) |
1251 | { | 1303 | { |
1252 | return 0; | 1304 | return 0; |
1253 | } | 1305 | } |
1306 | LCRYPTO_ALIAS(EC_GROUP_have_precompute_mult); | ||
1254 | 1307 | ||
1255 | int | 1308 | int |
1256 | ec_group_simple_order_bits(const EC_GROUP *group) | 1309 | ec_group_simple_order_bits(const EC_GROUP *group) |
@@ -1283,3 +1336,4 @@ ECParameters_dup(EC_KEY *key) | |||
1283 | 1336 | ||
1284 | return dup; | 1337 | return dup; |
1285 | } | 1338 | } |
1339 | LCRYPTO_ALIAS(ECParameters_dup); | ||
diff --git a/src/lib/libcrypto/ec/ec_oct.c b/src/lib/libcrypto/ec/ec_oct.c index f9de2f13a1..b9bc62a4e3 100644 --- a/src/lib/libcrypto/ec/ec_oct.c +++ b/src/lib/libcrypto/ec/ec_oct.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_oct.c,v 1.14 2023/05/04 06:45:51 tb Exp $ */ | 1 | /* $OpenBSD: ec_oct.c,v 1.15 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Originally written by Bodo Moeller for the OpenSSL project. | 3 | * Originally written by Bodo Moeller for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -99,6 +99,7 @@ EC_POINT_set_compressed_coordinates(const EC_GROUP *group, EC_POINT *point, | |||
99 | 99 | ||
100 | return ret; | 100 | return ret; |
101 | } | 101 | } |
102 | LCRYPTO_ALIAS(EC_POINT_set_compressed_coordinates); | ||
102 | 103 | ||
103 | int | 104 | int |
104 | EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, | 105 | EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, |
@@ -106,6 +107,7 @@ EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP *group, EC_POINT *point, | |||
106 | { | 107 | { |
107 | return EC_POINT_set_compressed_coordinates(group, point, x, y_bit, ctx); | 108 | return EC_POINT_set_compressed_coordinates(group, point, x, y_bit, ctx); |
108 | } | 109 | } |
110 | LCRYPTO_ALIAS(EC_POINT_set_compressed_coordinates_GFp); | ||
109 | 111 | ||
110 | size_t | 112 | size_t |
111 | EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *point, | 113 | EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *point, |
@@ -136,6 +138,7 @@ EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *point, | |||
136 | 138 | ||
137 | return ret; | 139 | return ret; |
138 | } | 140 | } |
141 | LCRYPTO_ALIAS(EC_POINT_point2oct); | ||
139 | 142 | ||
140 | int | 143 | int |
141 | EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point, | 144 | EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point, |
@@ -165,3 +168,4 @@ EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *point, | |||
165 | 168 | ||
166 | return ret; | 169 | return ret; |
167 | } | 170 | } |
171 | LCRYPTO_ALIAS(EC_POINT_oct2point); | ||
diff --git a/src/lib/libcrypto/ec/ec_print.c b/src/lib/libcrypto/ec/ec_print.c index da33c4eccd..312770f66c 100644 --- a/src/lib/libcrypto/ec/ec_print.c +++ b/src/lib/libcrypto/ec/ec_print.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ec_print.c,v 1.12 2023/06/23 10:34:16 tb Exp $ */ | 1 | /* $OpenBSD: ec_print.c,v 1.13 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -81,6 +81,7 @@ EC_POINT_point2bn(const EC_GROUP *group, const EC_POINT *point, | |||
81 | 81 | ||
82 | return ret; | 82 | return ret; |
83 | } | 83 | } |
84 | LCRYPTO_ALIAS(EC_POINT_point2bn); | ||
84 | 85 | ||
85 | EC_POINT * | 86 | EC_POINT * |
86 | EC_POINT_bn2point(const EC_GROUP *group, | 87 | EC_POINT_bn2point(const EC_GROUP *group, |
@@ -117,6 +118,7 @@ EC_POINT_bn2point(const EC_GROUP *group, | |||
117 | free(buf); | 118 | free(buf); |
118 | return ret; | 119 | return ret; |
119 | } | 120 | } |
121 | LCRYPTO_ALIAS(EC_POINT_bn2point); | ||
120 | 122 | ||
121 | static const char *HEX_DIGITS = "0123456789ABCDEF"; | 123 | static const char *HEX_DIGITS = "0123456789ABCDEF"; |
122 | 124 | ||
@@ -159,6 +161,7 @@ EC_POINT_point2hex(const EC_GROUP *group, const EC_POINT *point, | |||
159 | 161 | ||
160 | return ret; | 162 | return ret; |
161 | } | 163 | } |
164 | LCRYPTO_ALIAS(EC_POINT_point2hex); | ||
162 | 165 | ||
163 | EC_POINT * | 166 | EC_POINT * |
164 | EC_POINT_hex2point(const EC_GROUP *group, const char *buf, | 167 | EC_POINT_hex2point(const EC_GROUP *group, const char *buf, |
@@ -176,3 +179,4 @@ EC_POINT_hex2point(const EC_GROUP *group, const char *buf, | |||
176 | 179 | ||
177 | return ret; | 180 | return ret; |
178 | } | 181 | } |
182 | LCRYPTO_ALIAS(EC_POINT_hex2point); | ||
diff --git a/src/lib/libcrypto/ec/eck_prn.c b/src/lib/libcrypto/ec/eck_prn.c index f65b74518b..6e89bfa739 100644 --- a/src/lib/libcrypto/ec/eck_prn.c +++ b/src/lib/libcrypto/ec/eck_prn.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: eck_prn.c,v 1.27 2023/07/06 15:18:02 tb Exp $ */ | 1 | /* $OpenBSD: eck_prn.c,v 1.28 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -86,6 +86,7 @@ ECPKParameters_print_fp(FILE *fp, const EC_GROUP *x, int off) | |||
86 | BIO_free(b); | 86 | BIO_free(b); |
87 | return (ret); | 87 | return (ret); |
88 | } | 88 | } |
89 | LCRYPTO_ALIAS(ECPKParameters_print_fp); | ||
89 | 90 | ||
90 | int | 91 | int |
91 | EC_KEY_print_fp(FILE *fp, const EC_KEY *x, int off) | 92 | EC_KEY_print_fp(FILE *fp, const EC_KEY *x, int off) |
@@ -102,6 +103,7 @@ EC_KEY_print_fp(FILE *fp, const EC_KEY *x, int off) | |||
102 | BIO_free(b); | 103 | BIO_free(b); |
103 | return (ret); | 104 | return (ret); |
104 | } | 105 | } |
106 | LCRYPTO_ALIAS(EC_KEY_print_fp); | ||
105 | 107 | ||
106 | int | 108 | int |
107 | ECParameters_print_fp(FILE *fp, const EC_KEY *x) | 109 | ECParameters_print_fp(FILE *fp, const EC_KEY *x) |
@@ -118,6 +120,7 @@ ECParameters_print_fp(FILE *fp, const EC_KEY *x) | |||
118 | BIO_free(b); | 120 | BIO_free(b); |
119 | return (ret); | 121 | return (ret); |
120 | } | 122 | } |
123 | LCRYPTO_ALIAS(ECParameters_print_fp); | ||
121 | 124 | ||
122 | int | 125 | int |
123 | EC_KEY_print(BIO *bp, const EC_KEY *x, int off) | 126 | EC_KEY_print(BIO *bp, const EC_KEY *x, int off) |
@@ -136,6 +139,7 @@ EC_KEY_print(BIO *bp, const EC_KEY *x, int off) | |||
136 | EVP_PKEY_free(pk); | 139 | EVP_PKEY_free(pk); |
137 | return ret; | 140 | return ret; |
138 | } | 141 | } |
142 | LCRYPTO_ALIAS(EC_KEY_print); | ||
139 | 143 | ||
140 | int | 144 | int |
141 | ECParameters_print(BIO *bp, const EC_KEY *x) | 145 | ECParameters_print(BIO *bp, const EC_KEY *x) |
@@ -154,6 +158,7 @@ ECParameters_print(BIO *bp, const EC_KEY *x) | |||
154 | EVP_PKEY_free(pk); | 158 | EVP_PKEY_free(pk); |
155 | return ret; | 159 | return ret; |
156 | } | 160 | } |
161 | LCRYPTO_ALIAS(ECParameters_print); | ||
157 | 162 | ||
158 | static int | 163 | static int |
159 | print_bin(BIO *fp, const char *str, const unsigned char *num, | 164 | print_bin(BIO *fp, const char *str, const unsigned char *num, |
@@ -310,6 +315,7 @@ ECPKParameters_print(BIO *bp, const EC_GROUP *group, int off) | |||
310 | 315 | ||
311 | return ecpk_print_explicit_parameters(bp, group, off); | 316 | return ecpk_print_explicit_parameters(bp, group, off); |
312 | } | 317 | } |
318 | LCRYPTO_ALIAS(ECPKParameters_print); | ||
313 | 319 | ||
314 | static int | 320 | static int |
315 | print_bin(BIO *fp, const char *name, const unsigned char *buf, | 321 | print_bin(BIO *fp, const char *name, const unsigned char *buf, |
diff --git a/src/lib/libcrypto/ec/ecp_mont.c b/src/lib/libcrypto/ec/ecp_mont.c index b113855603..76d1f578ee 100644 --- a/src/lib/libcrypto/ec/ecp_mont.c +++ b/src/lib/libcrypto/ec/ecp_mont.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecp_mont.c,v 1.29 2023/04/11 18:58:20 jsing Exp $ */ | 1 | /* $OpenBSD: ecp_mont.c,v 1.30 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Originally written by Bodo Moeller for the OpenSSL project. | 3 | * Originally written by Bodo Moeller for the OpenSSL project. |
4 | */ | 4 | */ |
@@ -269,3 +269,4 @@ EC_GFp_mont_method(void) | |||
269 | { | 269 | { |
270 | return &ec_GFp_mont_method; | 270 | return &ec_GFp_mont_method; |
271 | } | 271 | } |
272 | LCRYPTO_ALIAS(EC_GFp_mont_method); | ||
diff --git a/src/lib/libcrypto/ec/ecp_smpl.c b/src/lib/libcrypto/ec/ecp_smpl.c index d3ee9f5d92..9aa9af11f3 100644 --- a/src/lib/libcrypto/ec/ecp_smpl.c +++ b/src/lib/libcrypto/ec/ecp_smpl.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecp_smpl.c,v 1.45 2023/06/30 18:19:35 tb Exp $ */ | 1 | /* $OpenBSD: ecp_smpl.c,v 1.46 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Includes code written by Lenka Fibikova <fibikova@exp-math.uni-essen.de> | 2 | /* Includes code written by Lenka Fibikova <fibikova@exp-math.uni-essen.de> |
3 | * for the OpenSSL project. | 3 | * for the OpenSSL project. |
4 | * Includes code written by Bodo Moeller for the OpenSSL project. | 4 | * Includes code written by Bodo Moeller for the OpenSSL project. |
@@ -1604,3 +1604,4 @@ EC_GFp_simple_method(void) | |||
1604 | { | 1604 | { |
1605 | return &ec_GFp_simple_method; | 1605 | return &ec_GFp_simple_method; |
1606 | } | 1606 | } |
1607 | LCRYPTO_ALIAS(EC_GFp_simple_method); | ||
diff --git a/src/lib/libcrypto/ecdh/ecdh.c b/src/lib/libcrypto/ecdh/ecdh.c index 1179564030..0781c30e09 100644 --- a/src/lib/libcrypto/ecdh/ecdh.c +++ b/src/lib/libcrypto/ecdh/ecdh.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecdh.c,v 1.3 2023/07/05 17:10:10 tb Exp $ */ | 1 | /* $OpenBSD: ecdh.c,v 1.4 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. | 3 | * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. |
4 | * | 4 | * |
@@ -264,9 +264,11 @@ ECDH_compute_key(void *out, size_t outlen, const EC_POINT *pub_key, | |||
264 | } | 264 | } |
265 | return eckey->meth->compute_key(out, outlen, pub_key, eckey, KDF); | 265 | return eckey->meth->compute_key(out, outlen, pub_key, eckey, KDF); |
266 | } | 266 | } |
267 | LCRYPTO_ALIAS(ECDH_compute_key); | ||
267 | 268 | ||
268 | int | 269 | int |
269 | ECDH_size(const EC_KEY *d) | 270 | ECDH_size(const EC_KEY *d) |
270 | { | 271 | { |
271 | return (EC_GROUP_get_degree(EC_KEY_get0_group(d)) + 7) / 8; | 272 | return (EC_GROUP_get_degree(EC_KEY_get0_group(d)) + 7) / 8; |
272 | } | 273 | } |
274 | LCRYPTO_ALIAS(ECDH_size); | ||
diff --git a/src/lib/libcrypto/ecdh/ech_err.c b/src/lib/libcrypto/ecdh/ech_err.c index e0cfddfe9c..1b194fe0fb 100644 --- a/src/lib/libcrypto/ecdh/ech_err.c +++ b/src/lib/libcrypto/ecdh/ech_err.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ech_err.c,v 1.7 2022/07/12 14:42:49 kn Exp $ */ | 1 | /* $OpenBSD: ech_err.c,v 1.8 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -91,3 +91,4 @@ ERR_load_ECDH_strings(void) | |||
91 | } | 91 | } |
92 | #endif | 92 | #endif |
93 | } | 93 | } |
94 | LCRYPTO_ALIAS(ERR_load_ECDH_strings); | ||
diff --git a/src/lib/libcrypto/ecdh/ech_lib.c b/src/lib/libcrypto/ecdh/ech_lib.c index 52019b01c1..c8e5744c0a 100644 --- a/src/lib/libcrypto/ecdh/ech_lib.c +++ b/src/lib/libcrypto/ecdh/ech_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ech_lib.c,v 1.23 2023/07/05 08:39:40 tb Exp $ */ | 1 | /* $OpenBSD: ech_lib.c,v 1.24 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. | 3 | * Copyright 2002 Sun Microsystems, Inc. ALL RIGHTS RESERVED. |
4 | * | 4 | * |
@@ -98,12 +98,14 @@ ECDH_OpenSSL(void) | |||
98 | { | 98 | { |
99 | return &openssl_ecdh_meth; | 99 | return &openssl_ecdh_meth; |
100 | } | 100 | } |
101 | LCRYPTO_ALIAS(ECDH_OpenSSL); | ||
101 | 102 | ||
102 | void | 103 | void |
103 | ECDH_set_default_method(const ECDH_METHOD *meth) | 104 | ECDH_set_default_method(const ECDH_METHOD *meth) |
104 | { | 105 | { |
105 | default_ECDH_method = meth; | 106 | default_ECDH_method = meth; |
106 | } | 107 | } |
108 | LCRYPTO_ALIAS(ECDH_set_default_method); | ||
107 | 109 | ||
108 | const ECDH_METHOD * | 110 | const ECDH_METHOD * |
109 | ECDH_get_default_method(void) | 111 | ECDH_get_default_method(void) |
@@ -113,12 +115,14 @@ ECDH_get_default_method(void) | |||
113 | } | 115 | } |
114 | return default_ECDH_method; | 116 | return default_ECDH_method; |
115 | } | 117 | } |
118 | LCRYPTO_ALIAS(ECDH_get_default_method); | ||
116 | 119 | ||
117 | int | 120 | int |
118 | ECDH_set_method(EC_KEY *eckey, const ECDH_METHOD *meth) | 121 | ECDH_set_method(EC_KEY *eckey, const ECDH_METHOD *meth) |
119 | { | 122 | { |
120 | return 0; | 123 | return 0; |
121 | } | 124 | } |
125 | LCRYPTO_ALIAS(ECDH_set_method); | ||
122 | 126 | ||
123 | int | 127 | int |
124 | ECDH_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | 128 | ECDH_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, |
@@ -126,15 +130,18 @@ ECDH_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | |||
126 | { | 130 | { |
127 | return -1; | 131 | return -1; |
128 | } | 132 | } |
133 | LCRYPTO_ALIAS(ECDH_get_ex_new_index); | ||
129 | 134 | ||
130 | int | 135 | int |
131 | ECDH_set_ex_data(EC_KEY *d, int idx, void *arg) | 136 | ECDH_set_ex_data(EC_KEY *d, int idx, void *arg) |
132 | { | 137 | { |
133 | return 0; | 138 | return 0; |
134 | } | 139 | } |
140 | LCRYPTO_ALIAS(ECDH_set_ex_data); | ||
135 | 141 | ||
136 | void * | 142 | void * |
137 | ECDH_get_ex_data(EC_KEY *d, int idx) | 143 | ECDH_get_ex_data(EC_KEY *d, int idx) |
138 | { | 144 | { |
139 | return NULL; | 145 | return NULL; |
140 | } | 146 | } |
147 | LCRYPTO_ALIAS(ECDH_get_ex_data); | ||
diff --git a/src/lib/libcrypto/ecdsa/ecdsa.c b/src/lib/libcrypto/ecdsa/ecdsa.c index b9c7ea6381..5a93b84637 100644 --- a/src/lib/libcrypto/ecdsa/ecdsa.c +++ b/src/lib/libcrypto/ecdsa/ecdsa.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecdsa.c,v 1.10 2023/07/05 17:10:10 tb Exp $ */ | 1 | /* $OpenBSD: ecdsa.c,v 1.11 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 2000-2002 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 2000-2002 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -104,24 +104,28 @@ d2i_ECDSA_SIG(ECDSA_SIG **a, const unsigned char **in, long len) | |||
104 | return (ECDSA_SIG *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, | 104 | return (ECDSA_SIG *)ASN1_item_d2i((ASN1_VALUE **)a, in, len, |
105 | &ECDSA_SIG_it); | 105 | &ECDSA_SIG_it); |
106 | } | 106 | } |
107 | LCRYPTO_ALIAS(d2i_ECDSA_SIG); | ||
107 | 108 | ||
108 | int | 109 | int |
109 | i2d_ECDSA_SIG(const ECDSA_SIG *a, unsigned char **out) | 110 | i2d_ECDSA_SIG(const ECDSA_SIG *a, unsigned char **out) |
110 | { | 111 | { |
111 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &ECDSA_SIG_it); | 112 | return ASN1_item_i2d((ASN1_VALUE *)a, out, &ECDSA_SIG_it); |
112 | } | 113 | } |
114 | LCRYPTO_ALIAS(i2d_ECDSA_SIG); | ||
113 | 115 | ||
114 | ECDSA_SIG * | 116 | ECDSA_SIG * |
115 | ECDSA_SIG_new(void) | 117 | ECDSA_SIG_new(void) |
116 | { | 118 | { |
117 | return (ECDSA_SIG *)ASN1_item_new(&ECDSA_SIG_it); | 119 | return (ECDSA_SIG *)ASN1_item_new(&ECDSA_SIG_it); |
118 | } | 120 | } |
121 | LCRYPTO_ALIAS(ECDSA_SIG_new); | ||
119 | 122 | ||
120 | void | 123 | void |
121 | ECDSA_SIG_free(ECDSA_SIG *a) | 124 | ECDSA_SIG_free(ECDSA_SIG *a) |
122 | { | 125 | { |
123 | ASN1_item_free((ASN1_VALUE *)a, &ECDSA_SIG_it); | 126 | ASN1_item_free((ASN1_VALUE *)a, &ECDSA_SIG_it); |
124 | } | 127 | } |
128 | LCRYPTO_ALIAS(ECDSA_SIG_free); | ||
125 | 129 | ||
126 | void | 130 | void |
127 | ECDSA_SIG_get0(const ECDSA_SIG *sig, const BIGNUM **pr, const BIGNUM **ps) | 131 | ECDSA_SIG_get0(const ECDSA_SIG *sig, const BIGNUM **pr, const BIGNUM **ps) |
@@ -131,18 +135,21 @@ ECDSA_SIG_get0(const ECDSA_SIG *sig, const BIGNUM **pr, const BIGNUM **ps) | |||
131 | if (ps != NULL) | 135 | if (ps != NULL) |
132 | *ps = sig->s; | 136 | *ps = sig->s; |
133 | } | 137 | } |
138 | LCRYPTO_ALIAS(ECDSA_SIG_get0); | ||
134 | 139 | ||
135 | const BIGNUM * | 140 | const BIGNUM * |
136 | ECDSA_SIG_get0_r(const ECDSA_SIG *sig) | 141 | ECDSA_SIG_get0_r(const ECDSA_SIG *sig) |
137 | { | 142 | { |
138 | return sig->r; | 143 | return sig->r; |
139 | } | 144 | } |
145 | LCRYPTO_ALIAS(ECDSA_SIG_get0_r); | ||
140 | 146 | ||
141 | const BIGNUM * | 147 | const BIGNUM * |
142 | ECDSA_SIG_get0_s(const ECDSA_SIG *sig) | 148 | ECDSA_SIG_get0_s(const ECDSA_SIG *sig) |
143 | { | 149 | { |
144 | return sig->s; | 150 | return sig->s; |
145 | } | 151 | } |
152 | LCRYPTO_ALIAS(ECDSA_SIG_get0_s); | ||
146 | 153 | ||
147 | int | 154 | int |
148 | ECDSA_SIG_set0(ECDSA_SIG *sig, BIGNUM *r, BIGNUM *s) | 155 | ECDSA_SIG_set0(ECDSA_SIG *sig, BIGNUM *r, BIGNUM *s) |
@@ -156,6 +163,7 @@ ECDSA_SIG_set0(ECDSA_SIG *sig, BIGNUM *r, BIGNUM *s) | |||
156 | sig->s = s; | 163 | sig->s = s; |
157 | return 1; | 164 | return 1; |
158 | } | 165 | } |
166 | LCRYPTO_ALIAS(ECDSA_SIG_set0); | ||
159 | 167 | ||
160 | int | 168 | int |
161 | ECDSA_size(const EC_KEY *r) | 169 | ECDSA_size(const EC_KEY *r) |
@@ -183,6 +191,7 @@ ECDSA_size(const EC_KEY *r) | |||
183 | err: | 191 | err: |
184 | return ret; | 192 | return ret; |
185 | } | 193 | } |
194 | LCRYPTO_ALIAS(ECDSA_size); | ||
186 | 195 | ||
187 | /* | 196 | /* |
188 | * FIPS 186-5, section 6.4.1, step 2: convert hashed message into an integer. | 197 | * FIPS 186-5, section 6.4.1, step 2: convert hashed message into an integer. |
@@ -751,6 +760,7 @@ ECDSA_do_sign(const unsigned char *digest, int digest_len, EC_KEY *key) | |||
751 | { | 760 | { |
752 | return ECDSA_do_sign_ex(digest, digest_len, NULL, NULL, key); | 761 | return ECDSA_do_sign_ex(digest, digest_len, NULL, NULL, key); |
753 | } | 762 | } |
763 | LCRYPTO_ALIAS(ECDSA_do_sign); | ||
754 | 764 | ||
755 | ECDSA_SIG * | 765 | ECDSA_SIG * |
756 | ECDSA_do_sign_ex(const unsigned char *digest, int digest_len, | 766 | ECDSA_do_sign_ex(const unsigned char *digest, int digest_len, |
@@ -762,6 +772,7 @@ ECDSA_do_sign_ex(const unsigned char *digest, int digest_len, | |||
762 | } | 772 | } |
763 | return key->meth->sign_sig(digest, digest_len, kinv, out_r, key); | 773 | return key->meth->sign_sig(digest, digest_len, kinv, out_r, key); |
764 | } | 774 | } |
775 | LCRYPTO_ALIAS(ECDSA_do_sign_ex); | ||
765 | 776 | ||
766 | int | 777 | int |
767 | ECDSA_sign(int type, const unsigned char *digest, int digest_len, | 778 | ECDSA_sign(int type, const unsigned char *digest, int digest_len, |
@@ -770,6 +781,7 @@ ECDSA_sign(int type, const unsigned char *digest, int digest_len, | |||
770 | return ECDSA_sign_ex(type, digest, digest_len, signature, signature_len, | 781 | return ECDSA_sign_ex(type, digest, digest_len, signature, signature_len, |
771 | NULL, NULL, key); | 782 | NULL, NULL, key); |
772 | } | 783 | } |
784 | LCRYPTO_ALIAS(ECDSA_sign); | ||
773 | 785 | ||
774 | int | 786 | int |
775 | ECDSA_sign_ex(int type, const unsigned char *digest, int digest_len, | 787 | ECDSA_sign_ex(int type, const unsigned char *digest, int digest_len, |
@@ -783,6 +795,7 @@ ECDSA_sign_ex(int type, const unsigned char *digest, int digest_len, | |||
783 | return key->meth->sign(type, digest, digest_len, signature, | 795 | return key->meth->sign(type, digest, digest_len, signature, |
784 | signature_len, kinv, r, key); | 796 | signature_len, kinv, r, key); |
785 | } | 797 | } |
798 | LCRYPTO_ALIAS(ECDSA_sign_ex); | ||
786 | 799 | ||
787 | int | 800 | int |
788 | ECDSA_sign_setup(EC_KEY *key, BN_CTX *in_ctx, BIGNUM **out_kinv, | 801 | ECDSA_sign_setup(EC_KEY *key, BN_CTX *in_ctx, BIGNUM **out_kinv, |
@@ -794,6 +807,7 @@ ECDSA_sign_setup(EC_KEY *key, BN_CTX *in_ctx, BIGNUM **out_kinv, | |||
794 | } | 807 | } |
795 | return key->meth->sign_setup(key, in_ctx, out_kinv, out_r); | 808 | return key->meth->sign_setup(key, in_ctx, out_kinv, out_r); |
796 | } | 809 | } |
810 | LCRYPTO_ALIAS(ECDSA_sign_setup); | ||
797 | 811 | ||
798 | int | 812 | int |
799 | ECDSA_do_verify(const unsigned char *digest, int digest_len, | 813 | ECDSA_do_verify(const unsigned char *digest, int digest_len, |
@@ -805,6 +819,7 @@ ECDSA_do_verify(const unsigned char *digest, int digest_len, | |||
805 | } | 819 | } |
806 | return key->meth->verify_sig(digest, digest_len, sig, key); | 820 | return key->meth->verify_sig(digest, digest_len, sig, key); |
807 | } | 821 | } |
822 | LCRYPTO_ALIAS(ECDSA_do_verify); | ||
808 | 823 | ||
809 | int | 824 | int |
810 | ECDSA_verify(int type, const unsigned char *digest, int digest_len, | 825 | ECDSA_verify(int type, const unsigned char *digest, int digest_len, |
@@ -816,3 +831,4 @@ ECDSA_verify(int type, const unsigned char *digest, int digest_len, | |||
816 | } | 831 | } |
817 | return key->meth->verify(type, digest, digest_len, sigbuf, sig_len, key); | 832 | return key->meth->verify(type, digest, digest_len, sigbuf, sig_len, key); |
818 | } | 833 | } |
834 | LCRYPTO_ALIAS(ECDSA_verify); | ||
diff --git a/src/lib/libcrypto/ecdsa/ecs_err.c b/src/lib/libcrypto/ecdsa/ecs_err.c index c839c35221..54d2f3f6ef 100644 --- a/src/lib/libcrypto/ecdsa/ecs_err.c +++ b/src/lib/libcrypto/ecdsa/ecs_err.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecs_err.c,v 1.7 2022/07/12 14:42:49 kn Exp $ */ | 1 | /* $OpenBSD: ecs_err.c,v 1.8 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -94,3 +94,4 @@ ERR_load_ECDSA_strings(void) | |||
94 | } | 94 | } |
95 | #endif | 95 | #endif |
96 | } | 96 | } |
97 | LCRYPTO_ALIAS(ERR_load_ECDSA_strings); | ||
diff --git a/src/lib/libcrypto/ecdsa/ecs_lib.c b/src/lib/libcrypto/ecdsa/ecs_lib.c index ed02b552c9..e3e67ba07d 100644 --- a/src/lib/libcrypto/ecdsa/ecs_lib.c +++ b/src/lib/libcrypto/ecdsa/ecs_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ecs_lib.c,v 1.24 2023/07/05 11:37:46 tb Exp $ */ | 1 | /* $OpenBSD: ecs_lib.c,v 1.25 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1998-2005 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2005 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -80,12 +80,14 @@ ECDSA_OpenSSL(void) | |||
80 | { | 80 | { |
81 | return &openssl_ecdsa_meth; | 81 | return &openssl_ecdsa_meth; |
82 | } | 82 | } |
83 | LCRYPTO_ALIAS(ECDSA_OpenSSL); | ||
83 | 84 | ||
84 | void | 85 | void |
85 | ECDSA_set_default_method(const ECDSA_METHOD *meth) | 86 | ECDSA_set_default_method(const ECDSA_METHOD *meth) |
86 | { | 87 | { |
87 | default_ECDSA_method = meth; | 88 | default_ECDSA_method = meth; |
88 | } | 89 | } |
90 | LCRYPTO_ALIAS(ECDSA_set_default_method); | ||
89 | 91 | ||
90 | const ECDSA_METHOD * | 92 | const ECDSA_METHOD * |
91 | ECDSA_get_default_method(void) | 93 | ECDSA_get_default_method(void) |
@@ -95,12 +97,14 @@ ECDSA_get_default_method(void) | |||
95 | } | 97 | } |
96 | return default_ECDSA_method; | 98 | return default_ECDSA_method; |
97 | } | 99 | } |
100 | LCRYPTO_ALIAS(ECDSA_get_default_method); | ||
98 | 101 | ||
99 | int | 102 | int |
100 | ECDSA_set_method(EC_KEY *eckey, const ECDSA_METHOD *meth) | 103 | ECDSA_set_method(EC_KEY *eckey, const ECDSA_METHOD *meth) |
101 | { | 104 | { |
102 | return 0; | 105 | return 0; |
103 | } | 106 | } |
107 | LCRYPTO_ALIAS(ECDSA_set_method); | ||
104 | 108 | ||
105 | int | 109 | int |
106 | ECDSA_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | 110 | ECDSA_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, |
@@ -108,15 +112,18 @@ ECDSA_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, | |||
108 | { | 112 | { |
109 | return -1; | 113 | return -1; |
110 | } | 114 | } |
115 | LCRYPTO_ALIAS(ECDSA_get_ex_new_index); | ||
111 | 116 | ||
112 | int | 117 | int |
113 | ECDSA_set_ex_data(EC_KEY *d, int idx, void *arg) | 118 | ECDSA_set_ex_data(EC_KEY *d, int idx, void *arg) |
114 | { | 119 | { |
115 | return 0; | 120 | return 0; |
116 | } | 121 | } |
122 | LCRYPTO_ALIAS(ECDSA_set_ex_data); | ||
117 | 123 | ||
118 | void * | 124 | void * |
119 | ECDSA_get_ex_data(EC_KEY *d, int idx) | 125 | ECDSA_get_ex_data(EC_KEY *d, int idx) |
120 | { | 126 | { |
121 | return NULL; | 127 | return NULL; |
122 | } | 128 | } |
129 | LCRYPTO_ALIAS(ECDSA_get_ex_data); | ||
diff --git a/src/lib/libcrypto/err/err.c b/src/lib/libcrypto/err/err.c index 365eae0e90..c513e45f9b 100644 --- a/src/lib/libcrypto/err/err.c +++ b/src/lib/libcrypto/err/err.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: err.c,v 1.52 2023/04/09 19:10:23 tb Exp $ */ | 1 | /* $OpenBSD: err.c,v 1.53 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -308,6 +308,7 @@ ERR_get_implementation(void) | |||
308 | err_fns_check(); | 308 | err_fns_check(); |
309 | return err_fns; | 309 | return err_fns; |
310 | } | 310 | } |
311 | LCRYPTO_ALIAS(ERR_get_implementation); | ||
311 | 312 | ||
312 | int | 313 | int |
313 | ERR_set_implementation(const ERR_FNS *fns) | 314 | ERR_set_implementation(const ERR_FNS *fns) |
@@ -324,6 +325,7 @@ ERR_set_implementation(const ERR_FNS *fns) | |||
324 | CRYPTO_w_unlock(CRYPTO_LOCK_ERR); | 325 | CRYPTO_w_unlock(CRYPTO_LOCK_ERR); |
325 | return ret; | 326 | return ret; |
326 | } | 327 | } |
328 | LCRYPTO_ALIAS(ERR_set_implementation); | ||
327 | 329 | ||
328 | /* These are the callbacks provided to "lh_new()" when creating the LHASH tables | 330 | /* These are the callbacks provided to "lh_new()" when creating the LHASH tables |
329 | * internal to the "err_defaults" implementation. */ | 331 | * internal to the "err_defaults" implementation. */ |
@@ -685,6 +687,7 @@ ERR_load_ERR_strings(void) | |||
685 | 687 | ||
686 | (void) pthread_once(&once, ERR_load_ERR_strings_internal); | 688 | (void) pthread_once(&once, ERR_load_ERR_strings_internal); |
687 | } | 689 | } |
690 | LCRYPTO_ALIAS(ERR_load_ERR_strings); | ||
688 | 691 | ||
689 | static void | 692 | static void |
690 | err_load_strings(int lib, ERR_STRING_DATA *str) | 693 | err_load_strings(int lib, ERR_STRING_DATA *str) |
@@ -703,6 +706,7 @@ ERR_load_strings(int lib, ERR_STRING_DATA *str) | |||
703 | ERR_load_ERR_strings(); | 706 | ERR_load_ERR_strings(); |
704 | err_load_strings(lib, str); | 707 | err_load_strings(lib, str); |
705 | } | 708 | } |
709 | LCRYPTO_ALIAS(ERR_load_strings); | ||
706 | 710 | ||
707 | void | 711 | void |
708 | ERR_unload_strings(int lib, ERR_STRING_DATA *str) | 712 | ERR_unload_strings(int lib, ERR_STRING_DATA *str) |
@@ -717,6 +721,7 @@ ERR_unload_strings(int lib, ERR_STRING_DATA *str) | |||
717 | str++; | 721 | str++; |
718 | } | 722 | } |
719 | } | 723 | } |
724 | LCRYPTO_ALIAS(ERR_unload_strings); | ||
720 | 725 | ||
721 | void | 726 | void |
722 | ERR_free_strings(void) | 727 | ERR_free_strings(void) |
@@ -727,6 +732,7 @@ ERR_free_strings(void) | |||
727 | err_fns_check(); | 732 | err_fns_check(); |
728 | ERRFN(err_del)(); | 733 | ERRFN(err_del)(); |
729 | } | 734 | } |
735 | LCRYPTO_ALIAS(ERR_free_strings); | ||
730 | 736 | ||
731 | /********************************************************/ | 737 | /********************************************************/ |
732 | 738 | ||
@@ -748,6 +754,7 @@ ERR_put_error(int lib, int func, int reason, const char *file, int line) | |||
748 | err_clear_data(es, es->top); | 754 | err_clear_data(es, es->top); |
749 | errno = save_errno; | 755 | errno = save_errno; |
750 | } | 756 | } |
757 | LCRYPTO_ALIAS(ERR_put_error); | ||
751 | 758 | ||
752 | void | 759 | void |
753 | ERR_clear_error(void) | 760 | ERR_clear_error(void) |
@@ -762,6 +769,7 @@ ERR_clear_error(void) | |||
762 | } | 769 | } |
763 | es->top = es->bottom = 0; | 770 | es->top = es->bottom = 0; |
764 | } | 771 | } |
772 | LCRYPTO_ALIAS(ERR_clear_error); | ||
765 | 773 | ||
766 | 774 | ||
767 | unsigned long | 775 | unsigned long |
@@ -769,12 +777,14 @@ ERR_get_error(void) | |||
769 | { | 777 | { |
770 | return (get_error_values(1, 0, NULL, NULL, NULL, NULL)); | 778 | return (get_error_values(1, 0, NULL, NULL, NULL, NULL)); |
771 | } | 779 | } |
780 | LCRYPTO_ALIAS(ERR_get_error); | ||
772 | 781 | ||
773 | unsigned long | 782 | unsigned long |
774 | ERR_get_error_line(const char **file, int *line) | 783 | ERR_get_error_line(const char **file, int *line) |
775 | { | 784 | { |
776 | return (get_error_values(1, 0, file, line, NULL, NULL)); | 785 | return (get_error_values(1, 0, file, line, NULL, NULL)); |
777 | } | 786 | } |
787 | LCRYPTO_ALIAS(ERR_get_error_line); | ||
778 | 788 | ||
779 | unsigned long | 789 | unsigned long |
780 | ERR_get_error_line_data(const char **file, int *line, | 790 | ERR_get_error_line_data(const char **file, int *line, |
@@ -782,6 +792,7 @@ ERR_get_error_line_data(const char **file, int *line, | |||
782 | { | 792 | { |
783 | return (get_error_values(1, 0, file, line, data, flags)); | 793 | return (get_error_values(1, 0, file, line, data, flags)); |
784 | } | 794 | } |
795 | LCRYPTO_ALIAS(ERR_get_error_line_data); | ||
785 | 796 | ||
786 | 797 | ||
787 | unsigned long | 798 | unsigned long |
@@ -789,12 +800,14 @@ ERR_peek_error(void) | |||
789 | { | 800 | { |
790 | return (get_error_values(0, 0, NULL, NULL, NULL, NULL)); | 801 | return (get_error_values(0, 0, NULL, NULL, NULL, NULL)); |
791 | } | 802 | } |
803 | LCRYPTO_ALIAS(ERR_peek_error); | ||
792 | 804 | ||
793 | unsigned long | 805 | unsigned long |
794 | ERR_peek_error_line(const char **file, int *line) | 806 | ERR_peek_error_line(const char **file, int *line) |
795 | { | 807 | { |
796 | return (get_error_values(0, 0, file, line, NULL, NULL)); | 808 | return (get_error_values(0, 0, file, line, NULL, NULL)); |
797 | } | 809 | } |
810 | LCRYPTO_ALIAS(ERR_peek_error_line); | ||
798 | 811 | ||
799 | unsigned long | 812 | unsigned long |
800 | ERR_peek_error_line_data(const char **file, int *line, | 813 | ERR_peek_error_line_data(const char **file, int *line, |
@@ -802,18 +815,21 @@ ERR_peek_error_line_data(const char **file, int *line, | |||
802 | { | 815 | { |
803 | return (get_error_values(0, 0, file, line, data, flags)); | 816 | return (get_error_values(0, 0, file, line, data, flags)); |
804 | } | 817 | } |
818 | LCRYPTO_ALIAS(ERR_peek_error_line_data); | ||
805 | 819 | ||
806 | unsigned long | 820 | unsigned long |
807 | ERR_peek_last_error(void) | 821 | ERR_peek_last_error(void) |
808 | { | 822 | { |
809 | return (get_error_values(0, 1, NULL, NULL, NULL, NULL)); | 823 | return (get_error_values(0, 1, NULL, NULL, NULL, NULL)); |
810 | } | 824 | } |
825 | LCRYPTO_ALIAS(ERR_peek_last_error); | ||
811 | 826 | ||
812 | unsigned long | 827 | unsigned long |
813 | ERR_peek_last_error_line(const char **file, int *line) | 828 | ERR_peek_last_error_line(const char **file, int *line) |
814 | { | 829 | { |
815 | return (get_error_values(0, 1, file, line, NULL, NULL)); | 830 | return (get_error_values(0, 1, file, line, NULL, NULL)); |
816 | } | 831 | } |
832 | LCRYPTO_ALIAS(ERR_peek_last_error_line); | ||
817 | 833 | ||
818 | unsigned long | 834 | unsigned long |
819 | ERR_peek_last_error_line_data(const char **file, int *line, | 835 | ERR_peek_last_error_line_data(const char **file, int *line, |
@@ -821,6 +837,7 @@ ERR_peek_last_error_line_data(const char **file, int *line, | |||
821 | { | 837 | { |
822 | return (get_error_values(0, 1, file, line, data, flags)); | 838 | return (get_error_values(0, 1, file, line, data, flags)); |
823 | } | 839 | } |
840 | LCRYPTO_ALIAS(ERR_peek_last_error_line_data); | ||
824 | 841 | ||
825 | static unsigned long | 842 | static unsigned long |
826 | get_error_values(int inc, int top, const char **file, int *line, | 843 | get_error_values(int inc, int top, const char **file, int *line, |
@@ -942,6 +959,7 @@ ERR_error_string_n(unsigned long e, char *buf, size_t len) | |||
942 | } | 959 | } |
943 | } | 960 | } |
944 | } | 961 | } |
962 | LCRYPTO_ALIAS(ERR_error_string_n); | ||
945 | 963 | ||
946 | /* BAD for multi-threading: uses a local buffer if ret == NULL */ | 964 | /* BAD for multi-threading: uses a local buffer if ret == NULL */ |
947 | /* ERR_error_string_n should be used instead for ret != NULL | 965 | /* ERR_error_string_n should be used instead for ret != NULL |
@@ -957,6 +975,7 @@ ERR_error_string(unsigned long e, char *ret) | |||
957 | 975 | ||
958 | return ret; | 976 | return ret; |
959 | } | 977 | } |
978 | LCRYPTO_ALIAS(ERR_error_string); | ||
960 | 979 | ||
961 | LHASH_OF(ERR_STRING_DATA) *ERR_get_string_table(void) | 980 | LHASH_OF(ERR_STRING_DATA) *ERR_get_string_table(void) |
962 | { | 981 | { |
@@ -976,6 +995,7 @@ ERR_release_err_state_table(LHASH_OF(ERR_STATE) **hash) | |||
976 | err_fns_check(); | 995 | err_fns_check(); |
977 | ERRFN(thread_release)(hash); | 996 | ERRFN(thread_release)(hash); |
978 | } | 997 | } |
998 | LCRYPTO_ALIAS(ERR_release_err_state_table); | ||
979 | 999 | ||
980 | const char * | 1000 | const char * |
981 | ERR_lib_error_string(unsigned long e) | 1001 | ERR_lib_error_string(unsigned long e) |
@@ -992,6 +1012,7 @@ ERR_lib_error_string(unsigned long e) | |||
992 | p = ERRFN(err_get_item)(&d); | 1012 | p = ERRFN(err_get_item)(&d); |
993 | return ((p == NULL) ? NULL : p->string); | 1013 | return ((p == NULL) ? NULL : p->string); |
994 | } | 1014 | } |
1015 | LCRYPTO_ALIAS(ERR_lib_error_string); | ||
995 | 1016 | ||
996 | const char * | 1017 | const char * |
997 | ERR_func_error_string(unsigned long e) | 1018 | ERR_func_error_string(unsigned long e) |
@@ -1006,6 +1027,7 @@ ERR_func_error_string(unsigned long e) | |||
1006 | p = ERRFN(err_get_item)(&d); | 1027 | p = ERRFN(err_get_item)(&d); |
1007 | return ((p == NULL) ? NULL : p->string); | 1028 | return ((p == NULL) ? NULL : p->string); |
1008 | } | 1029 | } |
1030 | LCRYPTO_ALIAS(ERR_func_error_string); | ||
1009 | 1031 | ||
1010 | const char * | 1032 | const char * |
1011 | ERR_reason_error_string(unsigned long e) | 1033 | ERR_reason_error_string(unsigned long e) |
@@ -1024,6 +1046,7 @@ ERR_reason_error_string(unsigned long e) | |||
1024 | } | 1046 | } |
1025 | return ((p == NULL) ? NULL : p->string); | 1047 | return ((p == NULL) ? NULL : p->string); |
1026 | } | 1048 | } |
1049 | LCRYPTO_ALIAS(ERR_reason_error_string); | ||
1027 | 1050 | ||
1028 | void | 1051 | void |
1029 | ERR_remove_thread_state(const CRYPTO_THREADID *id) | 1052 | ERR_remove_thread_state(const CRYPTO_THREADID *id) |
@@ -1039,12 +1062,14 @@ ERR_remove_thread_state(const CRYPTO_THREADID *id) | |||
1039 | * items reaches zero. */ | 1062 | * items reaches zero. */ |
1040 | ERRFN(thread_del_item)(&tmp); | 1063 | ERRFN(thread_del_item)(&tmp); |
1041 | } | 1064 | } |
1065 | LCRYPTO_ALIAS(ERR_remove_thread_state); | ||
1042 | 1066 | ||
1043 | void | 1067 | void |
1044 | ERR_remove_state(unsigned long pid) | 1068 | ERR_remove_state(unsigned long pid) |
1045 | { | 1069 | { |
1046 | ERR_remove_thread_state(NULL); | 1070 | ERR_remove_thread_state(NULL); |
1047 | } | 1071 | } |
1072 | LCRYPTO_ALIAS(ERR_remove_state); | ||
1048 | 1073 | ||
1049 | ERR_STATE * | 1074 | ERR_STATE * |
1050 | ERR_get_state(void) | 1075 | ERR_get_state(void) |
@@ -1084,6 +1109,7 @@ ERR_get_state(void) | |||
1084 | } | 1109 | } |
1085 | return ret; | 1110 | return ret; |
1086 | } | 1111 | } |
1112 | LCRYPTO_ALIAS(ERR_get_state); | ||
1087 | 1113 | ||
1088 | int | 1114 | int |
1089 | ERR_get_next_error_library(void) | 1115 | ERR_get_next_error_library(void) |
@@ -1091,6 +1117,7 @@ ERR_get_next_error_library(void) | |||
1091 | err_fns_check(); | 1117 | err_fns_check(); |
1092 | return ERRFN(get_next_lib)(); | 1118 | return ERRFN(get_next_lib)(); |
1093 | } | 1119 | } |
1120 | LCRYPTO_ALIAS(ERR_get_next_error_library); | ||
1094 | 1121 | ||
1095 | void | 1122 | void |
1096 | ERR_set_error_data(char *data, int flags) | 1123 | ERR_set_error_data(char *data, int flags) |
@@ -1108,6 +1135,7 @@ ERR_set_error_data(char *data, int flags) | |||
1108 | es->err_data[i] = data; | 1135 | es->err_data[i] = data; |
1109 | es->err_data_flags[i] = flags; | 1136 | es->err_data_flags[i] = flags; |
1110 | } | 1137 | } |
1138 | LCRYPTO_ALIAS(ERR_set_error_data); | ||
1111 | 1139 | ||
1112 | void | 1140 | void |
1113 | ERR_asprintf_error_data(char * format, ...) | 1141 | ERR_asprintf_error_data(char * format, ...) |
@@ -1124,6 +1152,7 @@ ERR_asprintf_error_data(char * format, ...) | |||
1124 | else | 1152 | else |
1125 | ERR_set_error_data(errbuf, ERR_TXT_MALLOCED|ERR_TXT_STRING); | 1153 | ERR_set_error_data(errbuf, ERR_TXT_MALLOCED|ERR_TXT_STRING); |
1126 | } | 1154 | } |
1155 | LCRYPTO_ALIAS(ERR_asprintf_error_data); | ||
1127 | 1156 | ||
1128 | void | 1157 | void |
1129 | ERR_add_error_vdata(int num, va_list args) | 1158 | ERR_add_error_vdata(int num, va_list args) |
@@ -1144,6 +1173,7 @@ ERR_add_error_vdata(int num, va_list args) | |||
1144 | else | 1173 | else |
1145 | ERR_set_error_data(errbuf, ERR_TXT_MALLOCED|ERR_TXT_STRING); | 1174 | ERR_set_error_data(errbuf, ERR_TXT_MALLOCED|ERR_TXT_STRING); |
1146 | } | 1175 | } |
1176 | LCRYPTO_ALIAS(ERR_add_error_vdata); | ||
1147 | 1177 | ||
1148 | void | 1178 | void |
1149 | ERR_add_error_data(int num, ...) | 1179 | ERR_add_error_data(int num, ...) |
@@ -1153,6 +1183,7 @@ ERR_add_error_data(int num, ...) | |||
1153 | ERR_add_error_vdata(num, args); | 1183 | ERR_add_error_vdata(num, args); |
1154 | va_end(args); | 1184 | va_end(args); |
1155 | } | 1185 | } |
1186 | LCRYPTO_ALIAS(ERR_add_error_data); | ||
1156 | 1187 | ||
1157 | int | 1188 | int |
1158 | ERR_set_mark(void) | 1189 | ERR_set_mark(void) |
@@ -1166,6 +1197,7 @@ ERR_set_mark(void) | |||
1166 | es->err_flags[es->top] |= ERR_FLAG_MARK; | 1197 | es->err_flags[es->top] |= ERR_FLAG_MARK; |
1167 | return 1; | 1198 | return 1; |
1168 | } | 1199 | } |
1200 | LCRYPTO_ALIAS(ERR_set_mark); | ||
1169 | 1201 | ||
1170 | int | 1202 | int |
1171 | ERR_pop_to_mark(void) | 1203 | ERR_pop_to_mark(void) |
@@ -1187,6 +1219,7 @@ ERR_pop_to_mark(void) | |||
1187 | es->err_flags[es->top]&=~ERR_FLAG_MARK; | 1219 | es->err_flags[es->top]&=~ERR_FLAG_MARK; |
1188 | return 1; | 1220 | return 1; |
1189 | } | 1221 | } |
1222 | LCRYPTO_ALIAS(ERR_pop_to_mark); | ||
1190 | 1223 | ||
1191 | void | 1224 | void |
1192 | err_clear_last_constant_time(int clear) | 1225 | err_clear_last_constant_time(int clear) |
diff --git a/src/lib/libcrypto/err/err_all.c b/src/lib/libcrypto/err/err_all.c index 9a46e93c24..12a0fcd329 100644 --- a/src/lib/libcrypto/err/err_all.c +++ b/src/lib/libcrypto/err/err_all.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: err_all.c,v 1.28 2023/06/11 05:35:43 tb Exp $ */ | 1 | /* $OpenBSD: err_all.c,v 1.29 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -174,3 +174,4 @@ ERR_load_crypto_strings(void) | |||
174 | static pthread_once_t loaded = PTHREAD_ONCE_INIT; | 174 | static pthread_once_t loaded = PTHREAD_ONCE_INIT; |
175 | (void) pthread_once(&loaded, ERR_load_crypto_strings_internal); | 175 | (void) pthread_once(&loaded, ERR_load_crypto_strings_internal); |
176 | } | 176 | } |
177 | LCRYPTO_ALIAS(ERR_load_crypto_strings); | ||
diff --git a/src/lib/libcrypto/err/err_prn.c b/src/lib/libcrypto/err/err_prn.c index 6b5c455f06..d60cfdcb92 100644 --- a/src/lib/libcrypto/err/err_prn.c +++ b/src/lib/libcrypto/err/err_prn.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: err_prn.c,v 1.19 2022/01/07 09:02:18 tb Exp $ */ | 1 | /* $OpenBSD: err_prn.c,v 1.20 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -88,6 +88,7 @@ ERR_print_errors_cb(int (*cb)(const char *str, size_t len, void *u), void *u) | |||
88 | break; /* abort outputting the error report */ | 88 | break; /* abort outputting the error report */ |
89 | } | 89 | } |
90 | } | 90 | } |
91 | LCRYPTO_ALIAS(ERR_print_errors_cb); | ||
91 | 92 | ||
92 | static int | 93 | static int |
93 | print_fp(const char *str, size_t len, void *fp) | 94 | print_fp(const char *str, size_t len, void *fp) |
@@ -105,6 +106,7 @@ ERR_print_errors_fp(FILE *fp) | |||
105 | { | 106 | { |
106 | ERR_print_errors_cb(print_fp, fp); | 107 | ERR_print_errors_cb(print_fp, fp); |
107 | } | 108 | } |
109 | LCRYPTO_ALIAS(ERR_print_errors_fp); | ||
108 | 110 | ||
109 | static int | 111 | static int |
110 | print_bio(const char *str, size_t len, void *bp) | 112 | print_bio(const char *str, size_t len, void *bp) |
@@ -117,3 +119,4 @@ ERR_print_errors(BIO *bp) | |||
117 | { | 119 | { |
118 | ERR_print_errors_cb(print_bio, bp); | 120 | ERR_print_errors_cb(print_bio, bp); |
119 | } | 121 | } |
122 | LCRYPTO_ALIAS(ERR_print_errors); | ||
diff --git a/src/lib/libcrypto/evp/bio_b64.c b/src/lib/libcrypto/evp/bio_b64.c index 8880a28375..5eceda0993 100644 --- a/src/lib/libcrypto/evp/bio_b64.c +++ b/src/lib/libcrypto/evp/bio_b64.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bio_b64.c,v 1.26 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: bio_b64.c,v 1.27 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -111,6 +111,7 @@ BIO_f_base64(void) | |||
111 | { | 111 | { |
112 | return (&methods_b64); | 112 | return (&methods_b64); |
113 | } | 113 | } |
114 | LCRYPTO_ALIAS(BIO_f_base64); | ||
114 | 115 | ||
115 | static int | 116 | static int |
116 | b64_new(BIO *bi) | 117 | b64_new(BIO *bi) |
diff --git a/src/lib/libcrypto/evp/bio_enc.c b/src/lib/libcrypto/evp/bio_enc.c index 098b1ea32b..747e64ed7f 100644 --- a/src/lib/libcrypto/evp/bio_enc.c +++ b/src/lib/libcrypto/evp/bio_enc.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bio_enc.c,v 1.27 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: bio_enc.c,v 1.28 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -106,6 +106,7 @@ BIO_f_cipher(void) | |||
106 | { | 106 | { |
107 | return (&methods_enc); | 107 | return (&methods_enc); |
108 | } | 108 | } |
109 | LCRYPTO_ALIAS(BIO_f_cipher); | ||
109 | 110 | ||
110 | static int | 111 | static int |
111 | enc_new(BIO *bi) | 112 | enc_new(BIO *bi) |
@@ -416,3 +417,4 @@ BIO_set_cipher(BIO *b, const EVP_CIPHER *c, const unsigned char *k, | |||
416 | 417 | ||
417 | return 1; | 418 | return 1; |
418 | } | 419 | } |
420 | LCRYPTO_ALIAS(BIO_set_cipher); | ||
diff --git a/src/lib/libcrypto/evp/bio_md.c b/src/lib/libcrypto/evp/bio_md.c index 4b7ca44551..83d6c3732c 100644 --- a/src/lib/libcrypto/evp/bio_md.c +++ b/src/lib/libcrypto/evp/bio_md.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bio_md.c,v 1.19 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: bio_md.c,v 1.20 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -94,6 +94,7 @@ BIO_f_md(void) | |||
94 | { | 94 | { |
95 | return (&methods_md); | 95 | return (&methods_md); |
96 | } | 96 | } |
97 | LCRYPTO_ALIAS(BIO_f_md); | ||
97 | 98 | ||
98 | static int | 99 | static int |
99 | md_new(BIO *bi) | 100 | md_new(BIO *bi) |
diff --git a/src/lib/libcrypto/evp/c_all.c b/src/lib/libcrypto/evp/c_all.c index 936d7e810f..5efcd5f237 100644 --- a/src/lib/libcrypto/evp/c_all.c +++ b/src/lib/libcrypto/evp/c_all.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: c_all.c,v 1.29 2023/04/25 15:48:48 tb Exp $ */ | 1 | /* $OpenBSD: c_all.c,v 1.30 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -251,6 +251,7 @@ OpenSSL_add_all_ciphers(void) | |||
251 | static pthread_once_t add_all_ciphers_once = PTHREAD_ONCE_INIT; | 251 | static pthread_once_t add_all_ciphers_once = PTHREAD_ONCE_INIT; |
252 | (void) pthread_once(&add_all_ciphers_once, OpenSSL_add_all_ciphers_internal); | 252 | (void) pthread_once(&add_all_ciphers_once, OpenSSL_add_all_ciphers_internal); |
253 | } | 253 | } |
254 | LCRYPTO_ALIAS(OpenSSL_add_all_ciphers); | ||
254 | 255 | ||
255 | static void | 256 | static void |
256 | OpenSSL_add_all_digests_internal(void) | 257 | OpenSSL_add_all_digests_internal(void) |
@@ -313,6 +314,7 @@ OpenSSL_add_all_digests(void) | |||
313 | static pthread_once_t add_all_digests_once = PTHREAD_ONCE_INIT; | 314 | static pthread_once_t add_all_digests_once = PTHREAD_ONCE_INIT; |
314 | (void) pthread_once(&add_all_digests_once, OpenSSL_add_all_digests_internal); | 315 | (void) pthread_once(&add_all_digests_once, OpenSSL_add_all_digests_internal); |
315 | } | 316 | } |
317 | LCRYPTO_ALIAS(OpenSSL_add_all_digests); | ||
316 | 318 | ||
317 | void | 319 | void |
318 | OPENSSL_add_all_algorithms_noconf(void) | 320 | OPENSSL_add_all_algorithms_noconf(void) |
@@ -321,6 +323,7 @@ OPENSSL_add_all_algorithms_noconf(void) | |||
321 | OpenSSL_add_all_ciphers(); | 323 | OpenSSL_add_all_ciphers(); |
322 | OpenSSL_add_all_digests(); | 324 | OpenSSL_add_all_digests(); |
323 | } | 325 | } |
326 | LCRYPTO_ALIAS(OPENSSL_add_all_algorithms_noconf); | ||
324 | 327 | ||
325 | void | 328 | void |
326 | OPENSSL_add_all_algorithms_conf(void) | 329 | OPENSSL_add_all_algorithms_conf(void) |
@@ -328,3 +331,4 @@ OPENSSL_add_all_algorithms_conf(void) | |||
328 | OPENSSL_add_all_algorithms_noconf(); | 331 | OPENSSL_add_all_algorithms_noconf(); |
329 | OPENSSL_config(NULL); | 332 | OPENSSL_config(NULL); |
330 | } | 333 | } |
334 | LCRYPTO_ALIAS(OPENSSL_add_all_algorithms_conf); | ||
diff --git a/src/lib/libcrypto/evp/cipher_method_lib.c b/src/lib/libcrypto/evp/cipher_method_lib.c index 55dc6b788c..9e4fd483a3 100644 --- a/src/lib/libcrypto/evp/cipher_method_lib.c +++ b/src/lib/libcrypto/evp/cipher_method_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: cipher_method_lib.c,v 1.8 2023/03/01 11:27:37 tb Exp $ */ | 1 | /* $OpenBSD: cipher_method_lib.c,v 1.9 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Richard Levitte (levitte@openssl.org) for the OpenSSL project | 3 | * Written by Richard Levitte (levitte@openssl.org) for the OpenSSL project |
4 | * 2015. | 4 | * 2015. |
@@ -77,6 +77,7 @@ EVP_CIPHER_meth_new(int cipher_type, int block_size, int key_len) | |||
77 | 77 | ||
78 | return cipher; | 78 | return cipher; |
79 | } | 79 | } |
80 | LCRYPTO_ALIAS(EVP_CIPHER_meth_new); | ||
80 | 81 | ||
81 | EVP_CIPHER * | 82 | EVP_CIPHER * |
82 | EVP_CIPHER_meth_dup(const EVP_CIPHER *cipher) | 83 | EVP_CIPHER_meth_dup(const EVP_CIPHER *cipher) |
@@ -90,12 +91,14 @@ EVP_CIPHER_meth_dup(const EVP_CIPHER *cipher) | |||
90 | 91 | ||
91 | return copy; | 92 | return copy; |
92 | } | 93 | } |
94 | LCRYPTO_ALIAS(EVP_CIPHER_meth_dup); | ||
93 | 95 | ||
94 | void | 96 | void |
95 | EVP_CIPHER_meth_free(EVP_CIPHER *cipher) | 97 | EVP_CIPHER_meth_free(EVP_CIPHER *cipher) |
96 | { | 98 | { |
97 | free(cipher); | 99 | free(cipher); |
98 | } | 100 | } |
101 | LCRYPTO_ALIAS(EVP_CIPHER_meth_free); | ||
99 | 102 | ||
100 | int | 103 | int |
101 | EVP_CIPHER_meth_set_iv_length(EVP_CIPHER *cipher, int iv_len) | 104 | EVP_CIPHER_meth_set_iv_length(EVP_CIPHER *cipher, int iv_len) |
@@ -104,6 +107,7 @@ EVP_CIPHER_meth_set_iv_length(EVP_CIPHER *cipher, int iv_len) | |||
104 | 107 | ||
105 | return 1; | 108 | return 1; |
106 | } | 109 | } |
110 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_iv_length); | ||
107 | 111 | ||
108 | int | 112 | int |
109 | EVP_CIPHER_meth_set_flags(EVP_CIPHER *cipher, unsigned long flags) | 113 | EVP_CIPHER_meth_set_flags(EVP_CIPHER *cipher, unsigned long flags) |
@@ -112,6 +116,7 @@ EVP_CIPHER_meth_set_flags(EVP_CIPHER *cipher, unsigned long flags) | |||
112 | 116 | ||
113 | return 1; | 117 | return 1; |
114 | } | 118 | } |
119 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_flags); | ||
115 | 120 | ||
116 | int | 121 | int |
117 | EVP_CIPHER_meth_set_impl_ctx_size(EVP_CIPHER *cipher, int ctx_size) | 122 | EVP_CIPHER_meth_set_impl_ctx_size(EVP_CIPHER *cipher, int ctx_size) |
@@ -120,6 +125,7 @@ EVP_CIPHER_meth_set_impl_ctx_size(EVP_CIPHER *cipher, int ctx_size) | |||
120 | 125 | ||
121 | return 1; | 126 | return 1; |
122 | } | 127 | } |
128 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_impl_ctx_size); | ||
123 | 129 | ||
124 | int | 130 | int |
125 | EVP_CIPHER_meth_set_init(EVP_CIPHER *cipher, | 131 | EVP_CIPHER_meth_set_init(EVP_CIPHER *cipher, |
@@ -130,6 +136,7 @@ EVP_CIPHER_meth_set_init(EVP_CIPHER *cipher, | |||
130 | 136 | ||
131 | return 1; | 137 | return 1; |
132 | } | 138 | } |
139 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_init); | ||
133 | 140 | ||
134 | int | 141 | int |
135 | EVP_CIPHER_meth_set_do_cipher(EVP_CIPHER *cipher, | 142 | EVP_CIPHER_meth_set_do_cipher(EVP_CIPHER *cipher, |
@@ -140,6 +147,7 @@ EVP_CIPHER_meth_set_do_cipher(EVP_CIPHER *cipher, | |||
140 | 147 | ||
141 | return 1; | 148 | return 1; |
142 | } | 149 | } |
150 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_do_cipher); | ||
143 | 151 | ||
144 | int | 152 | int |
145 | EVP_CIPHER_meth_set_cleanup(EVP_CIPHER *cipher, | 153 | EVP_CIPHER_meth_set_cleanup(EVP_CIPHER *cipher, |
@@ -149,6 +157,7 @@ EVP_CIPHER_meth_set_cleanup(EVP_CIPHER *cipher, | |||
149 | 157 | ||
150 | return 1; | 158 | return 1; |
151 | } | 159 | } |
160 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_cleanup); | ||
152 | 161 | ||
153 | int | 162 | int |
154 | EVP_CIPHER_meth_set_set_asn1_params(EVP_CIPHER *cipher, | 163 | EVP_CIPHER_meth_set_set_asn1_params(EVP_CIPHER *cipher, |
@@ -158,6 +167,7 @@ EVP_CIPHER_meth_set_set_asn1_params(EVP_CIPHER *cipher, | |||
158 | 167 | ||
159 | return 1; | 168 | return 1; |
160 | } | 169 | } |
170 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_set_asn1_params); | ||
161 | 171 | ||
162 | int | 172 | int |
163 | EVP_CIPHER_meth_set_get_asn1_params(EVP_CIPHER *cipher, | 173 | EVP_CIPHER_meth_set_get_asn1_params(EVP_CIPHER *cipher, |
@@ -167,6 +177,7 @@ EVP_CIPHER_meth_set_get_asn1_params(EVP_CIPHER *cipher, | |||
167 | 177 | ||
168 | return 1; | 178 | return 1; |
169 | } | 179 | } |
180 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_get_asn1_params); | ||
170 | 181 | ||
171 | int | 182 | int |
172 | EVP_CIPHER_meth_set_ctrl(EVP_CIPHER *cipher, | 183 | EVP_CIPHER_meth_set_ctrl(EVP_CIPHER *cipher, |
@@ -176,3 +187,4 @@ EVP_CIPHER_meth_set_ctrl(EVP_CIPHER *cipher, | |||
176 | 187 | ||
177 | return 1; | 188 | return 1; |
178 | } | 189 | } |
190 | LCRYPTO_ALIAS(EVP_CIPHER_meth_set_ctrl); | ||
diff --git a/src/lib/libcrypto/evp/digest.c b/src/lib/libcrypto/evp/digest.c index 7c129f025d..6615aa4a35 100644 --- a/src/lib/libcrypto/evp/digest.c +++ b/src/lib/libcrypto/evp/digest.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: digest.c,v 1.36 2022/12/26 07:18:52 jmc Exp $ */ | 1 | /* $OpenBSD: digest.c,v 1.37 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -130,6 +130,7 @@ EVP_DigestInit(EVP_MD_CTX *ctx, const EVP_MD *type) | |||
130 | EVP_MD_CTX_init(ctx); | 130 | EVP_MD_CTX_init(ctx); |
131 | return EVP_DigestInit_ex(ctx, type, NULL); | 131 | return EVP_DigestInit_ex(ctx, type, NULL); |
132 | } | 132 | } |
133 | LCRYPTO_ALIAS(EVP_DigestInit); | ||
133 | 134 | ||
134 | int | 135 | int |
135 | EVP_DigestInit_ex(EVP_MD_CTX *ctx, const EVP_MD *type, ENGINE *impl) | 136 | EVP_DigestInit_ex(EVP_MD_CTX *ctx, const EVP_MD *type, ENGINE *impl) |
@@ -211,12 +212,14 @@ skip_to_init: | |||
211 | return 1; | 212 | return 1; |
212 | return ctx->digest->init(ctx); | 213 | return ctx->digest->init(ctx); |
213 | } | 214 | } |
215 | LCRYPTO_ALIAS(EVP_DigestInit_ex); | ||
214 | 216 | ||
215 | int | 217 | int |
216 | EVP_DigestUpdate(EVP_MD_CTX *ctx, const void *data, size_t count) | 218 | EVP_DigestUpdate(EVP_MD_CTX *ctx, const void *data, size_t count) |
217 | { | 219 | { |
218 | return ctx->update(ctx, data, count); | 220 | return ctx->update(ctx, data, count); |
219 | } | 221 | } |
222 | LCRYPTO_ALIAS(EVP_DigestUpdate); | ||
220 | 223 | ||
221 | /* The caller can assume that this removes any secret data from the context */ | 224 | /* The caller can assume that this removes any secret data from the context */ |
222 | int | 225 | int |
@@ -228,6 +231,7 @@ EVP_DigestFinal(EVP_MD_CTX *ctx, unsigned char *md, unsigned int *size) | |||
228 | EVP_MD_CTX_cleanup(ctx); | 231 | EVP_MD_CTX_cleanup(ctx); |
229 | return ret; | 232 | return ret; |
230 | } | 233 | } |
234 | LCRYPTO_ALIAS(EVP_DigestFinal); | ||
231 | 235 | ||
232 | /* The caller can assume that this removes any secret data from the context */ | 236 | /* The caller can assume that this removes any secret data from the context */ |
233 | int | 237 | int |
@@ -249,6 +253,7 @@ EVP_DigestFinal_ex(EVP_MD_CTX *ctx, unsigned char *md, unsigned int *size) | |||
249 | memset(ctx->md_data, 0, ctx->digest->ctx_size); | 253 | memset(ctx->md_data, 0, ctx->digest->ctx_size); |
250 | return ret; | 254 | return ret; |
251 | } | 255 | } |
256 | LCRYPTO_ALIAS(EVP_DigestFinal_ex); | ||
252 | 257 | ||
253 | int | 258 | int |
254 | EVP_MD_CTX_copy(EVP_MD_CTX *out, const EVP_MD_CTX *in) | 259 | EVP_MD_CTX_copy(EVP_MD_CTX *out, const EVP_MD_CTX *in) |
@@ -256,6 +261,7 @@ EVP_MD_CTX_copy(EVP_MD_CTX *out, const EVP_MD_CTX *in) | |||
256 | EVP_MD_CTX_init(out); | 261 | EVP_MD_CTX_init(out); |
257 | return EVP_MD_CTX_copy_ex(out, in); | 262 | return EVP_MD_CTX_copy_ex(out, in); |
258 | } | 263 | } |
264 | LCRYPTO_ALIAS(EVP_MD_CTX_copy); | ||
259 | 265 | ||
260 | int | 266 | int |
261 | EVP_MD_CTX_copy_ex(EVP_MD_CTX *out, const EVP_MD_CTX *in) | 267 | EVP_MD_CTX_copy_ex(EVP_MD_CTX *out, const EVP_MD_CTX *in) |
@@ -318,6 +324,7 @@ EVP_MD_CTX_copy_ex(EVP_MD_CTX *out, const EVP_MD_CTX *in) | |||
318 | 324 | ||
319 | return 1; | 325 | return 1; |
320 | } | 326 | } |
327 | LCRYPTO_ALIAS(EVP_MD_CTX_copy_ex); | ||
321 | 328 | ||
322 | int | 329 | int |
323 | EVP_Digest(const void *data, size_t count, | 330 | EVP_Digest(const void *data, size_t count, |
@@ -335,12 +342,14 @@ EVP_Digest(const void *data, size_t count, | |||
335 | 342 | ||
336 | return ret; | 343 | return ret; |
337 | } | 344 | } |
345 | LCRYPTO_ALIAS(EVP_Digest); | ||
338 | 346 | ||
339 | EVP_MD_CTX * | 347 | EVP_MD_CTX * |
340 | EVP_MD_CTX_new(void) | 348 | EVP_MD_CTX_new(void) |
341 | { | 349 | { |
342 | return calloc(1, sizeof(EVP_MD_CTX)); | 350 | return calloc(1, sizeof(EVP_MD_CTX)); |
343 | } | 351 | } |
352 | LCRYPTO_ALIAS(EVP_MD_CTX_new); | ||
344 | 353 | ||
345 | void | 354 | void |
346 | EVP_MD_CTX_free(EVP_MD_CTX *ctx) | 355 | EVP_MD_CTX_free(EVP_MD_CTX *ctx) |
@@ -352,30 +361,35 @@ EVP_MD_CTX_free(EVP_MD_CTX *ctx) | |||
352 | 361 | ||
353 | free(ctx); | 362 | free(ctx); |
354 | } | 363 | } |
364 | LCRYPTO_ALIAS(EVP_MD_CTX_free); | ||
355 | 365 | ||
356 | void | 366 | void |
357 | EVP_MD_CTX_init(EVP_MD_CTX *ctx) | 367 | EVP_MD_CTX_init(EVP_MD_CTX *ctx) |
358 | { | 368 | { |
359 | memset(ctx, 0, sizeof(*ctx)); | 369 | memset(ctx, 0, sizeof(*ctx)); |
360 | } | 370 | } |
371 | LCRYPTO_ALIAS(EVP_MD_CTX_init); | ||
361 | 372 | ||
362 | int | 373 | int |
363 | EVP_MD_CTX_reset(EVP_MD_CTX *ctx) | 374 | EVP_MD_CTX_reset(EVP_MD_CTX *ctx) |
364 | { | 375 | { |
365 | return EVP_MD_CTX_cleanup(ctx); | 376 | return EVP_MD_CTX_cleanup(ctx); |
366 | } | 377 | } |
378 | LCRYPTO_ALIAS(EVP_MD_CTX_reset); | ||
367 | 379 | ||
368 | EVP_MD_CTX * | 380 | EVP_MD_CTX * |
369 | EVP_MD_CTX_create(void) | 381 | EVP_MD_CTX_create(void) |
370 | { | 382 | { |
371 | return EVP_MD_CTX_new(); | 383 | return EVP_MD_CTX_new(); |
372 | } | 384 | } |
385 | LCRYPTO_ALIAS(EVP_MD_CTX_create); | ||
373 | 386 | ||
374 | void | 387 | void |
375 | EVP_MD_CTX_destroy(EVP_MD_CTX *ctx) | 388 | EVP_MD_CTX_destroy(EVP_MD_CTX *ctx) |
376 | { | 389 | { |
377 | EVP_MD_CTX_free(ctx); | 390 | EVP_MD_CTX_free(ctx); |
378 | } | 391 | } |
392 | LCRYPTO_ALIAS(EVP_MD_CTX_destroy); | ||
379 | 393 | ||
380 | /* This call frees resources associated with the context */ | 394 | /* This call frees resources associated with the context */ |
381 | int | 395 | int |
@@ -404,6 +418,7 @@ EVP_MD_CTX_cleanup(EVP_MD_CTX *ctx) | |||
404 | 418 | ||
405 | return 1; | 419 | return 1; |
406 | } | 420 | } |
421 | LCRYPTO_ALIAS(EVP_MD_CTX_cleanup); | ||
407 | 422 | ||
408 | int | 423 | int |
409 | EVP_MD_CTX_ctrl(EVP_MD_CTX *ctx, int type, int arg, void *ptr) | 424 | EVP_MD_CTX_ctrl(EVP_MD_CTX *ctx, int type, int arg, void *ptr) |
@@ -427,3 +442,4 @@ EVP_MD_CTX_ctrl(EVP_MD_CTX *ctx, int type, int arg, void *ptr) | |||
427 | } | 442 | } |
428 | return ret; | 443 | return ret; |
429 | } | 444 | } |
445 | LCRYPTO_ALIAS(EVP_MD_CTX_ctrl); | ||
diff --git a/src/lib/libcrypto/evp/e_aes.c b/src/lib/libcrypto/evp/e_aes.c index 790b26384d..35c8d944ed 100644 --- a/src/lib/libcrypto/evp/e_aes.c +++ b/src/lib/libcrypto/evp/e_aes.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_aes.c,v 1.51 2023/03/01 11:16:06 tb Exp $ */ | 1 | /* $OpenBSD: e_aes.c,v 1.52 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 2001-2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -572,6 +572,7 @@ EVP_aes_128_cbc(void) | |||
572 | return &aes_128_cbc; | 572 | return &aes_128_cbc; |
573 | #endif | 573 | #endif |
574 | } | 574 | } |
575 | LCRYPTO_ALIAS(EVP_aes_128_cbc); | ||
575 | 576 | ||
576 | #ifdef AESNI_CAPABLE | 577 | #ifdef AESNI_CAPABLE |
577 | static const EVP_CIPHER aesni_128_ecb = { | 578 | static const EVP_CIPHER aesni_128_ecb = { |
@@ -606,6 +607,7 @@ EVP_aes_128_ecb(void) | |||
606 | return &aes_128_ecb; | 607 | return &aes_128_ecb; |
607 | #endif | 608 | #endif |
608 | } | 609 | } |
610 | LCRYPTO_ALIAS(EVP_aes_128_ecb); | ||
609 | 611 | ||
610 | #ifdef AESNI_CAPABLE | 612 | #ifdef AESNI_CAPABLE |
611 | static const EVP_CIPHER aesni_128_ofb = { | 613 | static const EVP_CIPHER aesni_128_ofb = { |
@@ -640,6 +642,7 @@ EVP_aes_128_ofb(void) | |||
640 | return &aes_128_ofb; | 642 | return &aes_128_ofb; |
641 | #endif | 643 | #endif |
642 | } | 644 | } |
645 | LCRYPTO_ALIAS(EVP_aes_128_ofb); | ||
643 | 646 | ||
644 | #ifdef AESNI_CAPABLE | 647 | #ifdef AESNI_CAPABLE |
645 | static const EVP_CIPHER aesni_128_cfb = { | 648 | static const EVP_CIPHER aesni_128_cfb = { |
@@ -708,6 +711,7 @@ EVP_aes_128_cfb1(void) | |||
708 | return &aes_128_cfb1; | 711 | return &aes_128_cfb1; |
709 | #endif | 712 | #endif |
710 | } | 713 | } |
714 | LCRYPTO_ALIAS(EVP_aes_128_cfb1); | ||
711 | 715 | ||
712 | #ifdef AESNI_CAPABLE | 716 | #ifdef AESNI_CAPABLE |
713 | static const EVP_CIPHER aesni_128_cfb8 = { | 717 | static const EVP_CIPHER aesni_128_cfb8 = { |
@@ -742,6 +746,7 @@ EVP_aes_128_cfb8(void) | |||
742 | return &aes_128_cfb8; | 746 | return &aes_128_cfb8; |
743 | #endif | 747 | #endif |
744 | } | 748 | } |
749 | LCRYPTO_ALIAS(EVP_aes_128_cfb8); | ||
745 | 750 | ||
746 | #ifdef AESNI_CAPABLE | 751 | #ifdef AESNI_CAPABLE |
747 | static const EVP_CIPHER aesni_128_ctr = { | 752 | static const EVP_CIPHER aesni_128_ctr = { |
@@ -776,6 +781,7 @@ EVP_aes_128_ctr(void) | |||
776 | return &aes_128_ctr; | 781 | return &aes_128_ctr; |
777 | #endif | 782 | #endif |
778 | } | 783 | } |
784 | LCRYPTO_ALIAS(EVP_aes_128_ctr); | ||
779 | 785 | ||
780 | 786 | ||
781 | #ifdef AESNI_CAPABLE | 787 | #ifdef AESNI_CAPABLE |
@@ -811,6 +817,7 @@ EVP_aes_192_cbc(void) | |||
811 | return &aes_192_cbc; | 817 | return &aes_192_cbc; |
812 | #endif | 818 | #endif |
813 | } | 819 | } |
820 | LCRYPTO_ALIAS(EVP_aes_192_cbc); | ||
814 | 821 | ||
815 | #ifdef AESNI_CAPABLE | 822 | #ifdef AESNI_CAPABLE |
816 | static const EVP_CIPHER aesni_192_ecb = { | 823 | static const EVP_CIPHER aesni_192_ecb = { |
@@ -845,6 +852,7 @@ EVP_aes_192_ecb(void) | |||
845 | return &aes_192_ecb; | 852 | return &aes_192_ecb; |
846 | #endif | 853 | #endif |
847 | } | 854 | } |
855 | LCRYPTO_ALIAS(EVP_aes_192_ecb); | ||
848 | 856 | ||
849 | #ifdef AESNI_CAPABLE | 857 | #ifdef AESNI_CAPABLE |
850 | static const EVP_CIPHER aesni_192_ofb = { | 858 | static const EVP_CIPHER aesni_192_ofb = { |
@@ -879,6 +887,7 @@ EVP_aes_192_ofb(void) | |||
879 | return &aes_192_ofb; | 887 | return &aes_192_ofb; |
880 | #endif | 888 | #endif |
881 | } | 889 | } |
890 | LCRYPTO_ALIAS(EVP_aes_192_ofb); | ||
882 | 891 | ||
883 | #ifdef AESNI_CAPABLE | 892 | #ifdef AESNI_CAPABLE |
884 | static const EVP_CIPHER aesni_192_cfb = { | 893 | static const EVP_CIPHER aesni_192_cfb = { |
@@ -947,6 +956,7 @@ EVP_aes_192_cfb1(void) | |||
947 | return &aes_192_cfb1; | 956 | return &aes_192_cfb1; |
948 | #endif | 957 | #endif |
949 | } | 958 | } |
959 | LCRYPTO_ALIAS(EVP_aes_192_cfb1); | ||
950 | 960 | ||
951 | #ifdef AESNI_CAPABLE | 961 | #ifdef AESNI_CAPABLE |
952 | static const EVP_CIPHER aesni_192_cfb8 = { | 962 | static const EVP_CIPHER aesni_192_cfb8 = { |
@@ -981,6 +991,7 @@ EVP_aes_192_cfb8(void) | |||
981 | return &aes_192_cfb8; | 991 | return &aes_192_cfb8; |
982 | #endif | 992 | #endif |
983 | } | 993 | } |
994 | LCRYPTO_ALIAS(EVP_aes_192_cfb8); | ||
984 | 995 | ||
985 | #ifdef AESNI_CAPABLE | 996 | #ifdef AESNI_CAPABLE |
986 | static const EVP_CIPHER aesni_192_ctr = { | 997 | static const EVP_CIPHER aesni_192_ctr = { |
@@ -1015,6 +1026,7 @@ EVP_aes_192_ctr(void) | |||
1015 | return &aes_192_ctr; | 1026 | return &aes_192_ctr; |
1016 | #endif | 1027 | #endif |
1017 | } | 1028 | } |
1029 | LCRYPTO_ALIAS(EVP_aes_192_ctr); | ||
1018 | 1030 | ||
1019 | 1031 | ||
1020 | #ifdef AESNI_CAPABLE | 1032 | #ifdef AESNI_CAPABLE |
@@ -1050,6 +1062,7 @@ EVP_aes_256_cbc(void) | |||
1050 | return &aes_256_cbc; | 1062 | return &aes_256_cbc; |
1051 | #endif | 1063 | #endif |
1052 | } | 1064 | } |
1065 | LCRYPTO_ALIAS(EVP_aes_256_cbc); | ||
1053 | 1066 | ||
1054 | #ifdef AESNI_CAPABLE | 1067 | #ifdef AESNI_CAPABLE |
1055 | static const EVP_CIPHER aesni_256_ecb = { | 1068 | static const EVP_CIPHER aesni_256_ecb = { |
@@ -1084,6 +1097,7 @@ EVP_aes_256_ecb(void) | |||
1084 | return &aes_256_ecb; | 1097 | return &aes_256_ecb; |
1085 | #endif | 1098 | #endif |
1086 | } | 1099 | } |
1100 | LCRYPTO_ALIAS(EVP_aes_256_ecb); | ||
1087 | 1101 | ||
1088 | #ifdef AESNI_CAPABLE | 1102 | #ifdef AESNI_CAPABLE |
1089 | static const EVP_CIPHER aesni_256_ofb = { | 1103 | static const EVP_CIPHER aesni_256_ofb = { |
@@ -1118,6 +1132,7 @@ EVP_aes_256_ofb(void) | |||
1118 | return &aes_256_ofb; | 1132 | return &aes_256_ofb; |
1119 | #endif | 1133 | #endif |
1120 | } | 1134 | } |
1135 | LCRYPTO_ALIAS(EVP_aes_256_ofb); | ||
1121 | 1136 | ||
1122 | #ifdef AESNI_CAPABLE | 1137 | #ifdef AESNI_CAPABLE |
1123 | static const EVP_CIPHER aesni_256_cfb = { | 1138 | static const EVP_CIPHER aesni_256_cfb = { |
@@ -1186,6 +1201,7 @@ EVP_aes_256_cfb1(void) | |||
1186 | return &aes_256_cfb1; | 1201 | return &aes_256_cfb1; |
1187 | #endif | 1202 | #endif |
1188 | } | 1203 | } |
1204 | LCRYPTO_ALIAS(EVP_aes_256_cfb1); | ||
1189 | 1205 | ||
1190 | #ifdef AESNI_CAPABLE | 1206 | #ifdef AESNI_CAPABLE |
1191 | static const EVP_CIPHER aesni_256_cfb8 = { | 1207 | static const EVP_CIPHER aesni_256_cfb8 = { |
@@ -1220,6 +1236,7 @@ EVP_aes_256_cfb8(void) | |||
1220 | return &aes_256_cfb8; | 1236 | return &aes_256_cfb8; |
1221 | #endif | 1237 | #endif |
1222 | } | 1238 | } |
1239 | LCRYPTO_ALIAS(EVP_aes_256_cfb8); | ||
1223 | 1240 | ||
1224 | #ifdef AESNI_CAPABLE | 1241 | #ifdef AESNI_CAPABLE |
1225 | static const EVP_CIPHER aesni_256_ctr = { | 1242 | static const EVP_CIPHER aesni_256_ctr = { |
@@ -1254,6 +1271,7 @@ EVP_aes_256_ctr(void) | |||
1254 | return &aes_256_ctr; | 1271 | return &aes_256_ctr; |
1255 | #endif | 1272 | #endif |
1256 | } | 1273 | } |
1274 | LCRYPTO_ALIAS(EVP_aes_256_ctr); | ||
1257 | 1275 | ||
1258 | static int | 1276 | static int |
1259 | aes_gcm_cleanup(EVP_CIPHER_CTX *c) | 1277 | aes_gcm_cleanup(EVP_CIPHER_CTX *c) |
@@ -1672,6 +1690,7 @@ EVP_aes_128_gcm(void) | |||
1672 | return &aes_128_gcm; | 1690 | return &aes_128_gcm; |
1673 | #endif | 1691 | #endif |
1674 | } | 1692 | } |
1693 | LCRYPTO_ALIAS(EVP_aes_128_gcm); | ||
1675 | 1694 | ||
1676 | #ifdef AESNI_CAPABLE | 1695 | #ifdef AESNI_CAPABLE |
1677 | static const EVP_CIPHER aesni_192_gcm = { | 1696 | static const EVP_CIPHER aesni_192_gcm = { |
@@ -1710,6 +1729,7 @@ EVP_aes_192_gcm(void) | |||
1710 | return &aes_192_gcm; | 1729 | return &aes_192_gcm; |
1711 | #endif | 1730 | #endif |
1712 | } | 1731 | } |
1732 | LCRYPTO_ALIAS(EVP_aes_192_gcm); | ||
1713 | 1733 | ||
1714 | #ifdef AESNI_CAPABLE | 1734 | #ifdef AESNI_CAPABLE |
1715 | static const EVP_CIPHER aesni_256_gcm = { | 1735 | static const EVP_CIPHER aesni_256_gcm = { |
@@ -1748,6 +1768,7 @@ EVP_aes_256_gcm(void) | |||
1748 | return &aes_256_gcm; | 1768 | return &aes_256_gcm; |
1749 | #endif | 1769 | #endif |
1750 | } | 1770 | } |
1771 | LCRYPTO_ALIAS(EVP_aes_256_gcm); | ||
1751 | 1772 | ||
1752 | static int | 1773 | static int |
1753 | aes_xts_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) | 1774 | aes_xts_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) |
@@ -1914,6 +1935,7 @@ EVP_aes_128_xts(void) | |||
1914 | return &aes_128_xts; | 1935 | return &aes_128_xts; |
1915 | #endif | 1936 | #endif |
1916 | } | 1937 | } |
1938 | LCRYPTO_ALIAS(EVP_aes_128_xts); | ||
1917 | 1939 | ||
1918 | #ifdef AESNI_CAPABLE | 1940 | #ifdef AESNI_CAPABLE |
1919 | static const EVP_CIPHER aesni_256_xts = { | 1941 | static const EVP_CIPHER aesni_256_xts = { |
@@ -1952,6 +1974,7 @@ EVP_aes_256_xts(void) | |||
1952 | return &aes_256_xts; | 1974 | return &aes_256_xts; |
1953 | #endif | 1975 | #endif |
1954 | } | 1976 | } |
1977 | LCRYPTO_ALIAS(EVP_aes_256_xts); | ||
1955 | 1978 | ||
1956 | static int | 1979 | static int |
1957 | aes_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) | 1980 | aes_ccm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr) |
@@ -2148,6 +2171,7 @@ EVP_aes_128_ccm(void) | |||
2148 | return &aes_128_ccm; | 2171 | return &aes_128_ccm; |
2149 | #endif | 2172 | #endif |
2150 | } | 2173 | } |
2174 | LCRYPTO_ALIAS(EVP_aes_128_ccm); | ||
2151 | 2175 | ||
2152 | #ifdef AESNI_CAPABLE | 2176 | #ifdef AESNI_CAPABLE |
2153 | static const EVP_CIPHER aesni_192_ccm = { | 2177 | static const EVP_CIPHER aesni_192_ccm = { |
@@ -2186,6 +2210,7 @@ EVP_aes_192_ccm(void) | |||
2186 | return &aes_192_ccm; | 2210 | return &aes_192_ccm; |
2187 | #endif | 2211 | #endif |
2188 | } | 2212 | } |
2213 | LCRYPTO_ALIAS(EVP_aes_192_ccm); | ||
2189 | 2214 | ||
2190 | #ifdef AESNI_CAPABLE | 2215 | #ifdef AESNI_CAPABLE |
2191 | static const EVP_CIPHER aesni_256_ccm = { | 2216 | static const EVP_CIPHER aesni_256_ccm = { |
@@ -2224,6 +2249,7 @@ EVP_aes_256_ccm(void) | |||
2224 | return &aes_256_ccm; | 2249 | return &aes_256_ccm; |
2225 | #endif | 2250 | #endif |
2226 | } | 2251 | } |
2252 | LCRYPTO_ALIAS(EVP_aes_256_ccm); | ||
2227 | 2253 | ||
2228 | #define EVP_AEAD_AES_GCM_TAG_LEN 16 | 2254 | #define EVP_AEAD_AES_GCM_TAG_LEN 16 |
2229 | 2255 | ||
@@ -2414,12 +2440,14 @@ EVP_aead_aes_128_gcm(void) | |||
2414 | { | 2440 | { |
2415 | return &aead_aes_128_gcm; | 2441 | return &aead_aes_128_gcm; |
2416 | } | 2442 | } |
2443 | LCRYPTO_ALIAS(EVP_aead_aes_128_gcm); | ||
2417 | 2444 | ||
2418 | const EVP_AEAD * | 2445 | const EVP_AEAD * |
2419 | EVP_aead_aes_256_gcm(void) | 2446 | EVP_aead_aes_256_gcm(void) |
2420 | { | 2447 | { |
2421 | return &aead_aes_256_gcm; | 2448 | return &aead_aes_256_gcm; |
2422 | } | 2449 | } |
2450 | LCRYPTO_ALIAS(EVP_aead_aes_256_gcm); | ||
2423 | 2451 | ||
2424 | typedef struct { | 2452 | typedef struct { |
2425 | union { | 2453 | union { |
@@ -2545,6 +2573,7 @@ EVP_aes_128_wrap(void) | |||
2545 | { | 2573 | { |
2546 | return &aes_128_wrap; | 2574 | return &aes_128_wrap; |
2547 | } | 2575 | } |
2576 | LCRYPTO_ALIAS(EVP_aes_128_wrap); | ||
2548 | 2577 | ||
2549 | static const EVP_CIPHER aes_192_wrap = { | 2578 | static const EVP_CIPHER aes_192_wrap = { |
2550 | .nid = NID_id_aes192_wrap, | 2579 | .nid = NID_id_aes192_wrap, |
@@ -2567,6 +2596,7 @@ EVP_aes_192_wrap(void) | |||
2567 | { | 2596 | { |
2568 | return &aes_192_wrap; | 2597 | return &aes_192_wrap; |
2569 | } | 2598 | } |
2599 | LCRYPTO_ALIAS(EVP_aes_192_wrap); | ||
2570 | 2600 | ||
2571 | static const EVP_CIPHER aes_256_wrap = { | 2601 | static const EVP_CIPHER aes_256_wrap = { |
2572 | .nid = NID_id_aes256_wrap, | 2602 | .nid = NID_id_aes256_wrap, |
@@ -2589,5 +2619,6 @@ EVP_aes_256_wrap(void) | |||
2589 | { | 2619 | { |
2590 | return &aes_256_wrap; | 2620 | return &aes_256_wrap; |
2591 | } | 2621 | } |
2622 | LCRYPTO_ALIAS(EVP_aes_256_wrap); | ||
2592 | 2623 | ||
2593 | #endif | 2624 | #endif |
diff --git a/src/lib/libcrypto/evp/e_aes_cbc_hmac_sha1.c b/src/lib/libcrypto/evp/e_aes_cbc_hmac_sha1.c index 9cde386150..b905b359c9 100644 --- a/src/lib/libcrypto/evp/e_aes_cbc_hmac_sha1.c +++ b/src/lib/libcrypto/evp/e_aes_cbc_hmac_sha1.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_aes_cbc_hmac_sha1.c,v 1.17 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_aes_cbc_hmac_sha1.c,v 1.18 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 2011-2013 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 2011-2013 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -581,6 +581,7 @@ EVP_aes_128_cbc_hmac_sha1(void) | |||
581 | return (OPENSSL_cpu_caps() & CPUCAP_MASK_AESNI) ? | 581 | return (OPENSSL_cpu_caps() & CPUCAP_MASK_AESNI) ? |
582 | &aesni_128_cbc_hmac_sha1_cipher : NULL; | 582 | &aesni_128_cbc_hmac_sha1_cipher : NULL; |
583 | } | 583 | } |
584 | LCRYPTO_ALIAS(EVP_aes_128_cbc_hmac_sha1); | ||
584 | 585 | ||
585 | const EVP_CIPHER * | 586 | const EVP_CIPHER * |
586 | EVP_aes_256_cbc_hmac_sha1(void) | 587 | EVP_aes_256_cbc_hmac_sha1(void) |
@@ -588,17 +589,20 @@ EVP_aes_256_cbc_hmac_sha1(void) | |||
588 | return (OPENSSL_cpu_caps() & CPUCAP_MASK_AESNI) ? | 589 | return (OPENSSL_cpu_caps() & CPUCAP_MASK_AESNI) ? |
589 | &aesni_256_cbc_hmac_sha1_cipher : NULL; | 590 | &aesni_256_cbc_hmac_sha1_cipher : NULL; |
590 | } | 591 | } |
592 | LCRYPTO_ALIAS(EVP_aes_256_cbc_hmac_sha1); | ||
591 | #else | 593 | #else |
592 | const EVP_CIPHER * | 594 | const EVP_CIPHER * |
593 | EVP_aes_128_cbc_hmac_sha1(void) | 595 | EVP_aes_128_cbc_hmac_sha1(void) |
594 | { | 596 | { |
595 | return NULL; | 597 | return NULL; |
596 | } | 598 | } |
599 | LCRYPTO_ALIAS(EVP_aes_128_cbc_hmac_sha1); | ||
597 | 600 | ||
598 | const EVP_CIPHER * | 601 | const EVP_CIPHER * |
599 | EVP_aes_256_cbc_hmac_sha1(void) | 602 | EVP_aes_256_cbc_hmac_sha1(void) |
600 | { | 603 | { |
601 | return NULL; | 604 | return NULL; |
602 | } | 605 | } |
606 | LCRYPTO_ALIAS(EVP_aes_256_cbc_hmac_sha1); | ||
603 | #endif | 607 | #endif |
604 | #endif | 608 | #endif |
diff --git a/src/lib/libcrypto/evp/e_bf.c b/src/lib/libcrypto/evp/e_bf.c index c2ab3178a5..4e671fab3e 100644 --- a/src/lib/libcrypto/evp/e_bf.c +++ b/src/lib/libcrypto/evp/e_bf.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_bf.c,v 1.15 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_bf.c,v 1.16 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -178,6 +178,7 @@ EVP_bf_cbc(void) | |||
178 | { | 178 | { |
179 | return &bf_cbc; | 179 | return &bf_cbc; |
180 | } | 180 | } |
181 | LCRYPTO_ALIAS(EVP_bf_cbc); | ||
181 | 182 | ||
182 | static const EVP_CIPHER bf_cfb64 = { | 183 | static const EVP_CIPHER bf_cfb64 = { |
183 | .nid = NID_bf_cfb64, | 184 | .nid = NID_bf_cfb64, |
@@ -200,6 +201,7 @@ EVP_bf_cfb64(void) | |||
200 | { | 201 | { |
201 | return &bf_cfb64; | 202 | return &bf_cfb64; |
202 | } | 203 | } |
204 | LCRYPTO_ALIAS(EVP_bf_cfb64); | ||
203 | 205 | ||
204 | static const EVP_CIPHER bf_ofb = { | 206 | static const EVP_CIPHER bf_ofb = { |
205 | .nid = NID_bf_ofb64, | 207 | .nid = NID_bf_ofb64, |
@@ -222,6 +224,7 @@ EVP_bf_ofb(void) | |||
222 | { | 224 | { |
223 | return &bf_ofb; | 225 | return &bf_ofb; |
224 | } | 226 | } |
227 | LCRYPTO_ALIAS(EVP_bf_ofb); | ||
225 | 228 | ||
226 | static const EVP_CIPHER bf_ecb = { | 229 | static const EVP_CIPHER bf_ecb = { |
227 | .nid = NID_bf_ecb, | 230 | .nid = NID_bf_ecb, |
@@ -244,4 +247,5 @@ EVP_bf_ecb(void) | |||
244 | { | 247 | { |
245 | return &bf_ecb; | 248 | return &bf_ecb; |
246 | } | 249 | } |
250 | LCRYPTO_ALIAS(EVP_bf_ecb); | ||
247 | #endif | 251 | #endif |
diff --git a/src/lib/libcrypto/evp/e_camellia.c b/src/lib/libcrypto/evp/e_camellia.c index 884f8cef2a..0ab6e9ca60 100644 --- a/src/lib/libcrypto/evp/e_camellia.c +++ b/src/lib/libcrypto/evp/e_camellia.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_camellia.c,v 1.16 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_camellia.c,v 1.17 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 2006 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 2006 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -179,6 +179,7 @@ EVP_camellia_128_cbc(void) | |||
179 | { | 179 | { |
180 | return &camellia_128_cbc; | 180 | return &camellia_128_cbc; |
181 | } | 181 | } |
182 | LCRYPTO_ALIAS(EVP_camellia_128_cbc); | ||
182 | 183 | ||
183 | static const EVP_CIPHER camellia_128_cfb128 = { | 184 | static const EVP_CIPHER camellia_128_cfb128 = { |
184 | .nid = NID_camellia_128_cfb128, | 185 | .nid = NID_camellia_128_cfb128, |
@@ -201,6 +202,7 @@ EVP_camellia_128_cfb128(void) | |||
201 | { | 202 | { |
202 | return &camellia_128_cfb128; | 203 | return &camellia_128_cfb128; |
203 | } | 204 | } |
205 | LCRYPTO_ALIAS(EVP_camellia_128_cfb128); | ||
204 | 206 | ||
205 | static const EVP_CIPHER camellia_128_ofb = { | 207 | static const EVP_CIPHER camellia_128_ofb = { |
206 | .nid = NID_camellia_128_ofb128, | 208 | .nid = NID_camellia_128_ofb128, |
@@ -223,6 +225,7 @@ EVP_camellia_128_ofb(void) | |||
223 | { | 225 | { |
224 | return &camellia_128_ofb; | 226 | return &camellia_128_ofb; |
225 | } | 227 | } |
228 | LCRYPTO_ALIAS(EVP_camellia_128_ofb); | ||
226 | 229 | ||
227 | static const EVP_CIPHER camellia_128_ecb = { | 230 | static const EVP_CIPHER camellia_128_ecb = { |
228 | .nid = NID_camellia_128_ecb, | 231 | .nid = NID_camellia_128_ecb, |
@@ -245,6 +248,7 @@ EVP_camellia_128_ecb(void) | |||
245 | { | 248 | { |
246 | return &camellia_128_ecb; | 249 | return &camellia_128_ecb; |
247 | } | 250 | } |
251 | LCRYPTO_ALIAS(EVP_camellia_128_ecb); | ||
248 | 252 | ||
249 | static int | 253 | static int |
250 | camellia_192_cbc_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 254 | camellia_192_cbc_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -337,6 +341,7 @@ EVP_camellia_192_cbc(void) | |||
337 | { | 341 | { |
338 | return &camellia_192_cbc; | 342 | return &camellia_192_cbc; |
339 | } | 343 | } |
344 | LCRYPTO_ALIAS(EVP_camellia_192_cbc); | ||
340 | 345 | ||
341 | static const EVP_CIPHER camellia_192_cfb128 = { | 346 | static const EVP_CIPHER camellia_192_cfb128 = { |
342 | .nid = NID_camellia_192_cfb128, | 347 | .nid = NID_camellia_192_cfb128, |
@@ -359,6 +364,7 @@ EVP_camellia_192_cfb128(void) | |||
359 | { | 364 | { |
360 | return &camellia_192_cfb128; | 365 | return &camellia_192_cfb128; |
361 | } | 366 | } |
367 | LCRYPTO_ALIAS(EVP_camellia_192_cfb128); | ||
362 | 368 | ||
363 | static const EVP_CIPHER camellia_192_ofb = { | 369 | static const EVP_CIPHER camellia_192_ofb = { |
364 | .nid = NID_camellia_192_ofb128, | 370 | .nid = NID_camellia_192_ofb128, |
@@ -381,6 +387,7 @@ EVP_camellia_192_ofb(void) | |||
381 | { | 387 | { |
382 | return &camellia_192_ofb; | 388 | return &camellia_192_ofb; |
383 | } | 389 | } |
390 | LCRYPTO_ALIAS(EVP_camellia_192_ofb); | ||
384 | 391 | ||
385 | static const EVP_CIPHER camellia_192_ecb = { | 392 | static const EVP_CIPHER camellia_192_ecb = { |
386 | .nid = NID_camellia_192_ecb, | 393 | .nid = NID_camellia_192_ecb, |
@@ -403,6 +410,7 @@ EVP_camellia_192_ecb(void) | |||
403 | { | 410 | { |
404 | return &camellia_192_ecb; | 411 | return &camellia_192_ecb; |
405 | } | 412 | } |
413 | LCRYPTO_ALIAS(EVP_camellia_192_ecb); | ||
406 | 414 | ||
407 | static int | 415 | static int |
408 | camellia_256_cbc_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 416 | camellia_256_cbc_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -495,6 +503,7 @@ EVP_camellia_256_cbc(void) | |||
495 | { | 503 | { |
496 | return &camellia_256_cbc; | 504 | return &camellia_256_cbc; |
497 | } | 505 | } |
506 | LCRYPTO_ALIAS(EVP_camellia_256_cbc); | ||
498 | 507 | ||
499 | static const EVP_CIPHER camellia_256_cfb128 = { | 508 | static const EVP_CIPHER camellia_256_cfb128 = { |
500 | .nid = NID_camellia_256_cfb128, | 509 | .nid = NID_camellia_256_cfb128, |
@@ -517,6 +526,7 @@ EVP_camellia_256_cfb128(void) | |||
517 | { | 526 | { |
518 | return &camellia_256_cfb128; | 527 | return &camellia_256_cfb128; |
519 | } | 528 | } |
529 | LCRYPTO_ALIAS(EVP_camellia_256_cfb128); | ||
520 | 530 | ||
521 | static const EVP_CIPHER camellia_256_ofb = { | 531 | static const EVP_CIPHER camellia_256_ofb = { |
522 | .nid = NID_camellia_256_ofb128, | 532 | .nid = NID_camellia_256_ofb128, |
@@ -539,6 +549,7 @@ EVP_camellia_256_ofb(void) | |||
539 | { | 549 | { |
540 | return &camellia_256_ofb; | 550 | return &camellia_256_ofb; |
541 | } | 551 | } |
552 | LCRYPTO_ALIAS(EVP_camellia_256_ofb); | ||
542 | 553 | ||
543 | static const EVP_CIPHER camellia_256_ecb = { | 554 | static const EVP_CIPHER camellia_256_ecb = { |
544 | .nid = NID_camellia_256_ecb, | 555 | .nid = NID_camellia_256_ecb, |
@@ -561,6 +572,7 @@ EVP_camellia_256_ecb(void) | |||
561 | { | 572 | { |
562 | return &camellia_256_ecb; | 573 | return &camellia_256_ecb; |
563 | } | 574 | } |
575 | LCRYPTO_ALIAS(EVP_camellia_256_ecb); | ||
564 | 576 | ||
565 | static int | 577 | static int |
566 | camellia_128_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 578 | camellia_128_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -605,6 +617,7 @@ EVP_camellia_128_cfb1(void) | |||
605 | { | 617 | { |
606 | return &camellia_128_cfb1; | 618 | return &camellia_128_cfb1; |
607 | } | 619 | } |
620 | LCRYPTO_ALIAS(EVP_camellia_128_cfb1); | ||
608 | 621 | ||
609 | static int | 622 | static int |
610 | camellia_192_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 623 | camellia_192_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -649,6 +662,7 @@ EVP_camellia_192_cfb1(void) | |||
649 | { | 662 | { |
650 | return &camellia_192_cfb1; | 663 | return &camellia_192_cfb1; |
651 | } | 664 | } |
665 | LCRYPTO_ALIAS(EVP_camellia_192_cfb1); | ||
652 | 666 | ||
653 | static int | 667 | static int |
654 | camellia_256_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 668 | camellia_256_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -693,6 +707,7 @@ EVP_camellia_256_cfb1(void) | |||
693 | { | 707 | { |
694 | return &camellia_256_cfb1; | 708 | return &camellia_256_cfb1; |
695 | } | 709 | } |
710 | LCRYPTO_ALIAS(EVP_camellia_256_cfb1); | ||
696 | 711 | ||
697 | 712 | ||
698 | static int | 713 | static int |
@@ -736,6 +751,7 @@ EVP_camellia_128_cfb8(void) | |||
736 | { | 751 | { |
737 | return &camellia_128_cfb8; | 752 | return &camellia_128_cfb8; |
738 | } | 753 | } |
754 | LCRYPTO_ALIAS(EVP_camellia_128_cfb8); | ||
739 | 755 | ||
740 | static int | 756 | static int |
741 | camellia_192_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 757 | camellia_192_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -778,6 +794,7 @@ EVP_camellia_192_cfb8(void) | |||
778 | { | 794 | { |
779 | return &camellia_192_cfb8; | 795 | return &camellia_192_cfb8; |
780 | } | 796 | } |
797 | LCRYPTO_ALIAS(EVP_camellia_192_cfb8); | ||
781 | 798 | ||
782 | static int | 799 | static int |
783 | camellia_256_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) | 800 | camellia_256_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, size_t inl) |
@@ -820,4 +837,5 @@ EVP_camellia_256_cfb8(void) | |||
820 | { | 837 | { |
821 | return &camellia_256_cfb8; | 838 | return &camellia_256_cfb8; |
822 | } | 839 | } |
840 | LCRYPTO_ALIAS(EVP_camellia_256_cfb8); | ||
823 | #endif | 841 | #endif |
diff --git a/src/lib/libcrypto/evp/e_cast.c b/src/lib/libcrypto/evp/e_cast.c index 98683e1d01..8f62ba6f29 100644 --- a/src/lib/libcrypto/evp/e_cast.c +++ b/src/lib/libcrypto/evp/e_cast.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_cast.c,v 1.14 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_cast.c,v 1.15 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -178,6 +178,7 @@ EVP_cast5_cbc(void) | |||
178 | { | 178 | { |
179 | return &cast5_cbc; | 179 | return &cast5_cbc; |
180 | } | 180 | } |
181 | LCRYPTO_ALIAS(EVP_cast5_cbc); | ||
181 | 182 | ||
182 | static const EVP_CIPHER cast5_cfb64 = { | 183 | static const EVP_CIPHER cast5_cfb64 = { |
183 | .nid = NID_cast5_cfb64, | 184 | .nid = NID_cast5_cfb64, |
@@ -200,6 +201,7 @@ EVP_cast5_cfb64(void) | |||
200 | { | 201 | { |
201 | return &cast5_cfb64; | 202 | return &cast5_cfb64; |
202 | } | 203 | } |
204 | LCRYPTO_ALIAS(EVP_cast5_cfb64); | ||
203 | 205 | ||
204 | static const EVP_CIPHER cast5_ofb = { | 206 | static const EVP_CIPHER cast5_ofb = { |
205 | .nid = NID_cast5_ofb64, | 207 | .nid = NID_cast5_ofb64, |
@@ -222,6 +224,7 @@ EVP_cast5_ofb(void) | |||
222 | { | 224 | { |
223 | return &cast5_ofb; | 225 | return &cast5_ofb; |
224 | } | 226 | } |
227 | LCRYPTO_ALIAS(EVP_cast5_ofb); | ||
225 | 228 | ||
226 | static const EVP_CIPHER cast5_ecb = { | 229 | static const EVP_CIPHER cast5_ecb = { |
227 | .nid = NID_cast5_ecb, | 230 | .nid = NID_cast5_ecb, |
@@ -244,4 +247,5 @@ EVP_cast5_ecb(void) | |||
244 | { | 247 | { |
245 | return &cast5_ecb; | 248 | return &cast5_ecb; |
246 | } | 249 | } |
250 | LCRYPTO_ALIAS(EVP_cast5_ecb); | ||
247 | #endif | 251 | #endif |
diff --git a/src/lib/libcrypto/evp/e_chacha.c b/src/lib/libcrypto/evp/e_chacha.c index f27ed1d37d..f781d66339 100644 --- a/src/lib/libcrypto/evp/e_chacha.c +++ b/src/lib/libcrypto/evp/e_chacha.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_chacha.c,v 1.10 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_chacha.c,v 1.11 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -74,5 +74,6 @@ EVP_chacha20(void) | |||
74 | { | 74 | { |
75 | return (&chacha20_cipher); | 75 | return (&chacha20_cipher); |
76 | } | 76 | } |
77 | LCRYPTO_ALIAS(EVP_chacha20); | ||
77 | 78 | ||
78 | #endif | 79 | #endif |
diff --git a/src/lib/libcrypto/evp/e_chacha20poly1305.c b/src/lib/libcrypto/evp/e_chacha20poly1305.c index 1bd04c1f1f..4b8f47cefc 100644 --- a/src/lib/libcrypto/evp/e_chacha20poly1305.c +++ b/src/lib/libcrypto/evp/e_chacha20poly1305.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_chacha20poly1305.c,v 1.28 2023/03/01 11:16:06 tb Exp $ */ | 1 | /* $OpenBSD: e_chacha20poly1305.c,v 1.29 2023/07/07 13:54:45 beck Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2022 Joel Sing <jsing@openbsd.org> | 4 | * Copyright (c) 2022 Joel Sing <jsing@openbsd.org> |
@@ -348,6 +348,7 @@ EVP_aead_chacha20_poly1305() | |||
348 | { | 348 | { |
349 | return &aead_chacha20_poly1305; | 349 | return &aead_chacha20_poly1305; |
350 | } | 350 | } |
351 | LCRYPTO_ALIAS(EVP_aead_chacha20_poly1305); | ||
351 | 352 | ||
352 | static const EVP_AEAD aead_xchacha20_poly1305 = { | 353 | static const EVP_AEAD aead_xchacha20_poly1305 = { |
353 | .key_len = 32, | 354 | .key_len = 32, |
@@ -366,6 +367,7 @@ EVP_aead_xchacha20_poly1305() | |||
366 | { | 367 | { |
367 | return &aead_xchacha20_poly1305; | 368 | return &aead_xchacha20_poly1305; |
368 | } | 369 | } |
370 | LCRYPTO_ALIAS(EVP_aead_xchacha20_poly1305); | ||
369 | 371 | ||
370 | struct chacha20_poly1305_ctx { | 372 | struct chacha20_poly1305_ctx { |
371 | ChaCha_ctx chacha; | 373 | ChaCha_ctx chacha; |
@@ -606,5 +608,6 @@ EVP_chacha20_poly1305(void) | |||
606 | { | 608 | { |
607 | return &cipher_chacha20_poly1305; | 609 | return &cipher_chacha20_poly1305; |
608 | } | 610 | } |
611 | LCRYPTO_ALIAS(EVP_chacha20_poly1305); | ||
609 | 612 | ||
610 | #endif /* !OPENSSL_NO_CHACHA && !OPENSSL_NO_POLY1305 */ | 613 | #endif /* !OPENSSL_NO_CHACHA && !OPENSSL_NO_POLY1305 */ |
diff --git a/src/lib/libcrypto/evp/e_des.c b/src/lib/libcrypto/evp/e_des.c index dffabc8125..c87de1a690 100644 --- a/src/lib/libcrypto/evp/e_des.c +++ b/src/lib/libcrypto/evp/e_des.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_des.c,v 1.20 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_des.c,v 1.21 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -242,6 +242,7 @@ EVP_des_cbc(void) | |||
242 | { | 242 | { |
243 | return &des_cbc; | 243 | return &des_cbc; |
244 | } | 244 | } |
245 | LCRYPTO_ALIAS(EVP_des_cbc); | ||
245 | 246 | ||
246 | static const EVP_CIPHER des_cfb64 = { | 247 | static const EVP_CIPHER des_cfb64 = { |
247 | .nid = NID_des_cfb64, | 248 | .nid = NID_des_cfb64, |
@@ -264,6 +265,7 @@ EVP_des_cfb64(void) | |||
264 | { | 265 | { |
265 | return &des_cfb64; | 266 | return &des_cfb64; |
266 | } | 267 | } |
268 | LCRYPTO_ALIAS(EVP_des_cfb64); | ||
267 | 269 | ||
268 | static const EVP_CIPHER des_ofb = { | 270 | static const EVP_CIPHER des_ofb = { |
269 | .nid = NID_des_ofb64, | 271 | .nid = NID_des_ofb64, |
@@ -286,6 +288,7 @@ EVP_des_ofb(void) | |||
286 | { | 288 | { |
287 | return &des_ofb; | 289 | return &des_ofb; |
288 | } | 290 | } |
291 | LCRYPTO_ALIAS(EVP_des_ofb); | ||
289 | 292 | ||
290 | static const EVP_CIPHER des_ecb = { | 293 | static const EVP_CIPHER des_ecb = { |
291 | .nid = NID_des_ecb, | 294 | .nid = NID_des_ecb, |
@@ -308,6 +311,7 @@ EVP_des_ecb(void) | |||
308 | { | 311 | { |
309 | return &des_ecb; | 312 | return &des_ecb; |
310 | } | 313 | } |
314 | LCRYPTO_ALIAS(EVP_des_ecb); | ||
311 | 315 | ||
312 | static const EVP_CIPHER des_cfb1 = { | 316 | static const EVP_CIPHER des_cfb1 = { |
313 | .nid = NID_des_cfb1, | 317 | .nid = NID_des_cfb1, |
@@ -330,6 +334,7 @@ EVP_des_cfb1(void) | |||
330 | { | 334 | { |
331 | return &des_cfb1; | 335 | return &des_cfb1; |
332 | } | 336 | } |
337 | LCRYPTO_ALIAS(EVP_des_cfb1); | ||
333 | 338 | ||
334 | static const EVP_CIPHER des_cfb8 = { | 339 | static const EVP_CIPHER des_cfb8 = { |
335 | .nid = NID_des_cfb8, | 340 | .nid = NID_des_cfb8, |
@@ -352,4 +357,5 @@ EVP_des_cfb8(void) | |||
352 | { | 357 | { |
353 | return &des_cfb8; | 358 | return &des_cfb8; |
354 | } | 359 | } |
360 | LCRYPTO_ALIAS(EVP_des_cfb8); | ||
355 | #endif | 361 | #endif |
diff --git a/src/lib/libcrypto/evp/e_des3.c b/src/lib/libcrypto/evp/e_des3.c index d6c7537aea..d345c354c0 100644 --- a/src/lib/libcrypto/evp/e_des3.c +++ b/src/lib/libcrypto/evp/e_des3.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_des3.c,v 1.26 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_des3.c,v 1.27 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -274,6 +274,7 @@ EVP_des_ede_cbc(void) | |||
274 | { | 274 | { |
275 | return &des_ede_cbc; | 275 | return &des_ede_cbc; |
276 | } | 276 | } |
277 | LCRYPTO_ALIAS(EVP_des_ede_cbc); | ||
277 | 278 | ||
278 | static const EVP_CIPHER des_ede_cfb64 = { | 279 | static const EVP_CIPHER des_ede_cfb64 = { |
279 | .nid = NID_des_ede_cfb64, | 280 | .nid = NID_des_ede_cfb64, |
@@ -296,6 +297,7 @@ EVP_des_ede_cfb64(void) | |||
296 | { | 297 | { |
297 | return &des_ede_cfb64; | 298 | return &des_ede_cfb64; |
298 | } | 299 | } |
300 | LCRYPTO_ALIAS(EVP_des_ede_cfb64); | ||
299 | 301 | ||
300 | static const EVP_CIPHER des_ede_ofb = { | 302 | static const EVP_CIPHER des_ede_ofb = { |
301 | .nid = NID_des_ede_ofb64, | 303 | .nid = NID_des_ede_ofb64, |
@@ -318,6 +320,7 @@ EVP_des_ede_ofb(void) | |||
318 | { | 320 | { |
319 | return &des_ede_ofb; | 321 | return &des_ede_ofb; |
320 | } | 322 | } |
323 | LCRYPTO_ALIAS(EVP_des_ede_ofb); | ||
321 | 324 | ||
322 | static const EVP_CIPHER des_ede_ecb = { | 325 | static const EVP_CIPHER des_ede_ecb = { |
323 | .nid = NID_des_ede_ecb, | 326 | .nid = NID_des_ede_ecb, |
@@ -340,6 +343,7 @@ EVP_des_ede_ecb(void) | |||
340 | { | 343 | { |
341 | return &des_ede_ecb; | 344 | return &des_ede_ecb; |
342 | } | 345 | } |
346 | LCRYPTO_ALIAS(EVP_des_ede_ecb); | ||
343 | 347 | ||
344 | 348 | ||
345 | #define des_ede3_cfb64_cipher des_ede_cfb64_cipher | 349 | #define des_ede3_cfb64_cipher des_ede_cfb64_cipher |
@@ -368,6 +372,7 @@ EVP_des_ede3_cbc(void) | |||
368 | { | 372 | { |
369 | return &des_ede3_cbc; | 373 | return &des_ede3_cbc; |
370 | } | 374 | } |
375 | LCRYPTO_ALIAS(EVP_des_ede3_cbc); | ||
371 | 376 | ||
372 | static const EVP_CIPHER des_ede3_cfb64 = { | 377 | static const EVP_CIPHER des_ede3_cfb64 = { |
373 | .nid = NID_des_ede3_cfb64, | 378 | .nid = NID_des_ede3_cfb64, |
@@ -390,6 +395,7 @@ EVP_des_ede3_cfb64(void) | |||
390 | { | 395 | { |
391 | return &des_ede3_cfb64; | 396 | return &des_ede3_cfb64; |
392 | } | 397 | } |
398 | LCRYPTO_ALIAS(EVP_des_ede3_cfb64); | ||
393 | 399 | ||
394 | static const EVP_CIPHER des_ede3_ofb = { | 400 | static const EVP_CIPHER des_ede3_ofb = { |
395 | .nid = NID_des_ede3_ofb64, | 401 | .nid = NID_des_ede3_ofb64, |
@@ -412,6 +418,7 @@ EVP_des_ede3_ofb(void) | |||
412 | { | 418 | { |
413 | return &des_ede3_ofb; | 419 | return &des_ede3_ofb; |
414 | } | 420 | } |
421 | LCRYPTO_ALIAS(EVP_des_ede3_ofb); | ||
415 | 422 | ||
416 | static const EVP_CIPHER des_ede3_ecb = { | 423 | static const EVP_CIPHER des_ede3_ecb = { |
417 | .nid = NID_des_ede3_ecb, | 424 | .nid = NID_des_ede3_ecb, |
@@ -434,6 +441,7 @@ EVP_des_ede3_ecb(void) | |||
434 | { | 441 | { |
435 | return &des_ede3_ecb; | 442 | return &des_ede3_ecb; |
436 | } | 443 | } |
444 | LCRYPTO_ALIAS(EVP_des_ede3_ecb); | ||
437 | 445 | ||
438 | 446 | ||
439 | static const EVP_CIPHER des_ede3_cfb1 = { | 447 | static const EVP_CIPHER des_ede3_cfb1 = { |
@@ -457,6 +465,7 @@ EVP_des_ede3_cfb1(void) | |||
457 | { | 465 | { |
458 | return &des_ede3_cfb1; | 466 | return &des_ede3_cfb1; |
459 | } | 467 | } |
468 | LCRYPTO_ALIAS(EVP_des_ede3_cfb1); | ||
460 | 469 | ||
461 | 470 | ||
462 | static const EVP_CIPHER des_ede3_cfb8 = { | 471 | static const EVP_CIPHER des_ede3_cfb8 = { |
@@ -480,16 +489,19 @@ EVP_des_ede3_cfb8(void) | |||
480 | { | 489 | { |
481 | return &des_ede3_cfb8; | 490 | return &des_ede3_cfb8; |
482 | } | 491 | } |
492 | LCRYPTO_ALIAS(EVP_des_ede3_cfb8); | ||
483 | 493 | ||
484 | const EVP_CIPHER * | 494 | const EVP_CIPHER * |
485 | EVP_des_ede(void) | 495 | EVP_des_ede(void) |
486 | { | 496 | { |
487 | return &des_ede_ecb; | 497 | return &des_ede_ecb; |
488 | } | 498 | } |
499 | LCRYPTO_ALIAS(EVP_des_ede); | ||
489 | 500 | ||
490 | const EVP_CIPHER * | 501 | const EVP_CIPHER * |
491 | EVP_des_ede3(void) | 502 | EVP_des_ede3(void) |
492 | { | 503 | { |
493 | return &des_ede3_ecb; | 504 | return &des_ede3_ecb; |
494 | } | 505 | } |
506 | LCRYPTO_ALIAS(EVP_des_ede3); | ||
495 | #endif | 507 | #endif |
diff --git a/src/lib/libcrypto/evp/e_gost2814789.c b/src/lib/libcrypto/evp/e_gost2814789.c index 6344a11e9b..fdbc662810 100644 --- a/src/lib/libcrypto/evp/e_gost2814789.c +++ b/src/lib/libcrypto/evp/e_gost2814789.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_gost2814789.c,v 1.11 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_gost2814789.c,v 1.12 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> |
4 | * Copyright (c) 2005-2006 Cryptocom LTD | 4 | * Copyright (c) 2005-2006 Cryptocom LTD |
@@ -268,6 +268,7 @@ EVP_gost2814789_ecb(void) | |||
268 | { | 268 | { |
269 | return &gost2814789_ecb; | 269 | return &gost2814789_ecb; |
270 | } | 270 | } |
271 | LCRYPTO_ALIAS(EVP_gost2814789_ecb); | ||
271 | 272 | ||
272 | static const EVP_CIPHER gost2814789_cfb64 = { | 273 | static const EVP_CIPHER gost2814789_cfb64 = { |
273 | .nid = NID_gost89_cfb64, | 274 | .nid = NID_gost89_cfb64, |
@@ -290,6 +291,7 @@ EVP_gost2814789_cfb64(void) | |||
290 | { | 291 | { |
291 | return &gost2814789_cfb64; | 292 | return &gost2814789_cfb64; |
292 | } | 293 | } |
294 | LCRYPTO_ALIAS(EVP_gost2814789_cfb64); | ||
293 | 295 | ||
294 | static const EVP_CIPHER gost2814789_cnt = { | 296 | static const EVP_CIPHER gost2814789_cnt = { |
295 | .nid = NID_gost89_cnt, | 297 | .nid = NID_gost89_cnt, |
@@ -312,4 +314,5 @@ EVP_gost2814789_cnt(void) | |||
312 | { | 314 | { |
313 | return &gost2814789_cnt; | 315 | return &gost2814789_cnt; |
314 | } | 316 | } |
317 | LCRYPTO_ALIAS(EVP_gost2814789_cnt); | ||
315 | #endif | 318 | #endif |
diff --git a/src/lib/libcrypto/evp/e_idea.c b/src/lib/libcrypto/evp/e_idea.c index b8349ee9cb..e330888ba6 100644 --- a/src/lib/libcrypto/evp/e_idea.c +++ b/src/lib/libcrypto/evp/e_idea.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_idea.c,v 1.18 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_idea.c,v 1.19 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -197,6 +197,7 @@ EVP_idea_cbc(void) | |||
197 | { | 197 | { |
198 | return &idea_cbc; | 198 | return &idea_cbc; |
199 | } | 199 | } |
200 | LCRYPTO_ALIAS(EVP_idea_cbc); | ||
200 | 201 | ||
201 | static const EVP_CIPHER idea_cfb64 = { | 202 | static const EVP_CIPHER idea_cfb64 = { |
202 | .nid = NID_idea_cfb64, | 203 | .nid = NID_idea_cfb64, |
@@ -219,6 +220,7 @@ EVP_idea_cfb64(void) | |||
219 | { | 220 | { |
220 | return &idea_cfb64; | 221 | return &idea_cfb64; |
221 | } | 222 | } |
223 | LCRYPTO_ALIAS(EVP_idea_cfb64); | ||
222 | 224 | ||
223 | static const EVP_CIPHER idea_ofb = { | 225 | static const EVP_CIPHER idea_ofb = { |
224 | .nid = NID_idea_ofb64, | 226 | .nid = NID_idea_ofb64, |
@@ -241,6 +243,7 @@ EVP_idea_ofb(void) | |||
241 | { | 243 | { |
242 | return &idea_ofb; | 244 | return &idea_ofb; |
243 | } | 245 | } |
246 | LCRYPTO_ALIAS(EVP_idea_ofb); | ||
244 | 247 | ||
245 | static const EVP_CIPHER idea_ecb = { | 248 | static const EVP_CIPHER idea_ecb = { |
246 | .nid = NID_idea_ecb, | 249 | .nid = NID_idea_ecb, |
@@ -263,4 +266,5 @@ EVP_idea_ecb(void) | |||
263 | { | 266 | { |
264 | return &idea_ecb; | 267 | return &idea_ecb; |
265 | } | 268 | } |
269 | LCRYPTO_ALIAS(EVP_idea_ecb); | ||
266 | #endif | 270 | #endif |
diff --git a/src/lib/libcrypto/evp/e_null.c b/src/lib/libcrypto/evp/e_null.c index ddd633dc7c..3daadb1479 100644 --- a/src/lib/libcrypto/evp/e_null.c +++ b/src/lib/libcrypto/evp/e_null.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_null.c,v 1.16 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_null.c,v 1.17 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -88,6 +88,7 @@ EVP_enc_null(void) | |||
88 | { | 88 | { |
89 | return (&n_cipher); | 89 | return (&n_cipher); |
90 | } | 90 | } |
91 | LCRYPTO_ALIAS(EVP_enc_null); | ||
91 | 92 | ||
92 | static int | 93 | static int |
93 | null_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, | 94 | null_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, |
diff --git a/src/lib/libcrypto/evp/e_rc2.c b/src/lib/libcrypto/evp/e_rc2.c index 78697d08c6..540c94cdfd 100644 --- a/src/lib/libcrypto/evp/e_rc2.c +++ b/src/lib/libcrypto/evp/e_rc2.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_rc2.c,v 1.20 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_rc2.c,v 1.21 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -180,6 +180,7 @@ EVP_rc2_cbc(void) | |||
180 | { | 180 | { |
181 | return &rc2_cbc; | 181 | return &rc2_cbc; |
182 | } | 182 | } |
183 | LCRYPTO_ALIAS(EVP_rc2_cbc); | ||
183 | 184 | ||
184 | static const EVP_CIPHER rc2_cfb64 = { | 185 | static const EVP_CIPHER rc2_cfb64 = { |
185 | .nid = NID_rc2_cfb64, | 186 | .nid = NID_rc2_cfb64, |
@@ -202,6 +203,7 @@ EVP_rc2_cfb64(void) | |||
202 | { | 203 | { |
203 | return &rc2_cfb64; | 204 | return &rc2_cfb64; |
204 | } | 205 | } |
206 | LCRYPTO_ALIAS(EVP_rc2_cfb64); | ||
205 | 207 | ||
206 | static const EVP_CIPHER rc2_ofb = { | 208 | static const EVP_CIPHER rc2_ofb = { |
207 | .nid = NID_rc2_ofb64, | 209 | .nid = NID_rc2_ofb64, |
@@ -224,6 +226,7 @@ EVP_rc2_ofb(void) | |||
224 | { | 226 | { |
225 | return &rc2_ofb; | 227 | return &rc2_ofb; |
226 | } | 228 | } |
229 | LCRYPTO_ALIAS(EVP_rc2_ofb); | ||
227 | 230 | ||
228 | static const EVP_CIPHER rc2_ecb = { | 231 | static const EVP_CIPHER rc2_ecb = { |
229 | .nid = NID_rc2_ecb, | 232 | .nid = NID_rc2_ecb, |
@@ -246,6 +249,7 @@ EVP_rc2_ecb(void) | |||
246 | { | 249 | { |
247 | return &rc2_ecb; | 250 | return &rc2_ecb; |
248 | } | 251 | } |
252 | LCRYPTO_ALIAS(EVP_rc2_ecb); | ||
249 | 253 | ||
250 | #define RC2_40_MAGIC 0xa0 | 254 | #define RC2_40_MAGIC 0xa0 |
251 | #define RC2_64_MAGIC 0x78 | 255 | #define RC2_64_MAGIC 0x78 |
@@ -284,12 +288,14 @@ EVP_rc2_64_cbc(void) | |||
284 | { | 288 | { |
285 | return (&r2_64_cbc_cipher); | 289 | return (&r2_64_cbc_cipher); |
286 | } | 290 | } |
291 | LCRYPTO_ALIAS(EVP_rc2_64_cbc); | ||
287 | 292 | ||
288 | const EVP_CIPHER * | 293 | const EVP_CIPHER * |
289 | EVP_rc2_40_cbc(void) | 294 | EVP_rc2_40_cbc(void) |
290 | { | 295 | { |
291 | return (&r2_40_cbc_cipher); | 296 | return (&r2_40_cbc_cipher); |
292 | } | 297 | } |
298 | LCRYPTO_ALIAS(EVP_rc2_40_cbc); | ||
293 | 299 | ||
294 | static int | 300 | static int |
295 | rc2_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, | 301 | rc2_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, |
diff --git a/src/lib/libcrypto/evp/e_rc4.c b/src/lib/libcrypto/evp/e_rc4.c index 7afc6af9cd..d79bfa729a 100644 --- a/src/lib/libcrypto/evp/e_rc4.c +++ b/src/lib/libcrypto/evp/e_rc4.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_rc4.c,v 1.15 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_rc4.c,v 1.16 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -115,12 +115,14 @@ EVP_rc4(void) | |||
115 | { | 115 | { |
116 | return (&r4_cipher); | 116 | return (&r4_cipher); |
117 | } | 117 | } |
118 | LCRYPTO_ALIAS(EVP_rc4); | ||
118 | 119 | ||
119 | const EVP_CIPHER * | 120 | const EVP_CIPHER * |
120 | EVP_rc4_40(void) | 121 | EVP_rc4_40(void) |
121 | { | 122 | { |
122 | return (&r4_40_cipher); | 123 | return (&r4_40_cipher); |
123 | } | 124 | } |
125 | LCRYPTO_ALIAS(EVP_rc4_40); | ||
124 | 126 | ||
125 | static int | 127 | static int |
126 | rc4_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, | 128 | rc4_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, |
diff --git a/src/lib/libcrypto/evp/e_rc4_hmac_md5.c b/src/lib/libcrypto/evp/e_rc4_hmac_md5.c index b3be57d5f2..1d0bced2df 100644 --- a/src/lib/libcrypto/evp/e_rc4_hmac_md5.c +++ b/src/lib/libcrypto/evp/e_rc4_hmac_md5.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_rc4_hmac_md5.c,v 1.10 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_rc4_hmac_md5.c,v 1.11 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -304,4 +304,5 @@ EVP_rc4_hmac_md5(void) | |||
304 | { | 304 | { |
305 | return (&r4_hmac_md5_cipher); | 305 | return (&r4_hmac_md5_cipher); |
306 | } | 306 | } |
307 | LCRYPTO_ALIAS(EVP_rc4_hmac_md5); | ||
307 | #endif | 308 | #endif |
diff --git a/src/lib/libcrypto/evp/e_sm4.c b/src/lib/libcrypto/evp/e_sm4.c index 0d37448109..705a914821 100644 --- a/src/lib/libcrypto/evp/e_sm4.c +++ b/src/lib/libcrypto/evp/e_sm4.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_sm4.c,v 1.7 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_sm4.c,v 1.8 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2017, 2019 Ribose Inc | 3 | * Copyright (c) 2017, 2019 Ribose Inc |
4 | * | 4 | * |
@@ -165,6 +165,7 @@ EVP_sm4_cbc(void) | |||
165 | { | 165 | { |
166 | return &sm4_cbc; | 166 | return &sm4_cbc; |
167 | } | 167 | } |
168 | LCRYPTO_ALIAS(EVP_sm4_cbc); | ||
168 | 169 | ||
169 | static const EVP_CIPHER sm4_cfb128 = { | 170 | static const EVP_CIPHER sm4_cfb128 = { |
170 | .nid = NID_sm4_cfb128, | 171 | .nid = NID_sm4_cfb128, |
@@ -187,6 +188,7 @@ EVP_sm4_cfb128(void) | |||
187 | { | 188 | { |
188 | return &sm4_cfb128; | 189 | return &sm4_cfb128; |
189 | } | 190 | } |
191 | LCRYPTO_ALIAS(EVP_sm4_cfb128); | ||
190 | 192 | ||
191 | static const EVP_CIPHER sm4_ofb = { | 193 | static const EVP_CIPHER sm4_ofb = { |
192 | .nid = NID_sm4_ofb128, | 194 | .nid = NID_sm4_ofb128, |
@@ -209,6 +211,7 @@ EVP_sm4_ofb(void) | |||
209 | { | 211 | { |
210 | return &sm4_ofb; | 212 | return &sm4_ofb; |
211 | } | 213 | } |
214 | LCRYPTO_ALIAS(EVP_sm4_ofb); | ||
212 | 215 | ||
213 | static const EVP_CIPHER sm4_ecb = { | 216 | static const EVP_CIPHER sm4_ecb = { |
214 | .nid = NID_sm4_ecb, | 217 | .nid = NID_sm4_ecb, |
@@ -231,6 +234,7 @@ EVP_sm4_ecb(void) | |||
231 | { | 234 | { |
232 | return &sm4_ecb; | 235 | return &sm4_ecb; |
233 | } | 236 | } |
237 | LCRYPTO_ALIAS(EVP_sm4_ecb); | ||
234 | 238 | ||
235 | static int | 239 | static int |
236 | sm4_ctr_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, | 240 | sm4_ctr_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, |
@@ -264,4 +268,5 @@ EVP_sm4_ctr(void) | |||
264 | { | 268 | { |
265 | return &sm4_ctr_mode; | 269 | return &sm4_ctr_mode; |
266 | } | 270 | } |
271 | LCRYPTO_ALIAS(EVP_sm4_ctr); | ||
267 | #endif | 272 | #endif |
diff --git a/src/lib/libcrypto/evp/e_xcbc_d.c b/src/lib/libcrypto/evp/e_xcbc_d.c index bbbc3a1ee9..c7810a2c22 100644 --- a/src/lib/libcrypto/evp/e_xcbc_d.c +++ b/src/lib/libcrypto/evp/e_xcbc_d.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: e_xcbc_d.c,v 1.13 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: e_xcbc_d.c,v 1.14 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -102,6 +102,7 @@ EVP_desx_cbc(void) | |||
102 | { | 102 | { |
103 | return (&d_xcbc_cipher); | 103 | return (&d_xcbc_cipher); |
104 | } | 104 | } |
105 | LCRYPTO_ALIAS(EVP_desx_cbc); | ||
105 | 106 | ||
106 | static int | 107 | static int |
107 | desx_cbc_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, | 108 | desx_cbc_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, |
diff --git a/src/lib/libcrypto/evp/encode.c b/src/lib/libcrypto/evp/encode.c index 718bdb5fc4..10cb51217a 100644 --- a/src/lib/libcrypto/evp/encode.c +++ b/src/lib/libcrypto/evp/encode.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: encode.c,v 1.30 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: encode.c,v 1.31 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -128,12 +128,14 @@ EVP_ENCODE_CTX_new(void) | |||
128 | { | 128 | { |
129 | return calloc(1, sizeof(EVP_ENCODE_CTX)); | 129 | return calloc(1, sizeof(EVP_ENCODE_CTX)); |
130 | } | 130 | } |
131 | LCRYPTO_ALIAS(EVP_ENCODE_CTX_new); | ||
131 | 132 | ||
132 | void | 133 | void |
133 | EVP_ENCODE_CTX_free(EVP_ENCODE_CTX *ctx) | 134 | EVP_ENCODE_CTX_free(EVP_ENCODE_CTX *ctx) |
134 | { | 135 | { |
135 | free(ctx); | 136 | free(ctx); |
136 | } | 137 | } |
138 | LCRYPTO_ALIAS(EVP_ENCODE_CTX_free); | ||
137 | 139 | ||
138 | void | 140 | void |
139 | EVP_EncodeInit(EVP_ENCODE_CTX *ctx) | 141 | EVP_EncodeInit(EVP_ENCODE_CTX *ctx) |
@@ -142,6 +144,7 @@ EVP_EncodeInit(EVP_ENCODE_CTX *ctx) | |||
142 | ctx->num = 0; | 144 | ctx->num = 0; |
143 | ctx->line_num = 0; | 145 | ctx->line_num = 0; |
144 | } | 146 | } |
147 | LCRYPTO_ALIAS(EVP_EncodeInit); | ||
145 | 148 | ||
146 | int | 149 | int |
147 | EVP_EncodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, | 150 | EVP_EncodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, |
@@ -192,6 +195,7 @@ EVP_EncodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, | |||
192 | 195 | ||
193 | return 1; | 196 | return 1; |
194 | } | 197 | } |
198 | LCRYPTO_ALIAS(EVP_EncodeUpdate); | ||
195 | 199 | ||
196 | void | 200 | void |
197 | EVP_EncodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) | 201 | EVP_EncodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) |
@@ -206,6 +210,7 @@ EVP_EncodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) | |||
206 | } | 210 | } |
207 | *outl = ret; | 211 | *outl = ret; |
208 | } | 212 | } |
213 | LCRYPTO_ALIAS(EVP_EncodeFinal); | ||
209 | 214 | ||
210 | int | 215 | int |
211 | EVP_EncodeBlock(unsigned char *t, const unsigned char *f, int dlen) | 216 | EVP_EncodeBlock(unsigned char *t, const unsigned char *f, int dlen) |
@@ -238,6 +243,7 @@ EVP_EncodeBlock(unsigned char *t, const unsigned char *f, int dlen) | |||
238 | *t = '\0'; | 243 | *t = '\0'; |
239 | return (ret); | 244 | return (ret); |
240 | } | 245 | } |
246 | LCRYPTO_ALIAS(EVP_EncodeBlock); | ||
241 | 247 | ||
242 | void | 248 | void |
243 | EVP_DecodeInit(EVP_ENCODE_CTX *ctx) | 249 | EVP_DecodeInit(EVP_ENCODE_CTX *ctx) |
@@ -247,6 +253,7 @@ EVP_DecodeInit(EVP_ENCODE_CTX *ctx) | |||
247 | ctx->line_num = 0; | 253 | ctx->line_num = 0; |
248 | ctx->expect_nl = 0; | 254 | ctx->expect_nl = 0; |
249 | } | 255 | } |
256 | LCRYPTO_ALIAS(EVP_DecodeInit); | ||
250 | 257 | ||
251 | int | 258 | int |
252 | EVP_DecodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, | 259 | EVP_DecodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, |
@@ -355,6 +362,7 @@ EVP_DecodeUpdate(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl, | |||
355 | ctx->num = n; | 362 | ctx->num = n; |
356 | return (rv); | 363 | return (rv); |
357 | } | 364 | } |
365 | LCRYPTO_ALIAS(EVP_DecodeUpdate); | ||
358 | 366 | ||
359 | int | 367 | int |
360 | EVP_DecodeBlock(unsigned char *t, const unsigned char *f, int n) | 368 | EVP_DecodeBlock(unsigned char *t, const unsigned char *f, int n) |
@@ -395,6 +403,7 @@ EVP_DecodeBlock(unsigned char *t, const unsigned char *f, int n) | |||
395 | } | 403 | } |
396 | return (ret); | 404 | return (ret); |
397 | } | 405 | } |
406 | LCRYPTO_ALIAS(EVP_DecodeBlock); | ||
398 | 407 | ||
399 | int | 408 | int |
400 | EVP_DecodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) | 409 | EVP_DecodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) |
@@ -412,3 +421,4 @@ EVP_DecodeFinal(EVP_ENCODE_CTX *ctx, unsigned char *out, int *outl) | |||
412 | } else | 421 | } else |
413 | return (1); | 422 | return (1); |
414 | } | 423 | } |
424 | LCRYPTO_ALIAS(EVP_DecodeFinal); | ||
diff --git a/src/lib/libcrypto/evp/evp_aead.c b/src/lib/libcrypto/evp/evp_aead.c index 58f1c8722d..8b39c7f923 100644 --- a/src/lib/libcrypto/evp/evp_aead.c +++ b/src/lib/libcrypto/evp/evp_aead.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_aead.c,v 1.8 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: evp_aead.c,v 1.9 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014, Google Inc. | 3 | * Copyright (c) 2014, Google Inc. |
4 | * | 4 | * |
@@ -28,24 +28,28 @@ EVP_AEAD_key_length(const EVP_AEAD *aead) | |||
28 | { | 28 | { |
29 | return aead->key_len; | 29 | return aead->key_len; |
30 | } | 30 | } |
31 | LCRYPTO_ALIAS(EVP_AEAD_key_length); | ||
31 | 32 | ||
32 | size_t | 33 | size_t |
33 | EVP_AEAD_nonce_length(const EVP_AEAD *aead) | 34 | EVP_AEAD_nonce_length(const EVP_AEAD *aead) |
34 | { | 35 | { |
35 | return aead->nonce_len; | 36 | return aead->nonce_len; |
36 | } | 37 | } |
38 | LCRYPTO_ALIAS(EVP_AEAD_nonce_length); | ||
37 | 39 | ||
38 | size_t | 40 | size_t |
39 | EVP_AEAD_max_overhead(const EVP_AEAD *aead) | 41 | EVP_AEAD_max_overhead(const EVP_AEAD *aead) |
40 | { | 42 | { |
41 | return aead->overhead; | 43 | return aead->overhead; |
42 | } | 44 | } |
45 | LCRYPTO_ALIAS(EVP_AEAD_max_overhead); | ||
43 | 46 | ||
44 | size_t | 47 | size_t |
45 | EVP_AEAD_max_tag_len(const EVP_AEAD *aead) | 48 | EVP_AEAD_max_tag_len(const EVP_AEAD *aead) |
46 | { | 49 | { |
47 | return aead->max_tag_len; | 50 | return aead->max_tag_len; |
48 | } | 51 | } |
52 | LCRYPTO_ALIAS(EVP_AEAD_max_tag_len); | ||
49 | 53 | ||
50 | int | 54 | int |
51 | EVP_AEAD_CTX_init(EVP_AEAD_CTX *ctx, const EVP_AEAD *aead, | 55 | EVP_AEAD_CTX_init(EVP_AEAD_CTX *ctx, const EVP_AEAD *aead, |
@@ -58,6 +62,7 @@ EVP_AEAD_CTX_init(EVP_AEAD_CTX *ctx, const EVP_AEAD *aead, | |||
58 | } | 62 | } |
59 | return aead->init(ctx, key, key_len, tag_len); | 63 | return aead->init(ctx, key, key_len, tag_len); |
60 | } | 64 | } |
65 | LCRYPTO_ALIAS(EVP_AEAD_CTX_init); | ||
61 | 66 | ||
62 | void | 67 | void |
63 | EVP_AEAD_CTX_cleanup(EVP_AEAD_CTX *ctx) | 68 | EVP_AEAD_CTX_cleanup(EVP_AEAD_CTX *ctx) |
@@ -67,12 +72,14 @@ EVP_AEAD_CTX_cleanup(EVP_AEAD_CTX *ctx) | |||
67 | ctx->aead->cleanup(ctx); | 72 | ctx->aead->cleanup(ctx); |
68 | ctx->aead = NULL; | 73 | ctx->aead = NULL; |
69 | } | 74 | } |
75 | LCRYPTO_ALIAS(EVP_AEAD_CTX_cleanup); | ||
70 | 76 | ||
71 | EVP_AEAD_CTX * | 77 | EVP_AEAD_CTX * |
72 | EVP_AEAD_CTX_new(void) | 78 | EVP_AEAD_CTX_new(void) |
73 | { | 79 | { |
74 | return calloc(1, sizeof(EVP_AEAD_CTX)); | 80 | return calloc(1, sizeof(EVP_AEAD_CTX)); |
75 | } | 81 | } |
82 | LCRYPTO_ALIAS(EVP_AEAD_CTX_new); | ||
76 | 83 | ||
77 | void | 84 | void |
78 | EVP_AEAD_CTX_free(EVP_AEAD_CTX *ctx) | 85 | EVP_AEAD_CTX_free(EVP_AEAD_CTX *ctx) |
@@ -83,6 +90,7 @@ EVP_AEAD_CTX_free(EVP_AEAD_CTX *ctx) | |||
83 | EVP_AEAD_CTX_cleanup(ctx); | 90 | EVP_AEAD_CTX_cleanup(ctx); |
84 | free(ctx); | 91 | free(ctx); |
85 | } | 92 | } |
93 | LCRYPTO_ALIAS(EVP_AEAD_CTX_free); | ||
86 | 94 | ||
87 | /* check_alias returns 0 if out points within the buffer determined by in | 95 | /* check_alias returns 0 if out points within the buffer determined by in |
88 | * and in_len and 1 otherwise. | 96 | * and in_len and 1 otherwise. |
@@ -133,6 +141,7 @@ error: | |||
133 | *out_len = 0; | 141 | *out_len = 0; |
134 | return 0; | 142 | return 0; |
135 | } | 143 | } |
144 | LCRYPTO_ALIAS(EVP_AEAD_CTX_seal); | ||
136 | 145 | ||
137 | int | 146 | int |
138 | EVP_AEAD_CTX_open(const EVP_AEAD_CTX *ctx, unsigned char *out, size_t *out_len, | 147 | EVP_AEAD_CTX_open(const EVP_AEAD_CTX *ctx, unsigned char *out, size_t *out_len, |
@@ -158,3 +167,4 @@ error: | |||
158 | *out_len = 0; | 167 | *out_len = 0; |
159 | return 0; | 168 | return 0; |
160 | } | 169 | } |
170 | LCRYPTO_ALIAS(EVP_AEAD_CTX_open); | ||
diff --git a/src/lib/libcrypto/evp/evp_enc.c b/src/lib/libcrypto/evp/evp_enc.c index df818e3a62..f9b8deddf5 100644 --- a/src/lib/libcrypto/evp/evp_enc.c +++ b/src/lib/libcrypto/evp/evp_enc.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_enc.c,v 1.50 2023/03/01 11:16:06 tb Exp $ */ | 1 | /* $OpenBSD: evp_enc.c,v 1.51 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -82,6 +82,7 @@ EVP_CipherInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, | |||
82 | EVP_CIPHER_CTX_init(ctx); | 82 | EVP_CIPHER_CTX_init(ctx); |
83 | return EVP_CipherInit_ex(ctx, cipher, NULL, key, iv, enc); | 83 | return EVP_CipherInit_ex(ctx, cipher, NULL, key, iv, enc); |
84 | } | 84 | } |
85 | LCRYPTO_ALIAS(EVP_CipherInit); | ||
85 | 86 | ||
86 | int | 87 | int |
87 | EVP_CipherInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, | 88 | EVP_CipherInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, |
@@ -230,6 +231,7 @@ skip_to_init: | |||
230 | ctx->block_mask = ctx->cipher->block_size - 1; | 231 | ctx->block_mask = ctx->cipher->block_size - 1; |
231 | return 1; | 232 | return 1; |
232 | } | 233 | } |
234 | LCRYPTO_ALIAS(EVP_CipherInit_ex); | ||
233 | 235 | ||
234 | int | 236 | int |
235 | EVP_CipherUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | 237 | EVP_CipherUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, |
@@ -240,6 +242,7 @@ EVP_CipherUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | |||
240 | else | 242 | else |
241 | return EVP_DecryptUpdate(ctx, out, outl, in, inl); | 243 | return EVP_DecryptUpdate(ctx, out, outl, in, inl); |
242 | } | 244 | } |
245 | LCRYPTO_ALIAS(EVP_CipherUpdate); | ||
243 | 246 | ||
244 | int | 247 | int |
245 | EVP_CipherFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | 248 | EVP_CipherFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) |
@@ -249,6 +252,7 @@ EVP_CipherFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
249 | else | 252 | else |
250 | return EVP_DecryptFinal_ex(ctx, out, outl); | 253 | return EVP_DecryptFinal_ex(ctx, out, outl); |
251 | } | 254 | } |
255 | LCRYPTO_ALIAS(EVP_CipherFinal_ex); | ||
252 | 256 | ||
253 | __warn_references(EVP_CipherFinal, | 257 | __warn_references(EVP_CipherFinal, |
254 | "EVP_CipherFinal is often misused, please use EVP_CipherFinal_ex and EVP_CIPHER_CTX_cleanup"); | 258 | "EVP_CipherFinal is often misused, please use EVP_CipherFinal_ex and EVP_CIPHER_CTX_cleanup"); |
@@ -263,6 +267,7 @@ EVP_CipherFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
263 | ret = EVP_DecryptFinal_ex(ctx, out, outl); | 267 | ret = EVP_DecryptFinal_ex(ctx, out, outl); |
264 | return ret; | 268 | return ret; |
265 | } | 269 | } |
270 | LCRYPTO_ALIAS(EVP_CipherFinal); | ||
266 | 271 | ||
267 | int | 272 | int |
268 | EVP_EncryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, | 273 | EVP_EncryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, |
@@ -270,6 +275,7 @@ EVP_EncryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, | |||
270 | { | 275 | { |
271 | return EVP_CipherInit(ctx, cipher, key, iv, 1); | 276 | return EVP_CipherInit(ctx, cipher, key, iv, 1); |
272 | } | 277 | } |
278 | LCRYPTO_ALIAS(EVP_EncryptInit); | ||
273 | 279 | ||
274 | int | 280 | int |
275 | EVP_EncryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, | 281 | EVP_EncryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, |
@@ -277,6 +283,7 @@ EVP_EncryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, | |||
277 | { | 283 | { |
278 | return EVP_CipherInit_ex(ctx, cipher, impl, key, iv, 1); | 284 | return EVP_CipherInit_ex(ctx, cipher, impl, key, iv, 1); |
279 | } | 285 | } |
286 | LCRYPTO_ALIAS(EVP_EncryptInit_ex); | ||
280 | 287 | ||
281 | int | 288 | int |
282 | EVP_DecryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, | 289 | EVP_DecryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, |
@@ -284,6 +291,7 @@ EVP_DecryptInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, | |||
284 | { | 291 | { |
285 | return EVP_CipherInit(ctx, cipher, key, iv, 0); | 292 | return EVP_CipherInit(ctx, cipher, key, iv, 0); |
286 | } | 293 | } |
294 | LCRYPTO_ALIAS(EVP_DecryptInit); | ||
287 | 295 | ||
288 | int | 296 | int |
289 | EVP_DecryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, | 297 | EVP_DecryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, |
@@ -291,6 +299,7 @@ EVP_DecryptInit_ex(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *cipher, ENGINE *impl, | |||
291 | { | 299 | { |
292 | return EVP_CipherInit_ex(ctx, cipher, impl, key, iv, 0); | 300 | return EVP_CipherInit_ex(ctx, cipher, impl, key, iv, 0); |
293 | } | 301 | } |
302 | LCRYPTO_ALIAS(EVP_DecryptInit_ex); | ||
294 | 303 | ||
295 | int | 304 | int |
296 | EVP_EncryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | 305 | EVP_EncryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, |
@@ -373,6 +382,7 @@ EVP_EncryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | |||
373 | ctx->buf_len = i; | 382 | ctx->buf_len = i; |
374 | return 1; | 383 | return 1; |
375 | } | 384 | } |
385 | LCRYPTO_ALIAS(EVP_EncryptUpdate); | ||
376 | 386 | ||
377 | __warn_references(EVP_EncryptFinal, | 387 | __warn_references(EVP_EncryptFinal, |
378 | "EVP_EncryptFinal is often misused, please use EVP_EncryptFinal_ex and EVP_CIPHER_CTX_cleanup"); | 388 | "EVP_EncryptFinal is often misused, please use EVP_EncryptFinal_ex and EVP_CIPHER_CTX_cleanup"); |
@@ -385,6 +395,7 @@ EVP_EncryptFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
385 | ret = EVP_EncryptFinal_ex(ctx, out, outl); | 395 | ret = EVP_EncryptFinal_ex(ctx, out, outl); |
386 | return ret; | 396 | return ret; |
387 | } | 397 | } |
398 | LCRYPTO_ALIAS(EVP_EncryptFinal); | ||
388 | 399 | ||
389 | int | 400 | int |
390 | EVP_EncryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | 401 | EVP_EncryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) |
@@ -431,6 +442,7 @@ EVP_EncryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
431 | 442 | ||
432 | return ret; | 443 | return ret; |
433 | } | 444 | } |
445 | LCRYPTO_ALIAS(EVP_EncryptFinal_ex); | ||
434 | 446 | ||
435 | int | 447 | int |
436 | EVP_DecryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | 448 | EVP_DecryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, |
@@ -501,6 +513,7 @@ EVP_DecryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl, | |||
501 | 513 | ||
502 | return 1; | 514 | return 1; |
503 | } | 515 | } |
516 | LCRYPTO_ALIAS(EVP_DecryptUpdate); | ||
504 | 517 | ||
505 | __warn_references(EVP_DecryptFinal, | 518 | __warn_references(EVP_DecryptFinal, |
506 | "EVP_DecryptFinal is often misused, please use EVP_DecryptFinal_ex and EVP_CIPHER_CTX_cleanup"); | 519 | "EVP_DecryptFinal is often misused, please use EVP_DecryptFinal_ex and EVP_CIPHER_CTX_cleanup"); |
@@ -513,6 +526,7 @@ EVP_DecryptFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
513 | ret = EVP_DecryptFinal_ex(ctx, out, outl); | 526 | ret = EVP_DecryptFinal_ex(ctx, out, outl); |
514 | return ret; | 527 | return ret; |
515 | } | 528 | } |
529 | LCRYPTO_ALIAS(EVP_DecryptFinal); | ||
516 | 530 | ||
517 | int | 531 | int |
518 | EVP_DecryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | 532 | EVP_DecryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) |
@@ -567,12 +581,14 @@ EVP_DecryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
567 | *outl = 0; | 581 | *outl = 0; |
568 | return (1); | 582 | return (1); |
569 | } | 583 | } |
584 | LCRYPTO_ALIAS(EVP_DecryptFinal_ex); | ||
570 | 585 | ||
571 | EVP_CIPHER_CTX * | 586 | EVP_CIPHER_CTX * |
572 | EVP_CIPHER_CTX_new(void) | 587 | EVP_CIPHER_CTX_new(void) |
573 | { | 588 | { |
574 | return calloc(1, sizeof(EVP_CIPHER_CTX)); | 589 | return calloc(1, sizeof(EVP_CIPHER_CTX)); |
575 | } | 590 | } |
591 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_new); | ||
576 | 592 | ||
577 | void | 593 | void |
578 | EVP_CIPHER_CTX_free(EVP_CIPHER_CTX *ctx) | 594 | EVP_CIPHER_CTX_free(EVP_CIPHER_CTX *ctx) |
@@ -584,18 +600,21 @@ EVP_CIPHER_CTX_free(EVP_CIPHER_CTX *ctx) | |||
584 | 600 | ||
585 | free(ctx); | 601 | free(ctx); |
586 | } | 602 | } |
603 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_free); | ||
587 | 604 | ||
588 | void | 605 | void |
589 | EVP_CIPHER_CTX_init(EVP_CIPHER_CTX *ctx) | 606 | EVP_CIPHER_CTX_init(EVP_CIPHER_CTX *ctx) |
590 | { | 607 | { |
591 | memset(ctx, 0, sizeof(EVP_CIPHER_CTX)); | 608 | memset(ctx, 0, sizeof(EVP_CIPHER_CTX)); |
592 | } | 609 | } |
610 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_init); | ||
593 | 611 | ||
594 | int | 612 | int |
595 | EVP_CIPHER_CTX_reset(EVP_CIPHER_CTX *a) | 613 | EVP_CIPHER_CTX_reset(EVP_CIPHER_CTX *a) |
596 | { | 614 | { |
597 | return EVP_CIPHER_CTX_cleanup(a); | 615 | return EVP_CIPHER_CTX_cleanup(a); |
598 | } | 616 | } |
617 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_reset); | ||
599 | 618 | ||
600 | int | 619 | int |
601 | EVP_CIPHER_CTX_cleanup(EVP_CIPHER_CTX *c) | 620 | EVP_CIPHER_CTX_cleanup(EVP_CIPHER_CTX *c) |
@@ -619,6 +638,7 @@ EVP_CIPHER_CTX_cleanup(EVP_CIPHER_CTX *c) | |||
619 | 638 | ||
620 | return 1; | 639 | return 1; |
621 | } | 640 | } |
641 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_cleanup); | ||
622 | 642 | ||
623 | int | 643 | int |
624 | EVP_CIPHER_CTX_set_key_length(EVP_CIPHER_CTX *c, int keylen) | 644 | EVP_CIPHER_CTX_set_key_length(EVP_CIPHER_CTX *c, int keylen) |
@@ -635,6 +655,7 @@ EVP_CIPHER_CTX_set_key_length(EVP_CIPHER_CTX *c, int keylen) | |||
635 | EVPerror(EVP_R_INVALID_KEY_LENGTH); | 655 | EVPerror(EVP_R_INVALID_KEY_LENGTH); |
636 | return 0; | 656 | return 0; |
637 | } | 657 | } |
658 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_key_length); | ||
638 | 659 | ||
639 | int | 660 | int |
640 | EVP_CIPHER_CTX_set_padding(EVP_CIPHER_CTX *ctx, int pad) | 661 | EVP_CIPHER_CTX_set_padding(EVP_CIPHER_CTX *ctx, int pad) |
@@ -645,6 +666,7 @@ EVP_CIPHER_CTX_set_padding(EVP_CIPHER_CTX *ctx, int pad) | |||
645 | ctx->flags |= EVP_CIPH_NO_PADDING; | 666 | ctx->flags |= EVP_CIPH_NO_PADDING; |
646 | return 1; | 667 | return 1; |
647 | } | 668 | } |
669 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_padding); | ||
648 | 670 | ||
649 | int | 671 | int |
650 | EVP_CIPHER_CTX_ctrl(EVP_CIPHER_CTX *ctx, int type, int arg, void *ptr) | 672 | EVP_CIPHER_CTX_ctrl(EVP_CIPHER_CTX *ctx, int type, int arg, void *ptr) |
@@ -668,6 +690,7 @@ EVP_CIPHER_CTX_ctrl(EVP_CIPHER_CTX *ctx, int type, int arg, void *ptr) | |||
668 | } | 690 | } |
669 | return ret; | 691 | return ret; |
670 | } | 692 | } |
693 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_ctrl); | ||
671 | 694 | ||
672 | int | 695 | int |
673 | EVP_CIPHER_CTX_rand_key(EVP_CIPHER_CTX *ctx, unsigned char *key) | 696 | EVP_CIPHER_CTX_rand_key(EVP_CIPHER_CTX *ctx, unsigned char *key) |
@@ -677,6 +700,7 @@ EVP_CIPHER_CTX_rand_key(EVP_CIPHER_CTX *ctx, unsigned char *key) | |||
677 | arc4random_buf(key, ctx->key_len); | 700 | arc4random_buf(key, ctx->key_len); |
678 | return 1; | 701 | return 1; |
679 | } | 702 | } |
703 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_rand_key); | ||
680 | 704 | ||
681 | int | 705 | int |
682 | EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in) | 706 | EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in) |
@@ -723,3 +747,4 @@ EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in) | |||
723 | 747 | ||
724 | return 1; | 748 | return 1; |
725 | } | 749 | } |
750 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_copy); | ||
diff --git a/src/lib/libcrypto/evp/evp_err.c b/src/lib/libcrypto/evp/evp_err.c index 9cf89f47fb..8835215c14 100644 --- a/src/lib/libcrypto/evp/evp_err.c +++ b/src/lib/libcrypto/evp/evp_err.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_err.c,v 1.30 2022/11/10 15:17:30 jsing Exp $ */ | 1 | /* $OpenBSD: evp_err.c,v 1.31 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1999-2011 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -164,3 +164,4 @@ ERR_load_EVP_strings(void) | |||
164 | } | 164 | } |
165 | #endif | 165 | #endif |
166 | } | 166 | } |
167 | LCRYPTO_ALIAS(ERR_load_EVP_strings); | ||
diff --git a/src/lib/libcrypto/evp/evp_key.c b/src/lib/libcrypto/evp/evp_key.c index 6fc8588cde..148fd2fe92 100644 --- a/src/lib/libcrypto/evp/evp_key.c +++ b/src/lib/libcrypto/evp/evp_key.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_key.c,v 1.28 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: evp_key.c,v 1.29 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -79,6 +79,7 @@ EVP_set_pw_prompt(const char *prompt) | |||
79 | strlcpy(prompt_string, prompt, sizeof(prompt_string)); | 79 | strlcpy(prompt_string, prompt, sizeof(prompt_string)); |
80 | } | 80 | } |
81 | } | 81 | } |
82 | LCRYPTO_ALIAS(EVP_set_pw_prompt); | ||
82 | 83 | ||
83 | char * | 84 | char * |
84 | EVP_get_pw_prompt(void) | 85 | EVP_get_pw_prompt(void) |
@@ -88,12 +89,14 @@ EVP_get_pw_prompt(void) | |||
88 | else | 89 | else |
89 | return (prompt_string); | 90 | return (prompt_string); |
90 | } | 91 | } |
92 | LCRYPTO_ALIAS(EVP_get_pw_prompt); | ||
91 | 93 | ||
92 | int | 94 | int |
93 | EVP_read_pw_string(char *buf, int len, const char *prompt, int verify) | 95 | EVP_read_pw_string(char *buf, int len, const char *prompt, int verify) |
94 | { | 96 | { |
95 | return EVP_read_pw_string_min(buf, 0, len, prompt, verify); | 97 | return EVP_read_pw_string_min(buf, 0, len, prompt, verify); |
96 | } | 98 | } |
99 | LCRYPTO_ALIAS(EVP_read_pw_string); | ||
97 | 100 | ||
98 | int | 101 | int |
99 | EVP_read_pw_string_min(char *buf, int min, int len, const char *prompt, | 102 | EVP_read_pw_string_min(char *buf, int min, int len, const char *prompt, |
@@ -125,6 +128,7 @@ EVP_read_pw_string_min(char *buf, int min, int len, const char *prompt, | |||
125 | explicit_bzero(buff, BUFSIZ); | 128 | explicit_bzero(buff, BUFSIZ); |
126 | return ret; | 129 | return ret; |
127 | } | 130 | } |
131 | LCRYPTO_ALIAS(EVP_read_pw_string_min); | ||
128 | 132 | ||
129 | int | 133 | int |
130 | EVP_BytesToKey(const EVP_CIPHER *type, const EVP_MD *md, | 134 | EVP_BytesToKey(const EVP_CIPHER *type, const EVP_MD *md, |
@@ -210,3 +214,4 @@ err: | |||
210 | explicit_bzero(md_buf, sizeof md_buf); | 214 | explicit_bzero(md_buf, sizeof md_buf); |
211 | return rv; | 215 | return rv; |
212 | } | 216 | } |
217 | LCRYPTO_ALIAS(EVP_BytesToKey); | ||
diff --git a/src/lib/libcrypto/evp/evp_lib.c b/src/lib/libcrypto/evp/evp_lib.c index f64842b86f..d6b929c0e3 100644 --- a/src/lib/libcrypto/evp/evp_lib.c +++ b/src/lib/libcrypto/evp/evp_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_lib.c,v 1.25 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: evp_lib.c,v 1.26 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -79,6 +79,7 @@ EVP_CIPHER_param_to_asn1(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | |||
79 | ret = -1; | 79 | ret = -1; |
80 | return (ret); | 80 | return (ret); |
81 | } | 81 | } |
82 | LCRYPTO_ALIAS(EVP_CIPHER_param_to_asn1); | ||
82 | 83 | ||
83 | int | 84 | int |
84 | EVP_CIPHER_asn1_to_param(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | 85 | EVP_CIPHER_asn1_to_param(EVP_CIPHER_CTX *c, ASN1_TYPE *type) |
@@ -93,6 +94,7 @@ EVP_CIPHER_asn1_to_param(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | |||
93 | ret = -1; | 94 | ret = -1; |
94 | return (ret); | 95 | return (ret); |
95 | } | 96 | } |
97 | LCRYPTO_ALIAS(EVP_CIPHER_asn1_to_param); | ||
96 | 98 | ||
97 | int | 99 | int |
98 | EVP_CIPHER_get_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | 100 | EVP_CIPHER_get_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) |
@@ -114,6 +116,7 @@ EVP_CIPHER_get_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | |||
114 | } | 116 | } |
115 | return (i); | 117 | return (i); |
116 | } | 118 | } |
119 | LCRYPTO_ALIAS(EVP_CIPHER_get_asn1_iv); | ||
117 | 120 | ||
118 | int | 121 | int |
119 | EVP_CIPHER_set_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | 122 | EVP_CIPHER_set_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) |
@@ -131,6 +134,7 @@ EVP_CIPHER_set_asn1_iv(EVP_CIPHER_CTX *c, ASN1_TYPE *type) | |||
131 | } | 134 | } |
132 | return (i); | 135 | return (i); |
133 | } | 136 | } |
137 | LCRYPTO_ALIAS(EVP_CIPHER_set_asn1_iv); | ||
134 | 138 | ||
135 | /* Convert the various cipher NIDs and dummies to a proper OID NID */ | 139 | /* Convert the various cipher NIDs and dummies to a proper OID NID */ |
136 | int | 140 | int |
@@ -184,18 +188,21 @@ EVP_CIPHER_type(const EVP_CIPHER *ctx) | |||
184 | return nid; | 188 | return nid; |
185 | } | 189 | } |
186 | } | 190 | } |
191 | LCRYPTO_ALIAS(EVP_CIPHER_type); | ||
187 | 192 | ||
188 | int | 193 | int |
189 | EVP_CIPHER_block_size(const EVP_CIPHER *e) | 194 | EVP_CIPHER_block_size(const EVP_CIPHER *e) |
190 | { | 195 | { |
191 | return e->block_size; | 196 | return e->block_size; |
192 | } | 197 | } |
198 | LCRYPTO_ALIAS(EVP_CIPHER_block_size); | ||
193 | 199 | ||
194 | int | 200 | int |
195 | EVP_CIPHER_CTX_block_size(const EVP_CIPHER_CTX *ctx) | 201 | EVP_CIPHER_CTX_block_size(const EVP_CIPHER_CTX *ctx) |
196 | { | 202 | { |
197 | return ctx->cipher->block_size; | 203 | return ctx->cipher->block_size; |
198 | } | 204 | } |
205 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_block_size); | ||
199 | 206 | ||
200 | int | 207 | int |
201 | EVP_Cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, | 208 | EVP_Cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, |
@@ -203,48 +210,56 @@ EVP_Cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, const unsigned char *in, | |||
203 | { | 210 | { |
204 | return ctx->cipher->do_cipher(ctx, out, in, inl); | 211 | return ctx->cipher->do_cipher(ctx, out, in, inl); |
205 | } | 212 | } |
213 | LCRYPTO_ALIAS(EVP_Cipher); | ||
206 | 214 | ||
207 | const EVP_CIPHER * | 215 | const EVP_CIPHER * |
208 | EVP_CIPHER_CTX_cipher(const EVP_CIPHER_CTX *ctx) | 216 | EVP_CIPHER_CTX_cipher(const EVP_CIPHER_CTX *ctx) |
209 | { | 217 | { |
210 | return ctx->cipher; | 218 | return ctx->cipher; |
211 | } | 219 | } |
220 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_cipher); | ||
212 | 221 | ||
213 | int | 222 | int |
214 | EVP_CIPHER_CTX_encrypting(const EVP_CIPHER_CTX *ctx) | 223 | EVP_CIPHER_CTX_encrypting(const EVP_CIPHER_CTX *ctx) |
215 | { | 224 | { |
216 | return ctx->encrypt; | 225 | return ctx->encrypt; |
217 | } | 226 | } |
227 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_encrypting); | ||
218 | 228 | ||
219 | unsigned long | 229 | unsigned long |
220 | EVP_CIPHER_flags(const EVP_CIPHER *cipher) | 230 | EVP_CIPHER_flags(const EVP_CIPHER *cipher) |
221 | { | 231 | { |
222 | return cipher->flags; | 232 | return cipher->flags; |
223 | } | 233 | } |
234 | LCRYPTO_ALIAS(EVP_CIPHER_flags); | ||
224 | 235 | ||
225 | unsigned long | 236 | unsigned long |
226 | EVP_CIPHER_CTX_flags(const EVP_CIPHER_CTX *ctx) | 237 | EVP_CIPHER_CTX_flags(const EVP_CIPHER_CTX *ctx) |
227 | { | 238 | { |
228 | return ctx->cipher->flags; | 239 | return ctx->cipher->flags; |
229 | } | 240 | } |
241 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_flags); | ||
230 | 242 | ||
231 | void * | 243 | void * |
232 | EVP_CIPHER_CTX_get_app_data(const EVP_CIPHER_CTX *ctx) | 244 | EVP_CIPHER_CTX_get_app_data(const EVP_CIPHER_CTX *ctx) |
233 | { | 245 | { |
234 | return ctx->app_data; | 246 | return ctx->app_data; |
235 | } | 247 | } |
248 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_get_app_data); | ||
236 | 249 | ||
237 | void | 250 | void |
238 | EVP_CIPHER_CTX_set_app_data(EVP_CIPHER_CTX *ctx, void *data) | 251 | EVP_CIPHER_CTX_set_app_data(EVP_CIPHER_CTX *ctx, void *data) |
239 | { | 252 | { |
240 | ctx->app_data = data; | 253 | ctx->app_data = data; |
241 | } | 254 | } |
255 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_app_data); | ||
242 | 256 | ||
243 | void * | 257 | void * |
244 | EVP_CIPHER_CTX_get_cipher_data(const EVP_CIPHER_CTX *ctx) | 258 | EVP_CIPHER_CTX_get_cipher_data(const EVP_CIPHER_CTX *ctx) |
245 | { | 259 | { |
246 | return ctx->cipher_data; | 260 | return ctx->cipher_data; |
247 | } | 261 | } |
262 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_get_cipher_data); | ||
248 | 263 | ||
249 | void * | 264 | void * |
250 | EVP_CIPHER_CTX_set_cipher_data(EVP_CIPHER_CTX *ctx, void *cipher_data) | 265 | EVP_CIPHER_CTX_set_cipher_data(EVP_CIPHER_CTX *ctx, void *cipher_data) |
@@ -256,48 +271,56 @@ EVP_CIPHER_CTX_set_cipher_data(EVP_CIPHER_CTX *ctx, void *cipher_data) | |||
256 | 271 | ||
257 | return old_cipher_data; | 272 | return old_cipher_data; |
258 | } | 273 | } |
274 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_cipher_data); | ||
259 | 275 | ||
260 | int | 276 | int |
261 | EVP_CIPHER_iv_length(const EVP_CIPHER *cipher) | 277 | EVP_CIPHER_iv_length(const EVP_CIPHER *cipher) |
262 | { | 278 | { |
263 | return cipher->iv_len; | 279 | return cipher->iv_len; |
264 | } | 280 | } |
281 | LCRYPTO_ALIAS(EVP_CIPHER_iv_length); | ||
265 | 282 | ||
266 | int | 283 | int |
267 | EVP_CIPHER_CTX_iv_length(const EVP_CIPHER_CTX *ctx) | 284 | EVP_CIPHER_CTX_iv_length(const EVP_CIPHER_CTX *ctx) |
268 | { | 285 | { |
269 | return ctx->cipher->iv_len; | 286 | return ctx->cipher->iv_len; |
270 | } | 287 | } |
288 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_iv_length); | ||
271 | 289 | ||
272 | unsigned char * | 290 | unsigned char * |
273 | EVP_CIPHER_CTX_buf_noconst(EVP_CIPHER_CTX *ctx) | 291 | EVP_CIPHER_CTX_buf_noconst(EVP_CIPHER_CTX *ctx) |
274 | { | 292 | { |
275 | return ctx->buf; | 293 | return ctx->buf; |
276 | } | 294 | } |
295 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_buf_noconst); | ||
277 | 296 | ||
278 | int | 297 | int |
279 | EVP_CIPHER_key_length(const EVP_CIPHER *cipher) | 298 | EVP_CIPHER_key_length(const EVP_CIPHER *cipher) |
280 | { | 299 | { |
281 | return cipher->key_len; | 300 | return cipher->key_len; |
282 | } | 301 | } |
302 | LCRYPTO_ALIAS(EVP_CIPHER_key_length); | ||
283 | 303 | ||
284 | int | 304 | int |
285 | EVP_CIPHER_CTX_key_length(const EVP_CIPHER_CTX *ctx) | 305 | EVP_CIPHER_CTX_key_length(const EVP_CIPHER_CTX *ctx) |
286 | { | 306 | { |
287 | return ctx->key_len; | 307 | return ctx->key_len; |
288 | } | 308 | } |
309 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_key_length); | ||
289 | 310 | ||
290 | int | 311 | int |
291 | EVP_CIPHER_nid(const EVP_CIPHER *cipher) | 312 | EVP_CIPHER_nid(const EVP_CIPHER *cipher) |
292 | { | 313 | { |
293 | return cipher->nid; | 314 | return cipher->nid; |
294 | } | 315 | } |
316 | LCRYPTO_ALIAS(EVP_CIPHER_nid); | ||
295 | 317 | ||
296 | int | 318 | int |
297 | EVP_CIPHER_CTX_nid(const EVP_CIPHER_CTX *ctx) | 319 | EVP_CIPHER_CTX_nid(const EVP_CIPHER_CTX *ctx) |
298 | { | 320 | { |
299 | return ctx->cipher->nid; | 321 | return ctx->cipher->nid; |
300 | } | 322 | } |
323 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_nid); | ||
301 | 324 | ||
302 | int | 325 | int |
303 | EVP_CIPHER_CTX_get_iv(const EVP_CIPHER_CTX *ctx, unsigned char *iv, size_t len) | 326 | EVP_CIPHER_CTX_get_iv(const EVP_CIPHER_CTX *ctx, unsigned char *iv, size_t len) |
@@ -317,6 +340,7 @@ EVP_CIPHER_CTX_get_iv(const EVP_CIPHER_CTX *ctx, unsigned char *iv, size_t len) | |||
317 | } | 340 | } |
318 | return 1; | 341 | return 1; |
319 | } | 342 | } |
343 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_get_iv); | ||
320 | 344 | ||
321 | int | 345 | int |
322 | EVP_CIPHER_CTX_set_iv(EVP_CIPHER_CTX *ctx, const unsigned char *iv, size_t len) | 346 | EVP_CIPHER_CTX_set_iv(EVP_CIPHER_CTX *ctx, const unsigned char *iv, size_t len) |
@@ -336,24 +360,28 @@ EVP_CIPHER_CTX_set_iv(EVP_CIPHER_CTX *ctx, const unsigned char *iv, size_t len) | |||
336 | } | 360 | } |
337 | return 1; | 361 | return 1; |
338 | } | 362 | } |
363 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_iv); | ||
339 | 364 | ||
340 | int | 365 | int |
341 | EVP_MD_block_size(const EVP_MD *md) | 366 | EVP_MD_block_size(const EVP_MD *md) |
342 | { | 367 | { |
343 | return md->block_size; | 368 | return md->block_size; |
344 | } | 369 | } |
370 | LCRYPTO_ALIAS(EVP_MD_block_size); | ||
345 | 371 | ||
346 | int | 372 | int |
347 | EVP_MD_type(const EVP_MD *md) | 373 | EVP_MD_type(const EVP_MD *md) |
348 | { | 374 | { |
349 | return md->type; | 375 | return md->type; |
350 | } | 376 | } |
377 | LCRYPTO_ALIAS(EVP_MD_type); | ||
351 | 378 | ||
352 | int | 379 | int |
353 | EVP_MD_pkey_type(const EVP_MD *md) | 380 | EVP_MD_pkey_type(const EVP_MD *md) |
354 | { | 381 | { |
355 | return md->pkey_type; | 382 | return md->pkey_type; |
356 | } | 383 | } |
384 | LCRYPTO_ALIAS(EVP_MD_pkey_type); | ||
357 | 385 | ||
358 | int | 386 | int |
359 | EVP_MD_size(const EVP_MD *md) | 387 | EVP_MD_size(const EVP_MD *md) |
@@ -364,12 +392,14 @@ EVP_MD_size(const EVP_MD *md) | |||
364 | } | 392 | } |
365 | return md->md_size; | 393 | return md->md_size; |
366 | } | 394 | } |
395 | LCRYPTO_ALIAS(EVP_MD_size); | ||
367 | 396 | ||
368 | unsigned long | 397 | unsigned long |
369 | EVP_MD_flags(const EVP_MD *md) | 398 | EVP_MD_flags(const EVP_MD *md) |
370 | { | 399 | { |
371 | return md->flags; | 400 | return md->flags; |
372 | } | 401 | } |
402 | LCRYPTO_ALIAS(EVP_MD_flags); | ||
373 | 403 | ||
374 | EVP_MD * | 404 | EVP_MD * |
375 | EVP_MD_meth_new(int md_type, int pkey_type) | 405 | EVP_MD_meth_new(int md_type, int pkey_type) |
@@ -384,6 +414,7 @@ EVP_MD_meth_new(int md_type, int pkey_type) | |||
384 | 414 | ||
385 | return md; | 415 | return md; |
386 | } | 416 | } |
417 | LCRYPTO_ALIAS(EVP_MD_meth_new); | ||
387 | 418 | ||
388 | EVP_MD * | 419 | EVP_MD * |
389 | EVP_MD_meth_dup(const EVP_MD *md) | 420 | EVP_MD_meth_dup(const EVP_MD *md) |
@@ -397,12 +428,14 @@ EVP_MD_meth_dup(const EVP_MD *md) | |||
397 | 428 | ||
398 | return to; | 429 | return to; |
399 | } | 430 | } |
431 | LCRYPTO_ALIAS(EVP_MD_meth_dup); | ||
400 | 432 | ||
401 | void | 433 | void |
402 | EVP_MD_meth_free(EVP_MD *md) | 434 | EVP_MD_meth_free(EVP_MD *md) |
403 | { | 435 | { |
404 | freezero(md, sizeof(*md)); | 436 | freezero(md, sizeof(*md)); |
405 | } | 437 | } |
438 | LCRYPTO_ALIAS(EVP_MD_meth_free); | ||
406 | 439 | ||
407 | int | 440 | int |
408 | EVP_MD_meth_set_input_blocksize(EVP_MD *md, int blocksize) | 441 | EVP_MD_meth_set_input_blocksize(EVP_MD *md, int blocksize) |
@@ -410,6 +443,7 @@ EVP_MD_meth_set_input_blocksize(EVP_MD *md, int blocksize) | |||
410 | md->block_size = blocksize; | 443 | md->block_size = blocksize; |
411 | return 1; | 444 | return 1; |
412 | } | 445 | } |
446 | LCRYPTO_ALIAS(EVP_MD_meth_set_input_blocksize); | ||
413 | 447 | ||
414 | int | 448 | int |
415 | EVP_MD_meth_set_result_size(EVP_MD *md, int result_size) | 449 | EVP_MD_meth_set_result_size(EVP_MD *md, int result_size) |
@@ -417,6 +451,7 @@ EVP_MD_meth_set_result_size(EVP_MD *md, int result_size) | |||
417 | md->md_size = result_size; | 451 | md->md_size = result_size; |
418 | return 1; | 452 | return 1; |
419 | } | 453 | } |
454 | LCRYPTO_ALIAS(EVP_MD_meth_set_result_size); | ||
420 | 455 | ||
421 | int | 456 | int |
422 | EVP_MD_meth_set_app_datasize(EVP_MD *md, int datasize) | 457 | EVP_MD_meth_set_app_datasize(EVP_MD *md, int datasize) |
@@ -424,6 +459,7 @@ EVP_MD_meth_set_app_datasize(EVP_MD *md, int datasize) | |||
424 | md->ctx_size = datasize; | 459 | md->ctx_size = datasize; |
425 | return 1; | 460 | return 1; |
426 | } | 461 | } |
462 | LCRYPTO_ALIAS(EVP_MD_meth_set_app_datasize); | ||
427 | 463 | ||
428 | int | 464 | int |
429 | EVP_MD_meth_set_flags(EVP_MD *md, unsigned long flags) | 465 | EVP_MD_meth_set_flags(EVP_MD *md, unsigned long flags) |
@@ -431,6 +467,7 @@ EVP_MD_meth_set_flags(EVP_MD *md, unsigned long flags) | |||
431 | md->flags = flags; | 467 | md->flags = flags; |
432 | return 1; | 468 | return 1; |
433 | } | 469 | } |
470 | LCRYPTO_ALIAS(EVP_MD_meth_set_flags); | ||
434 | 471 | ||
435 | int | 472 | int |
436 | EVP_MD_meth_set_init(EVP_MD *md, int (*init)(EVP_MD_CTX *ctx)) | 473 | EVP_MD_meth_set_init(EVP_MD *md, int (*init)(EVP_MD_CTX *ctx)) |
@@ -438,6 +475,7 @@ EVP_MD_meth_set_init(EVP_MD *md, int (*init)(EVP_MD_CTX *ctx)) | |||
438 | md->init = init; | 475 | md->init = init; |
439 | return 1; | 476 | return 1; |
440 | } | 477 | } |
478 | LCRYPTO_ALIAS(EVP_MD_meth_set_init); | ||
441 | 479 | ||
442 | int | 480 | int |
443 | EVP_MD_meth_set_update(EVP_MD *md, | 481 | EVP_MD_meth_set_update(EVP_MD *md, |
@@ -446,6 +484,7 @@ EVP_MD_meth_set_update(EVP_MD *md, | |||
446 | md->update = update; | 484 | md->update = update; |
447 | return 1; | 485 | return 1; |
448 | } | 486 | } |
487 | LCRYPTO_ALIAS(EVP_MD_meth_set_update); | ||
449 | 488 | ||
450 | int | 489 | int |
451 | EVP_MD_meth_set_final(EVP_MD *md, | 490 | EVP_MD_meth_set_final(EVP_MD *md, |
@@ -454,6 +493,7 @@ EVP_MD_meth_set_final(EVP_MD *md, | |||
454 | md->final = final; | 493 | md->final = final; |
455 | return 1; | 494 | return 1; |
456 | } | 495 | } |
496 | LCRYPTO_ALIAS(EVP_MD_meth_set_final); | ||
457 | 497 | ||
458 | int | 498 | int |
459 | EVP_MD_meth_set_copy(EVP_MD *md, | 499 | EVP_MD_meth_set_copy(EVP_MD *md, |
@@ -462,6 +502,7 @@ EVP_MD_meth_set_copy(EVP_MD *md, | |||
462 | md->copy = copy; | 502 | md->copy = copy; |
463 | return 1; | 503 | return 1; |
464 | } | 504 | } |
505 | LCRYPTO_ALIAS(EVP_MD_meth_set_copy); | ||
465 | 506 | ||
466 | int | 507 | int |
467 | EVP_MD_meth_set_cleanup(EVP_MD *md, | 508 | EVP_MD_meth_set_cleanup(EVP_MD *md, |
@@ -470,6 +511,7 @@ EVP_MD_meth_set_cleanup(EVP_MD *md, | |||
470 | md->cleanup = cleanup; | 511 | md->cleanup = cleanup; |
471 | return 1; | 512 | return 1; |
472 | } | 513 | } |
514 | LCRYPTO_ALIAS(EVP_MD_meth_set_cleanup); | ||
473 | 515 | ||
474 | int | 516 | int |
475 | EVP_MD_meth_set_ctrl(EVP_MD *md, | 517 | EVP_MD_meth_set_ctrl(EVP_MD *md, |
@@ -478,6 +520,7 @@ EVP_MD_meth_set_ctrl(EVP_MD *md, | |||
478 | md->md_ctrl = ctrl; | 520 | md->md_ctrl = ctrl; |
479 | return 1; | 521 | return 1; |
480 | } | 522 | } |
523 | LCRYPTO_ALIAS(EVP_MD_meth_set_ctrl); | ||
481 | 524 | ||
482 | const EVP_MD * | 525 | const EVP_MD * |
483 | EVP_MD_CTX_md(const EVP_MD_CTX *ctx) | 526 | EVP_MD_CTX_md(const EVP_MD_CTX *ctx) |
@@ -486,18 +529,21 @@ EVP_MD_CTX_md(const EVP_MD_CTX *ctx) | |||
486 | return NULL; | 529 | return NULL; |
487 | return ctx->digest; | 530 | return ctx->digest; |
488 | } | 531 | } |
532 | LCRYPTO_ALIAS(EVP_MD_CTX_md); | ||
489 | 533 | ||
490 | void * | 534 | void * |
491 | EVP_MD_CTX_md_data(const EVP_MD_CTX *ctx) | 535 | EVP_MD_CTX_md_data(const EVP_MD_CTX *ctx) |
492 | { | 536 | { |
493 | return ctx->md_data; | 537 | return ctx->md_data; |
494 | } | 538 | } |
539 | LCRYPTO_ALIAS(EVP_MD_CTX_md_data); | ||
495 | 540 | ||
496 | EVP_PKEY_CTX * | 541 | EVP_PKEY_CTX * |
497 | EVP_MD_CTX_pkey_ctx(const EVP_MD_CTX *ctx) | 542 | EVP_MD_CTX_pkey_ctx(const EVP_MD_CTX *ctx) |
498 | { | 543 | { |
499 | return ctx->pctx; | 544 | return ctx->pctx; |
500 | } | 545 | } |
546 | LCRYPTO_ALIAS(EVP_MD_CTX_pkey_ctx); | ||
501 | 547 | ||
502 | void | 548 | void |
503 | EVP_MD_CTX_set_pkey_ctx(EVP_MD_CTX *ctx, EVP_PKEY_CTX *pctx) | 549 | EVP_MD_CTX_set_pkey_ctx(EVP_MD_CTX *ctx, EVP_PKEY_CTX *pctx) |
@@ -521,39 +567,46 @@ EVP_MD_CTX_set_pkey_ctx(EVP_MD_CTX *ctx, EVP_PKEY_CTX *pctx) | |||
521 | EVP_MD_CTX_set_flags(ctx, EVP_MD_CTX_FLAG_KEEP_PKEY_CTX); | 567 | EVP_MD_CTX_set_flags(ctx, EVP_MD_CTX_FLAG_KEEP_PKEY_CTX); |
522 | } | 568 | } |
523 | } | 569 | } |
570 | LCRYPTO_ALIAS(EVP_MD_CTX_set_pkey_ctx); | ||
524 | 571 | ||
525 | void | 572 | void |
526 | EVP_MD_CTX_set_flags(EVP_MD_CTX *ctx, int flags) | 573 | EVP_MD_CTX_set_flags(EVP_MD_CTX *ctx, int flags) |
527 | { | 574 | { |
528 | ctx->flags |= flags; | 575 | ctx->flags |= flags; |
529 | } | 576 | } |
577 | LCRYPTO_ALIAS(EVP_MD_CTX_set_flags); | ||
530 | 578 | ||
531 | void | 579 | void |
532 | EVP_MD_CTX_clear_flags(EVP_MD_CTX *ctx, int flags) | 580 | EVP_MD_CTX_clear_flags(EVP_MD_CTX *ctx, int flags) |
533 | { | 581 | { |
534 | ctx->flags &= ~flags; | 582 | ctx->flags &= ~flags; |
535 | } | 583 | } |
584 | LCRYPTO_ALIAS(EVP_MD_CTX_clear_flags); | ||
536 | 585 | ||
537 | int | 586 | int |
538 | EVP_MD_CTX_test_flags(const EVP_MD_CTX *ctx, int flags) | 587 | EVP_MD_CTX_test_flags(const EVP_MD_CTX *ctx, int flags) |
539 | { | 588 | { |
540 | return (ctx->flags & flags); | 589 | return (ctx->flags & flags); |
541 | } | 590 | } |
591 | LCRYPTO_ALIAS(EVP_MD_CTX_test_flags); | ||
542 | 592 | ||
543 | void | 593 | void |
544 | EVP_CIPHER_CTX_set_flags(EVP_CIPHER_CTX *ctx, int flags) | 594 | EVP_CIPHER_CTX_set_flags(EVP_CIPHER_CTX *ctx, int flags) |
545 | { | 595 | { |
546 | ctx->flags |= flags; | 596 | ctx->flags |= flags; |
547 | } | 597 | } |
598 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_set_flags); | ||
548 | 599 | ||
549 | void | 600 | void |
550 | EVP_CIPHER_CTX_clear_flags(EVP_CIPHER_CTX *ctx, int flags) | 601 | EVP_CIPHER_CTX_clear_flags(EVP_CIPHER_CTX *ctx, int flags) |
551 | { | 602 | { |
552 | ctx->flags &= ~flags; | 603 | ctx->flags &= ~flags; |
553 | } | 604 | } |
605 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_clear_flags); | ||
554 | 606 | ||
555 | int | 607 | int |
556 | EVP_CIPHER_CTX_test_flags(const EVP_CIPHER_CTX *ctx, int flags) | 608 | EVP_CIPHER_CTX_test_flags(const EVP_CIPHER_CTX *ctx, int flags) |
557 | { | 609 | { |
558 | return (ctx->flags & flags); | 610 | return (ctx->flags & flags); |
559 | } | 611 | } |
612 | LCRYPTO_ALIAS(EVP_CIPHER_CTX_test_flags); | ||
diff --git a/src/lib/libcrypto/evp/evp_pbe.c b/src/lib/libcrypto/evp/evp_pbe.c index 565955524a..5592521e62 100644 --- a/src/lib/libcrypto/evp/evp_pbe.c +++ b/src/lib/libcrypto/evp/evp_pbe.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_pbe.c,v 1.27 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: evp_pbe.c,v 1.28 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 1999. | 3 | * project 1999. |
4 | */ | 4 | */ |
@@ -170,6 +170,7 @@ EVP_PBE_CipherInit(ASN1_OBJECT *pbe_obj, const char *pass, int passlen, | |||
170 | } | 170 | } |
171 | return 1; | 171 | return 1; |
172 | } | 172 | } |
173 | LCRYPTO_ALIAS(EVP_PBE_CipherInit); | ||
173 | 174 | ||
174 | static int pbe2_cmp_BSEARCH_CMP_FN(const void *, const void *); | 175 | static int pbe2_cmp_BSEARCH_CMP_FN(const void *, const void *); |
175 | static int pbe2_cmp(EVP_PBE_CTL const *, EVP_PBE_CTL const *); | 176 | static int pbe2_cmp(EVP_PBE_CTL const *, EVP_PBE_CTL const *); |
@@ -246,6 +247,7 @@ EVP_PBE_alg_add_type(int pbe_type, int pbe_nid, int cipher_nid, int md_nid, | |||
246 | } | 247 | } |
247 | return 1; | 248 | return 1; |
248 | } | 249 | } |
250 | LCRYPTO_ALIAS(EVP_PBE_alg_add_type); | ||
249 | 251 | ||
250 | int | 252 | int |
251 | EVP_PBE_alg_add(int nid, const EVP_CIPHER *cipher, const EVP_MD *md, | 253 | EVP_PBE_alg_add(int nid, const EVP_CIPHER *cipher, const EVP_MD *md, |
@@ -265,6 +267,7 @@ EVP_PBE_alg_add(int nid, const EVP_CIPHER *cipher, const EVP_MD *md, | |||
265 | return EVP_PBE_alg_add_type(EVP_PBE_TYPE_OUTER, nid, | 267 | return EVP_PBE_alg_add_type(EVP_PBE_TYPE_OUTER, nid, |
266 | cipher_nid, md_nid, keygen); | 268 | cipher_nid, md_nid, keygen); |
267 | } | 269 | } |
270 | LCRYPTO_ALIAS(EVP_PBE_alg_add); | ||
268 | 271 | ||
269 | int | 272 | int |
270 | EVP_PBE_find(int type, int pbe_nid, | 273 | EVP_PBE_find(int type, int pbe_nid, |
@@ -297,6 +300,7 @@ EVP_PBE_find(int type, int pbe_nid, | |||
297 | *pkeygen = pbetmp->keygen; | 300 | *pkeygen = pbetmp->keygen; |
298 | return 1; | 301 | return 1; |
299 | } | 302 | } |
303 | LCRYPTO_ALIAS(EVP_PBE_find); | ||
300 | 304 | ||
301 | static void | 305 | static void |
302 | free_evp_pbe_ctl(EVP_PBE_CTL *pbe) | 306 | free_evp_pbe_ctl(EVP_PBE_CTL *pbe) |
@@ -310,3 +314,4 @@ EVP_PBE_cleanup(void) | |||
310 | sk_EVP_PBE_CTL_pop_free(pbe_algs, free_evp_pbe_ctl); | 314 | sk_EVP_PBE_CTL_pop_free(pbe_algs, free_evp_pbe_ctl); |
311 | pbe_algs = NULL; | 315 | pbe_algs = NULL; |
312 | } | 316 | } |
317 | LCRYPTO_ALIAS(EVP_PBE_cleanup); | ||
diff --git a/src/lib/libcrypto/evp/evp_pkey.c b/src/lib/libcrypto/evp/evp_pkey.c index d2fbdee46c..31a59e2536 100644 --- a/src/lib/libcrypto/evp/evp_pkey.c +++ b/src/lib/libcrypto/evp/evp_pkey.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: evp_pkey.c,v 1.25 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: evp_pkey.c,v 1.26 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 1999. | 3 | * project 1999. |
4 | */ | 4 | */ |
@@ -105,6 +105,7 @@ error: | |||
105 | EVP_PKEY_free(pkey); | 105 | EVP_PKEY_free(pkey); |
106 | return NULL; | 106 | return NULL; |
107 | } | 107 | } |
108 | LCRYPTO_ALIAS(EVP_PKCS82PKEY); | ||
108 | 109 | ||
109 | /* Turn a private key into a PKCS8 structure */ | 110 | /* Turn a private key into a PKCS8 structure */ |
110 | 111 | ||
@@ -138,6 +139,7 @@ error: | |||
138 | PKCS8_PRIV_KEY_INFO_free(p8); | 139 | PKCS8_PRIV_KEY_INFO_free(p8); |
139 | return NULL; | 140 | return NULL; |
140 | } | 141 | } |
142 | LCRYPTO_ALIAS(EVP_PKEY2PKCS8); | ||
141 | 143 | ||
142 | /* EVP_PKEY attribute functions */ | 144 | /* EVP_PKEY attribute functions */ |
143 | 145 | ||
@@ -146,12 +148,14 @@ EVP_PKEY_get_attr_count(const EVP_PKEY *key) | |||
146 | { | 148 | { |
147 | return X509at_get_attr_count(key->attributes); | 149 | return X509at_get_attr_count(key->attributes); |
148 | } | 150 | } |
151 | LCRYPTO_ALIAS(EVP_PKEY_get_attr_count); | ||
149 | 152 | ||
150 | int | 153 | int |
151 | EVP_PKEY_get_attr_by_NID(const EVP_PKEY *key, int nid, int lastpos) | 154 | EVP_PKEY_get_attr_by_NID(const EVP_PKEY *key, int nid, int lastpos) |
152 | { | 155 | { |
153 | return X509at_get_attr_by_NID(key->attributes, nid, lastpos); | 156 | return X509at_get_attr_by_NID(key->attributes, nid, lastpos); |
154 | } | 157 | } |
158 | LCRYPTO_ALIAS(EVP_PKEY_get_attr_by_NID); | ||
155 | 159 | ||
156 | int | 160 | int |
157 | EVP_PKEY_get_attr_by_OBJ(const EVP_PKEY *key, const ASN1_OBJECT *obj, | 161 | EVP_PKEY_get_attr_by_OBJ(const EVP_PKEY *key, const ASN1_OBJECT *obj, |
@@ -159,18 +163,21 @@ EVP_PKEY_get_attr_by_OBJ(const EVP_PKEY *key, const ASN1_OBJECT *obj, | |||
159 | { | 163 | { |
160 | return X509at_get_attr_by_OBJ(key->attributes, obj, lastpos); | 164 | return X509at_get_attr_by_OBJ(key->attributes, obj, lastpos); |
161 | } | 165 | } |
166 | LCRYPTO_ALIAS(EVP_PKEY_get_attr_by_OBJ); | ||
162 | 167 | ||
163 | X509_ATTRIBUTE * | 168 | X509_ATTRIBUTE * |
164 | EVP_PKEY_get_attr(const EVP_PKEY *key, int loc) | 169 | EVP_PKEY_get_attr(const EVP_PKEY *key, int loc) |
165 | { | 170 | { |
166 | return X509at_get_attr(key->attributes, loc); | 171 | return X509at_get_attr(key->attributes, loc); |
167 | } | 172 | } |
173 | LCRYPTO_ALIAS(EVP_PKEY_get_attr); | ||
168 | 174 | ||
169 | X509_ATTRIBUTE * | 175 | X509_ATTRIBUTE * |
170 | EVP_PKEY_delete_attr(EVP_PKEY *key, int loc) | 176 | EVP_PKEY_delete_attr(EVP_PKEY *key, int loc) |
171 | { | 177 | { |
172 | return X509at_delete_attr(key->attributes, loc); | 178 | return X509at_delete_attr(key->attributes, loc); |
173 | } | 179 | } |
180 | LCRYPTO_ALIAS(EVP_PKEY_delete_attr); | ||
174 | 181 | ||
175 | int | 182 | int |
176 | EVP_PKEY_add1_attr(EVP_PKEY *key, X509_ATTRIBUTE *attr) | 183 | EVP_PKEY_add1_attr(EVP_PKEY *key, X509_ATTRIBUTE *attr) |
@@ -179,6 +186,7 @@ EVP_PKEY_add1_attr(EVP_PKEY *key, X509_ATTRIBUTE *attr) | |||
179 | return 1; | 186 | return 1; |
180 | return 0; | 187 | return 0; |
181 | } | 188 | } |
189 | LCRYPTO_ALIAS(EVP_PKEY_add1_attr); | ||
182 | 190 | ||
183 | int | 191 | int |
184 | EVP_PKEY_add1_attr_by_OBJ(EVP_PKEY *key, const ASN1_OBJECT *obj, int type, | 192 | EVP_PKEY_add1_attr_by_OBJ(EVP_PKEY *key, const ASN1_OBJECT *obj, int type, |
@@ -188,6 +196,7 @@ EVP_PKEY_add1_attr_by_OBJ(EVP_PKEY *key, const ASN1_OBJECT *obj, int type, | |||
188 | return 1; | 196 | return 1; |
189 | return 0; | 197 | return 0; |
190 | } | 198 | } |
199 | LCRYPTO_ALIAS(EVP_PKEY_add1_attr_by_OBJ); | ||
191 | 200 | ||
192 | int | 201 | int |
193 | EVP_PKEY_add1_attr_by_NID(EVP_PKEY *key, int nid, int type, | 202 | EVP_PKEY_add1_attr_by_NID(EVP_PKEY *key, int nid, int type, |
@@ -197,6 +206,7 @@ EVP_PKEY_add1_attr_by_NID(EVP_PKEY *key, int nid, int type, | |||
197 | return 1; | 206 | return 1; |
198 | return 0; | 207 | return 0; |
199 | } | 208 | } |
209 | LCRYPTO_ALIAS(EVP_PKEY_add1_attr_by_NID); | ||
200 | 210 | ||
201 | int | 211 | int |
202 | EVP_PKEY_add1_attr_by_txt(EVP_PKEY *key, const char *attrname, int type, | 212 | EVP_PKEY_add1_attr_by_txt(EVP_PKEY *key, const char *attrname, int type, |
@@ -207,3 +217,4 @@ EVP_PKEY_add1_attr_by_txt(EVP_PKEY *key, const char *attrname, int type, | |||
207 | return 1; | 217 | return 1; |
208 | return 0; | 218 | return 0; |
209 | } | 219 | } |
220 | LCRYPTO_ALIAS(EVP_PKEY_add1_attr_by_txt); | ||
diff --git a/src/lib/libcrypto/evp/m_gost2814789.c b/src/lib/libcrypto/evp/m_gost2814789.c index ca303dab9f..69f927c5a7 100644 --- a/src/lib/libcrypto/evp/m_gost2814789.c +++ b/src/lib/libcrypto/evp/m_gost2814789.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_gost2814789.c,v 1.4 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_gost2814789.c,v 1.5 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> |
4 | * Copyright (c) 2005-2006 Cryptocom LTD | 4 | * Copyright (c) 2005-2006 Cryptocom LTD |
@@ -110,4 +110,5 @@ EVP_gost2814789imit(void) | |||
110 | { | 110 | { |
111 | return (&gost2814789imit_md); | 111 | return (&gost2814789imit_md); |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EVP_gost2814789imit); | ||
113 | #endif | 114 | #endif |
diff --git a/src/lib/libcrypto/evp/m_gostr341194.c b/src/lib/libcrypto/evp/m_gostr341194.c index 33e96a5a2c..e2a65a3147 100644 --- a/src/lib/libcrypto/evp/m_gostr341194.c +++ b/src/lib/libcrypto/evp/m_gostr341194.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_gostr341194.c,v 1.5 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_gostr341194.c,v 1.6 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> |
4 | * Copyright (c) 2005-2006 Cryptocom LTD | 4 | * Copyright (c) 2005-2006 Cryptocom LTD |
@@ -97,4 +97,5 @@ EVP_gostr341194(void) | |||
97 | { | 97 | { |
98 | return (&gostr341194_md); | 98 | return (&gostr341194_md); |
99 | } | 99 | } |
100 | LCRYPTO_ALIAS(EVP_gostr341194); | ||
100 | #endif | 101 | #endif |
diff --git a/src/lib/libcrypto/evp/m_md4.c b/src/lib/libcrypto/evp/m_md4.c index c1e0256b38..d86ed426d3 100644 --- a/src/lib/libcrypto/evp/m_md4.c +++ b/src/lib/libcrypto/evp/m_md4.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_md4.c,v 1.19 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_md4.c,v 1.20 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -110,4 +110,5 @@ EVP_md4(void) | |||
110 | { | 110 | { |
111 | return (&md4_md); | 111 | return (&md4_md); |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EVP_md4); | ||
113 | #endif | 114 | #endif |
diff --git a/src/lib/libcrypto/evp/m_md5.c b/src/lib/libcrypto/evp/m_md5.c index b66b25bab8..18a78016c6 100644 --- a/src/lib/libcrypto/evp/m_md5.c +++ b/src/lib/libcrypto/evp/m_md5.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_md5.c,v 1.18 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_md5.c,v 1.19 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -110,4 +110,5 @@ EVP_md5(void) | |||
110 | { | 110 | { |
111 | return (&md5_md); | 111 | return (&md5_md); |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EVP_md5); | ||
113 | #endif | 114 | #endif |
diff --git a/src/lib/libcrypto/evp/m_md5_sha1.c b/src/lib/libcrypto/evp/m_md5_sha1.c index b1944b881e..32a6f56a1b 100644 --- a/src/lib/libcrypto/evp/m_md5_sha1.c +++ b/src/lib/libcrypto/evp/m_md5_sha1.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_md5_sha1.c,v 1.5 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_md5_sha1.c,v 1.6 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2017 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2017 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -87,3 +87,4 @@ EVP_md5_sha1(void) | |||
87 | { | 87 | { |
88 | return &md5_sha1_md; | 88 | return &md5_sha1_md; |
89 | } | 89 | } |
90 | LCRYPTO_ALIAS(EVP_md5_sha1); | ||
diff --git a/src/lib/libcrypto/evp/m_null.c b/src/lib/libcrypto/evp/m_null.c index d09c0007f3..884a47927e 100644 --- a/src/lib/libcrypto/evp/m_null.c +++ b/src/lib/libcrypto/evp/m_null.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_null.c,v 1.12 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_null.c,v 1.13 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -101,3 +101,4 @@ EVP_md_null(void) | |||
101 | { | 101 | { |
102 | return (&null_md); | 102 | return (&null_md); |
103 | } | 103 | } |
104 | LCRYPTO_ALIAS(EVP_md_null); | ||
diff --git a/src/lib/libcrypto/evp/m_ripemd.c b/src/lib/libcrypto/evp/m_ripemd.c index 896de59d1c..3cba1dcf1b 100644 --- a/src/lib/libcrypto/evp/m_ripemd.c +++ b/src/lib/libcrypto/evp/m_ripemd.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_ripemd.c,v 1.15 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_ripemd.c,v 1.16 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -110,4 +110,5 @@ EVP_ripemd160(void) | |||
110 | { | 110 | { |
111 | return (&ripemd160_md); | 111 | return (&ripemd160_md); |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EVP_ripemd160); | ||
113 | #endif | 114 | #endif |
diff --git a/src/lib/libcrypto/evp/m_sha1.c b/src/lib/libcrypto/evp/m_sha1.c index b7f4705d86..631e19549e 100644 --- a/src/lib/libcrypto/evp/m_sha1.c +++ b/src/lib/libcrypto/evp/m_sha1.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_sha1.c,v 1.23 2023/04/16 16:42:06 jsing Exp $ */ | 1 | /* $OpenBSD: m_sha1.c,v 1.24 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -110,6 +110,7 @@ EVP_sha1(void) | |||
110 | { | 110 | { |
111 | return &sha1_md; | 111 | return &sha1_md; |
112 | } | 112 | } |
113 | LCRYPTO_ALIAS(EVP_sha1); | ||
113 | #endif | 114 | #endif |
114 | 115 | ||
115 | #ifndef OPENSSL_NO_SHA256 | 116 | #ifndef OPENSSL_NO_SHA256 |
@@ -155,6 +156,7 @@ EVP_sha224(void) | |||
155 | { | 156 | { |
156 | return &sha224_md; | 157 | return &sha224_md; |
157 | } | 158 | } |
159 | LCRYPTO_ALIAS(EVP_sha224); | ||
158 | 160 | ||
159 | static int | 161 | static int |
160 | sha256_init(EVP_MD_CTX *ctx) | 162 | sha256_init(EVP_MD_CTX *ctx) |
@@ -193,6 +195,7 @@ EVP_sha256(void) | |||
193 | { | 195 | { |
194 | return &sha256_md; | 196 | return &sha256_md; |
195 | } | 197 | } |
198 | LCRYPTO_ALIAS(EVP_sha256); | ||
196 | #endif /* ifndef OPENSSL_NO_SHA256 */ | 199 | #endif /* ifndef OPENSSL_NO_SHA256 */ |
197 | 200 | ||
198 | #ifndef OPENSSL_NO_SHA512 | 201 | #ifndef OPENSSL_NO_SHA512 |
@@ -234,6 +237,7 @@ EVP_sha384(void) | |||
234 | { | 237 | { |
235 | return &sha384_md; | 238 | return &sha384_md; |
236 | } | 239 | } |
240 | LCRYPTO_ALIAS(EVP_sha384); | ||
237 | 241 | ||
238 | static int | 242 | static int |
239 | sha512_init(EVP_MD_CTX *ctx) | 243 | sha512_init(EVP_MD_CTX *ctx) |
@@ -272,6 +276,7 @@ EVP_sha512(void) | |||
272 | { | 276 | { |
273 | return &sha512_md; | 277 | return &sha512_md; |
274 | } | 278 | } |
279 | LCRYPTO_ALIAS(EVP_sha512); | ||
275 | 280 | ||
276 | static int | 281 | static int |
277 | sha512_224_init(EVP_MD_CTX *ctx) | 282 | sha512_224_init(EVP_MD_CTX *ctx) |
@@ -310,6 +315,7 @@ EVP_sha512_224(void) | |||
310 | { | 315 | { |
311 | return &sha512_224_md; | 316 | return &sha512_224_md; |
312 | } | 317 | } |
318 | LCRYPTO_ALIAS(EVP_sha512_224); | ||
313 | 319 | ||
314 | static int | 320 | static int |
315 | sha512_256_init(EVP_MD_CTX *ctx) | 321 | sha512_256_init(EVP_MD_CTX *ctx) |
@@ -348,4 +354,5 @@ EVP_sha512_256(void) | |||
348 | { | 354 | { |
349 | return &sha512_256_md; | 355 | return &sha512_256_md; |
350 | } | 356 | } |
357 | LCRYPTO_ALIAS(EVP_sha512_256); | ||
351 | #endif /* ifndef OPENSSL_NO_SHA512 */ | 358 | #endif /* ifndef OPENSSL_NO_SHA512 */ |
diff --git a/src/lib/libcrypto/evp/m_sha3.c b/src/lib/libcrypto/evp/m_sha3.c index 9944ec979d..9137629823 100644 --- a/src/lib/libcrypto/evp/m_sha3.c +++ b/src/lib/libcrypto/evp/m_sha3.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_sha3.c,v 1.1 2023/04/16 17:06:19 jsing Exp $ */ | 1 | /* $OpenBSD: m_sha3.c,v 1.2 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -57,6 +57,7 @@ EVP_sha3_224(void) | |||
57 | { | 57 | { |
58 | return &sha3_224_md; | 58 | return &sha3_224_md; |
59 | } | 59 | } |
60 | LCRYPTO_ALIAS(EVP_sha3_224); | ||
60 | 61 | ||
61 | static int | 62 | static int |
62 | sha3_256_init(EVP_MD_CTX *ctx) | 63 | sha3_256_init(EVP_MD_CTX *ctx) |
@@ -95,6 +96,7 @@ EVP_sha3_256(void) | |||
95 | { | 96 | { |
96 | return &sha3_256_md; | 97 | return &sha3_256_md; |
97 | } | 98 | } |
99 | LCRYPTO_ALIAS(EVP_sha3_256); | ||
98 | 100 | ||
99 | static int | 101 | static int |
100 | sha3_384_init(EVP_MD_CTX *ctx) | 102 | sha3_384_init(EVP_MD_CTX *ctx) |
@@ -133,6 +135,7 @@ EVP_sha3_384(void) | |||
133 | { | 135 | { |
134 | return &sha3_384_md; | 136 | return &sha3_384_md; |
135 | } | 137 | } |
138 | LCRYPTO_ALIAS(EVP_sha3_384); | ||
136 | 139 | ||
137 | static int | 140 | static int |
138 | sha3_512_init(EVP_MD_CTX *ctx) | 141 | sha3_512_init(EVP_MD_CTX *ctx) |
@@ -171,3 +174,4 @@ EVP_sha3_512(void) | |||
171 | { | 174 | { |
172 | return &sha3_512_md; | 175 | return &sha3_512_md; |
173 | } | 176 | } |
177 | LCRYPTO_ALIAS(EVP_sha3_512); | ||
diff --git a/src/lib/libcrypto/evp/m_sigver.c b/src/lib/libcrypto/evp/m_sigver.c index 49b1ce29b7..950e4a2a2f 100644 --- a/src/lib/libcrypto/evp/m_sigver.c +++ b/src/lib/libcrypto/evp/m_sigver.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_sigver.c,v 1.11 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_sigver.c,v 1.12 2023/07/07 13:54:45 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 2006. | 3 | * project 2006. |
4 | */ | 4 | */ |
@@ -133,6 +133,7 @@ EVP_DigestSignInit(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx, const EVP_MD *type, | |||
133 | { | 133 | { |
134 | return do_sigver_init(ctx, pctx, type, e, pkey, 0); | 134 | return do_sigver_init(ctx, pctx, type, e, pkey, 0); |
135 | } | 135 | } |
136 | LCRYPTO_ALIAS(EVP_DigestSignInit); | ||
136 | 137 | ||
137 | int | 138 | int |
138 | EVP_DigestVerifyInit(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx, const EVP_MD *type, | 139 | EVP_DigestVerifyInit(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx, const EVP_MD *type, |
@@ -140,6 +141,7 @@ EVP_DigestVerifyInit(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx, const EVP_MD *type, | |||
140 | { | 141 | { |
141 | return do_sigver_init(ctx, pctx, type, e, pkey, 1); | 142 | return do_sigver_init(ctx, pctx, type, e, pkey, 1); |
142 | } | 143 | } |
144 | LCRYPTO_ALIAS(EVP_DigestVerifyInit); | ||
143 | 145 | ||
144 | int | 146 | int |
145 | EVP_DigestSignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen) | 147 | EVP_DigestSignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen) |
@@ -198,6 +200,7 @@ EVP_DigestSignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen) | |||
198 | } | 200 | } |
199 | return 1; | 201 | return 1; |
200 | } | 202 | } |
203 | LCRYPTO_ALIAS(EVP_DigestSignFinal); | ||
201 | 204 | ||
202 | int | 205 | int |
203 | EVP_DigestSign(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen, | 206 | EVP_DigestSign(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen, |
@@ -214,6 +217,7 @@ EVP_DigestSign(EVP_MD_CTX *ctx, unsigned char *sigret, size_t *siglen, | |||
214 | 217 | ||
215 | return EVP_DigestSignFinal(ctx, sigret, siglen); | 218 | return EVP_DigestSignFinal(ctx, sigret, siglen); |
216 | } | 219 | } |
220 | LCRYPTO_ALIAS(EVP_DigestSign); | ||
217 | 221 | ||
218 | int | 222 | int |
219 | EVP_DigestVerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sig, size_t siglen) | 223 | EVP_DigestVerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sig, size_t siglen) |
@@ -241,6 +245,7 @@ EVP_DigestVerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sig, size_t siglen) | |||
241 | return r; | 245 | return r; |
242 | return EVP_PKEY_verify(ctx->pctx, sig, siglen, md, mdlen); | 246 | return EVP_PKEY_verify(ctx->pctx, sig, siglen, md, mdlen); |
243 | } | 247 | } |
248 | LCRYPTO_ALIAS(EVP_DigestVerifyFinal); | ||
244 | 249 | ||
245 | int | 250 | int |
246 | EVP_DigestVerify(EVP_MD_CTX *ctx, const unsigned char *sigret, size_t siglen, | 251 | EVP_DigestVerify(EVP_MD_CTX *ctx, const unsigned char *sigret, size_t siglen, |
@@ -255,3 +260,4 @@ EVP_DigestVerify(EVP_MD_CTX *ctx, const unsigned char *sigret, size_t siglen, | |||
255 | 260 | ||
256 | return EVP_DigestVerifyFinal(ctx, sigret, siglen); | 261 | return EVP_DigestVerifyFinal(ctx, sigret, siglen); |
257 | } | 262 | } |
263 | LCRYPTO_ALIAS(EVP_DigestVerify); | ||
diff --git a/src/lib/libcrypto/evp/m_sm3.c b/src/lib/libcrypto/evp/m_sm3.c index bf0ef527eb..169a492d68 100644 --- a/src/lib/libcrypto/evp/m_sm3.c +++ b/src/lib/libcrypto/evp/m_sm3.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_sm3.c,v 1.4 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_sm3.c,v 1.5 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2018, Ribose Inc | 3 | * Copyright (c) 2018, Ribose Inc |
4 | * | 4 | * |
@@ -64,5 +64,6 @@ EVP_sm3(void) | |||
64 | { | 64 | { |
65 | return &sm3_md; | 65 | return &sm3_md; |
66 | } | 66 | } |
67 | LCRYPTO_ALIAS(EVP_sm3); | ||
67 | 68 | ||
68 | #endif /* OPENSSL_NO_SM3 */ | 69 | #endif /* OPENSSL_NO_SM3 */ |
diff --git a/src/lib/libcrypto/evp/m_streebog.c b/src/lib/libcrypto/evp/m_streebog.c index 5a0dece599..ce41e4ca8f 100644 --- a/src/lib/libcrypto/evp/m_streebog.c +++ b/src/lib/libcrypto/evp/m_streebog.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_streebog.c,v 1.5 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_streebog.c,v 1.6 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 3 | * Copyright (c) 2014 Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> |
4 | * Copyright (c) 2005-2006 Cryptocom LTD | 4 | * Copyright (c) 2005-2006 Cryptocom LTD |
@@ -124,10 +124,12 @@ EVP_streebog256(void) | |||
124 | { | 124 | { |
125 | return (&streebog256_md); | 125 | return (&streebog256_md); |
126 | } | 126 | } |
127 | LCRYPTO_ALIAS(EVP_streebog256); | ||
127 | 128 | ||
128 | const EVP_MD * | 129 | const EVP_MD * |
129 | EVP_streebog512(void) | 130 | EVP_streebog512(void) |
130 | { | 131 | { |
131 | return (&streebog512_md); | 132 | return (&streebog512_md); |
132 | } | 133 | } |
134 | LCRYPTO_ALIAS(EVP_streebog512); | ||
133 | #endif | 135 | #endif |
diff --git a/src/lib/libcrypto/evp/m_wp.c b/src/lib/libcrypto/evp/m_wp.c index 2e0b46d5d3..9bd43370e6 100644 --- a/src/lib/libcrypto/evp/m_wp.c +++ b/src/lib/libcrypto/evp/m_wp.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: m_wp.c,v 1.11 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: m_wp.c,v 1.12 2023/07/07 13:54:46 beck Exp $ */ |
2 | 2 | ||
3 | #include <stdio.h> | 3 | #include <stdio.h> |
4 | 4 | ||
@@ -50,4 +50,5 @@ EVP_whirlpool(void) | |||
50 | { | 50 | { |
51 | return (&whirlpool_md); | 51 | return (&whirlpool_md); |
52 | } | 52 | } |
53 | LCRYPTO_ALIAS(EVP_whirlpool); | ||
53 | #endif | 54 | #endif |
diff --git a/src/lib/libcrypto/evp/names.c b/src/lib/libcrypto/evp/names.c index 10ce13bb89..c6109a5356 100644 --- a/src/lib/libcrypto/evp/names.c +++ b/src/lib/libcrypto/evp/names.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: names.c,v 1.17 2023/06/29 06:11:33 tb Exp $ */ | 1 | /* $OpenBSD: names.c,v 1.18 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -84,6 +84,7 @@ EVP_add_cipher(const EVP_CIPHER *c) | |||
84 | (const char *)c); | 84 | (const char *)c); |
85 | return (r); | 85 | return (r); |
86 | } | 86 | } |
87 | LCRYPTO_ALIAS(EVP_add_cipher); | ||
87 | 88 | ||
88 | int | 89 | int |
89 | EVP_add_digest(const EVP_MD *md) | 90 | EVP_add_digest(const EVP_MD *md) |
@@ -112,6 +113,7 @@ EVP_add_digest(const EVP_MD *md) | |||
112 | } | 113 | } |
113 | return (r); | 114 | return (r); |
114 | } | 115 | } |
116 | LCRYPTO_ALIAS(EVP_add_digest); | ||
115 | 117 | ||
116 | const EVP_CIPHER * | 118 | const EVP_CIPHER * |
117 | EVP_get_cipherbyname(const char *name) | 119 | EVP_get_cipherbyname(const char *name) |
@@ -124,6 +126,7 @@ EVP_get_cipherbyname(const char *name) | |||
124 | cp = (const EVP_CIPHER *)OBJ_NAME_get(name, OBJ_NAME_TYPE_CIPHER_METH); | 126 | cp = (const EVP_CIPHER *)OBJ_NAME_get(name, OBJ_NAME_TYPE_CIPHER_METH); |
125 | return (cp); | 127 | return (cp); |
126 | } | 128 | } |
129 | LCRYPTO_ALIAS(EVP_get_cipherbyname); | ||
127 | 130 | ||
128 | const EVP_MD * | 131 | const EVP_MD * |
129 | EVP_get_digestbyname(const char *name) | 132 | EVP_get_digestbyname(const char *name) |
@@ -136,6 +139,7 @@ EVP_get_digestbyname(const char *name) | |||
136 | cp = (const EVP_MD *)OBJ_NAME_get(name, OBJ_NAME_TYPE_MD_METH); | 139 | cp = (const EVP_MD *)OBJ_NAME_get(name, OBJ_NAME_TYPE_MD_METH); |
137 | return (cp); | 140 | return (cp); |
138 | } | 141 | } |
142 | LCRYPTO_ALIAS(EVP_get_digestbyname); | ||
139 | 143 | ||
140 | void | 144 | void |
141 | EVP_cleanup(void) | 145 | EVP_cleanup(void) |
@@ -154,6 +158,7 @@ EVP_cleanup(void) | |||
154 | } | 158 | } |
155 | OBJ_sigid_free(); | 159 | OBJ_sigid_free(); |
156 | } | 160 | } |
161 | LCRYPTO_ALIAS(EVP_cleanup); | ||
157 | 162 | ||
158 | struct doall_cipher { | 163 | struct doall_cipher { |
159 | void *arg; | 164 | void *arg; |
@@ -185,6 +190,7 @@ EVP_CIPHER_do_all(void (*fn)(const EVP_CIPHER *ciph, const char *from, | |||
185 | dc.arg = arg; | 190 | dc.arg = arg; |
186 | OBJ_NAME_do_all(OBJ_NAME_TYPE_CIPHER_METH, do_all_cipher_fn, &dc); | 191 | OBJ_NAME_do_all(OBJ_NAME_TYPE_CIPHER_METH, do_all_cipher_fn, &dc); |
187 | } | 192 | } |
193 | LCRYPTO_ALIAS(EVP_CIPHER_do_all); | ||
188 | 194 | ||
189 | void | 195 | void |
190 | EVP_CIPHER_do_all_sorted(void (*fn)(const EVP_CIPHER *ciph, const char *from, | 196 | EVP_CIPHER_do_all_sorted(void (*fn)(const EVP_CIPHER *ciph, const char *from, |
@@ -200,6 +206,7 @@ EVP_CIPHER_do_all_sorted(void (*fn)(const EVP_CIPHER *ciph, const char *from, | |||
200 | OBJ_NAME_do_all_sorted(OBJ_NAME_TYPE_CIPHER_METH, | 206 | OBJ_NAME_do_all_sorted(OBJ_NAME_TYPE_CIPHER_METH, |
201 | do_all_cipher_fn, &dc); | 207 | do_all_cipher_fn, &dc); |
202 | } | 208 | } |
209 | LCRYPTO_ALIAS(EVP_CIPHER_do_all_sorted); | ||
203 | 210 | ||
204 | struct doall_md { | 211 | struct doall_md { |
205 | void *arg; | 212 | void *arg; |
@@ -231,6 +238,7 @@ EVP_MD_do_all(void (*fn)(const EVP_MD *md, const char *from, const char *to, | |||
231 | dc.arg = arg; | 238 | dc.arg = arg; |
232 | OBJ_NAME_do_all(OBJ_NAME_TYPE_MD_METH, do_all_md_fn, &dc); | 239 | OBJ_NAME_do_all(OBJ_NAME_TYPE_MD_METH, do_all_md_fn, &dc); |
233 | } | 240 | } |
241 | LCRYPTO_ALIAS(EVP_MD_do_all); | ||
234 | 242 | ||
235 | void | 243 | void |
236 | EVP_MD_do_all_sorted(void (*fn)(const EVP_MD *md, | 244 | EVP_MD_do_all_sorted(void (*fn)(const EVP_MD *md, |
@@ -245,3 +253,4 @@ EVP_MD_do_all_sorted(void (*fn)(const EVP_MD *md, | |||
245 | dc.arg = arg; | 253 | dc.arg = arg; |
246 | OBJ_NAME_do_all_sorted(OBJ_NAME_TYPE_MD_METH, do_all_md_fn, &dc); | 254 | OBJ_NAME_do_all_sorted(OBJ_NAME_TYPE_MD_METH, do_all_md_fn, &dc); |
247 | } | 255 | } |
256 | LCRYPTO_ALIAS(EVP_MD_do_all_sorted); | ||
diff --git a/src/lib/libcrypto/evp/p5_crpt.c b/src/lib/libcrypto/evp/p5_crpt.c index e85a60f50e..cf30ad9176 100644 --- a/src/lib/libcrypto/evp/p5_crpt.c +++ b/src/lib/libcrypto/evp/p5_crpt.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p5_crpt.c,v 1.21 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: p5_crpt.c,v 1.22 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 1999. | 3 | * project 1999. |
4 | */ | 4 | */ |
@@ -73,6 +73,7 @@ void | |||
73 | PKCS5_PBE_add(void) | 73 | PKCS5_PBE_add(void) |
74 | { | 74 | { |
75 | } | 75 | } |
76 | LCRYPTO_ALIAS(PKCS5_PBE_add); | ||
76 | 77 | ||
77 | int | 78 | int |
78 | PKCS5_PBE_keyivgen(EVP_CIPHER_CTX *cctx, const char *pass, int passlen, | 79 | PKCS5_PBE_keyivgen(EVP_CIPHER_CTX *cctx, const char *pass, int passlen, |
@@ -161,3 +162,4 @@ err: | |||
161 | PBEPARAM_free(pbe); | 162 | PBEPARAM_free(pbe); |
162 | return rv; | 163 | return rv; |
163 | } | 164 | } |
165 | LCRYPTO_ALIAS(PKCS5_PBE_keyivgen); | ||
diff --git a/src/lib/libcrypto/evp/p5_crpt2.c b/src/lib/libcrypto/evp/p5_crpt2.c index 6c0cf529a4..a6fcc30fa4 100644 --- a/src/lib/libcrypto/evp/p5_crpt2.c +++ b/src/lib/libcrypto/evp/p5_crpt2.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p5_crpt2.c,v 1.25 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: p5_crpt2.c,v 1.26 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 1999. | 3 | * project 1999. |
4 | */ | 4 | */ |
@@ -149,6 +149,7 @@ PKCS5_PBKDF2_HMAC(const char *pass, int passlen, const unsigned char *salt, | |||
149 | HMAC_CTX_cleanup(&hctx_tpl); | 149 | HMAC_CTX_cleanup(&hctx_tpl); |
150 | return 1; | 150 | return 1; |
151 | } | 151 | } |
152 | LCRYPTO_ALIAS(PKCS5_PBKDF2_HMAC); | ||
152 | 153 | ||
153 | int | 154 | int |
154 | PKCS5_PBKDF2_HMAC_SHA1(const char *pass, int passlen, const unsigned char *salt, | 155 | PKCS5_PBKDF2_HMAC_SHA1(const char *pass, int passlen, const unsigned char *salt, |
@@ -157,6 +158,7 @@ PKCS5_PBKDF2_HMAC_SHA1(const char *pass, int passlen, const unsigned char *salt, | |||
157 | return PKCS5_PBKDF2_HMAC(pass, passlen, salt, saltlen, iter, | 158 | return PKCS5_PBKDF2_HMAC(pass, passlen, salt, saltlen, iter, |
158 | EVP_sha1(), keylen, out); | 159 | EVP_sha1(), keylen, out); |
159 | } | 160 | } |
161 | LCRYPTO_ALIAS(PKCS5_PBKDF2_HMAC_SHA1); | ||
160 | 162 | ||
161 | /* Now the key derivation function itself. This is a bit evil because | 163 | /* Now the key derivation function itself. This is a bit evil because |
162 | * it has to check the ASN1 parameters are valid: and there are quite a | 164 | * it has to check the ASN1 parameters are valid: and there are quite a |
@@ -218,6 +220,7 @@ err: | |||
218 | PBE2PARAM_free(pbe2); | 220 | PBE2PARAM_free(pbe2); |
219 | return rv; | 221 | return rv; |
220 | } | 222 | } |
223 | LCRYPTO_ALIAS(PKCS5_v2_PBE_keyivgen); | ||
221 | 224 | ||
222 | int | 225 | int |
223 | PKCS5_v2_PBKDF2_keyivgen(EVP_CIPHER_CTX *ctx, const char *pass, int passlen, | 226 | PKCS5_v2_PBKDF2_keyivgen(EVP_CIPHER_CTX *ctx, const char *pass, int passlen, |
diff --git a/src/lib/libcrypto/evp/p_dec.c b/src/lib/libcrypto/evp/p_dec.c index 33dd301911..7225606c31 100644 --- a/src/lib/libcrypto/evp/p_dec.c +++ b/src/lib/libcrypto/evp/p_dec.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_dec.c,v 1.13 2022/11/26 16:08:52 tb Exp $ */ | 1 | /* $OpenBSD: p_dec.c,v 1.14 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -92,3 +92,4 @@ err: | |||
92 | #endif | 92 | #endif |
93 | return (ret); | 93 | return (ret); |
94 | } | 94 | } |
95 | LCRYPTO_ALIAS(EVP_PKEY_decrypt_old); | ||
diff --git a/src/lib/libcrypto/evp/p_enc.c b/src/lib/libcrypto/evp/p_enc.c index 4685f55cad..c2a16234e8 100644 --- a/src/lib/libcrypto/evp/p_enc.c +++ b/src/lib/libcrypto/evp/p_enc.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_enc.c,v 1.13 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: p_enc.c,v 1.14 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -89,3 +89,4 @@ err: | |||
89 | #endif | 89 | #endif |
90 | return (ret); | 90 | return (ret); |
91 | } | 91 | } |
92 | LCRYPTO_ALIAS(EVP_PKEY_encrypt_old); | ||
diff --git a/src/lib/libcrypto/evp/p_lib.c b/src/lib/libcrypto/evp/p_lib.c index e1760122c6..325fb605df 100644 --- a/src/lib/libcrypto/evp/p_lib.c +++ b/src/lib/libcrypto/evp/p_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_lib.c,v 1.32 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: p_lib.c,v 1.33 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -93,6 +93,7 @@ EVP_PKEY_bits(const EVP_PKEY *pkey) | |||
93 | return pkey->ameth->pkey_bits(pkey); | 93 | return pkey->ameth->pkey_bits(pkey); |
94 | return 0; | 94 | return 0; |
95 | } | 95 | } |
96 | LCRYPTO_ALIAS(EVP_PKEY_bits); | ||
96 | 97 | ||
97 | int | 98 | int |
98 | EVP_PKEY_security_bits(const EVP_PKEY *pkey) | 99 | EVP_PKEY_security_bits(const EVP_PKEY *pkey) |
@@ -104,6 +105,7 @@ EVP_PKEY_security_bits(const EVP_PKEY *pkey) | |||
104 | 105 | ||
105 | return pkey->ameth->pkey_security_bits(pkey); | 106 | return pkey->ameth->pkey_security_bits(pkey); |
106 | } | 107 | } |
108 | LCRYPTO_ALIAS(EVP_PKEY_security_bits); | ||
107 | 109 | ||
108 | int | 110 | int |
109 | EVP_PKEY_size(const EVP_PKEY *pkey) | 111 | EVP_PKEY_size(const EVP_PKEY *pkey) |
@@ -112,6 +114,7 @@ EVP_PKEY_size(const EVP_PKEY *pkey) | |||
112 | return pkey->ameth->pkey_size(pkey); | 114 | return pkey->ameth->pkey_size(pkey); |
113 | return 0; | 115 | return 0; |
114 | } | 116 | } |
117 | LCRYPTO_ALIAS(EVP_PKEY_size); | ||
115 | 118 | ||
116 | int | 119 | int |
117 | EVP_PKEY_save_parameters(EVP_PKEY *pkey, int mode) | 120 | EVP_PKEY_save_parameters(EVP_PKEY *pkey, int mode) |
@@ -136,6 +139,7 @@ EVP_PKEY_save_parameters(EVP_PKEY *pkey, int mode) | |||
136 | #endif | 139 | #endif |
137 | return (0); | 140 | return (0); |
138 | } | 141 | } |
142 | LCRYPTO_ALIAS(EVP_PKEY_save_parameters); | ||
139 | 143 | ||
140 | int | 144 | int |
141 | EVP_PKEY_copy_parameters(EVP_PKEY *to, const EVP_PKEY *from) | 145 | EVP_PKEY_copy_parameters(EVP_PKEY *to, const EVP_PKEY *from) |
@@ -155,6 +159,7 @@ EVP_PKEY_copy_parameters(EVP_PKEY *to, const EVP_PKEY *from) | |||
155 | err: | 159 | err: |
156 | return 0; | 160 | return 0; |
157 | } | 161 | } |
162 | LCRYPTO_ALIAS(EVP_PKEY_copy_parameters); | ||
158 | 163 | ||
159 | int | 164 | int |
160 | EVP_PKEY_missing_parameters(const EVP_PKEY *pkey) | 165 | EVP_PKEY_missing_parameters(const EVP_PKEY *pkey) |
@@ -163,6 +168,7 @@ EVP_PKEY_missing_parameters(const EVP_PKEY *pkey) | |||
163 | return pkey->ameth->param_missing(pkey); | 168 | return pkey->ameth->param_missing(pkey); |
164 | return 0; | 169 | return 0; |
165 | } | 170 | } |
171 | LCRYPTO_ALIAS(EVP_PKEY_missing_parameters); | ||
166 | 172 | ||
167 | int | 173 | int |
168 | EVP_PKEY_cmp_parameters(const EVP_PKEY *a, const EVP_PKEY *b) | 174 | EVP_PKEY_cmp_parameters(const EVP_PKEY *a, const EVP_PKEY *b) |
@@ -173,6 +179,7 @@ EVP_PKEY_cmp_parameters(const EVP_PKEY *a, const EVP_PKEY *b) | |||
173 | return a->ameth->param_cmp(a, b); | 179 | return a->ameth->param_cmp(a, b); |
174 | return -2; | 180 | return -2; |
175 | } | 181 | } |
182 | LCRYPTO_ALIAS(EVP_PKEY_cmp_parameters); | ||
176 | 183 | ||
177 | int | 184 | int |
178 | EVP_PKEY_cmp(const EVP_PKEY *a, const EVP_PKEY *b) | 185 | EVP_PKEY_cmp(const EVP_PKEY *a, const EVP_PKEY *b) |
@@ -195,6 +202,7 @@ EVP_PKEY_cmp(const EVP_PKEY *a, const EVP_PKEY *b) | |||
195 | 202 | ||
196 | return -2; | 203 | return -2; |
197 | } | 204 | } |
205 | LCRYPTO_ALIAS(EVP_PKEY_cmp); | ||
198 | 206 | ||
199 | EVP_PKEY * | 207 | EVP_PKEY * |
200 | EVP_PKEY_new(void) | 208 | EVP_PKEY_new(void) |
@@ -216,6 +224,7 @@ EVP_PKEY_new(void) | |||
216 | ret->save_parameters = 1; | 224 | ret->save_parameters = 1; |
217 | return (ret); | 225 | return (ret); |
218 | } | 226 | } |
227 | LCRYPTO_ALIAS(EVP_PKEY_new); | ||
219 | 228 | ||
220 | int | 229 | int |
221 | EVP_PKEY_up_ref(EVP_PKEY *pkey) | 230 | EVP_PKEY_up_ref(EVP_PKEY *pkey) |
@@ -223,6 +232,7 @@ EVP_PKEY_up_ref(EVP_PKEY *pkey) | |||
223 | int refs = CRYPTO_add(&pkey->references, 1, CRYPTO_LOCK_EVP_PKEY); | 232 | int refs = CRYPTO_add(&pkey->references, 1, CRYPTO_LOCK_EVP_PKEY); |
224 | return ((refs > 1) ? 1 : 0); | 233 | return ((refs > 1) ? 1 : 0); |
225 | } | 234 | } |
235 | LCRYPTO_ALIAS(EVP_PKEY_up_ref); | ||
226 | 236 | ||
227 | /* Setup a public key ASN1 method and ENGINE from a NID or a string. | 237 | /* Setup a public key ASN1 method and ENGINE from a NID or a string. |
228 | * If pkey is NULL just return 1 or 0 if the algorithm exists. | 238 | * If pkey is NULL just return 1 or 0 if the algorithm exists. |
@@ -277,6 +287,7 @@ EVP_PKEY_set_type(EVP_PKEY *pkey, int type) | |||
277 | { | 287 | { |
278 | return pkey_set_type(pkey, NULL, type, NULL, -1); | 288 | return pkey_set_type(pkey, NULL, type, NULL, -1); |
279 | } | 289 | } |
290 | LCRYPTO_ALIAS(EVP_PKEY_set_type); | ||
280 | 291 | ||
281 | EVP_PKEY * | 292 | EVP_PKEY * |
282 | EVP_PKEY_new_raw_private_key(int type, ENGINE *engine, | 293 | EVP_PKEY_new_raw_private_key(int type, ENGINE *engine, |
@@ -306,6 +317,7 @@ EVP_PKEY_new_raw_private_key(int type, ENGINE *engine, | |||
306 | 317 | ||
307 | return NULL; | 318 | return NULL; |
308 | } | 319 | } |
320 | LCRYPTO_ALIAS(EVP_PKEY_new_raw_private_key); | ||
309 | 321 | ||
310 | EVP_PKEY * | 322 | EVP_PKEY * |
311 | EVP_PKEY_new_raw_public_key(int type, ENGINE *engine, | 323 | EVP_PKEY_new_raw_public_key(int type, ENGINE *engine, |
@@ -335,6 +347,7 @@ EVP_PKEY_new_raw_public_key(int type, ENGINE *engine, | |||
335 | 347 | ||
336 | return NULL; | 348 | return NULL; |
337 | } | 349 | } |
350 | LCRYPTO_ALIAS(EVP_PKEY_new_raw_public_key); | ||
338 | 351 | ||
339 | int | 352 | int |
340 | EVP_PKEY_get_raw_private_key(const EVP_PKEY *pkey, | 353 | EVP_PKEY_get_raw_private_key(const EVP_PKEY *pkey, |
@@ -351,6 +364,7 @@ EVP_PKEY_get_raw_private_key(const EVP_PKEY *pkey, | |||
351 | 364 | ||
352 | return 1; | 365 | return 1; |
353 | } | 366 | } |
367 | LCRYPTO_ALIAS(EVP_PKEY_get_raw_private_key); | ||
354 | 368 | ||
355 | int | 369 | int |
356 | EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, | 370 | EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, |
@@ -367,6 +381,7 @@ EVP_PKEY_get_raw_public_key(const EVP_PKEY *pkey, | |||
367 | 381 | ||
368 | return 1; | 382 | return 1; |
369 | } | 383 | } |
384 | LCRYPTO_ALIAS(EVP_PKEY_get_raw_public_key); | ||
370 | 385 | ||
371 | EVP_PKEY * | 386 | EVP_PKEY * |
372 | EVP_PKEY_new_CMAC_key(ENGINE *e, const unsigned char *priv, size_t len, | 387 | EVP_PKEY_new_CMAC_key(ENGINE *e, const unsigned char *priv, size_t len, |
@@ -397,12 +412,14 @@ EVP_PKEY_new_CMAC_key(ENGINE *e, const unsigned char *priv, size_t len, | |||
397 | CMAC_CTX_free(cmctx); | 412 | CMAC_CTX_free(cmctx); |
398 | return NULL; | 413 | return NULL; |
399 | } | 414 | } |
415 | LCRYPTO_ALIAS(EVP_PKEY_new_CMAC_key); | ||
400 | 416 | ||
401 | int | 417 | int |
402 | EVP_PKEY_set_type_str(EVP_PKEY *pkey, const char *str, int len) | 418 | EVP_PKEY_set_type_str(EVP_PKEY *pkey, const char *str, int len) |
403 | { | 419 | { |
404 | return pkey_set_type(pkey, NULL, EVP_PKEY_NONE, str, len); | 420 | return pkey_set_type(pkey, NULL, EVP_PKEY_NONE, str, len); |
405 | } | 421 | } |
422 | LCRYPTO_ALIAS(EVP_PKEY_set_type_str); | ||
406 | 423 | ||
407 | int | 424 | int |
408 | EVP_PKEY_assign(EVP_PKEY *pkey, int type, void *key) | 425 | EVP_PKEY_assign(EVP_PKEY *pkey, int type, void *key) |
@@ -412,12 +429,14 @@ EVP_PKEY_assign(EVP_PKEY *pkey, int type, void *key) | |||
412 | pkey->pkey.ptr = key; | 429 | pkey->pkey.ptr = key; |
413 | return (key != NULL); | 430 | return (key != NULL); |
414 | } | 431 | } |
432 | LCRYPTO_ALIAS(EVP_PKEY_assign); | ||
415 | 433 | ||
416 | void * | 434 | void * |
417 | EVP_PKEY_get0(const EVP_PKEY *pkey) | 435 | EVP_PKEY_get0(const EVP_PKEY *pkey) |
418 | { | 436 | { |
419 | return pkey->pkey.ptr; | 437 | return pkey->pkey.ptr; |
420 | } | 438 | } |
439 | LCRYPTO_ALIAS(EVP_PKEY_get0); | ||
421 | 440 | ||
422 | const unsigned char * | 441 | const unsigned char * |
423 | EVP_PKEY_get0_hmac(const EVP_PKEY *pkey, size_t *len) | 442 | EVP_PKEY_get0_hmac(const EVP_PKEY *pkey, size_t *len) |
@@ -434,6 +453,7 @@ EVP_PKEY_get0_hmac(const EVP_PKEY *pkey, size_t *len) | |||
434 | 453 | ||
435 | return os->data; | 454 | return os->data; |
436 | } | 455 | } |
456 | LCRYPTO_ALIAS(EVP_PKEY_get0_hmac); | ||
437 | 457 | ||
438 | #ifndef OPENSSL_NO_RSA | 458 | #ifndef OPENSSL_NO_RSA |
439 | RSA * | 459 | RSA * |
@@ -445,6 +465,7 @@ EVP_PKEY_get0_RSA(EVP_PKEY *pkey) | |||
445 | } | 465 | } |
446 | return pkey->pkey.rsa; | 466 | return pkey->pkey.rsa; |
447 | } | 467 | } |
468 | LCRYPTO_ALIAS(EVP_PKEY_get0_RSA); | ||
448 | 469 | ||
449 | RSA * | 470 | RSA * |
450 | EVP_PKEY_get1_RSA(EVP_PKEY *pkey) | 471 | EVP_PKEY_get1_RSA(EVP_PKEY *pkey) |
@@ -456,6 +477,7 @@ EVP_PKEY_get1_RSA(EVP_PKEY *pkey) | |||
456 | RSA_up_ref(pkey->pkey.rsa); | 477 | RSA_up_ref(pkey->pkey.rsa); |
457 | return pkey->pkey.rsa; | 478 | return pkey->pkey.rsa; |
458 | } | 479 | } |
480 | LCRYPTO_ALIAS(EVP_PKEY_get1_RSA); | ||
459 | 481 | ||
460 | int | 482 | int |
461 | EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) | 483 | EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) |
@@ -465,6 +487,7 @@ EVP_PKEY_set1_RSA(EVP_PKEY *pkey, RSA *key) | |||
465 | RSA_up_ref(key); | 487 | RSA_up_ref(key); |
466 | return ret; | 488 | return ret; |
467 | } | 489 | } |
490 | LCRYPTO_ALIAS(EVP_PKEY_set1_RSA); | ||
468 | #endif | 491 | #endif |
469 | 492 | ||
470 | #ifndef OPENSSL_NO_DSA | 493 | #ifndef OPENSSL_NO_DSA |
@@ -477,6 +500,7 @@ EVP_PKEY_get0_DSA(EVP_PKEY *pkey) | |||
477 | } | 500 | } |
478 | return pkey->pkey.dsa; | 501 | return pkey->pkey.dsa; |
479 | } | 502 | } |
503 | LCRYPTO_ALIAS(EVP_PKEY_get0_DSA); | ||
480 | 504 | ||
481 | DSA * | 505 | DSA * |
482 | EVP_PKEY_get1_DSA(EVP_PKEY *pkey) | 506 | EVP_PKEY_get1_DSA(EVP_PKEY *pkey) |
@@ -488,6 +512,7 @@ EVP_PKEY_get1_DSA(EVP_PKEY *pkey) | |||
488 | DSA_up_ref(pkey->pkey.dsa); | 512 | DSA_up_ref(pkey->pkey.dsa); |
489 | return pkey->pkey.dsa; | 513 | return pkey->pkey.dsa; |
490 | } | 514 | } |
515 | LCRYPTO_ALIAS(EVP_PKEY_get1_DSA); | ||
491 | 516 | ||
492 | int | 517 | int |
493 | EVP_PKEY_set1_DSA(EVP_PKEY *pkey, DSA *key) | 518 | EVP_PKEY_set1_DSA(EVP_PKEY *pkey, DSA *key) |
@@ -497,6 +522,7 @@ EVP_PKEY_set1_DSA(EVP_PKEY *pkey, DSA *key) | |||
497 | DSA_up_ref(key); | 522 | DSA_up_ref(key); |
498 | return ret; | 523 | return ret; |
499 | } | 524 | } |
525 | LCRYPTO_ALIAS(EVP_PKEY_set1_DSA); | ||
500 | #endif | 526 | #endif |
501 | 527 | ||
502 | #ifndef OPENSSL_NO_EC | 528 | #ifndef OPENSSL_NO_EC |
@@ -509,6 +535,7 @@ EVP_PKEY_get0_EC_KEY(EVP_PKEY *pkey) | |||
509 | } | 535 | } |
510 | return pkey->pkey.ec; | 536 | return pkey->pkey.ec; |
511 | } | 537 | } |
538 | LCRYPTO_ALIAS(EVP_PKEY_get0_EC_KEY); | ||
512 | 539 | ||
513 | EC_KEY * | 540 | EC_KEY * |
514 | EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) | 541 | EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) |
@@ -520,6 +547,7 @@ EVP_PKEY_get1_EC_KEY(EVP_PKEY *pkey) | |||
520 | EC_KEY_up_ref(pkey->pkey.ec); | 547 | EC_KEY_up_ref(pkey->pkey.ec); |
521 | return pkey->pkey.ec; | 548 | return pkey->pkey.ec; |
522 | } | 549 | } |
550 | LCRYPTO_ALIAS(EVP_PKEY_get1_EC_KEY); | ||
523 | 551 | ||
524 | int | 552 | int |
525 | EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key) | 553 | EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key) |
@@ -529,6 +557,7 @@ EVP_PKEY_set1_EC_KEY(EVP_PKEY *pkey, EC_KEY *key) | |||
529 | EC_KEY_up_ref(key); | 557 | EC_KEY_up_ref(key); |
530 | return ret; | 558 | return ret; |
531 | } | 559 | } |
560 | LCRYPTO_ALIAS(EVP_PKEY_set1_EC_KEY); | ||
532 | #endif | 561 | #endif |
533 | 562 | ||
534 | 563 | ||
@@ -542,6 +571,7 @@ EVP_PKEY_get0_DH(EVP_PKEY *pkey) | |||
542 | } | 571 | } |
543 | return pkey->pkey.dh; | 572 | return pkey->pkey.dh; |
544 | } | 573 | } |
574 | LCRYPTO_ALIAS(EVP_PKEY_get0_DH); | ||
545 | 575 | ||
546 | DH * | 576 | DH * |
547 | EVP_PKEY_get1_DH(EVP_PKEY *pkey) | 577 | EVP_PKEY_get1_DH(EVP_PKEY *pkey) |
@@ -553,6 +583,7 @@ EVP_PKEY_get1_DH(EVP_PKEY *pkey) | |||
553 | DH_up_ref(pkey->pkey.dh); | 583 | DH_up_ref(pkey->pkey.dh); |
554 | return pkey->pkey.dh; | 584 | return pkey->pkey.dh; |
555 | } | 585 | } |
586 | LCRYPTO_ALIAS(EVP_PKEY_get1_DH); | ||
556 | 587 | ||
557 | int | 588 | int |
558 | EVP_PKEY_set1_DH(EVP_PKEY *pkey, DH *key) | 589 | EVP_PKEY_set1_DH(EVP_PKEY *pkey, DH *key) |
@@ -562,6 +593,7 @@ EVP_PKEY_set1_DH(EVP_PKEY *pkey, DH *key) | |||
562 | DH_up_ref(key); | 593 | DH_up_ref(key); |
563 | return ret; | 594 | return ret; |
564 | } | 595 | } |
596 | LCRYPTO_ALIAS(EVP_PKEY_set1_DH); | ||
565 | #endif | 597 | #endif |
566 | 598 | ||
567 | int | 599 | int |
@@ -580,18 +612,21 @@ EVP_PKEY_type(int type) | |||
580 | #endif | 612 | #endif |
581 | return ret; | 613 | return ret; |
582 | } | 614 | } |
615 | LCRYPTO_ALIAS(EVP_PKEY_type); | ||
583 | 616 | ||
584 | int | 617 | int |
585 | EVP_PKEY_id(const EVP_PKEY *pkey) | 618 | EVP_PKEY_id(const EVP_PKEY *pkey) |
586 | { | 619 | { |
587 | return pkey->type; | 620 | return pkey->type; |
588 | } | 621 | } |
622 | LCRYPTO_ALIAS(EVP_PKEY_id); | ||
589 | 623 | ||
590 | int | 624 | int |
591 | EVP_PKEY_base_id(const EVP_PKEY *pkey) | 625 | EVP_PKEY_base_id(const EVP_PKEY *pkey) |
592 | { | 626 | { |
593 | return EVP_PKEY_type(pkey->type); | 627 | return EVP_PKEY_type(pkey->type); |
594 | } | 628 | } |
629 | LCRYPTO_ALIAS(EVP_PKEY_base_id); | ||
595 | 630 | ||
596 | void | 631 | void |
597 | EVP_PKEY_free(EVP_PKEY *x) | 632 | EVP_PKEY_free(EVP_PKEY *x) |
@@ -610,6 +645,7 @@ EVP_PKEY_free(EVP_PKEY *x) | |||
610 | sk_X509_ATTRIBUTE_pop_free(x->attributes, X509_ATTRIBUTE_free); | 645 | sk_X509_ATTRIBUTE_pop_free(x->attributes, X509_ATTRIBUTE_free); |
611 | free(x); | 646 | free(x); |
612 | } | 647 | } |
648 | LCRYPTO_ALIAS(EVP_PKEY_free); | ||
613 | 649 | ||
614 | static void | 650 | static void |
615 | EVP_PKEY_free_it(EVP_PKEY *x) | 651 | EVP_PKEY_free_it(EVP_PKEY *x) |
@@ -643,6 +679,7 @@ EVP_PKEY_print_public(BIO *out, const EVP_PKEY *pkey, int indent, | |||
643 | 679 | ||
644 | return unsup_alg(out, pkey, indent, "Public Key"); | 680 | return unsup_alg(out, pkey, indent, "Public Key"); |
645 | } | 681 | } |
682 | LCRYPTO_ALIAS(EVP_PKEY_print_public); | ||
646 | 683 | ||
647 | int | 684 | int |
648 | EVP_PKEY_print_private(BIO *out, const EVP_PKEY *pkey, int indent, | 685 | EVP_PKEY_print_private(BIO *out, const EVP_PKEY *pkey, int indent, |
@@ -653,6 +690,7 @@ EVP_PKEY_print_private(BIO *out, const EVP_PKEY *pkey, int indent, | |||
653 | 690 | ||
654 | return unsup_alg(out, pkey, indent, "Private Key"); | 691 | return unsup_alg(out, pkey, indent, "Private Key"); |
655 | } | 692 | } |
693 | LCRYPTO_ALIAS(EVP_PKEY_print_private); | ||
656 | 694 | ||
657 | int | 695 | int |
658 | EVP_PKEY_print_params(BIO *out, const EVP_PKEY *pkey, int indent, | 696 | EVP_PKEY_print_params(BIO *out, const EVP_PKEY *pkey, int indent, |
@@ -662,6 +700,7 @@ EVP_PKEY_print_params(BIO *out, const EVP_PKEY *pkey, int indent, | |||
662 | return pkey->ameth->param_print(out, pkey, indent, pctx); | 700 | return pkey->ameth->param_print(out, pkey, indent, pctx); |
663 | return unsup_alg(out, pkey, indent, "Parameters"); | 701 | return unsup_alg(out, pkey, indent, "Parameters"); |
664 | } | 702 | } |
703 | LCRYPTO_ALIAS(EVP_PKEY_print_params); | ||
665 | 704 | ||
666 | int | 705 | int |
667 | EVP_PKEY_get_default_digest_nid(EVP_PKEY *pkey, int *pnid) | 706 | EVP_PKEY_get_default_digest_nid(EVP_PKEY *pkey, int *pnid) |
@@ -671,3 +710,4 @@ EVP_PKEY_get_default_digest_nid(EVP_PKEY *pkey, int *pnid) | |||
671 | return pkey->ameth->pkey_ctrl(pkey, ASN1_PKEY_CTRL_DEFAULT_MD_NID, | 710 | return pkey->ameth->pkey_ctrl(pkey, ASN1_PKEY_CTRL_DEFAULT_MD_NID, |
672 | 0, pnid); | 711 | 0, pnid); |
673 | } | 712 | } |
713 | LCRYPTO_ALIAS(EVP_PKEY_get_default_digest_nid); | ||
diff --git a/src/lib/libcrypto/evp/p_open.c b/src/lib/libcrypto/evp/p_open.c index bce900b9ab..5ab36b8ef5 100644 --- a/src/lib/libcrypto/evp/p_open.c +++ b/src/lib/libcrypto/evp/p_open.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_open.c,v 1.21 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: p_open.c,v 1.22 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -114,6 +114,7 @@ err: | |||
114 | freezero(key, size); | 114 | freezero(key, size); |
115 | return (ret); | 115 | return (ret); |
116 | } | 116 | } |
117 | LCRYPTO_ALIAS(EVP_OpenInit); | ||
117 | 118 | ||
118 | int | 119 | int |
119 | EVP_OpenFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | 120 | EVP_OpenFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) |
@@ -125,4 +126,5 @@ EVP_OpenFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
125 | i = EVP_DecryptInit_ex(ctx, NULL, NULL, NULL, NULL); | 126 | i = EVP_DecryptInit_ex(ctx, NULL, NULL, NULL, NULL); |
126 | return (i); | 127 | return (i); |
127 | } | 128 | } |
129 | LCRYPTO_ALIAS(EVP_OpenFinal); | ||
128 | #endif | 130 | #endif |
diff --git a/src/lib/libcrypto/evp/p_seal.c b/src/lib/libcrypto/evp/p_seal.c index 8b9740fbcd..52521e133b 100644 --- a/src/lib/libcrypto/evp/p_seal.c +++ b/src/lib/libcrypto/evp/p_seal.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_seal.c,v 1.14 2014/10/22 13:02:04 jsing Exp $ */ | 1 | /* $OpenBSD: p_seal.c,v 1.15 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -99,6 +99,7 @@ EVP_SealInit(EVP_CIPHER_CTX *ctx, const EVP_CIPHER *type, unsigned char **ek, | |||
99 | } | 99 | } |
100 | return (npubk); | 100 | return (npubk); |
101 | } | 101 | } |
102 | LCRYPTO_ALIAS(EVP_SealInit); | ||
102 | 103 | ||
103 | /* MACRO | 104 | /* MACRO |
104 | void EVP_SealUpdate(ctx,out,outl,in,inl) | 105 | void EVP_SealUpdate(ctx,out,outl,in,inl) |
@@ -122,3 +123,4 @@ EVP_SealFinal(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl) | |||
122 | i = EVP_EncryptInit_ex(ctx, NULL, NULL, NULL, NULL); | 123 | i = EVP_EncryptInit_ex(ctx, NULL, NULL, NULL, NULL); |
123 | return i; | 124 | return i; |
124 | } | 125 | } |
126 | LCRYPTO_ALIAS(EVP_SealFinal); | ||
diff --git a/src/lib/libcrypto/evp/p_sign.c b/src/lib/libcrypto/evp/p_sign.c index 1f78d1efef..13655b076f 100644 --- a/src/lib/libcrypto/evp/p_sign.c +++ b/src/lib/libcrypto/evp/p_sign.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_sign.c,v 1.17 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: p_sign.c,v 1.18 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -102,3 +102,4 @@ EVP_SignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, unsigned int *siglen, | |||
102 | EVP_PKEY_CTX_free(pkctx); | 102 | EVP_PKEY_CTX_free(pkctx); |
103 | return ret; | 103 | return ret; |
104 | } | 104 | } |
105 | LCRYPTO_ALIAS(EVP_SignFinal); | ||
diff --git a/src/lib/libcrypto/evp/p_verify.c b/src/lib/libcrypto/evp/p_verify.c index 545715325d..601b44e5e0 100644 --- a/src/lib/libcrypto/evp/p_verify.c +++ b/src/lib/libcrypto/evp/p_verify.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: p_verify.c,v 1.16 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: p_verify.c,v 1.17 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -95,3 +95,4 @@ EVP_VerifyFinal(EVP_MD_CTX *ctx, const unsigned char *sigbuf, | |||
95 | EVP_PKEY_CTX_free(pkctx); | 95 | EVP_PKEY_CTX_free(pkctx); |
96 | return ret; | 96 | return ret; |
97 | } | 97 | } |
98 | LCRYPTO_ALIAS(EVP_VerifyFinal); | ||
diff --git a/src/lib/libcrypto/evp/pmeth_fn.c b/src/lib/libcrypto/evp/pmeth_fn.c index cab1dfab6f..3025005034 100644 --- a/src/lib/libcrypto/evp/pmeth_fn.c +++ b/src/lib/libcrypto/evp/pmeth_fn.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: pmeth_fn.c,v 1.7 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: pmeth_fn.c,v 1.8 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 2006. | 3 | * project 2006. |
4 | */ | 4 | */ |
@@ -98,6 +98,7 @@ EVP_PKEY_sign_init(EVP_PKEY_CTX *ctx) | |||
98 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 98 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
99 | return ret; | 99 | return ret; |
100 | } | 100 | } |
101 | LCRYPTO_ALIAS(EVP_PKEY_sign_init); | ||
101 | 102 | ||
102 | int | 103 | int |
103 | EVP_PKEY_sign(EVP_PKEY_CTX *ctx, unsigned char *sig, size_t *siglen, | 104 | EVP_PKEY_sign(EVP_PKEY_CTX *ctx, unsigned char *sig, size_t *siglen, |
@@ -114,6 +115,7 @@ EVP_PKEY_sign(EVP_PKEY_CTX *ctx, unsigned char *sig, size_t *siglen, | |||
114 | M_check_autoarg(ctx, sig, siglen, EVP_F_EVP_PKEY_SIGN) | 115 | M_check_autoarg(ctx, sig, siglen, EVP_F_EVP_PKEY_SIGN) |
115 | return ctx->pmeth->sign(ctx, sig, siglen, tbs, tbslen); | 116 | return ctx->pmeth->sign(ctx, sig, siglen, tbs, tbslen); |
116 | } | 117 | } |
118 | LCRYPTO_ALIAS(EVP_PKEY_sign); | ||
117 | 119 | ||
118 | int | 120 | int |
119 | EVP_PKEY_verify_init(EVP_PKEY_CTX *ctx) | 121 | EVP_PKEY_verify_init(EVP_PKEY_CTX *ctx) |
@@ -132,6 +134,7 @@ EVP_PKEY_verify_init(EVP_PKEY_CTX *ctx) | |||
132 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 134 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
133 | return ret; | 135 | return ret; |
134 | } | 136 | } |
137 | LCRYPTO_ALIAS(EVP_PKEY_verify_init); | ||
135 | 138 | ||
136 | int | 139 | int |
137 | EVP_PKEY_verify(EVP_PKEY_CTX *ctx, const unsigned char *sig, size_t siglen, | 140 | EVP_PKEY_verify(EVP_PKEY_CTX *ctx, const unsigned char *sig, size_t siglen, |
@@ -147,6 +150,7 @@ EVP_PKEY_verify(EVP_PKEY_CTX *ctx, const unsigned char *sig, size_t siglen, | |||
147 | } | 150 | } |
148 | return ctx->pmeth->verify(ctx, sig, siglen, tbs, tbslen); | 151 | return ctx->pmeth->verify(ctx, sig, siglen, tbs, tbslen); |
149 | } | 152 | } |
153 | LCRYPTO_ALIAS(EVP_PKEY_verify); | ||
150 | 154 | ||
151 | int | 155 | int |
152 | EVP_PKEY_verify_recover_init(EVP_PKEY_CTX *ctx) | 156 | EVP_PKEY_verify_recover_init(EVP_PKEY_CTX *ctx) |
@@ -165,6 +169,7 @@ EVP_PKEY_verify_recover_init(EVP_PKEY_CTX *ctx) | |||
165 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 169 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
166 | return ret; | 170 | return ret; |
167 | } | 171 | } |
172 | LCRYPTO_ALIAS(EVP_PKEY_verify_recover_init); | ||
168 | 173 | ||
169 | int | 174 | int |
170 | EVP_PKEY_verify_recover(EVP_PKEY_CTX *ctx, unsigned char *rout, size_t *routlen, | 175 | EVP_PKEY_verify_recover(EVP_PKEY_CTX *ctx, unsigned char *rout, size_t *routlen, |
@@ -181,6 +186,7 @@ EVP_PKEY_verify_recover(EVP_PKEY_CTX *ctx, unsigned char *rout, size_t *routlen, | |||
181 | M_check_autoarg(ctx, rout, routlen, EVP_F_EVP_PKEY_VERIFY_RECOVER) | 186 | M_check_autoarg(ctx, rout, routlen, EVP_F_EVP_PKEY_VERIFY_RECOVER) |
182 | return ctx->pmeth->verify_recover(ctx, rout, routlen, sig, siglen); | 187 | return ctx->pmeth->verify_recover(ctx, rout, routlen, sig, siglen); |
183 | } | 188 | } |
189 | LCRYPTO_ALIAS(EVP_PKEY_verify_recover); | ||
184 | 190 | ||
185 | int | 191 | int |
186 | EVP_PKEY_encrypt_init(EVP_PKEY_CTX *ctx) | 192 | EVP_PKEY_encrypt_init(EVP_PKEY_CTX *ctx) |
@@ -199,6 +205,7 @@ EVP_PKEY_encrypt_init(EVP_PKEY_CTX *ctx) | |||
199 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 205 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
200 | return ret; | 206 | return ret; |
201 | } | 207 | } |
208 | LCRYPTO_ALIAS(EVP_PKEY_encrypt_init); | ||
202 | 209 | ||
203 | int | 210 | int |
204 | EVP_PKEY_encrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, | 211 | EVP_PKEY_encrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, |
@@ -215,6 +222,7 @@ EVP_PKEY_encrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, | |||
215 | M_check_autoarg(ctx, out, outlen, EVP_F_EVP_PKEY_ENCRYPT) | 222 | M_check_autoarg(ctx, out, outlen, EVP_F_EVP_PKEY_ENCRYPT) |
216 | return ctx->pmeth->encrypt(ctx, out, outlen, in, inlen); | 223 | return ctx->pmeth->encrypt(ctx, out, outlen, in, inlen); |
217 | } | 224 | } |
225 | LCRYPTO_ALIAS(EVP_PKEY_encrypt); | ||
218 | 226 | ||
219 | int | 227 | int |
220 | EVP_PKEY_decrypt_init(EVP_PKEY_CTX *ctx) | 228 | EVP_PKEY_decrypt_init(EVP_PKEY_CTX *ctx) |
@@ -233,6 +241,7 @@ EVP_PKEY_decrypt_init(EVP_PKEY_CTX *ctx) | |||
233 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 241 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
234 | return ret; | 242 | return ret; |
235 | } | 243 | } |
244 | LCRYPTO_ALIAS(EVP_PKEY_decrypt_init); | ||
236 | 245 | ||
237 | int | 246 | int |
238 | EVP_PKEY_decrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, | 247 | EVP_PKEY_decrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, |
@@ -249,6 +258,7 @@ EVP_PKEY_decrypt(EVP_PKEY_CTX *ctx, unsigned char *out, size_t *outlen, | |||
249 | M_check_autoarg(ctx, out, outlen, EVP_F_EVP_PKEY_DECRYPT) | 258 | M_check_autoarg(ctx, out, outlen, EVP_F_EVP_PKEY_DECRYPT) |
250 | return ctx->pmeth->decrypt(ctx, out, outlen, in, inlen); | 259 | return ctx->pmeth->decrypt(ctx, out, outlen, in, inlen); |
251 | } | 260 | } |
261 | LCRYPTO_ALIAS(EVP_PKEY_decrypt); | ||
252 | 262 | ||
253 | int | 263 | int |
254 | EVP_PKEY_derive_init(EVP_PKEY_CTX *ctx) | 264 | EVP_PKEY_derive_init(EVP_PKEY_CTX *ctx) |
@@ -267,6 +277,7 @@ EVP_PKEY_derive_init(EVP_PKEY_CTX *ctx) | |||
267 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 277 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
268 | return ret; | 278 | return ret; |
269 | } | 279 | } |
280 | LCRYPTO_ALIAS(EVP_PKEY_derive_init); | ||
270 | 281 | ||
271 | int | 282 | int |
272 | EVP_PKEY_derive_set_peer(EVP_PKEY_CTX *ctx, EVP_PKEY *peer) | 283 | EVP_PKEY_derive_set_peer(EVP_PKEY_CTX *ctx, EVP_PKEY *peer) |
@@ -328,6 +339,7 @@ EVP_PKEY_derive_set_peer(EVP_PKEY_CTX *ctx, EVP_PKEY *peer) | |||
328 | CRYPTO_add(&peer->references, 1, CRYPTO_LOCK_EVP_PKEY); | 339 | CRYPTO_add(&peer->references, 1, CRYPTO_LOCK_EVP_PKEY); |
329 | return 1; | 340 | return 1; |
330 | } | 341 | } |
342 | LCRYPTO_ALIAS(EVP_PKEY_derive_set_peer); | ||
331 | 343 | ||
332 | int | 344 | int |
333 | EVP_PKEY_derive(EVP_PKEY_CTX *ctx, unsigned char *key, size_t *pkeylen) | 345 | EVP_PKEY_derive(EVP_PKEY_CTX *ctx, unsigned char *key, size_t *pkeylen) |
@@ -343,3 +355,4 @@ EVP_PKEY_derive(EVP_PKEY_CTX *ctx, unsigned char *key, size_t *pkeylen) | |||
343 | M_check_autoarg(ctx, key, pkeylen, EVP_F_EVP_PKEY_DERIVE) | 355 | M_check_autoarg(ctx, key, pkeylen, EVP_F_EVP_PKEY_DERIVE) |
344 | return ctx->pmeth->derive(ctx, key, pkeylen); | 356 | return ctx->pmeth->derive(ctx, key, pkeylen); |
345 | } | 357 | } |
358 | LCRYPTO_ALIAS(EVP_PKEY_derive); | ||
diff --git a/src/lib/libcrypto/evp/pmeth_gn.c b/src/lib/libcrypto/evp/pmeth_gn.c index d31bb7c0b4..2b835cd8fe 100644 --- a/src/lib/libcrypto/evp/pmeth_gn.c +++ b/src/lib/libcrypto/evp/pmeth_gn.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: pmeth_gn.c,v 1.11 2022/11/26 16:08:53 tb Exp $ */ | 1 | /* $OpenBSD: pmeth_gn.c,v 1.12 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 2006. | 3 | * project 2006. |
4 | */ | 4 | */ |
@@ -85,6 +85,7 @@ EVP_PKEY_paramgen_init(EVP_PKEY_CTX *ctx) | |||
85 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 85 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
86 | return ret; | 86 | return ret; |
87 | } | 87 | } |
88 | LCRYPTO_ALIAS(EVP_PKEY_paramgen_init); | ||
88 | 89 | ||
89 | int | 90 | int |
90 | EVP_PKEY_paramgen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) | 91 | EVP_PKEY_paramgen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) |
@@ -114,6 +115,7 @@ EVP_PKEY_paramgen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) | |||
114 | } | 115 | } |
115 | return ret; | 116 | return ret; |
116 | } | 117 | } |
118 | LCRYPTO_ALIAS(EVP_PKEY_paramgen); | ||
117 | 119 | ||
118 | int | 120 | int |
119 | EVP_PKEY_keygen_init(EVP_PKEY_CTX *ctx) | 121 | EVP_PKEY_keygen_init(EVP_PKEY_CTX *ctx) |
@@ -132,6 +134,7 @@ EVP_PKEY_keygen_init(EVP_PKEY_CTX *ctx) | |||
132 | ctx->operation = EVP_PKEY_OP_UNDEFINED; | 134 | ctx->operation = EVP_PKEY_OP_UNDEFINED; |
133 | return ret; | 135 | return ret; |
134 | } | 136 | } |
137 | LCRYPTO_ALIAS(EVP_PKEY_keygen_init); | ||
135 | 138 | ||
136 | int | 139 | int |
137 | EVP_PKEY_keygen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) | 140 | EVP_PKEY_keygen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) |
@@ -160,18 +163,21 @@ EVP_PKEY_keygen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) | |||
160 | } | 163 | } |
161 | return ret; | 164 | return ret; |
162 | } | 165 | } |
166 | LCRYPTO_ALIAS(EVP_PKEY_keygen); | ||
163 | 167 | ||
164 | void | 168 | void |
165 | EVP_PKEY_CTX_set_cb(EVP_PKEY_CTX *ctx, EVP_PKEY_gen_cb *cb) | 169 | EVP_PKEY_CTX_set_cb(EVP_PKEY_CTX *ctx, EVP_PKEY_gen_cb *cb) |
166 | { | 170 | { |
167 | ctx->pkey_gencb = cb; | 171 | ctx->pkey_gencb = cb; |
168 | } | 172 | } |
173 | LCRYPTO_ALIAS(EVP_PKEY_CTX_set_cb); | ||
169 | 174 | ||
170 | EVP_PKEY_gen_cb * | 175 | EVP_PKEY_gen_cb * |
171 | EVP_PKEY_CTX_get_cb(EVP_PKEY_CTX *ctx) | 176 | EVP_PKEY_CTX_get_cb(EVP_PKEY_CTX *ctx) |
172 | { | 177 | { |
173 | return ctx->pkey_gencb; | 178 | return ctx->pkey_gencb; |
174 | } | 179 | } |
180 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get_cb); | ||
175 | 181 | ||
176 | /* "translation callback" to call EVP_PKEY_CTX callbacks using BN_GENCB | 182 | /* "translation callback" to call EVP_PKEY_CTX callbacks using BN_GENCB |
177 | * style callbacks. | 183 | * style callbacks. |
@@ -201,6 +207,7 @@ EVP_PKEY_CTX_get_keygen_info(EVP_PKEY_CTX *ctx, int idx) | |||
201 | return 0; | 207 | return 0; |
202 | return ctx->keygen_info[idx]; | 208 | return ctx->keygen_info[idx]; |
203 | } | 209 | } |
210 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get_keygen_info); | ||
204 | 211 | ||
205 | EVP_PKEY * | 212 | EVP_PKEY * |
206 | EVP_PKEY_new_mac_key(int type, ENGINE *e, const unsigned char *key, int keylen) | 213 | EVP_PKEY_new_mac_key(int type, ENGINE *e, const unsigned char *key, int keylen) |
@@ -223,6 +230,7 @@ merr: | |||
223 | EVP_PKEY_CTX_free(mac_ctx); | 230 | EVP_PKEY_CTX_free(mac_ctx); |
224 | return mac_key; | 231 | return mac_key; |
225 | } | 232 | } |
233 | LCRYPTO_ALIAS(EVP_PKEY_new_mac_key); | ||
226 | 234 | ||
227 | int | 235 | int |
228 | EVP_PKEY_check(EVP_PKEY_CTX *ctx) | 236 | EVP_PKEY_check(EVP_PKEY_CTX *ctx) |
@@ -244,6 +252,7 @@ EVP_PKEY_check(EVP_PKEY_CTX *ctx) | |||
244 | 252 | ||
245 | return pkey->ameth->pkey_check(pkey); | 253 | return pkey->ameth->pkey_check(pkey); |
246 | } | 254 | } |
255 | LCRYPTO_ALIAS(EVP_PKEY_check); | ||
247 | 256 | ||
248 | int | 257 | int |
249 | EVP_PKEY_public_check(EVP_PKEY_CTX *ctx) | 258 | EVP_PKEY_public_check(EVP_PKEY_CTX *ctx) |
@@ -265,6 +274,7 @@ EVP_PKEY_public_check(EVP_PKEY_CTX *ctx) | |||
265 | 274 | ||
266 | return pkey->ameth->pkey_public_check(pkey); | 275 | return pkey->ameth->pkey_public_check(pkey); |
267 | } | 276 | } |
277 | LCRYPTO_ALIAS(EVP_PKEY_public_check); | ||
268 | 278 | ||
269 | int | 279 | int |
270 | EVP_PKEY_param_check(EVP_PKEY_CTX *ctx) | 280 | EVP_PKEY_param_check(EVP_PKEY_CTX *ctx) |
@@ -286,3 +296,4 @@ EVP_PKEY_param_check(EVP_PKEY_CTX *ctx) | |||
286 | 296 | ||
287 | return pkey->ameth->pkey_param_check(pkey); | 297 | return pkey->ameth->pkey_param_check(pkey); |
288 | } | 298 | } |
299 | LCRYPTO_ALIAS(EVP_PKEY_param_check); | ||
diff --git a/src/lib/libcrypto/evp/pmeth_lib.c b/src/lib/libcrypto/evp/pmeth_lib.c index 3341ba1e0f..cad38d4fe9 100644 --- a/src/lib/libcrypto/evp/pmeth_lib.c +++ b/src/lib/libcrypto/evp/pmeth_lib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: pmeth_lib.c,v 1.31 2023/06/20 14:14:00 tb Exp $ */ | 1 | /* $OpenBSD: pmeth_lib.c,v 1.32 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 2006. | 3 | * project 2006. |
4 | */ | 4 | */ |
@@ -149,6 +149,7 @@ EVP_PKEY_meth_find(int type) | |||
149 | 149 | ||
150 | return NULL; | 150 | return NULL; |
151 | } | 151 | } |
152 | LCRYPTO_ALIAS(EVP_PKEY_meth_find); | ||
152 | 153 | ||
153 | static EVP_PKEY_CTX * | 154 | static EVP_PKEY_CTX * |
154 | evp_pkey_ctx_new(EVP_PKEY *pkey, ENGINE *engine, int id) | 155 | evp_pkey_ctx_new(EVP_PKEY *pkey, ENGINE *engine, int id) |
@@ -225,6 +226,7 @@ EVP_PKEY_meth_new(int id, int flags) | |||
225 | 226 | ||
226 | return pmeth; | 227 | return pmeth; |
227 | } | 228 | } |
229 | LCRYPTO_ALIAS(EVP_PKEY_meth_new); | ||
228 | 230 | ||
229 | void | 231 | void |
230 | EVP_PKEY_meth_get0_info(int *ppkey_id, int *pflags, const EVP_PKEY_METHOD *meth) | 232 | EVP_PKEY_meth_get0_info(int *ppkey_id, int *pflags, const EVP_PKEY_METHOD *meth) |
@@ -234,6 +236,7 @@ EVP_PKEY_meth_get0_info(int *ppkey_id, int *pflags, const EVP_PKEY_METHOD *meth) | |||
234 | if (pflags) | 236 | if (pflags) |
235 | *pflags = meth->flags; | 237 | *pflags = meth->flags; |
236 | } | 238 | } |
239 | LCRYPTO_ALIAS(EVP_PKEY_meth_get0_info); | ||
237 | 240 | ||
238 | void | 241 | void |
239 | EVP_PKEY_meth_copy(EVP_PKEY_METHOD *dst, const EVP_PKEY_METHOD *src) | 242 | EVP_PKEY_meth_copy(EVP_PKEY_METHOD *dst, const EVP_PKEY_METHOD *src) |
@@ -248,6 +251,7 @@ EVP_PKEY_meth_copy(EVP_PKEY_METHOD *dst, const EVP_PKEY_METHOD *src) | |||
248 | dst->pkey_id = preserve.pkey_id; | 251 | dst->pkey_id = preserve.pkey_id; |
249 | dst->flags = preserve.flags; | 252 | dst->flags = preserve.flags; |
250 | } | 253 | } |
254 | LCRYPTO_ALIAS(EVP_PKEY_meth_copy); | ||
251 | 255 | ||
252 | void | 256 | void |
253 | EVP_PKEY_meth_free(EVP_PKEY_METHOD *pmeth) | 257 | EVP_PKEY_meth_free(EVP_PKEY_METHOD *pmeth) |
@@ -255,18 +259,21 @@ EVP_PKEY_meth_free(EVP_PKEY_METHOD *pmeth) | |||
255 | if (pmeth && (pmeth->flags & EVP_PKEY_FLAG_DYNAMIC)) | 259 | if (pmeth && (pmeth->flags & EVP_PKEY_FLAG_DYNAMIC)) |
256 | free(pmeth); | 260 | free(pmeth); |
257 | } | 261 | } |
262 | LCRYPTO_ALIAS(EVP_PKEY_meth_free); | ||
258 | 263 | ||
259 | EVP_PKEY_CTX * | 264 | EVP_PKEY_CTX * |
260 | EVP_PKEY_CTX_new(EVP_PKEY *pkey, ENGINE *engine) | 265 | EVP_PKEY_CTX_new(EVP_PKEY *pkey, ENGINE *engine) |
261 | { | 266 | { |
262 | return evp_pkey_ctx_new(pkey, engine, -1); | 267 | return evp_pkey_ctx_new(pkey, engine, -1); |
263 | } | 268 | } |
269 | LCRYPTO_ALIAS(EVP_PKEY_CTX_new); | ||
264 | 270 | ||
265 | EVP_PKEY_CTX * | 271 | EVP_PKEY_CTX * |
266 | EVP_PKEY_CTX_new_id(int id, ENGINE *engine) | 272 | EVP_PKEY_CTX_new_id(int id, ENGINE *engine) |
267 | { | 273 | { |
268 | return evp_pkey_ctx_new(NULL, engine, id); | 274 | return evp_pkey_ctx_new(NULL, engine, id); |
269 | } | 275 | } |
276 | LCRYPTO_ALIAS(EVP_PKEY_CTX_new_id); | ||
270 | 277 | ||
271 | EVP_PKEY_CTX * | 278 | EVP_PKEY_CTX * |
272 | EVP_PKEY_CTX_dup(EVP_PKEY_CTX *pctx) | 279 | EVP_PKEY_CTX_dup(EVP_PKEY_CTX *pctx) |
@@ -308,6 +315,7 @@ EVP_PKEY_CTX_dup(EVP_PKEY_CTX *pctx) | |||
308 | EVP_PKEY_CTX_free(rctx); | 315 | EVP_PKEY_CTX_free(rctx); |
309 | return NULL; | 316 | return NULL; |
310 | } | 317 | } |
318 | LCRYPTO_ALIAS(EVP_PKEY_CTX_dup); | ||
311 | 319 | ||
312 | int | 320 | int |
313 | EVP_PKEY_meth_add0(const EVP_PKEY_METHOD *pmeth) | 321 | EVP_PKEY_meth_add0(const EVP_PKEY_METHOD *pmeth) |
@@ -323,6 +331,7 @@ EVP_PKEY_meth_add0(const EVP_PKEY_METHOD *pmeth) | |||
323 | 331 | ||
324 | return 1; | 332 | return 1; |
325 | } | 333 | } |
334 | LCRYPTO_ALIAS(EVP_PKEY_meth_add0); | ||
326 | 335 | ||
327 | void | 336 | void |
328 | EVP_PKEY_CTX_free(EVP_PKEY_CTX *ctx) | 337 | EVP_PKEY_CTX_free(EVP_PKEY_CTX *ctx) |
@@ -338,6 +347,7 @@ EVP_PKEY_CTX_free(EVP_PKEY_CTX *ctx) | |||
338 | #endif | 347 | #endif |
339 | free(ctx); | 348 | free(ctx); |
340 | } | 349 | } |
350 | LCRYPTO_ALIAS(EVP_PKEY_CTX_free); | ||
341 | 351 | ||
342 | int | 352 | int |
343 | EVP_PKEY_CTX_ctrl(EVP_PKEY_CTX *ctx, int keytype, int optype, int cmd, | 353 | EVP_PKEY_CTX_ctrl(EVP_PKEY_CTX *ctx, int keytype, int optype, int cmd, |
@@ -370,6 +380,7 @@ EVP_PKEY_CTX_ctrl(EVP_PKEY_CTX *ctx, int keytype, int optype, int cmd, | |||
370 | return ret; | 380 | return ret; |
371 | 381 | ||
372 | } | 382 | } |
383 | LCRYPTO_ALIAS(EVP_PKEY_CTX_ctrl); | ||
373 | 384 | ||
374 | int | 385 | int |
375 | EVP_PKEY_CTX_ctrl_str(EVP_PKEY_CTX *ctx, const char *name, const char *value) | 386 | EVP_PKEY_CTX_ctrl_str(EVP_PKEY_CTX *ctx, const char *name, const char *value) |
@@ -384,6 +395,7 @@ EVP_PKEY_CTX_ctrl_str(EVP_PKEY_CTX *ctx, const char *name, const char *value) | |||
384 | } | 395 | } |
385 | return ctx->pmeth->ctrl_str(ctx, name, value); | 396 | return ctx->pmeth->ctrl_str(ctx, name, value); |
386 | } | 397 | } |
398 | LCRYPTO_ALIAS(EVP_PKEY_CTX_ctrl_str); | ||
387 | 399 | ||
388 | int | 400 | int |
389 | EVP_PKEY_CTX_str2ctrl(EVP_PKEY_CTX *ctx, int cmd, const char *str) | 401 | EVP_PKEY_CTX_str2ctrl(EVP_PKEY_CTX *ctx, int cmd, const char *str) |
@@ -434,6 +446,7 @@ EVP_PKEY_CTX_get_operation(EVP_PKEY_CTX *ctx) | |||
434 | { | 446 | { |
435 | return ctx->operation; | 447 | return ctx->operation; |
436 | } | 448 | } |
449 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get_operation); | ||
437 | 450 | ||
438 | void | 451 | void |
439 | EVP_PKEY_CTX_set0_keygen_info(EVP_PKEY_CTX *ctx, int *dat, int datlen) | 452 | EVP_PKEY_CTX_set0_keygen_info(EVP_PKEY_CTX *ctx, int *dat, int datlen) |
@@ -441,42 +454,49 @@ EVP_PKEY_CTX_set0_keygen_info(EVP_PKEY_CTX *ctx, int *dat, int datlen) | |||
441 | ctx->keygen_info = dat; | 454 | ctx->keygen_info = dat; |
442 | ctx->keygen_info_count = datlen; | 455 | ctx->keygen_info_count = datlen; |
443 | } | 456 | } |
457 | LCRYPTO_ALIAS(EVP_PKEY_CTX_set0_keygen_info); | ||
444 | 458 | ||
445 | void | 459 | void |
446 | EVP_PKEY_CTX_set_data(EVP_PKEY_CTX *ctx, void *data) | 460 | EVP_PKEY_CTX_set_data(EVP_PKEY_CTX *ctx, void *data) |
447 | { | 461 | { |
448 | ctx->data = data; | 462 | ctx->data = data; |
449 | } | 463 | } |
464 | LCRYPTO_ALIAS(EVP_PKEY_CTX_set_data); | ||
450 | 465 | ||
451 | void * | 466 | void * |
452 | EVP_PKEY_CTX_get_data(EVP_PKEY_CTX *ctx) | 467 | EVP_PKEY_CTX_get_data(EVP_PKEY_CTX *ctx) |
453 | { | 468 | { |
454 | return ctx->data; | 469 | return ctx->data; |
455 | } | 470 | } |
471 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get_data); | ||
456 | 472 | ||
457 | EVP_PKEY * | 473 | EVP_PKEY * |
458 | EVP_PKEY_CTX_get0_pkey(EVP_PKEY_CTX *ctx) | 474 | EVP_PKEY_CTX_get0_pkey(EVP_PKEY_CTX *ctx) |
459 | { | 475 | { |
460 | return ctx->pkey; | 476 | return ctx->pkey; |
461 | } | 477 | } |
478 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get0_pkey); | ||
462 | 479 | ||
463 | EVP_PKEY * | 480 | EVP_PKEY * |
464 | EVP_PKEY_CTX_get0_peerkey(EVP_PKEY_CTX *ctx) | 481 | EVP_PKEY_CTX_get0_peerkey(EVP_PKEY_CTX *ctx) |
465 | { | 482 | { |
466 | return ctx->peerkey; | 483 | return ctx->peerkey; |
467 | } | 484 | } |
485 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get0_peerkey); | ||
468 | 486 | ||
469 | void | 487 | void |
470 | EVP_PKEY_CTX_set_app_data(EVP_PKEY_CTX *ctx, void *data) | 488 | EVP_PKEY_CTX_set_app_data(EVP_PKEY_CTX *ctx, void *data) |
471 | { | 489 | { |
472 | ctx->app_data = data; | 490 | ctx->app_data = data; |
473 | } | 491 | } |
492 | LCRYPTO_ALIAS(EVP_PKEY_CTX_set_app_data); | ||
474 | 493 | ||
475 | void * | 494 | void * |
476 | EVP_PKEY_CTX_get_app_data(EVP_PKEY_CTX *ctx) | 495 | EVP_PKEY_CTX_get_app_data(EVP_PKEY_CTX *ctx) |
477 | { | 496 | { |
478 | return ctx->app_data; | 497 | return ctx->app_data; |
479 | } | 498 | } |
499 | LCRYPTO_ALIAS(EVP_PKEY_CTX_get_app_data); | ||
480 | 500 | ||
481 | void | 501 | void |
482 | EVP_PKEY_meth_set_init(EVP_PKEY_METHOD *pmeth, | 502 | EVP_PKEY_meth_set_init(EVP_PKEY_METHOD *pmeth, |
@@ -484,6 +504,7 @@ EVP_PKEY_meth_set_init(EVP_PKEY_METHOD *pmeth, | |||
484 | { | 504 | { |
485 | pmeth->init = init; | 505 | pmeth->init = init; |
486 | } | 506 | } |
507 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_init); | ||
487 | 508 | ||
488 | void | 509 | void |
489 | EVP_PKEY_meth_set_copy(EVP_PKEY_METHOD *pmeth, | 510 | EVP_PKEY_meth_set_copy(EVP_PKEY_METHOD *pmeth, |
@@ -491,6 +512,7 @@ EVP_PKEY_meth_set_copy(EVP_PKEY_METHOD *pmeth, | |||
491 | { | 512 | { |
492 | pmeth->copy = copy; | 513 | pmeth->copy = copy; |
493 | } | 514 | } |
515 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_copy); | ||
494 | 516 | ||
495 | void | 517 | void |
496 | EVP_PKEY_meth_set_cleanup(EVP_PKEY_METHOD *pmeth, | 518 | EVP_PKEY_meth_set_cleanup(EVP_PKEY_METHOD *pmeth, |
@@ -498,6 +520,7 @@ EVP_PKEY_meth_set_cleanup(EVP_PKEY_METHOD *pmeth, | |||
498 | { | 520 | { |
499 | pmeth->cleanup = cleanup; | 521 | pmeth->cleanup = cleanup; |
500 | } | 522 | } |
523 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_cleanup); | ||
501 | 524 | ||
502 | void | 525 | void |
503 | EVP_PKEY_meth_set_paramgen(EVP_PKEY_METHOD *pmeth, | 526 | EVP_PKEY_meth_set_paramgen(EVP_PKEY_METHOD *pmeth, |
@@ -507,6 +530,7 @@ EVP_PKEY_meth_set_paramgen(EVP_PKEY_METHOD *pmeth, | |||
507 | pmeth->paramgen_init = paramgen_init; | 530 | pmeth->paramgen_init = paramgen_init; |
508 | pmeth->paramgen = paramgen; | 531 | pmeth->paramgen = paramgen; |
509 | } | 532 | } |
533 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_paramgen); | ||
510 | 534 | ||
511 | void | 535 | void |
512 | EVP_PKEY_meth_set_keygen(EVP_PKEY_METHOD *pmeth, | 536 | EVP_PKEY_meth_set_keygen(EVP_PKEY_METHOD *pmeth, |
@@ -516,6 +540,7 @@ EVP_PKEY_meth_set_keygen(EVP_PKEY_METHOD *pmeth, | |||
516 | pmeth->keygen_init = keygen_init; | 540 | pmeth->keygen_init = keygen_init; |
517 | pmeth->keygen = keygen; | 541 | pmeth->keygen = keygen; |
518 | } | 542 | } |
543 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_keygen); | ||
519 | 544 | ||
520 | void | 545 | void |
521 | EVP_PKEY_meth_set_sign(EVP_PKEY_METHOD *pmeth, | 546 | EVP_PKEY_meth_set_sign(EVP_PKEY_METHOD *pmeth, |
@@ -526,6 +551,7 @@ EVP_PKEY_meth_set_sign(EVP_PKEY_METHOD *pmeth, | |||
526 | pmeth->sign_init = sign_init; | 551 | pmeth->sign_init = sign_init; |
527 | pmeth->sign = sign; | 552 | pmeth->sign = sign; |
528 | } | 553 | } |
554 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_sign); | ||
529 | 555 | ||
530 | void | 556 | void |
531 | EVP_PKEY_meth_set_verify(EVP_PKEY_METHOD *pmeth, | 557 | EVP_PKEY_meth_set_verify(EVP_PKEY_METHOD *pmeth, |
@@ -536,6 +562,7 @@ EVP_PKEY_meth_set_verify(EVP_PKEY_METHOD *pmeth, | |||
536 | pmeth->verify_init = verify_init; | 562 | pmeth->verify_init = verify_init; |
537 | pmeth->verify = verify; | 563 | pmeth->verify = verify; |
538 | } | 564 | } |
565 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_verify); | ||
539 | 566 | ||
540 | void | 567 | void |
541 | EVP_PKEY_meth_set_verify_recover(EVP_PKEY_METHOD *pmeth, | 568 | EVP_PKEY_meth_set_verify_recover(EVP_PKEY_METHOD *pmeth, |
@@ -547,6 +574,7 @@ EVP_PKEY_meth_set_verify_recover(EVP_PKEY_METHOD *pmeth, | |||
547 | pmeth->verify_recover_init = verify_recover_init; | 574 | pmeth->verify_recover_init = verify_recover_init; |
548 | pmeth->verify_recover = verify_recover; | 575 | pmeth->verify_recover = verify_recover; |
549 | } | 576 | } |
577 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_verify_recover); | ||
550 | 578 | ||
551 | void | 579 | void |
552 | EVP_PKEY_meth_set_signctx(EVP_PKEY_METHOD *pmeth, | 580 | EVP_PKEY_meth_set_signctx(EVP_PKEY_METHOD *pmeth, |
@@ -557,6 +585,7 @@ EVP_PKEY_meth_set_signctx(EVP_PKEY_METHOD *pmeth, | |||
557 | pmeth->signctx_init = signctx_init; | 585 | pmeth->signctx_init = signctx_init; |
558 | pmeth->signctx = signctx; | 586 | pmeth->signctx = signctx; |
559 | } | 587 | } |
588 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_signctx); | ||
560 | 589 | ||
561 | void | 590 | void |
562 | EVP_PKEY_meth_set_verifyctx(EVP_PKEY_METHOD *pmeth, | 591 | EVP_PKEY_meth_set_verifyctx(EVP_PKEY_METHOD *pmeth, |
@@ -567,6 +596,7 @@ EVP_PKEY_meth_set_verifyctx(EVP_PKEY_METHOD *pmeth, | |||
567 | pmeth->verifyctx_init = verifyctx_init; | 596 | pmeth->verifyctx_init = verifyctx_init; |
568 | pmeth->verifyctx = verifyctx; | 597 | pmeth->verifyctx = verifyctx; |
569 | } | 598 | } |
599 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_verifyctx); | ||
570 | 600 | ||
571 | void | 601 | void |
572 | EVP_PKEY_meth_set_encrypt(EVP_PKEY_METHOD *pmeth, | 602 | EVP_PKEY_meth_set_encrypt(EVP_PKEY_METHOD *pmeth, |
@@ -577,6 +607,7 @@ EVP_PKEY_meth_set_encrypt(EVP_PKEY_METHOD *pmeth, | |||
577 | pmeth->encrypt_init = encrypt_init; | 607 | pmeth->encrypt_init = encrypt_init; |
578 | pmeth->encrypt = encryptfn; | 608 | pmeth->encrypt = encryptfn; |
579 | } | 609 | } |
610 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_encrypt); | ||
580 | 611 | ||
581 | void | 612 | void |
582 | EVP_PKEY_meth_set_decrypt(EVP_PKEY_METHOD *pmeth, | 613 | EVP_PKEY_meth_set_decrypt(EVP_PKEY_METHOD *pmeth, |
@@ -587,6 +618,7 @@ EVP_PKEY_meth_set_decrypt(EVP_PKEY_METHOD *pmeth, | |||
587 | pmeth->decrypt_init = decrypt_init; | 618 | pmeth->decrypt_init = decrypt_init; |
588 | pmeth->decrypt = decrypt; | 619 | pmeth->decrypt = decrypt; |
589 | } | 620 | } |
621 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_decrypt); | ||
590 | 622 | ||
591 | void | 623 | void |
592 | EVP_PKEY_meth_set_derive(EVP_PKEY_METHOD *pmeth, | 624 | EVP_PKEY_meth_set_derive(EVP_PKEY_METHOD *pmeth, |
@@ -596,6 +628,7 @@ EVP_PKEY_meth_set_derive(EVP_PKEY_METHOD *pmeth, | |||
596 | pmeth->derive_init = derive_init; | 628 | pmeth->derive_init = derive_init; |
597 | pmeth->derive = derive; | 629 | pmeth->derive = derive; |
598 | } | 630 | } |
631 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_derive); | ||
599 | 632 | ||
600 | void | 633 | void |
601 | EVP_PKEY_meth_set_ctrl(EVP_PKEY_METHOD *pmeth, | 634 | EVP_PKEY_meth_set_ctrl(EVP_PKEY_METHOD *pmeth, |
@@ -605,12 +638,14 @@ EVP_PKEY_meth_set_ctrl(EVP_PKEY_METHOD *pmeth, | |||
605 | pmeth->ctrl = ctrl; | 638 | pmeth->ctrl = ctrl; |
606 | pmeth->ctrl_str = ctrl_str; | 639 | pmeth->ctrl_str = ctrl_str; |
607 | } | 640 | } |
641 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_ctrl); | ||
608 | 642 | ||
609 | void | 643 | void |
610 | EVP_PKEY_meth_set_check(EVP_PKEY_METHOD *pmeth, int (*check)(EVP_PKEY *pkey)) | 644 | EVP_PKEY_meth_set_check(EVP_PKEY_METHOD *pmeth, int (*check)(EVP_PKEY *pkey)) |
611 | { | 645 | { |
612 | pmeth->check = check; | 646 | pmeth->check = check; |
613 | } | 647 | } |
648 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_check); | ||
614 | 649 | ||
615 | void | 650 | void |
616 | EVP_PKEY_meth_set_public_check(EVP_PKEY_METHOD *pmeth, | 651 | EVP_PKEY_meth_set_public_check(EVP_PKEY_METHOD *pmeth, |
@@ -618,6 +653,7 @@ EVP_PKEY_meth_set_public_check(EVP_PKEY_METHOD *pmeth, | |||
618 | { | 653 | { |
619 | pmeth->public_check = public_check; | 654 | pmeth->public_check = public_check; |
620 | } | 655 | } |
656 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_public_check); | ||
621 | 657 | ||
622 | void | 658 | void |
623 | EVP_PKEY_meth_set_param_check(EVP_PKEY_METHOD *pmeth, | 659 | EVP_PKEY_meth_set_param_check(EVP_PKEY_METHOD *pmeth, |
@@ -625,3 +661,4 @@ EVP_PKEY_meth_set_param_check(EVP_PKEY_METHOD *pmeth, | |||
625 | { | 661 | { |
626 | pmeth->param_check = param_check; | 662 | pmeth->param_check = param_check; |
627 | } | 663 | } |
664 | LCRYPTO_ALIAS(EVP_PKEY_meth_set_param_check); | ||
diff --git a/src/lib/libcrypto/hkdf/hkdf.c b/src/lib/libcrypto/hkdf/hkdf.c index 9e0e206324..4f9c9e566a 100644 --- a/src/lib/libcrypto/hkdf/hkdf.c +++ b/src/lib/libcrypto/hkdf/hkdf.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: hkdf.c,v 1.9 2023/06/01 02:34:23 tb Exp $ */ | 1 | /* $OpenBSD: hkdf.c,v 1.10 2023/07/07 13:54:46 beck Exp $ */ |
2 | /* Copyright (c) 2014, Google Inc. | 2 | /* Copyright (c) 2014, Google Inc. |
3 | * | 3 | * |
4 | * Permission to use, copy, modify, and/or distribute this software for any | 4 | * Permission to use, copy, modify, and/or distribute this software for any |
@@ -42,6 +42,7 @@ HKDF(uint8_t *out_key, size_t out_len, const EVP_MD *digest, | |||
42 | 42 | ||
43 | return 1; | 43 | return 1; |
44 | } | 44 | } |
45 | LCRYPTO_ALIAS(HKDF); | ||
45 | 46 | ||
46 | /* https://tools.ietf.org/html/rfc5869#section-2.2 */ | 47 | /* https://tools.ietf.org/html/rfc5869#section-2.2 */ |
47 | int | 48 | int |
@@ -63,6 +64,7 @@ HKDF_extract(uint8_t *out_key, size_t *out_len, | |||
63 | *out_len = len; | 64 | *out_len = len; |
64 | return 1; | 65 | return 1; |
65 | } | 66 | } |
67 | LCRYPTO_ALIAS(HKDF_extract); | ||
66 | 68 | ||
67 | /* https://tools.ietf.org/html/rfc5869#section-2.3 */ | 69 | /* https://tools.ietf.org/html/rfc5869#section-2.3 */ |
68 | int | 70 | int |
@@ -118,3 +120,4 @@ HKDF_expand(uint8_t *out_key, size_t out_len, | |||
118 | CRYPTOerror(ERR_R_CRYPTO_LIB); | 120 | CRYPTOerror(ERR_R_CRYPTO_LIB); |
119 | return ret; | 121 | return ret; |
120 | } | 122 | } |
123 | LCRYPTO_ALIAS(HKDF_expand); | ||