Logo Search packages:      
Sourcecode: openssl version File versions

STACK_OF ( X509_NAME   ) 

Load CA certs from a file into a STACK. Note that it is somewhat misnamed; it doesn't really have anything to do with clients (except that a common use for a stack of CAs is to send it to the client). Actually, it doesn't have much to do with CAs, either, since it will load any old cert.

Parameters:
file the file containing one or more certs.
Returns:
a STACK containing the certs.

Definition at line 526 of file ssl_cert.c.

Referenced by SSL_CTX_set_cipher_list(), SSL_CTX_set_ssl_version(), SSL_get_cipher_list(), and SSL_set_cipher_list().

      {
      int i;
      STACK_OF(X509_NAME) *ret;
      X509_NAME *name;

      ret=sk_X509_NAME_new_null();
      for (i=0; i<sk_X509_NAME_num(sk); i++)
            {
            name=X509_NAME_dup(sk_X509_NAME_value(sk,i));
            if ((name == NULL) || !sk_X509_NAME_push(ret,name))
                  {
                  sk_X509_NAME_pop_free(ret,X509_NAME_free);
                  return(NULL);
                  }
            }
      return(ret);
      }


Generated by  Doxygen 1.6.0   Back to index