diff options
author | Christian Grothoff <christian@grothoff.org> | 2016-03-21 13:41:12 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2016-03-21 13:41:12 +0000 |
commit | 1733de7305720882b8745e82b51b6ff47c10099e (patch) | |
tree | df9199b0e8670b089ead17186b191b80629bda8f /src/include/gnunet_crypto_lib.h | |
parent | 60de5f48cbfc3868570284e91415ca7e06c390e1 (diff) | |
download | gnunet-1733de7305720882b8745e82b51b6ff47c10099e.tar.gz gnunet-1733de7305720882b8745e82b51b6ff47c10099e.zip |
fixing symbol naming and coding convention issues
Diffstat (limited to 'src/include/gnunet_crypto_lib.h')
-rw-r--r-- | src/include/gnunet_crypto_lib.h | 74 |
1 files changed, 37 insertions, 37 deletions
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index 93ee09cab..d104318e3 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -1779,12 +1779,12 @@ GNUNET_CRYPTO_paillier_hom_get_remaining (const struct GNUNET_CRYPTO_PaillierCip | |||
1779 | /** | 1779 | /** |
1780 | * The private information of an RSA key pair. | 1780 | * The private information of an RSA key pair. |
1781 | */ | 1781 | */ |
1782 | struct GNUNET_CRYPTO_rsa_PrivateKey; | 1782 | struct GNUNET_CRYPTO_RsaPrivateKey; |
1783 | 1783 | ||
1784 | /** | 1784 | /** |
1785 | * The public information of an RSA key pair. | 1785 | * The public information of an RSA key pair. |
1786 | */ | 1786 | */ |
1787 | struct GNUNET_CRYPTO_rsa_PublicKey; | 1787 | struct GNUNET_CRYPTO_RsaPublicKey; |
1788 | 1788 | ||
1789 | /** | 1789 | /** |
1790 | * Key used to blind a message | 1790 | * Key used to blind a message |
@@ -1794,7 +1794,7 @@ struct GNUNET_CRYPTO_rsa_BlindingKey; | |||
1794 | /** | 1794 | /** |
1795 | * @brief an RSA signature | 1795 | * @brief an RSA signature |
1796 | */ | 1796 | */ |
1797 | struct GNUNET_CRYPTO_rsa_Signature; | 1797 | struct GNUNET_CRYPTO_RsaSignature; |
1798 | 1798 | ||
1799 | 1799 | ||
1800 | /** | 1800 | /** |
@@ -1803,7 +1803,7 @@ struct GNUNET_CRYPTO_rsa_Signature; | |||
1803 | * @param len length of the key in bits (i.e. 2048) | 1803 | * @param len length of the key in bits (i.e. 2048) |
1804 | * @return fresh private key | 1804 | * @return fresh private key |
1805 | */ | 1805 | */ |
1806 | struct GNUNET_CRYPTO_rsa_PrivateKey * | 1806 | struct GNUNET_CRYPTO_RsaPrivateKey * |
1807 | GNUNET_CRYPTO_rsa_private_key_create (unsigned int len); | 1807 | GNUNET_CRYPTO_rsa_private_key_create (unsigned int len); |
1808 | 1808 | ||
1809 | 1809 | ||
@@ -1813,7 +1813,7 @@ GNUNET_CRYPTO_rsa_private_key_create (unsigned int len); | |||
1813 | * @param key pointer to the memory to free | 1813 | * @param key pointer to the memory to free |
1814 | */ | 1814 | */ |
1815 | void | 1815 | void |
1816 | GNUNET_CRYPTO_rsa_private_key_free (struct GNUNET_CRYPTO_rsa_PrivateKey *key); | 1816 | GNUNET_CRYPTO_rsa_private_key_free (struct GNUNET_CRYPTO_RsaPrivateKey *key); |
1817 | 1817 | ||
1818 | 1818 | ||
1819 | /** | 1819 | /** |
@@ -1825,7 +1825,7 @@ GNUNET_CRYPTO_rsa_private_key_free (struct GNUNET_CRYPTO_rsa_PrivateKey *key); | |||
1825 | * @return size of memory allocatedin @a buffer | 1825 | * @return size of memory allocatedin @a buffer |
1826 | */ | 1826 | */ |
1827 | size_t | 1827 | size_t |
1828 | GNUNET_CRYPTO_rsa_private_key_encode (const struct GNUNET_CRYPTO_rsa_PrivateKey *key, | 1828 | GNUNET_CRYPTO_rsa_private_key_encode (const struct GNUNET_CRYPTO_RsaPrivateKey *key, |
1829 | char **buffer); | 1829 | char **buffer); |
1830 | 1830 | ||
1831 | 1831 | ||
@@ -1837,7 +1837,7 @@ GNUNET_CRYPTO_rsa_private_key_encode (const struct GNUNET_CRYPTO_rsa_PrivateKey | |||
1837 | * @param len the length of the data in @a buf | 1837 | * @param len the length of the data in @a buf |
1838 | * @return NULL on error | 1838 | * @return NULL on error |
1839 | */ | 1839 | */ |
1840 | struct GNUNET_CRYPTO_rsa_PrivateKey * | 1840 | struct GNUNET_CRYPTO_RsaPrivateKey * |
1841 | GNUNET_CRYPTO_rsa_private_key_decode (const char *buf, | 1841 | GNUNET_CRYPTO_rsa_private_key_decode (const char *buf, |
1842 | size_t len); | 1842 | size_t len); |
1843 | 1843 | ||
@@ -1848,8 +1848,8 @@ GNUNET_CRYPTO_rsa_private_key_decode (const char *buf, | |||
1848 | * @param key the private key to duplicate | 1848 | * @param key the private key to duplicate |
1849 | * @return the duplicate key; NULL upon error | 1849 | * @return the duplicate key; NULL upon error |
1850 | */ | 1850 | */ |
1851 | struct GNUNET_CRYPTO_rsa_PrivateKey * | 1851 | struct GNUNET_CRYPTO_RsaPrivateKey * |
1852 | GNUNET_CRYPTO_rsa_private_key_dup (const struct GNUNET_CRYPTO_rsa_PrivateKey *key); | 1852 | GNUNET_CRYPTO_rsa_private_key_dup (const struct GNUNET_CRYPTO_RsaPrivateKey *key); |
1853 | 1853 | ||
1854 | 1854 | ||
1855 | /** | 1855 | /** |
@@ -1858,8 +1858,8 @@ GNUNET_CRYPTO_rsa_private_key_dup (const struct GNUNET_CRYPTO_rsa_PrivateKey *ke | |||
1858 | * @param priv the private key | 1858 | * @param priv the private key |
1859 | * @retur NULL on error, otherwise the public key | 1859 | * @retur NULL on error, otherwise the public key |
1860 | */ | 1860 | */ |
1861 | struct GNUNET_CRYPTO_rsa_PublicKey * | 1861 | struct GNUNET_CRYPTO_RsaPublicKey * |
1862 | GNUNET_CRYPTO_rsa_private_key_get_public (const struct GNUNET_CRYPTO_rsa_PrivateKey *priv); | 1862 | GNUNET_CRYPTO_rsa_private_key_get_public (const struct GNUNET_CRYPTO_RsaPrivateKey *priv); |
1863 | 1863 | ||
1864 | 1864 | ||
1865 | /** | 1865 | /** |
@@ -1869,7 +1869,7 @@ GNUNET_CRYPTO_rsa_private_key_get_public (const struct GNUNET_CRYPTO_rsa_Private | |||
1869 | * @param hc where to store the hash code | 1869 | * @param hc where to store the hash code |
1870 | */ | 1870 | */ |
1871 | void | 1871 | void |
1872 | GNUNET_CRYPTO_rsa_public_key_hash (const struct GNUNET_CRYPTO_rsa_PublicKey *key, | 1872 | GNUNET_CRYPTO_rsa_public_key_hash (const struct GNUNET_CRYPTO_RsaPublicKey *key, |
1873 | struct GNUNET_HashCode *hc); | 1873 | struct GNUNET_HashCode *hc); |
1874 | 1874 | ||
1875 | 1875 | ||
@@ -1880,7 +1880,7 @@ GNUNET_CRYPTO_rsa_public_key_hash (const struct GNUNET_CRYPTO_rsa_PublicKey *key | |||
1880 | * @return length of the key in bits | 1880 | * @return length of the key in bits |
1881 | */ | 1881 | */ |
1882 | unsigned int | 1882 | unsigned int |
1883 | GNUNET_CRYPTO_rsa_public_key_len (const struct GNUNET_CRYPTO_rsa_PublicKey *key); | 1883 | GNUNET_CRYPTO_rsa_public_key_len (const struct GNUNET_CRYPTO_RsaPublicKey *key); |
1884 | 1884 | ||
1885 | 1885 | ||
1886 | /** | 1886 | /** |
@@ -1889,7 +1889,7 @@ GNUNET_CRYPTO_rsa_public_key_len (const struct GNUNET_CRYPTO_rsa_PublicKey *key) | |||
1889 | * @param key pointer to the memory to free | 1889 | * @param key pointer to the memory to free |
1890 | */ | 1890 | */ |
1891 | void | 1891 | void |
1892 | GNUNET_CRYPTO_rsa_public_key_free (struct GNUNET_CRYPTO_rsa_PublicKey *key); | 1892 | GNUNET_CRYPTO_rsa_public_key_free (struct GNUNET_CRYPTO_RsaPublicKey *key); |
1893 | 1893 | ||
1894 | 1894 | ||
1895 | /** | 1895 | /** |
@@ -1901,7 +1901,7 @@ GNUNET_CRYPTO_rsa_public_key_free (struct GNUNET_CRYPTO_rsa_PublicKey *key); | |||
1901 | * @return size of memory allocated in @a buffer | 1901 | * @return size of memory allocated in @a buffer |
1902 | */ | 1902 | */ |
1903 | size_t | 1903 | size_t |
1904 | GNUNET_CRYPTO_rsa_public_key_encode (const struct GNUNET_CRYPTO_rsa_PublicKey *key, | 1904 | GNUNET_CRYPTO_rsa_public_key_encode (const struct GNUNET_CRYPTO_RsaPublicKey *key, |
1905 | char **buffer); | 1905 | char **buffer); |
1906 | 1906 | ||
1907 | 1907 | ||
@@ -1913,7 +1913,7 @@ GNUNET_CRYPTO_rsa_public_key_encode (const struct GNUNET_CRYPTO_rsa_PublicKey *k | |||
1913 | * @param len the length of the data in @a buf | 1913 | * @param len the length of the data in @a buf |
1914 | * @return NULL on error | 1914 | * @return NULL on error |
1915 | */ | 1915 | */ |
1916 | struct GNUNET_CRYPTO_rsa_PublicKey * | 1916 | struct GNUNET_CRYPTO_RsaPublicKey * |
1917 | GNUNET_CRYPTO_rsa_public_key_decode (const char *buf, | 1917 | GNUNET_CRYPTO_rsa_public_key_decode (const char *buf, |
1918 | size_t len); | 1918 | size_t len); |
1919 | 1919 | ||
@@ -1924,8 +1924,8 @@ GNUNET_CRYPTO_rsa_public_key_decode (const char *buf, | |||
1924 | * @param key the public key to duplicate | 1924 | * @param key the public key to duplicate |
1925 | * @return the duplicate key; NULL upon error | 1925 | * @return the duplicate key; NULL upon error |
1926 | */ | 1926 | */ |
1927 | struct GNUNET_CRYPTO_rsa_PublicKey * | 1927 | struct GNUNET_CRYPTO_RsaPublicKey * |
1928 | GNUNET_CRYPTO_rsa_public_key_dup (const struct GNUNET_CRYPTO_rsa_PublicKey *key); | 1928 | GNUNET_CRYPTO_rsa_public_key_dup (const struct GNUNET_CRYPTO_RsaPublicKey *key); |
1929 | 1929 | ||
1930 | 1930 | ||
1931 | /** | 1931 | /** |
@@ -1958,8 +1958,8 @@ GNUNET_CRYPTO_rsa_blinding_key_cmp (struct GNUNET_CRYPTO_rsa_BlindingKey *b1, | |||
1958 | * @return 0 if the two are equal | 1958 | * @return 0 if the two are equal |
1959 | */ | 1959 | */ |
1960 | int | 1960 | int |
1961 | GNUNET_CRYPTO_rsa_signature_cmp (struct GNUNET_CRYPTO_rsa_Signature *s1, | 1961 | GNUNET_CRYPTO_rsa_signature_cmp (struct GNUNET_CRYPTO_RsaSignature *s1, |
1962 | struct GNUNET_CRYPTO_rsa_Signature *s2); | 1962 | struct GNUNET_CRYPTO_RsaSignature *s2); |
1963 | 1963 | ||
1964 | /** | 1964 | /** |
1965 | * Compare the values of two private keys. | 1965 | * Compare the values of two private keys. |
@@ -1969,8 +1969,8 @@ GNUNET_CRYPTO_rsa_signature_cmp (struct GNUNET_CRYPTO_rsa_Signature *s1, | |||
1969 | * @return 0 if the two are equal | 1969 | * @return 0 if the two are equal |
1970 | */ | 1970 | */ |
1971 | int | 1971 | int |
1972 | GNUNET_CRYPTO_rsa_private_key_cmp (struct GNUNET_CRYPTO_rsa_PrivateKey *p1, | 1972 | GNUNET_CRYPTO_rsa_private_key_cmp (struct GNUNET_CRYPTO_RsaPrivateKey *p1, |
1973 | struct GNUNET_CRYPTO_rsa_PrivateKey *p2); | 1973 | struct GNUNET_CRYPTO_RsaPrivateKey *p2); |
1974 | 1974 | ||
1975 | 1975 | ||
1976 | /** | 1976 | /** |
@@ -1981,8 +1981,8 @@ GNUNET_CRYPTO_rsa_private_key_cmp (struct GNUNET_CRYPTO_rsa_PrivateKey *p1, | |||
1981 | * @return 0 if the two are equal | 1981 | * @return 0 if the two are equal |
1982 | */ | 1982 | */ |
1983 | int | 1983 | int |
1984 | GNUNET_CRYPTO_rsa_public_key_cmp (struct GNUNET_CRYPTO_rsa_PublicKey *p1, | 1984 | GNUNET_CRYPTO_rsa_public_key_cmp (struct GNUNET_CRYPTO_RsaPublicKey *p1, |
1985 | struct GNUNET_CRYPTO_rsa_PublicKey *p2); | 1985 | struct GNUNET_CRYPTO_RsaPublicKey *p2); |
1986 | 1986 | ||
1987 | 1987 | ||
1988 | /** | 1988 | /** |
@@ -2032,7 +2032,7 @@ GNUNET_CRYPTO_rsa_blinding_key_decode (const char *buf, | |||
2032 | size_t | 2032 | size_t |
2033 | GNUNET_CRYPTO_rsa_blind (const struct GNUNET_HashCode *hash, | 2033 | GNUNET_CRYPTO_rsa_blind (const struct GNUNET_HashCode *hash, |
2034 | struct GNUNET_CRYPTO_rsa_BlindingKey *bkey, | 2034 | struct GNUNET_CRYPTO_rsa_BlindingKey *bkey, |
2035 | struct GNUNET_CRYPTO_rsa_PublicKey *pkey, | 2035 | struct GNUNET_CRYPTO_RsaPublicKey *pkey, |
2036 | char **buffer); | 2036 | char **buffer); |
2037 | 2037 | ||
2038 | 2038 | ||
@@ -2044,8 +2044,8 @@ GNUNET_CRYPTO_rsa_blind (const struct GNUNET_HashCode *hash, | |||
2044 | * @param msg_len number of bytes in @a msg to sign | 2044 | * @param msg_len number of bytes in @a msg to sign |
2045 | * @return NULL on error, signature on success | 2045 | * @return NULL on error, signature on success |
2046 | */ | 2046 | */ |
2047 | struct GNUNET_CRYPTO_rsa_Signature * | 2047 | struct GNUNET_CRYPTO_RsaSignature * |
2048 | GNUNET_CRYPTO_rsa_sign (const struct GNUNET_CRYPTO_rsa_PrivateKey *key, | 2048 | GNUNET_CRYPTO_rsa_sign (const struct GNUNET_CRYPTO_RsaPrivateKey *key, |
2049 | const void *msg, | 2049 | const void *msg, |
2050 | size_t msg_len); | 2050 | size_t msg_len); |
2051 | 2051 | ||
@@ -2056,7 +2056,7 @@ GNUNET_CRYPTO_rsa_sign (const struct GNUNET_CRYPTO_rsa_PrivateKey *key, | |||
2056 | * @param sig memory to free | 2056 | * @param sig memory to free |
2057 | */ | 2057 | */ |
2058 | void | 2058 | void |
2059 | GNUNET_CRYPTO_rsa_signature_free (struct GNUNET_CRYPTO_rsa_Signature *sig); | 2059 | GNUNET_CRYPTO_rsa_signature_free (struct GNUNET_CRYPTO_RsaSignature *sig); |
2060 | 2060 | ||
2061 | 2061 | ||
2062 | /** | 2062 | /** |
@@ -2067,7 +2067,7 @@ GNUNET_CRYPTO_rsa_signature_free (struct GNUNET_CRYPTO_rsa_Signature *sig); | |||
2067 | * @return size of memory allocated in @a buffer | 2067 | * @return size of memory allocated in @a buffer |
2068 | */ | 2068 | */ |
2069 | size_t | 2069 | size_t |
2070 | GNUNET_CRYPTO_rsa_signature_encode (const struct GNUNET_CRYPTO_rsa_Signature *sig, | 2070 | GNUNET_CRYPTO_rsa_signature_encode (const struct GNUNET_CRYPTO_RsaSignature *sig, |
2071 | char **buffer); | 2071 | char **buffer); |
2072 | 2072 | ||
2073 | 2073 | ||
@@ -2079,7 +2079,7 @@ GNUNET_CRYPTO_rsa_signature_encode (const struct GNUNET_CRYPTO_rsa_Signature *si | |||
2079 | * @param len the length of the data in @a buf | 2079 | * @param len the length of the data in @a buf |
2080 | * @return NULL on error | 2080 | * @return NULL on error |
2081 | */ | 2081 | */ |
2082 | struct GNUNET_CRYPTO_rsa_Signature * | 2082 | struct GNUNET_CRYPTO_RsaSignature * |
2083 | GNUNET_CRYPTO_rsa_signature_decode (const char *buf, | 2083 | GNUNET_CRYPTO_rsa_signature_decode (const char *buf, |
2084 | size_t len); | 2084 | size_t len); |
2085 | 2085 | ||
@@ -2090,8 +2090,8 @@ GNUNET_CRYPTO_rsa_signature_decode (const char *buf, | |||
2090 | * @param sig the signature to duplicate | 2090 | * @param sig the signature to duplicate |
2091 | * @return the duplicate key; NULL upon error | 2091 | * @return the duplicate key; NULL upon error |
2092 | */ | 2092 | */ |
2093 | struct GNUNET_CRYPTO_rsa_Signature * | 2093 | struct GNUNET_CRYPTO_RsaSignature * |
2094 | GNUNET_CRYPTO_rsa_signature_dup (const struct GNUNET_CRYPTO_rsa_Signature *sig); | 2094 | GNUNET_CRYPTO_rsa_signature_dup (const struct GNUNET_CRYPTO_RsaSignature *sig); |
2095 | 2095 | ||
2096 | 2096 | ||
2097 | /** | 2097 | /** |
@@ -2104,10 +2104,10 @@ GNUNET_CRYPTO_rsa_signature_dup (const struct GNUNET_CRYPTO_rsa_Signature *sig); | |||
2104 | * @param pkey the public key of the signer | 2104 | * @param pkey the public key of the signer |
2105 | * @return unblinded signature on success, NULL on error | 2105 | * @return unblinded signature on success, NULL on error |
2106 | */ | 2106 | */ |
2107 | struct GNUNET_CRYPTO_rsa_Signature * | 2107 | struct GNUNET_CRYPTO_RsaSignature * |
2108 | GNUNET_CRYPTO_rsa_unblind (struct GNUNET_CRYPTO_rsa_Signature *sig, | 2108 | GNUNET_CRYPTO_rsa_unblind (struct GNUNET_CRYPTO_RsaSignature *sig, |
2109 | struct GNUNET_CRYPTO_rsa_BlindingKey *bkey, | 2109 | struct GNUNET_CRYPTO_rsa_BlindingKey *bkey, |
2110 | struct GNUNET_CRYPTO_rsa_PublicKey *pkey); | 2110 | struct GNUNET_CRYPTO_RsaPublicKey *pkey); |
2111 | 2111 | ||
2112 | 2112 | ||
2113 | /** | 2113 | /** |
@@ -2121,8 +2121,8 @@ GNUNET_CRYPTO_rsa_unblind (struct GNUNET_CRYPTO_rsa_Signature *sig, | |||
2121 | */ | 2121 | */ |
2122 | int | 2122 | int |
2123 | GNUNET_CRYPTO_rsa_verify (const struct GNUNET_HashCode *hash, | 2123 | GNUNET_CRYPTO_rsa_verify (const struct GNUNET_HashCode *hash, |
2124 | const struct GNUNET_CRYPTO_rsa_Signature *sig, | 2124 | const struct GNUNET_CRYPTO_RsaSignature *sig, |
2125 | const struct GNUNET_CRYPTO_rsa_PublicKey *public_key); | 2125 | const struct GNUNET_CRYPTO_RsaPublicKey *public_key); |
2126 | 2126 | ||
2127 | 2127 | ||
2128 | #if 0 /* keep Emacsens' auto-indent happy */ | 2128 | #if 0 /* keep Emacsens' auto-indent happy */ |