const char * SSL_CIPHER_get_name(SSL_CIPHER *c);
int SSL_get_fd(SSL *s);
+int SSL_get_rfd(SSL *s);
+int SSL_get_wfd(SSL *s);
const char * SSL_get_cipher_list(SSL *s,int n);
char * SSL_get_shared_ciphers(SSL *s, char *buf, int len);
int SSL_get_read_ahead(SSL * s);
{ return(s->wbio); }
int SSL_get_fd(SSL *s)
+ {
+ return(SSL_get_rfc(s));
+ }
+
+int SSL_get_rfd(SSL *s)
{
int ret= -1;
BIO *b,*r;
return(ret);
}
+int SSL_get_wfd(SSL *s)
+ {
+ int ret= -1;
+ BIO *b,*r;
+
+ b=SSL_get_wbio(s);
+ r=BIO_find_type(b,BIO_TYPE_DESCRIPTOR);
+ if (r != NULL)
+ BIO_get_fd(r,&ret);
+ return(ret);
+ }
+
#ifndef NO_SOCK
int SSL_set_fd(SSL *s,int fd)
{