Remove '_ext' suffix from SSL key exporter API

Signed-off-by: Hanno Becker <hanno.becker@arm.com>
diff --git a/include/mbedtls/config.h b/include/mbedtls/config.h
index 598e59f..e9da07a 100644
--- a/include/mbedtls/config.h
+++ b/include/mbedtls/config.h
@@ -1556,7 +1556,7 @@
  * (see Section 5 of RFC 5764), are not handled by this feature.
  * Instead, after successful completion of a handshake negotiating
  * the use of DTLS-SRTP, the extended key exporter API
- * mbedtls_ssl_conf_export_keys_ext_cb() should be used to implement
+ * mbedtls_ssl_conf_export_keys_cb() should be used to implement
  * the key exporter described in Section 4.2 of RFC 5764 and RFC 5705
  * (this is implemented in the SSL example programs).
  * The resulting key should then be passed to an SRTP stack.
diff --git a/include/mbedtls/ssl.h b/include/mbedtls/ssl.h
index 6c24aab..410ac0e 100644
--- a/include/mbedtls/ssl.h
+++ b/include/mbedtls/ssl.h
@@ -1035,7 +1035,7 @@
 #if defined(MBEDTLS_SSL_EXPORT_KEYS)
     /** Callback to export key block, master secret,
      *  tls_prf and random bytes. Should replace f_export_keys    */
-    int (*MBEDTLS_PRIVATE(f_export_keys_ext))( void *, const unsigned char *,
+    int (*MBEDTLS_PRIVATE(f_export_keys))( void *, const unsigned char *,
                 const unsigned char *, size_t, size_t, size_t,
                 const unsigned char[32], const unsigned char[32],
                 mbedtls_tls_prf_types );
@@ -1941,7 +1941,7 @@
  * \return          0 if successful, or
  *                  a specific MBEDTLS_ERR_XXX code.
  */
-typedef int mbedtls_ssl_export_keys_ext_t( void *p_expkey,
+typedef int mbedtls_ssl_export_keys_t( void *p_expkey,
                                            const unsigned char *ms,
                                            const unsigned char *kb,
                                            size_t maclen,
@@ -2020,16 +2020,16 @@
  * \brief           Configure extended key export callback.
  *                  (Default: none.)
  *
- * \note            See \c mbedtls_ssl_export_keys_ext_t.
+ * \note            See \c mbedtls_ssl_export_keys_t.
  * \warning         Exported key material must not be used for any purpose
  *                  before the (D)TLS handshake is completed
  *
  * \param conf      SSL configuration context
- * \param f_export_keys_ext Callback for exporting keys
+ * \param f_export_keys Callback for exporting keys
  * \param p_export_keys     Context for the callback
  */
-void mbedtls_ssl_conf_export_keys_ext_cb( mbedtls_ssl_config *conf,
-        mbedtls_ssl_export_keys_ext_t *f_export_keys_ext,
+void mbedtls_ssl_conf_export_keys_cb( mbedtls_ssl_config *conf,
+        mbedtls_ssl_export_keys_t *f_export_keys,
         void *p_export_keys );
 #endif /* MBEDTLS_SSL_EXPORT_KEYS */
 
diff --git a/library/ssl_tls.c b/library/ssl_tls.c
index e6bc790..94f906a 100644
--- a/library/ssl_tls.c
+++ b/library/ssl_tls.c
@@ -986,9 +986,9 @@
     ((void) mac_enc);
 
 #if defined(MBEDTLS_SSL_EXPORT_KEYS)
-    if( ssl->conf->f_export_keys_ext != NULL )
+    if( ssl->conf->f_export_keys != NULL )
     {
-        ssl->conf->f_export_keys_ext( ssl->conf->p_export_keys,
+        ssl->conf->f_export_keys( ssl->conf->p_export_keys,
                                       master, keyblk,
                                       mac_key_len, keylen,
                                       iv_copy_len,
@@ -4185,11 +4185,11 @@
 #endif /* MBEDTLS_SSL_SESSION_TICKETS */
 
 #if defined(MBEDTLS_SSL_EXPORT_KEYS)
-void mbedtls_ssl_conf_export_keys_ext_cb( mbedtls_ssl_config *conf,
-        mbedtls_ssl_export_keys_ext_t *f_export_keys_ext,
+void mbedtls_ssl_conf_export_keys_cb( mbedtls_ssl_config *conf,
+        mbedtls_ssl_export_keys_t *f_export_keys,
         void *p_export_keys )
 {
-    conf->f_export_keys_ext = f_export_keys_ext;
+    conf->f_export_keys = f_export_keys;
     conf->p_export_keys = p_export_keys;
 }
 #endif
diff --git a/programs/ssl/ssl_client2.c b/programs/ssl/ssl_client2.c
index 322cef8..bc5ed2e 100644
--- a/programs/ssl/ssl_client2.c
+++ b/programs/ssl/ssl_client2.c
@@ -1739,19 +1739,19 @@
 #if defined(MBEDTLS_SSL_EXPORT_KEYS)
     if( opt.eap_tls != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf, eap_tls_key_derivation,
+        mbedtls_ssl_conf_export_keys_cb( &conf, eap_tls_key_derivation,
                                              &eap_tls_keying );
     }
     else if( opt.nss_keylog != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf,
+        mbedtls_ssl_conf_export_keys_cb( &conf,
                                              nss_keylog_export,
                                              NULL );
     }
 #if defined( MBEDTLS_SSL_DTLS_SRTP )
     else if( opt.use_srtp != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf, dtls_srtp_key_derivation,
+        mbedtls_ssl_conf_export_keys_cb( &conf, dtls_srtp_key_derivation,
                                              &dtls_srtp_keying );
     }
 #endif /* MBEDTLS_SSL_DTLS_SRTP */
diff --git a/programs/ssl/ssl_server2.c b/programs/ssl/ssl_server2.c
index 51125bd..334eb7d 100644
--- a/programs/ssl/ssl_server2.c
+++ b/programs/ssl/ssl_server2.c
@@ -2528,19 +2528,19 @@
 #if defined(MBEDTLS_SSL_EXPORT_KEYS)
     if( opt.eap_tls != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf, eap_tls_key_derivation,
+        mbedtls_ssl_conf_export_keys_cb( &conf, eap_tls_key_derivation,
                                              &eap_tls_keying );
     }
     else if( opt.nss_keylog != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf,
+        mbedtls_ssl_conf_export_keys_cb( &conf,
                                              nss_keylog_export,
                                              NULL );
     }
 #if defined( MBEDTLS_SSL_DTLS_SRTP )
     else if( opt.use_srtp != 0 )
     {
-        mbedtls_ssl_conf_export_keys_ext_cb( &conf, dtls_srtp_key_derivation,
+        mbedtls_ssl_conf_export_keys_cb( &conf, dtls_srtp_key_derivation,
                                              &dtls_srtp_keying );
     }
 #endif /* MBEDTLS_SSL_DTLS_SRTP */