doc_encdec.h 4.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. /**
  2. * \file doc_encdec.h
  3. *
  4. * \brief Encryption/decryption module documentation file.
  5. */
  6. /*
  7. *
  8. * Copyright The Mbed TLS Contributors
  9. * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
  10. *
  11. * This file is provided under the Apache License 2.0, or the
  12. * GNU General Public License v2.0 or later.
  13. *
  14. * **********
  15. * Apache License 2.0:
  16. *
  17. * Licensed under the Apache License, Version 2.0 (the "License"); you may
  18. * not use this file except in compliance with the License.
  19. * You may obtain a copy of the License at
  20. *
  21. * http://www.apache.org/licenses/LICENSE-2.0
  22. *
  23. * Unless required by applicable law or agreed to in writing, software
  24. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  25. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  26. * See the License for the specific language governing permissions and
  27. * limitations under the License.
  28. *
  29. * **********
  30. *
  31. * **********
  32. * GNU General Public License v2.0 or later:
  33. *
  34. * This program is free software; you can redistribute it and/or modify
  35. * it under the terms of the GNU General Public License as published by
  36. * the Free Software Foundation; either version 2 of the License, or
  37. * (at your option) any later version.
  38. *
  39. * This program is distributed in the hope that it will be useful,
  40. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  41. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  42. * GNU General Public License for more details.
  43. *
  44. * You should have received a copy of the GNU General Public License along
  45. * with this program; if not, write to the Free Software Foundation, Inc.,
  46. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  47. *
  48. * **********
  49. */
  50. /**
  51. * @addtogroup encdec_module Encryption/decryption module
  52. *
  53. * The Encryption/decryption module provides encryption/decryption functions.
  54. * One can differentiate between symmetric and asymmetric algorithms; the
  55. * symmetric ones are mostly used for message confidentiality and the asymmetric
  56. * ones for key exchange and message integrity.
  57. * Some symmetric algorithms provide different block cipher modes, mainly
  58. * Electronic Code Book (ECB) which is used for short (64-bit) messages and
  59. * Cipher Block Chaining (CBC) which provides the structure needed for longer
  60. * messages. In addition the Cipher Feedback Mode (CFB-128) stream cipher mode,
  61. * Counter mode (CTR) and Galois Counter Mode (GCM) are implemented for
  62. * specific algorithms.
  63. *
  64. * All symmetric encryption algorithms are accessible via the generic cipher layer
  65. * (see \c mbedtls_cipher_setup()).
  66. *
  67. * The asymmetric encryptrion algorithms are accessible via the generic public
  68. * key layer (see \c mbedtls_pk_init()).
  69. *
  70. * The following algorithms are provided:
  71. * - Symmetric:
  72. * - AES (see \c mbedtls_aes_crypt_ecb(), \c mbedtls_aes_crypt_cbc(), \c mbedtls_aes_crypt_cfb128() and
  73. * \c mbedtls_aes_crypt_ctr()).
  74. * - ARCFOUR (see \c mbedtls_arc4_crypt()).
  75. * - Blowfish / BF (see \c mbedtls_blowfish_crypt_ecb(), \c mbedtls_blowfish_crypt_cbc(),
  76. * \c mbedtls_blowfish_crypt_cfb64() and \c mbedtls_blowfish_crypt_ctr())
  77. * - Camellia (see \c mbedtls_camellia_crypt_ecb(), \c mbedtls_camellia_crypt_cbc(),
  78. * \c mbedtls_camellia_crypt_cfb128() and \c mbedtls_camellia_crypt_ctr()).
  79. * - DES/3DES (see \c mbedtls_des_crypt_ecb(), \c mbedtls_des_crypt_cbc(), \c mbedtls_des3_crypt_ecb()
  80. * and \c mbedtls_des3_crypt_cbc()).
  81. * - GCM (AES-GCM and CAMELLIA-GCM) (see \c mbedtls_gcm_init())
  82. * - XTEA (see \c mbedtls_xtea_crypt_ecb()).
  83. * - Asymmetric:
  84. * - Diffie-Hellman-Merkle (see \c mbedtls_dhm_read_public(), \c mbedtls_dhm_make_public()
  85. * and \c mbedtls_dhm_calc_secret()).
  86. * - RSA (see \c mbedtls_rsa_public() and \c mbedtls_rsa_private()).
  87. * - Elliptic Curves over GF(p) (see \c mbedtls_ecp_point_init()).
  88. * - Elliptic Curve Digital Signature Algorithm (ECDSA) (see \c mbedtls_ecdsa_init()).
  89. * - Elliptic Curve Diffie Hellman (ECDH) (see \c mbedtls_ecdh_init()).
  90. *
  91. * This module provides encryption/decryption which can be used to provide
  92. * secrecy.
  93. *
  94. * It also provides asymmetric key functions which can be used for
  95. * confidentiality, integrity, authentication and non-repudiation.
  96. */