summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2012-11-04 17:22:39 +0100
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2012-11-04 17:30:53 +0100
commitc40b9845e723a9b405cccc501e5eeb440791c13c (patch)
treed918c85a210b9e3cfa59c51811bf2fe258a63599
parentc17feb96403ad8bb827702bd5e52a7fb81a3e71b (diff)
downloadgnutls-c40b9845e723a9b405cccc501e5eeb440791c13c.tar.gz
Added HMAC prefix to SRTP profiles and updated documentation.
-rw-r--r--doc/cha-intro-tls.texi5
-rw-r--r--lib/ext/srtp.c20
-rw-r--r--lib/includes/gnutls/gnutls.h.in16
3 files changed, 22 insertions, 19 deletions
diff --git a/doc/cha-intro-tls.texi b/doc/cha-intro-tls.texi
index b2b46def35..624efb9e22 100644
--- a/doc/cha-intro-tls.texi
+++ b/doc/cha-intro-tls.texi
@@ -601,7 +601,10 @@ request.
The TLS protocol was extended in @xcite{RFC5764} to provide keying material to the
Secure RTP (SRTP) protocol. The SRTP protocol provides an encapsulation of encrypted
data that is optimized for voice data. With the SRTP TLS extension two peers can
-negotiate keys using TLS or DTLS and obtain keying material for use with SRTP.
+negotiate keys using TLS or DTLS and obtain keying material for use with SRTP. The
+available SRTP profiles are listed below.
+
+@showenumdesc{gnutls_srtp_profile_t,Supported SRTP profiles}
To enable use the following functions.
diff --git a/lib/ext/srtp.c b/lib/ext/srtp.c
index 35e99facfc..7cc41d8bf6 100644
--- a/lib/ext/srtp.c
+++ b/lib/ext/srtp.c
@@ -61,23 +61,23 @@ typedef struct
static const srtp_profile_st profile_names[] = {
{
- "SRTP_AES128_CM_SHA1_80",
- GNUTLS_SRTP_AES128_CM_SHA1_80,
+ "SRTP_AES128_CM_HMAC_SHA1_80",
+ GNUTLS_SRTP_AES128_CM_HMAC_SHA1_80,
16,14
},
{
- "SRTP_AES128_CM_SHA1_32",
- GNUTLS_SRTP_AES128_CM_SHA1_32,
+ "SRTP_AES128_CM_HMAC_SHA1_32",
+ GNUTLS_SRTP_AES128_CM_HMAC_SHA1_32,
16,14
},
{
- "SRTP_NULL_SHA1_80",
- GNUTLS_SRTP_NULL_SHA1_80,
+ "SRTP_NULL_HMAC_SHA1_80",
+ GNUTLS_SRTP_NULL_HMAC_SHA1_80,
16,14
},
{
"SRTP_NULL_SHA1_32",
- GNUTLS_SRTP_NULL_SHA1_32,
+ GNUTLS_SRTP_NULL_HMAC_SHA1_32,
16,14
},
{
@@ -448,12 +448,12 @@ gnutls_srtp_set_profile_direct (gnutls_session_t session,
* This is a helper function to generate the keying material for SRTP.
* It requires the space of the key material to be pre-allocated (should be at least
* 2x the maximum key size and salt size). The @client_key, @client_salt, @server_key
- * and @server_salt are convenience datums that point inside the key material. The may
+ * and @server_salt are convenience datums that point inside the key material. They may
* be %NULL.
*
* Returns: On success the size of the key material is returned,
- * %GNUTLS_E_SHORT_MEMORY_BUFFER if the buffer given is not sufficient,
- * or a negative error code.
+ * otherwise, %GNUTLS_E_SHORT_MEMORY_BUFFER if the buffer given is not
+ * sufficient, or a negative error code.
*
* Since 3.1.4
**/
diff --git a/lib/includes/gnutls/gnutls.h.in b/lib/includes/gnutls/gnutls.h.in
index 505b9929b5..565e5bea4a 100644
--- a/lib/includes/gnutls/gnutls.h.in
+++ b/lib/includes/gnutls/gnutls.h.in
@@ -972,19 +972,19 @@ gnutls_ecc_curve_t gnutls_ecc_curve_get(gnutls_session_t session);
/**
* gnutls_srtp_profile_t:
- * @GNUTLS_SRTP_AES128_CM_SHA1_80: 128 bit AES with a 80 bit HMAC-SHA1
- * @GNUTLS_SRTP_AES128_CM_SHA1_32: 128 bit AES with a 32 bit HMAC-SHA1
- * @GNUTLS_SRTP_NULL_SHA1_80: NULL cipher with a 80 bit HMAC-SHA1
- * @GNUTLS_SRTP_NULL_SHA1_32: NULL cipher with a 32 bit HMAC-SHA1
+ * @GNUTLS_SRTP_AES128_CM_HMAC_SHA1_80: 128 bit AES with a 80 bit HMAC-SHA1
+ * @GNUTLS_SRTP_AES128_CM_HMAC_SHA1_32: 128 bit AES with a 32 bit HMAC-SHA1
+ * @GNUTLS_SRTP_NULL_HMAC_SHA1_80: NULL cipher with a 80 bit HMAC-SHA1
+ * @GNUTLS_SRTP_NULL_HMAC_SHA1_32: NULL cipher with a 32 bit HMAC-SHA1
*
* Enumeration of different SRTP protection profiles.
*/
typedef enum
{
- GNUTLS_SRTP_AES128_CM_SHA1_80 = 0x0001,
- GNUTLS_SRTP_AES128_CM_SHA1_32 = 0x0002,
- GNUTLS_SRTP_NULL_SHA1_80 = 0x0005,
- GNUTLS_SRTP_NULL_SHA1_32 = 0x0006
+ GNUTLS_SRTP_AES128_CM_HMAC_SHA1_80 = 0x0001,
+ GNUTLS_SRTP_AES128_CM_HMAC_SHA1_32 = 0x0002,
+ GNUTLS_SRTP_NULL_HMAC_SHA1_80 = 0x0005,
+ GNUTLS_SRTP_NULL_HMAC_SHA1_32 = 0x0006
} gnutls_srtp_profile_t;
int gnutls_srtp_set_profile (gnutls_session_t session,