simplified write / idle handlers

SSL/TLS connection states merged into HTTP states
This commit is contained in:
lv-426 committed 2008-07-10 17:28:48 +00:00
1 parent 08ee1d01c9
commit a6a989cf12
18 files changed
+213 -145

No files matched your search

+3 -3
View File
@@ -8,12 +8,12 @@
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
*
* GNUTLS is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@@ -192,7 +192,7 @@ print_x509_info (gnutls_session_t session, const char *hostname)
printf (" # fingerprint: %s\n", print);
}
/* Print the version of the X.509
/* Print the version of the X.509
* certificate.
*/
if (verbose)
+3 -5
View File
@@ -9,12 +9,12 @@
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
*
* GNUTLS-EXTRA is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@@ -38,7 +38,7 @@ extern int _gnutls_comp_algorithms_size;
static int _gnutls_init_extra = 0;
/**
* gnutls_global_init_extra - This function initializes the global state of gnutls-extra
* gnutls_global_init_extra - This function initializes the global state of gnutls-extra
*
* This function initializes the global state of gnutls-extra library
* to defaults. Returns zero on success.
@@ -51,8 +51,6 @@ static int _gnutls_init_extra = 0;
int
gnutls_global_init_extra (void)
{
int ret;
/* If the version of libgnutls != version of
* libextra, then do not initialize the library.
* This is because it may break things.
-3
View File
@@ -38,7 +38,6 @@ oprfi_recv_server (gnutls_session_t session,
{
ssize_t data_size = _data_size;
uint16_t len;
int ret;
if (!session->security_parameters.extensions.oprfi_cb)
{
@@ -75,7 +74,6 @@ oprfi_recv_client (gnutls_session_t session,
{
ssize_t data_size = _data_size;
uint16_t len;
int ret;
if (session->security_parameters.extensions.oprfi_client == NULL)
{
@@ -149,7 +147,6 @@ oprfi_send_server (gnutls_session_t session, opaque * data, size_t _data_size)
opaque *p = data;
int ret;
ssize_t data_size = _data_size;
size_t len;
if (!session->security_parameters.extensions.oprfi_client ||
!session->security_parameters.extensions.oprfi_cb)
+1 -1
View File
@@ -4,7 +4,7 @@
#include <libtasn1.h>
extern const ASN1_ARRAY_TYPE gnutls_asn1_tab[] = {
const ASN1_ARRAY_TYPE gnutls_asn1_tab[] = {
{"GNUTLS", 536872976, 0},
{0, 1073741836, 0},
{"RSAPublicKey", 1610612741, 0},
+2 -7
View File
@@ -34,7 +34,6 @@ comp_hd_t
_gnutls_comp_init (gnutls_compression_method_t method, int d)
{
comp_hd_t ret;
int err;
ret = gnutls_malloc (sizeof (struct comp_hd_t_STRUCT));
if (ret == NULL)
@@ -105,8 +104,6 @@ cleanup_ret:
void
_gnutls_comp_deinit (comp_hd_t handle, int d)
{
int err;
if (handle != NULL)
{
switch (handle->algo)
@@ -128,7 +125,7 @@ _gnutls_comp_deinit (comp_hd_t handle, int d)
}
}
/* These functions are memory consuming
/* These functions are memory consuming
*/
int
@@ -137,7 +134,6 @@ _gnutls_compress (comp_hd_t handle, const opaque * plain,
size_t max_comp_size)
{
int compressed_size = GNUTLS_E_COMPRESSION_FAILED;
int err;
/* NULL compression is not handled here
*/
@@ -212,8 +208,7 @@ _gnutls_decompress (comp_hd_t handle, opaque * compressed,
size_t compressed_size, opaque ** plain,
size_t max_record_size)
{
int plain_size = GNUTLS_E_DECOMPRESSION_FAILED, err;
int cur_pos;
int plain_size = GNUTLS_E_DECOMPRESSION_FAILED;
if (compressed_size > max_record_size + EXTRA_COMP_SIZE)
{
+1 -1
View File
@@ -160,7 +160,7 @@ static void
_gnutls_gcry_log_handler (void *dummy, int level,
const char *fmt, va_list list)
{
_gnutls_log (fmt, list);
_gnutls_log (level, fmt, list);
}
#endif
+1 -1
View File
@@ -23,7 +23,7 @@
*/
#ifndef GNUTLS_MPI_H
# define GNUTLS_MPI_H
#define GNUTLS_MPI_H
# include <gnutls_int.h>
# include <gcrypt.h>
+1 -1
View File
@@ -23,7 +23,7 @@
*/
#ifndef GNUTLS_PK_H
# define GNUTLS_PK_H
#define GNUTLS_PK_H
int _gnutls_pkcs1_rsa_encrypt (gnutls_datum_t * ciphertext,
const gnutls_datum_t * plaintext,
+2 -3
View File
@@ -82,7 +82,7 @@ _gnutls_x509_read_rsa_params (opaque * der, int dersize, mpi_t * params)
}
/* reads p,q and g
/* reads p,q and g
* from the certificate (subjectPublicKey BIT STRING).
* params[0-2]
*/
@@ -193,7 +193,7 @@ _gnutls_x509_read_der_int (opaque * der, int dersize, mpi_t * out)
}
/* reads DSA's Y
* from the certificate
* from the certificate
* only sets params[3]
*/
int
@@ -339,7 +339,6 @@ _gnutls_x509_write_sig_params (ASN1_TYPE dst,
gnutls_digest_algorithm_t dig,
mpi_t * params, int params_size)
{
gnutls_datum_t der;
int result;
char name[128];
const char *pk;