mturk       2005/06/07 01:18:23

  Modified:    jni/native/src sslcontext.c
  Log:
  Check for supplied certificate file.
  BTW this should be the responsibility of higher API.
  
  Revision  Changes    Path
  1.23      +6 -1      jakarta-tomcat-connectors/jni/native/src/sslcontext.c
  
  Index: sslcontext.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jni/native/src/sslcontext.c,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- sslcontext.c      7 Jun 2005 08:15:32 -0000       1.22
  +++ sslcontext.c      7 Jun 2005 08:18:23 -0000       1.23
  @@ -484,6 +484,11 @@
       cert_file = J2S(cert);
       if (!key_file)
           key_file = cert_file;
  +    if (!key_file) {
  +        tcn_Throw(e, "No Certificate file specified");
  +        rv = JNI_FALSE;
  +        goto cleanup;
  +    }
       if ((c->keys[idx] = load_pem_key(c, key_file)) == NULL) {
           ERR_error_string(ERR_get_error(), err);
           tcn_Throw(e, "Unable to load certificate key %s (%s)",
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to