GskStreamSsl

Name

GskStreamSsl -- 

Synopsis



struct      GskStreamSsl;
GskStream*  gsk_stream_ssl_new_client       (const char *cert_file,
                                             const char *key_file,
                                             const char *password,
                                             GskStream *transport,
                                             GError **error);
GskStream*  gsk_stream_ssl_new_server       (const char *cert_file,
                                             const char *key_file,
                                             const char *password,
                                             GskStream *transport,
                                             GError **error);
GskStream*  gsk_stream_ssl_peek_backend     (GskStreamSsl *ssl);

Object Hierarchy


  GObject
   +----GskIO
         +----GskStream
               +----GskStreamSsl

Properties


  "cert-file"            gchararray           : Read / Write / Construct Only
  "is-client"            gboolean             : Read / Write / Construct Only
  "key-file"             gchararray           : Read / Write / Construct Only
  "password"             gchararray           : Write / Construct Only

Description

Details

struct GskStreamSsl

struct GskStreamSsl;

A SSL client or server.


gsk_stream_ssl_new_client ()

GskStream*  gsk_stream_ssl_new_client       (const char *cert_file,
                                             const char *key_file,
                                             const char *password,
                                             GskStream *transport,
                                             GError **error);

Create the client end of a SSL connection. This should be attached to a connecting or connected stream, usually provided as the transport argument.

cert_file :

the PEM x509 certificate file.

key_file :

key file???

password :

password required by the certificate, or NULL.

transport :

optional transport layer (which will be connected to the backend stream by bidirectionally).

error :

optional location in which to store a GError.

Returns :

the new SSL stream, or NULL if an error occurs.


gsk_stream_ssl_new_server ()

GskStream*  gsk_stream_ssl_new_server       (const char *cert_file,
                                             const char *key_file,
                                             const char *password,
                                             GskStream *transport,
                                             GError **error);

Create a new SSL server. It should be connected to a socket which was accepted from a server (usually provided as the transport argument).

cert_file :

the PEM x509 certificate file.

key_file :

key file???

password :

password required by the certificate, or NULL.

transport :

optional transport layer (which will be connected to the backend stream by bidirectionally).

error :

optional location in which to store a GError.

Returns :

the new SSL stream, or NULL if an error occurs.


gsk_stream_ssl_peek_backend ()

GskStream*  gsk_stream_ssl_peek_backend     (GskStreamSsl *ssl);

Get a reference to the backend stream, which should be connected to the underlying transport layer.

ssl :

the stream to query.

Returns :

the SSL backend (to be connected to the transport, which is the stream which is typically insecure without SSL protection).

Properties

"cert-file" (gchararray : Read / Write / Construct Only)

"is-client" (gboolean : Read / Write / Construct Only)

"key-file" (gchararray : Read / Write / Construct Only)

"password" (gchararray : Write / Construct Only)