axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kausha...@apache.org
Subject svn commit: r442087 - in /webservices/axis2/trunk/c/rampart: include/ src/omxmlsec/ src/omxmlsec/openssl/ src/util/
Date Mon, 11 Sep 2006 04:07:31 GMT
Author: kaushalye
Date: Sun Sep 10 21:07:30 2006
New Revision: 442087

URL: http://svn.apache.org/viewvc?view=rev&rev=442087
Log:
Committing changes made for the buffer class. Along with some code formatting and memory leak fixes.

Modified:
    webservices/axis2/trunk/c/rampart/include/openssl_util.h
    webservices/axis2/trunk/c/rampart/include/oxs_axis2_utils.h
    webservices/axis2/trunk/c/rampart/include/oxs_buffer.h
    webservices/axis2/trunk/c/rampart/include/oxs_enc_engine.h
    webservices/axis2/trunk/c/rampart/include/oxs_key.h
    webservices/axis2/trunk/c/rampart/src/omxmlsec/axis2_utils.c
    webservices/axis2/trunk/c/rampart/src/omxmlsec/buffer.c
    webservices/axis2/trunk/c/rampart/src/omxmlsec/enc_engine.c
    webservices/axis2/trunk/c/rampart/src/omxmlsec/key.c
    webservices/axis2/trunk/c/rampart/src/omxmlsec/openssl/util.c
    webservices/axis2/trunk/c/rampart/src/util/rampart_crypto_engine.c

Modified: webservices/axis2/trunk/c/rampart/include/openssl_util.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/include/openssl_util.h?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/include/openssl_util.h (original)
+++ webservices/axis2/trunk/c/rampart/include/openssl_util.h Sun Sep 10 21:07:30 2006
@@ -30,7 +30,7 @@
 #endif
 
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
-generate_random_data(const axis2_env_t *env, oxs_buffer_ptr buf, int size);
+generate_random_data(const axis2_env_t *env, oxs_buffer_t *buffer, int size);
 
 /*Get the cipher property for a given cipher name
   @see openssl_cipher_property.h*/

Modified: webservices/axis2/trunk/c/rampart/include/oxs_axis2_utils.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/include/oxs_axis2_utils.h?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/include/oxs_axis2_utils.h (original)
+++ webservices/axis2/trunk/c/rampart/include/oxs_axis2_utils.h Sun Sep 10 21:07:30 2006
@@ -32,6 +32,7 @@
  * @ingroup
  * @{
  */
+#if 0
 /*Decoded buffer will be returned*/
 AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL  oxs_base64_decode(axis2_env_t *env,
     oxs_buffer_ptr coded_buf);
@@ -39,6 +40,7 @@
 /*Encoded input buffer will be returned*/
 AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL  oxs_base64_encode(axis2_env_t *env,
     oxs_buffer_ptr plain_buf);
+#endif
 
 /** @} */
 #ifdef __cplusplus

Modified: webservices/axis2/trunk/c/rampart/include/oxs_buffer.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/include/oxs_buffer.h?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/include/oxs_buffer.h (original)
+++ webservices/axis2/trunk/c/rampart/include/oxs_buffer.h Sun Sep 10 21:07:30 2006
@@ -26,7 +26,6 @@
 #include <axis2_defines.h>
 #include <axis2_env.h>
 #include <axis2_util.h>
-#include <oxs_axiom.h>
 
 #ifdef __cplusplus
 extern "C"
@@ -40,73 +39,155 @@
 
 #define OXS_BUFFER_INITIAL_SIZE 1024
 
+    /**
+    * Allocate mode for the buffer
+    * oxs_alloc_mode_exact : Minimizes the allocated memory size
+    * oxs_alloc_mode_double : Minimizes number of Malloc calls
+    */
+    typedef enum {
+        oxs_alloc_mode_exact = 0,
+        oxs_alloc_mode_double
+    } oxs_AllocMode;
+
+    /** Type name for struct  oxs_buffer_ops */
+    typedef struct oxs_buffer_ops oxs_buffer_ops_t;
+
+    /** Type name for struct  oxs_buffer */
+    typedef struct oxs_buffer oxs_buffer_t;
+
+    struct oxs_buffer_ops
+    {
+        axis2_status_t (AXIS2_CALL *
+                free)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                remove_head)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                remove_tail)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+        
+        axis2_status_t (AXIS2_CALL *
+                populate)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                append)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                prepend)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                read_file)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    const axis2_char_t *filename
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                set_size)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+        axis2_status_t (AXIS2_CALL *
+                set_max_size)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+        
+        unsigned char* (AXIS2_CALL *
+                get_data)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+        int (AXIS2_CALL *
+                get_size)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+        int (AXIS2_CALL *
+                get_max_size)(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+    };
+
+    struct oxs_buffer
+    {
+        oxs_buffer_ops_t *ops;
+    };
+
+AXIS2_EXTERN oxs_buffer_t *AXIS2_CALL
+oxs_buffer_create(const axis2_env_t *env);
+
+/*Macros*/
+
+#define OXS_BUFFER_FREE(buffer,env)\
+    ((buffer)->ops->free(buffer,env))
+
+#define OXS_BUFFER_REMOVE_HEAD(buffer,env, size)\
+    ((buffer)->ops->remove_head(buffer,env, size))
+
+#define OXS_BUFFER_REMOVE_TAIL(buffer,env, size)\
+    ((buffer)->ops->remove_tail(buffer,env, size))
+
+#define OXS_BUFFER_POPULATE(buffer,env, data, size)\
+    ((buffer)->ops->populate(buffer,env, data, size))
+
+#define OXS_BUFFER_APPEND(buffer,env, data, size)\
+    ((buffer)->ops->append(buffer,env, data, size))
+
+#define OXS_BUFFER_PREPEND(buffer,env, data, size)\
+    ((buffer)->ops->prepend(buffer,env, data, size))
+
+#define OXS_BUFFER_READ_FILE(buffer,env, file_name)\
+    ((buffer)->ops->read_file(buffer,env, file_name))
+
+#define OXS_BUFFER_SET_SIZE(buffer,env, size)\
+    ((buffer)->ops->set_size(buffer,env, size))
+
+#define OXS_BUFFER_SET_MAX_SIZE(buffer, env, size)\
+    ((buffer)->ops->set_max_size(buffer, env, size))
 
-typedef struct _oxs_buffer                    oxs_buffer,
-                                *oxs_buffer_ptr;
+#define OXS_BUFFER_GET_DATA(buffer,env)\
+    ((buffer)->ops->get_data(buffer,env))
 
+#define OXS_BUFFER_GET_SIZE(buffer,env)\
+    ((buffer)->ops->get_size(buffer,env))
 
-/**
-* Allocate mode for the buffer
-* oxs_alloc_mode_exact : Minimizes the allocated memory size
-* oxs_alloc_mode_double : Minimizes number of Malloc calls
-*/
-typedef enum {
-    oxs_alloc_mode_exact = 0,
-    oxs_alloc_mode_double
-} oxs_AllocMode;
-
-/**
-* Buffer to hold data
-* @data : pointer to buffer data
-* @size : size of the buffer data
-* @max_size : allocated size of the buffer
-* @alloc_mode : Mode of the allcoation
-*/
-struct _oxs_buffer{
-    unsigned char* data;
-    unsigned int size;
-    unsigned int max_size;
-    oxs_AllocMode alloc_mode;
-}; 
-
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_create_buffer(const axis2_env_t *env, unsigned int size);
-
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_buffer_initialize(const axis2_env_t *env ,oxs_buffer_ptr buf,  unsigned int size);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_free_buffer(const axis2_env_t *env, oxs_buffer_ptr buf);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_remove_head(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size);
-
-AXIS2_EXTERN axis2_status_t AXIS2_CALL
-oxs_buffer_remove_tail(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size);
-
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_string_to_buffer(const axis2_env_t *env, axis2_char_t* string);
-
-AXIS2_EXTERN axis2_char_t* AXIS2_CALL
-oxs_buffer_to_string(const axis2_env_t *env, oxs_buffer_ptr buf);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_append(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned char* data, unsigned int size);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_prepend(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned char* data, unsigned int size);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_set_size(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size);
+#define OXS_BUFFER_GET_MAX_SIZE(buffer,env)\
+    ((buffer)->ops->get_max_size(buffer,env))
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_set_max_size(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size);
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_read_file(const axis2_env_t *env, oxs_buffer_ptr buf, const char* filename);
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_base64_node_content_read(const axis2_env_t *env, oxs_buffer_ptr buf, axiom_node_t *node);
 /** @} */
 #ifdef __cplusplus
 }

Modified: webservices/axis2/trunk/c/rampart/include/oxs_enc_engine.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/include/oxs_enc_engine.h?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/include/oxs_enc_engine.h (original)
+++ webservices/axis2/trunk/c/rampart/include/oxs_enc_engine.h Sun Sep 10 21:07:30 2006
@@ -68,8 +68,8 @@
         prvkey_decrypt_data) (
                 oxs_enc_engine_t *enc_engine,
                 const axis2_env_t *env,
-                oxs_buffer_ptr input,
-                oxs_buffer_ptr result,
+                oxs_buffer_t *input,
+                oxs_buffer_t *result,
                 axis2_char_t *filename
                 );
         /**
@@ -85,8 +85,8 @@
         pubkey_encrypt_data)(
                 oxs_enc_engine_t *enc_engine,
                 const axis2_env_t *env,
-                oxs_buffer_ptr input,
-                oxs_buffer_ptr result,
+                oxs_buffer_t * input,
+                oxs_buffer_t * result,
                 axis2_char_t *filename
                 );
 
@@ -122,8 +122,8 @@
                 oxs_enc_engine_t *enc_engine,
                 const axis2_env_t *env,
                 oxs_ctx_t * enc_ctx,
-                oxs_buffer_ptr input,
-                oxs_buffer_ptr result);
+                oxs_buffer_t * input,
+                oxs_buffer_t * result);
 
         /**
          * Populate the cipher value node. 
@@ -138,7 +138,7 @@
                 oxs_enc_engine_t *enc_engine,
                 const axis2_env_t *env,
                 axiom_node_t* template_node,
-                oxs_buffer_ptr databuf);
+                oxs_buffer_t * databuf);
     
         /**
          * Decrypt an xml document template. Expects a template similar to the above. 

Modified: webservices/axis2/trunk/c/rampart/include/oxs_key.h
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/include/oxs_key.h?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/include/oxs_key.h (original)
+++ webservices/axis2/trunk/c/rampart/include/oxs_key.h Sun Sep 10 21:07:30 2006
@@ -60,7 +60,7 @@
          * @return data 
          */
 
-        axis2_char_t *(AXIS2_CALL *
+        unsigned char *(AXIS2_CALL *
                 get_data)(
                     const oxs_key_t *key,
                     const axis2_env_t *env);
@@ -106,7 +106,7 @@
                 set_data)(
                     oxs_key_t *key,
                     const axis2_env_t *env,
-                    axis2_char_t *data);
+                    unsigned char *data);
 
          /**
          * Sets the name of the key.
@@ -173,7 +173,7 @@
                 populate)(
                     oxs_key_t *key,
                     const axis2_env_t *env,
-                    axis2_char_t *data,
+                    unsigned char *data,
                     axis2_char_t *name,
                     int size,
                     int usage

Modified: webservices/axis2/trunk/c/rampart/src/omxmlsec/axis2_utils.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/omxmlsec/axis2_utils.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/omxmlsec/axis2_utils.c (original)
+++ webservices/axis2/trunk/c/rampart/src/omxmlsec/axis2_utils.c Sun Sep 10 21:07:30 2006
@@ -17,27 +17,27 @@
 #include <stdio.h>
 #include <axis2_util.h>
 #include <oxs_axis2_utils.h>
-
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL  oxs_base64_decode(axis2_env_t *env,
-    oxs_buffer_ptr coded_buf    )
+#if 0
+AXIS2_EXTERN oxs_buffer_t * AXIS2_CALL  oxs_base64_decode(axis2_env_t *env,
+    oxs_buffer_t *coded_buf    )
 {
-    axis2_char_t* plain_str=NULL;/* Here plain can be binary sometimes */
-    oxs_buffer_ptr out_buf = NULL;
+    axis2_char_t *plain_str=NULL;/* Here plain can be binary sometimes */
+    oxs_buffer_t *out_buf = NULL;
     int  ret, length;
 
-    length =  axis2_base64_decode_len((char*)(coded_buf->data));
-    plain_str = AXIS2_MALLOC(env->allocator, axis2_base64_decode_len((char*)(coded_buf->data)));
-    ret =  axis2_base64_decode(plain_str, (char*)(coded_buf->data)); 
+    length =  axis2_base64_decode_len((char*)(OXS_BUFFER_GET_DATA(coded_buf, env)));
+    plain_str = AXIS2_MALLOC(env->allocator, axis2_base64_decode_len((char*)(OXS_BUFFER_GET_DATA(coded_buf, env))));
+    ret =  axis2_base64_decode(plain_str, (char*)(OXS_BUFFER_GET_DATA(coded_buf, env))); 
     if(ret < 0) return NULL;
     out_buf = oxs_string_to_buffer(env, plain_str);
     return out_buf;
 }
 
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL  oxs_base64_encode(axis2_env_t *env,
-    oxs_buffer_ptr plain_buf    )
+AXIS2_EXTERN oxs_buffer_t * AXIS2_CALL  oxs_base64_encode(axis2_env_t *env,
+    oxs_buffer_t *plain_buf    )
 {
-    axis2_char_t* encoded_str=NULL;
-    oxs_buffer_ptr out_buf = NULL;
+    axis2_char_t *encoded_str=NULL;
+    oxs_buffer_t *out_buf = NULL;
 
     int ret;
 
@@ -53,4 +53,5 @@
     out_buf = oxs_string_to_buffer(env, encoded_str);    
     return out_buf;
 }
+#endif
 

Modified: webservices/axis2/trunk/c/rampart/src/omxmlsec/buffer.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/omxmlsec/buffer.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/omxmlsec/buffer.c (original)
+++ webservices/axis2/trunk/c/rampart/src/omxmlsec/buffer.c Sun Sep 10 21:07:30 2006
@@ -22,236 +22,445 @@
 #include <oxs_error.h>
 
 
-static unsigned int  g_initial_size = OXS_BUFFER_INITIAL_SIZE;
 
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_create_buffer(const axis2_env_t *env, unsigned int size)
+typedef struct oxs_buffer_impl{
+    oxs_buffer_t buffer;
+
+    unsigned char* data;
+    unsigned int size;
+    unsigned int max_size;
+    oxs_AllocMode alloc_mode;
+}
+oxs_buffer_impl_t;
+
+/** Interface to implementation conversion macro */
+#define AXIS2_INTF_TO_IMPL(oxs_buffer) ((oxs_buffer_impl_t *)oxs_buffer)
+
+/******** function headers ***************/
+
+/*private functions*/
+static void
+oxs_buffer_init_ops(
+    oxs_buffer_t *buffer);
+
+/*public functions*/
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_free(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_remove_head(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_remove_tail(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_populate(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_append(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_prepend(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_read_file(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    const axis2_char_t *filename
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_set_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+axis2_status_t AXIS2_CALL 
+oxs_buffer_set_max_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                );
+
+unsigned char* AXIS2_CALL 
+oxs_buffer_get_data(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+int AXIS2_CALL 
+oxs_buffer_get_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+int AXIS2_CALL 
+oxs_buffer_get_max_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                );
+
+
+/******************** end of function headers *****************/
+static void
+oxs_buffer_init_ops(
+    oxs_buffer_t *buffer)
+{
+    buffer->ops->free  = oxs_buffer_free ;
+    buffer->ops->remove_head  = oxs_buffer_remove_head ;
+    buffer->ops->remove_tail  = oxs_buffer_remove_tail ;
+    buffer->ops->populate  = oxs_buffer_populate ;
+    buffer->ops->append  = oxs_buffer_append ;
+    buffer->ops->prepend  = oxs_buffer_prepend ;
+    buffer->ops->read_file = oxs_buffer_read_file ;
+    buffer->ops->set_size  = oxs_buffer_set_size ;
+    buffer->ops->set_max_size  = oxs_buffer_set_max_size ;
+    buffer->ops->get_data  = oxs_buffer_get_data ;
+    buffer->ops->get_size  = oxs_buffer_get_size ;
+    buffer->ops->get_max_size  = oxs_buffer_get_max_size ;
+}
+
+AXIS2_EXTERN oxs_buffer_t *AXIS2_CALL
+oxs_buffer_create(const axis2_env_t *env)
 {
-    oxs_buffer_ptr buf = NULL;
-    buf = (oxs_buffer_ptr)AXIS2_MALLOC(env->allocator,sizeof(oxs_buffer));
-   
-    buf = oxs_buffer_initialize(env, buf, size); 
-    
-    return buf;
-}
-
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_buffer_initialize(const axis2_env_t *env ,oxs_buffer_ptr buf,  unsigned int size)
-{
-    int ret;
-    buf->data = NULL;
-    buf->size = 0;
-    buf->max_size = 0;
-    buf->alloc_mode = oxs_alloc_mode_double;
-    
-    ret = oxs_buffer_set_max_size(env, buf, size);
-    if(ret<0){
+    oxs_buffer_impl_t *buffer_impl = NULL;
+    axis2_status_t status = AXIS2_FAILURE;
+
+    AXIS2_ENV_CHECK(env, NULL);
+
+    buffer_impl = AXIS2_MALLOC( env->allocator, sizeof(oxs_buffer_impl_t));
+    if (!buffer_impl)
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        return NULL;
+    }
+
+    buffer_impl->data = NULL;
+    buffer_impl->size = 0;
+    buffer_impl->max_size = 0;
+    buffer_impl->alloc_mode = oxs_alloc_mode_double;
+
+    status = oxs_buffer_set_max_size(&(buffer_impl->buffer), env, OXS_BUFFER_INITIAL_SIZE);
+    if(status == AXIS2_FAILURE){
         oxs_error(ERROR_LOCATION, OXS_ERROR_DEFAULT,
                      "oxs_buffer_set_max_size");
         return NULL;
     }
-    return buf;
-    
+
+
+    buffer_impl->buffer.ops =  AXIS2_MALLOC(env->allocator,sizeof(oxs_buffer_ops_t));
+    if (!buffer_impl->buffer.ops)
+    {
+        AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        oxs_buffer_free(&(buffer_impl->buffer), env);
+        return NULL;
+    }
+
+    oxs_buffer_init_ops(&(buffer_impl->buffer));
+
+    return &(buffer_impl->buffer);
+
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_free_buffer(const axis2_env_t *env, oxs_buffer_ptr buf)
+axis2_status_t AXIS2_CALL
+oxs_buffer_free(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                )
 {
-    if(!buf){
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "oxs_free_buffer failed");
-        return (-1);
-    }   
- 
-    AXIS2_FREE(env->allocator, buf->data);
-    buf->data = NULL;
-    buf->size = 0;
-    buf->max_size = 0;
-    
-    AXIS2_FREE(env->allocator, buf);
-    buf = NULL;
-    return (0);
-}
-
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_remove_head(const axis2_env_t *env,
-        oxs_buffer_ptr buf, unsigned int size)
+    oxs_buffer_impl_t *buffer_impl= NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
+
+    if(buffer_impl->data ){
+        AXIS2_FREE(env->allocator,  buffer_impl->data);
+        buffer_impl->data = NULL;
+    }
+
+    AXIS2_FREE(env->allocator,  buffer_impl);
+    buffer_impl = NULL;
+
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+oxs_buffer_remove_head(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                )
 {
-    if(size < buf->size) {
-        if(buf->data != NULL){
+    oxs_buffer_impl_t *buffer_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
+   
+    /*If the size to be removed is less than the buffer size*/ 
+    if(size < buffer_impl->size) {
+        if(buffer_impl->data != NULL){
             oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "oxs_buffer_remove_head failed"); 
-            return  (-1);
+                     "oxs_buffer_remove_head failed");
+            return  AXIS2_FAILURE;
         }
-        buf->size -= size;
-        memmove(buf->data, buf->data + size, buf->size);
+        buffer_impl->size -= size;
+        memmove(buffer_impl->data, buffer_impl->data + size, buffer_impl->size);
     } else {
-        buf->size = 0;
+        buffer_impl->size = 0;
     }
 
-    if(buf->size < buf->max_size) {
-        if(buf->data != NULL){
+    /*If the buffer size is less than the max_size.*/
+    if(buffer_impl->size < buffer_impl->max_size) {
+        if(buffer_impl->data != NULL){
              oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "oxs_buffer_remove_head failed");
-             return  (-1);
+             return  AXIS2_FAILURE;
         }
-        memset(buf->data + buf->size, 0, buf->max_size - buf->size);
+        memset(buffer_impl->data + buffer_impl->size, 0, buffer_impl->max_size - buffer_impl->size);
     }
-    return(0);
 
+    return AXIS2_SUCCESS;
 }
-AXIS2_EXTERN axis2_status_t AXIS2_CALL
-oxs_buffer_remove_tail(const axis2_env_t *env, 
-        oxs_buffer_ptr buf,unsigned int size)
+
+axis2_status_t AXIS2_CALL
+oxs_buffer_remove_tail(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                )
 {
+    oxs_buffer_impl_t *buffer_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
-    if(size < buf->size) {
-        buf->size -= size;
+    if(size < buffer_impl->size) {
+        buffer_impl->size -= size;
     } else {
-        buf->size = 0;
+        buffer_impl->size = 0;
     }
-    if(buf->size < buf->max_size) {
-        if(buf->data != NULL){
+    if(buffer_impl->size < buffer_impl->max_size) {
+        if(buffer_impl->data != NULL){
             oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     ""); 
-            return  (-1);
+                     "");
+            return  AXIS2_FAILURE;
         }
-        memset(buf->data + buf->size, 0, buf->max_size - buf->size);
+        memset(buffer_impl->data + buffer_impl->size, 0, buffer_impl->max_size - buffer_impl->size);
     }
-    return(0);
-}
 
-AXIS2_EXTERN oxs_buffer_ptr AXIS2_CALL
-oxs_string_to_buffer(const axis2_env_t *env, axis2_char_t* string)
-{
-    oxs_buffer_ptr buf = NULL;
-    unsigned int size ;
-    unsigned char* data = NULL;
- 
-    if(!string){
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");     
-        return NULL;
-    }
-    size =(unsigned int) AXIS2_STRLEN(string);
-    data = (unsigned char*)AXIS2_STRDUP(string, env);
-    
-    buf = oxs_create_buffer(env, size);        
-    buf->data = data;
-    buf->size = size;
-    /*buf->max_size = size;*/
-    buf->alloc_mode = oxs_alloc_mode_double;
- 
-    return buf; 
+
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN axis2_char_t* AXIS2_CALL
-oxs_buffer_to_string(const axis2_env_t *env, oxs_buffer_ptr buf)
+axis2_status_t AXIS2_CALL
+oxs_buffer_populate(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                )
 {
-    axis2_char_t* string;
-    
-    if(!buf){
-         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");        
-         return NULL;
+    oxs_buffer_impl_t *buffer_impl = NULL;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
+
+    if(size > 0) {
+        oxs_buffer_set_max_size( &(buffer_impl->buffer), env, size);
+        if(!data){
+            oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
+                     "data is NULL");
+            return AXIS2_FAILURE;
+        }
+
+        memcpy(buffer_impl->data, data, size);
+        buffer_impl->size = size;
     }
-    
-    string = (axis2_char_t*)buf->data;
-    return string;
 
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_append(const axis2_env_t *env,
-        oxs_buffer_ptr buf, unsigned char* data, unsigned int size)
+axis2_status_t AXIS2_CALL
+oxs_buffer_append(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                )
 {
+    oxs_buffer_impl_t *buffer_impl = NULL;
 
-    if(!buf){
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-        return(-1);
-    }
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
     if(size > 0) {
-        oxs_buffer_set_max_size(env, buf, buf->size + size);
+        oxs_buffer_set_max_size( &(buffer_impl->buffer), env,  buffer_impl->size + size);
         if(!data){
             oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-            return (-1);
+                     "data is NULL");
+            return AXIS2_FAILURE;
         }
 
-        memcpy(buf->data + buf->size, data, size);
-        buf->size += size;
+        memcpy(buffer_impl->data + buffer_impl->size, data, size);
+        buffer_impl->size += size;
     }
 
-    return(0);
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_prepend(const axis2_env_t *env,
-        oxs_buffer_ptr buf, unsigned char* data, unsigned int size)
+axis2_status_t AXIS2_CALL
+oxs_buffer_prepend(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    unsigned char *data,
+                    int size
+                )
 {
+    oxs_buffer_impl_t *buffer_impl = NULL;
 
-    if(!buf){
-         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");        
-         return (-1);
-    }
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
     if(size > 0) {
         if(!data) {
             oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-            return (-1);
+                     "Passed data is NULL");
+            return AXIS2_FAILURE;
         }
 
-        buf->max_size = buf->size + size;
+        buffer_impl->max_size = buffer_impl->size + size;
 
-        memmove(buf->data + size, buf->data, buf->size);
-        memcpy(buf->data, data, size);
-        buf->size += size;
+        memmove(buffer_impl->data + size, buffer_impl->data, buffer_impl->size);
+        memcpy(buffer_impl->data, data, size);
+        buffer_impl->size += size;
     }
 
-    return(0);
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_set_size(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size)
+axis2_status_t AXIS2_CALL
+oxs_buffer_read_file(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    const axis2_char_t *filename
+                )
 {
-    int ret;
+    oxs_buffer_impl_t *buffer_impl = NULL;
+    unsigned char fbuffer[1024];
+    FILE* f;
+    int  len;
+    axis2_status_t status = AXIS2_FAILURE;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
-    if(buf == NULL){
+
+    f = fopen(filename, "rb");
+    if(f == NULL) {
         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "buffer is NULL");
-         return (-1);
+                     "");
+        return AXIS2_FAILURE;
     }
-    ret = oxs_buffer_set_max_size(env, buf, size);
-    if(ret < 0) {
+
+    while(1)
+    {
+        len = fread(fbuffer, 1, sizeof(fbuffer), f);
+        if(len == 0){
+            break; /*Stop reading*/
+        }else if(len < 0){
+            fclose(f);
+            return AXIS2_FAILURE;
+        }
+        status = oxs_buffer_append( &(buffer_impl->buffer), env, fbuffer, len);
+        if(status == AXIS2_FAILURE){
+            fclose(f);
+            oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
+                     "");
+            return AXIS2_FAILURE;
+        }
+
+        /*Alright so far everything is fine. So let's close the output*/
+        fclose(f);
+        return AXIS2_SUCCESS;
+    }/*End of while*/
+
+    return AXIS2_SUCCESS;
+}
+
+axis2_status_t AXIS2_CALL
+oxs_buffer_set_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                )
+{
+    oxs_buffer_impl_t *buffer_impl = NULL;
+    axis2_status_t status = AXIS2_FAILURE;
+
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
+
+    /*First we need to make sure that the max size has a value greater or equal value*/
+    status = oxs_buffer_set_max_size( buffer, env,  size);
+    if(status == AXIS2_FAILURE) {
         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "oxs_buffer_set_max_size failed");
-        return(-1);
+        return AXIS2_FAILURE;
     }
-    buf->size = size;
-    return(0);
+    /*Now set the size*/
+    buffer_impl->size = size;
+
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_set_max_size(const axis2_env_t *env, oxs_buffer_ptr buf, unsigned int size)
+axis2_status_t AXIS2_CALL
+oxs_buffer_set_max_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env,
+                    int size
+                )
 {
+    oxs_buffer_impl_t *buffer_impl = NULL;
     unsigned char* new_data;
     unsigned int new_size = 0;
 
-    if(buf == NULL) {
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-        return (-1);
-    }
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
-    if(size <= buf->max_size) {
-       return(0);
+    if(size <= buffer_impl->max_size) {
+       return AXIS2_SUCCESS;
     }
 
-    switch(buf->alloc_mode) {
+    switch(buffer_impl->alloc_mode) {
     case oxs_alloc_mode_exact:
         new_size = size + 8;
         break;
@@ -260,13 +469,13 @@
         break;
     }
 
-    if(new_size < g_initial_size) {
-       new_size = g_initial_size;
+    if(new_size < OXS_BUFFER_INITIAL_SIZE) {
+       new_size = OXS_BUFFER_INITIAL_SIZE;
     }
 
-
-    if(buf->data != NULL) {
-        new_data = (unsigned char*)AXIS2_REALLOC(env->allocator, buf->data, new_size);
+    /*If there are data already then use realloc instead of malloc*/
+    if(buffer_impl->data != NULL) {
+        new_data = (unsigned char*)AXIS2_REALLOC(env->allocator, buffer_impl->data, new_size);
     } else {
         new_data = (unsigned char*)AXIS2_MALLOC(env->allocator, new_size);
     }
@@ -274,99 +483,63 @@
     if(new_data == NULL) {
         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "");
-        return(-1);
+        return AXIS2_FAILURE;
     }
 
-    buf->data = new_data;
-    buf->max_size = new_size;
+    buffer_impl->data = new_data;
+    buffer_impl->max_size = new_size;
 
-    if(buf->size < buf->max_size) {
-        if(buf->data == NULL){
+    if(buffer_impl->size < buffer_impl->max_size) {
+        if(buffer_impl->data == NULL){
             oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "");
-             return (-1);
+             return AXIS2_FAILURE;
         }
-        memset(buf->data + buf->size, 0, buf->max_size - buf->size);
+        memset(buffer_impl->data + buffer_impl->size, 0, buffer_impl->max_size - buffer_impl->size);
     }
 
-    return(0);
-
+    return AXIS2_SUCCESS;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_read_file(const axis2_env_t *env, oxs_buffer_ptr buf, const char* filename)
+unsigned char* AXIS2_CALL
+oxs_buffer_get_data(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                )
 {
-    unsigned char buffer[1024];
-    FILE* f;
-    int ret, len;
+    oxs_buffer_impl_t *buffer_impl = NULL;
 
-    f = fopen(filename, "rb");
-    if(f == NULL) {
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-        return (-1);
-    }
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
-    while(1)
-    {
-        len = fread(buffer, 1, sizeof(buffer), f);
-        if(len == 0){
-            break; /*Stop reading*/
-        }else if(len < 0){
-            fclose(f);
-            return(-1);
-        }
-        ret = oxs_buffer_append(env, buf, buffer, len);
-        if(ret < 0){
-            fclose(f);
-            oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-            return (-1);
-        }
-       
-        /*Alright so far everything is fine. So let's close the output*/
-        fclose(f);
-        return (0); 
-    }/*End of while*/
-    return(0);
+    return buffer_impl->data;
 }
 
-AXIS2_EXTERN int AXIS2_CALL
-oxs_buffer_base64_node_content_read(const axis2_env_t *env, oxs_buffer_ptr buf, axiom_node_t *node)
+int AXIS2_CALL
+oxs_buffer_get_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                )
 {
-    axis2_char_t *content = NULL;
-    axis2_char_t *decoded_str = NULL;
-    int ret;
-    unsigned int length;
-        
-    content = oxs_axiom_get_node_content(env, node);    
-    if(content == NULL) {
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-        return (-1);
-    }
-   
-    ret = oxs_buffer_set_max_size(env, buf, AXIS2_STRLEN(content));
-    if(ret < 0)  {
-        oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
-                     "");
-        return(-1);
-    }
+    oxs_buffer_impl_t *buffer_impl = NULL;
 
-    /*OK. Now decode*/
-    /*axis2_base64_decode(plain, encoded)*/
-    length = axis2_base64_decode(decoded_str, content); 
-    if(length < 0 ) return (-1);
-    
-    /*Store data in the buffer*/    
-    buf->data = (unsigned char*)decoded_str;
-    buf->size = length;
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
-    return (0);  
+    return buffer_impl->size;
 }
 
-  
-
+int AXIS2_CALL
+oxs_buffer_get_max_size(
+                    oxs_buffer_t *buffer,
+                    const axis2_env_t *env
+                )
+{
+    oxs_buffer_impl_t *buffer_impl = NULL;
 
+    AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
+    buffer_impl = AXIS2_INTF_TO_IMPL(buffer);
 
+    return buffer_impl->max_size;
+}
 

Modified: webservices/axis2/trunk/c/rampart/src/omxmlsec/enc_engine.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/omxmlsec/enc_engine.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/omxmlsec/enc_engine.c (original)
+++ webservices/axis2/trunk/c/rampart/src/omxmlsec/enc_engine.c Sun Sep 10 21:07:30 2006
@@ -73,16 +73,16 @@
 oxs_enc_engine_prvkey_decrypt_data(
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env,
-    oxs_buffer_ptr input,
-    oxs_buffer_ptr result,
+    oxs_buffer_t * input,
+    oxs_buffer_t * result,
     axis2_char_t *filename);
 
 axis2_status_t AXIS2_CALL 
 oxs_enc_engine_pubkey_encrypt_data(
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env,
-    oxs_buffer_ptr input,
-    oxs_buffer_ptr result,
+    oxs_buffer_t * input,
+    oxs_buffer_t * result,
     axis2_char_t *filename);
 
 axis2_status_t AXIS2_CALL 
@@ -98,15 +98,15 @@
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env,
     oxs_ctx_t * enc_ctx,
-    oxs_buffer_ptr input,
-    oxs_buffer_ptr result);
+    oxs_buffer_t * input,
+    oxs_buffer_t * result);
 
 axis2_status_t AXIS2_CALL 
 oxs_enc_engine_populate_cipher_value(
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env,
     axiom_node_t* template_node,
-    oxs_buffer_ptr databuf);
+    oxs_buffer_t * databuf);
 
 axis2_status_t AXIS2_CALL 
 oxs_enc_engine_decrypt_template(
@@ -204,10 +204,14 @@
         oxs_key_t *prv_key,
         oxs_key_t *session_key)
 {
-    axis2_char_t *key_enc_algo = NULL, *encrypted_key_value = NULL;
-    axiom_node_t *enc_method_node = NULL, *cd_node = NULL, *cv_node = NULL;
+    axis2_char_t *key_enc_algo = NULL;
+    axis2_char_t *encrypted_key_value = NULL;
+    axiom_node_t *enc_method_node = NULL;
+    axiom_node_t *cd_node = NULL;
+    axiom_node_t *cv_node = NULL;
     axis2_status_t status = AXIS2_FAILURE;
-    oxs_buffer_ptr encrypted_key_buf = NULL, decrypted_key_buf = NULL;
+    oxs_buffer_t *encrypted_key_buf = NULL;
+    oxs_buffer_t *decrypted_key_buf = NULL;
     oxs_enc_engine_impl_t *enc_engine_impl = NULL;
 
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
@@ -221,7 +225,7 @@
         return AXIS2_FAILURE;
     }
 
-    enc_method_node = oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeEncryptionMethod, NULL, NULL);
+    enc_method_node = (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeEncryptionMethod, NULL, NULL);
     if(!enc_method_node){
         oxs_error(ERROR_LOCATION, OXS_ERROR_DECRYPT_FAILED,
             "Cannot find EncryptionMethodElement");
@@ -234,14 +238,14 @@
         key_enc_algo = OXS_DEFAULT_KT_ALGO_HREF;
     }
 
-    cd_node = oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeCipherData, NULL, NULL);
+    cd_node = (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeCipherData, NULL, NULL);
     if(!cd_node){
         oxs_error(ERROR_LOCATION, OXS_ERROR_DECRYPT_FAILED,
             "Cannot find CipherData element");
         return AXIS2_FAILURE;
     }
 
-    cv_node = oxs_axiom_get_first_child_node_by_name(env, cd_node, OXS_NodeCipherValue, NULL, NULL);
+    cv_node = (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, cd_node, OXS_NodeCipherValue, NULL, NULL);
     if(!cv_node){
         oxs_error(ERROR_LOCATION, OXS_ERROR_DECRYPT_FAILED,
             "Cannot find CipherValue element");
@@ -251,9 +255,11 @@
     encrypted_key_value = (axis2_char_t*)oxs_token_get_cipher_value(env, cv_node);
 
     /*Create buffers for decryption*/
-    encrypted_key_buf = oxs_create_buffer(env, AXIS2_STRLEN(encrypted_key_value));
-    encrypted_key_buf->data = (unsigned char *)encrypted_key_value;
-    decrypted_key_buf = oxs_create_buffer(env, OXS_BUFFER_INITIAL_SIZE);
+    encrypted_key_buf = oxs_buffer_create(env);
+    status = OXS_BUFFER_POPULATE(encrypted_key_buf, env, 
+                                    (unsigned char *)encrypted_key_value,
+                                    AXIS2_STRLEN(encrypted_key_value));
+    decrypted_key_buf = oxs_buffer_create(env);
 
     /*Decrypt the encrypted key*/
     status  = oxs_enc_engine_prvkey_decrypt_data(enc_engine, env, encrypted_key_buf, decrypted_key_buf, OXS_KEY_GET_NAME(prv_key, env));  
@@ -263,8 +269,8 @@
         return AXIS2_FAILURE;
     }
     /*Trim data to the key size*/
-    OXS_KEY_SET_DATA(session_key, env,(axis2_char_t*) decrypted_key_buf->data);
-    OXS_KEY_SET_SIZE(session_key, env, decrypted_key_buf->size);
+    OXS_KEY_SET_DATA(session_key, env, OXS_BUFFER_GET_DATA(decrypted_key_buf, env));
+    OXS_KEY_SET_SIZE(session_key, env, OXS_BUFFER_GET_SIZE(decrypted_key_buf, env));
     OXS_KEY_SET_USAGE(session_key, env, OXS_KEY_USAGE_DECRYPT);
     
     return AXIS2_SUCCESS;
@@ -276,8 +282,8 @@
 oxs_enc_engine_prvkey_decrypt_data(
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env, 
-    oxs_buffer_ptr input, 
-    oxs_buffer_ptr result, 
+    oxs_buffer_t *input, 
+    oxs_buffer_t *result, 
     axis2_char_t *filename)
 {
     openssl_pkey_t *pkey = NULL;
@@ -292,8 +298,8 @@
     enc_engine_impl = AXIS2_INTF_TO_IMPL(enc_engine);
 
     /*First do base64 decode*/
-    decoded_encrypted_str = AXIS2_MALLOC(env->allocator, axis2_base64_decode_len( (char*)(input->data)));
-    ret = axis2_base64_decode(decoded_encrypted_str, (char*)(input->data));
+    decoded_encrypted_str = AXIS2_MALLOC(env->allocator, axis2_base64_decode_len( (char*)OXS_BUFFER_GET_DATA(input, env)));
+    ret = axis2_base64_decode(decoded_encrypted_str, (char*)OXS_BUFFER_GET_DATA(input, env));
    
     printf("oxs_enc_engine_prvkey_decrypt_data\n"); 
     /*Create a private key*/
@@ -316,8 +322,7 @@
          return AXIS2_FAILURE;
     }
 
-    result->data = decrypted;
-    result->size = declen;
+    status = OXS_BUFFER_POPULATE(result, env, (unsigned char*)decrypted, declen);
     
     return AXIS2_SUCCESS;
 }
@@ -328,8 +333,8 @@
 oxs_enc_engine_pubkey_encrypt_data(
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env, 
-    oxs_buffer_ptr input, 
-    oxs_buffer_ptr result, 
+    oxs_buffer_t *input, 
+    oxs_buffer_t *result, 
     axis2_char_t *filename )
 {
     openssl_pkey_t *pkey = NULL;
@@ -356,7 +361,7 @@
     }
     /*Now we support only rsa*/
     rsa = openssl_rsa_create(env);
-    ret = OPENSSL_RSA_PUB_ENCRYPT(rsa, env, pkey, input->data, &encrypted);
+    ret = OPENSSL_RSA_PUB_ENCRYPT(rsa, env, pkey, OXS_BUFFER_GET_DATA(input, env), &encrypted);
     if(ret < 0 ){
          oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "openssl_rsa_pub_encrypt");
@@ -376,8 +381,7 @@
     }
 
     /*Attach the result to the result buf*/
-    result->size = encodedlen;
-    result->data = (unsigned char*)AXIS2_STRDUP(encoded_str, env);
+    status = OXS_BUFFER_POPULATE(result, env, (unsigned char*)AXIS2_STRDUP(encoded_str, env), encodedlen);
 
     return AXIS2_SUCCESS;
 }
@@ -390,8 +394,8 @@
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env, 
     oxs_ctx_t * enc_ctx,
-    oxs_buffer_ptr input,
-    oxs_buffer_ptr result)
+    oxs_buffer_t *input,
+    oxs_buffer_t *result)
 {
     unsigned char *out_main_buf = NULL;
     openssl_cipher_ctx_t *oc_ctx = NULL;
@@ -459,7 +463,9 @@
     /*If this is to encrypt we simply pass the data to crypto function*/
     if(OXS_CTX_GET_OPERATION(enc_ctx, env) == OXS_CTX_OPERATION_ENCRYPT){
         enclen = openssl_block_cipher_crypt(env, oc_ctx,
-                                         input->data, strlen((char*)input->data),  &out_main_buf, OPENSSL_ENCRYPT);
+                                         OXS_BUFFER_GET_DATA(input, env), 
+                                         OXS_BUFFER_GET_SIZE(input, env),  
+                                         &out_main_buf, OPENSSL_ENCRYPT);
     
     /*If this is to decrypt, then we need to base64decode first*/
     }else if(OXS_CTX_GET_OPERATION(enc_ctx, env) == OXS_CTX_OPERATION_DECRYPT){
@@ -505,11 +511,10 @@
         }
     
         /*Attach the result to the result buf*/    
-        result->size = encodedlen;
-        result->data = (unsigned char*)AXIS2_STRDUP(encoded_str, env);
+        ret = OXS_BUFFER_POPULATE(result, env, (unsigned char*)AXIS2_STRDUP(encoded_str, env), encodedlen);
+
     }else if(OXS_CTX_GET_OPERATION(enc_ctx, env) == OXS_CTX_OPERATION_DECRYPT){
-        result->size = enclen;
-        result->data = AXIS2_STRMEMDUP(out_main_buf, enclen, env);
+        ret = OXS_BUFFER_POPULATE(result, env, AXIS2_STRMEMDUP(out_main_buf, enclen, env), enclen);        
     
     }else{
         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
@@ -526,7 +531,7 @@
     oxs_enc_engine_t *enc_engine,
     const axis2_env_t *env,
     axiom_node_t* template_node,
-    oxs_buffer_ptr databuf)
+    oxs_buffer_t *databuf)
 {
     axis2_status_t ret = AXIS2_FAILURE;
     axiom_element_t *template_ele = NULL, *cv_ele = NULL, *cd_ele = NULL;
@@ -570,7 +575,7 @@
     }
     
 
-    ret =  AXIOM_ELEMENT_SET_TEXT(cv_ele, env, (axis2_char_t *)databuf->data , cv_node); 
+    ret =  AXIOM_ELEMENT_SET_TEXT(cv_ele, env, (axis2_char_t *)OXS_BUFFER_GET_DATA(databuf, env) , cv_node); 
     if(ret != AXIS2_SUCCESS){
         oxs_error(ERROR_LOCATION, OXS_ERROR_INVALID_DATA,
                      "Cannot set data to the CipherValue element");
@@ -590,8 +595,8 @@
     )
 {
     axis2_status_t  ret =  AXIS2_FAILURE;
-    oxs_buffer_ptr input = NULL;
-    oxs_buffer_ptr result = NULL;
+    oxs_buffer_t *input = NULL;
+    oxs_buffer_t *result = NULL;
     oxs_enc_engine_impl_t *enc_engine_impl = NULL;
 
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
@@ -609,12 +614,12 @@
     }
 
     /*Now look for data to be decrypted*/
-    input = oxs_create_buffer(env, OXS_BUFFER_INITIAL_SIZE);
-    input->data = (unsigned char *)OXS_CTX_GET_INPUT_DATA(enc_ctx, env);
-    input->size = AXIS2_STRLEN(OXS_CTX_GET_INPUT_DATA(enc_ctx, env));
+    input = oxs_buffer_create(env);
+    ret  = OXS_BUFFER_POPULATE(input, env, (unsigned char *)OXS_CTX_GET_INPUT_DATA(enc_ctx, env), 
+                                     AXIS2_STRLEN(OXS_CTX_GET_INPUT_DATA(enc_ctx, env))); 
 
     /*Initialize the result buffer*/
-    result = oxs_create_buffer(env, OXS_BUFFER_INITIAL_SIZE);
+    result = oxs_buffer_create(env);
 
     ret = oxs_enc_engine_crypt(enc_engine, env, enc_ctx, input,  result ); 
     if(ret != AXIS2_SUCCESS){
@@ -623,9 +628,8 @@
         return ret;
     }
 
-    *decrypted_data =   AXIS2_MALLOC(env->allocator,result->size); 
-    *decrypted_data =  (axis2_char_t*)result->data;
-
+    *decrypted_data =   AXIS2_MALLOC(env->allocator,OXS_BUFFER_GET_SIZE(result, env)); 
+    *decrypted_data =  (axis2_char_t*)OXS_BUFFER_GET_DATA(result, env);
        
     return ret;
 }
@@ -642,8 +646,8 @@
     )
 {
     axis2_status_t  ret =  AXIS2_FAILURE;
-    oxs_buffer_ptr input = NULL;
-    oxs_buffer_ptr result = NULL;
+    oxs_buffer_t *input = NULL;
+    oxs_buffer_t *result = NULL;
     oxs_enc_engine_impl_t *enc_engine_impl = NULL;
 
     AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
@@ -664,8 +668,10 @@
     /*We've populated the context*/
     
     /*Create the input buffer*/
-    input = oxs_string_to_buffer(env, data);
-    result = oxs_create_buffer(env, OXS_BUFFER_INITIAL_SIZE);
+    input = oxs_buffer_create(env);
+    ret =  OXS_BUFFER_POPULATE(input, env, (unsigned char *)data, AXIS2_STRLEN(data));
+    
+    result = oxs_buffer_create(env);
      
     ret = oxs_enc_engine_crypt(enc_engine, env, enc_ctx, input, result ); 
     if(ret != AXIS2_SUCCESS){

Modified: webservices/axis2/trunk/c/rampart/src/omxmlsec/key.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/omxmlsec/key.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/omxmlsec/key.c (original)
+++ webservices/axis2/trunk/c/rampart/src/omxmlsec/key.c Sun Sep 10 21:07:30 2006
@@ -26,7 +26,7 @@
 typedef struct oxs_key_impl{
     oxs_key_t key;
 
-    axis2_char_t *data;
+    unsigned char *data;
     axis2_char_t *name;
     int            size;
     int            usage;
@@ -44,7 +44,7 @@
     oxs_key_t *key);
 
 /*Public functions*/
-axis2_char_t *AXIS2_CALL
+unsigned char *AXIS2_CALL
 oxs_key_get_data(
     const oxs_key_t *key,
     const axis2_env_t *env);
@@ -68,7 +68,7 @@
 oxs_key_set_data(
     oxs_key_t *key,
     const axis2_env_t *env,
-    axis2_char_t *data);
+    unsigned char *data);
 
 axis2_status_t AXIS2_CALL
 oxs_key_set_name(
@@ -98,7 +98,7 @@
 oxs_key_populate(
         oxs_key_t *key,
         const axis2_env_t *env,
-        axis2_char_t *data,
+        unsigned char *data,
         axis2_char_t *name,
         int size,
         int usage);
@@ -116,7 +116,7 @@
 
 /******************** end of function headers *****************/
 
-axis2_char_t *AXIS2_CALL
+unsigned char *AXIS2_CALL
 oxs_key_get_data(
     const oxs_key_t *key,
     const axis2_env_t *env)
@@ -173,7 +173,7 @@
 oxs_key_set_data(
     oxs_key_t *key,
     const axis2_env_t *env,
-    axis2_char_t *data)
+    unsigned char *data)
 {
     oxs_key_impl_t *oxs_key_impl = NULL;
 
@@ -184,7 +184,7 @@
         AXIS2_FREE(env->allocator, oxs_key_impl->data);
         oxs_key_impl->data = NULL;
     }
-    oxs_key_impl->data = (axis2_char_t *)data;
+    oxs_key_impl->data = data;
     return AXIS2_SUCCESS;
 
 }
@@ -318,7 +318,7 @@
 axis2_status_t AXIS2_CALL
 oxs_key_populate(oxs_key_t *key,
         const axis2_env_t *env,
-        axis2_char_t *data,
+        unsigned char *data,
         axis2_char_t *name,
         int size,
         int usage)
@@ -339,16 +339,17 @@
         const axis2_env_t *env,
         axis2_char_t *file_name)
 {
-    oxs_buffer_ptr buf = NULL;
-    axis2_status_t ret;
-    int reti;
+    oxs_buffer_t *buf = NULL;
+    axis2_status_t status = AXIS2_FAILURE;
  
-    buf = oxs_create_buffer(env, OXS_KEY_DEFAULT_SIZE);
-    reti = oxs_buffer_read_file(env, buf, file_name);
+    buf = oxs_buffer_create(env);
+    status = oxs_buffer_read_file(env, buf, file_name);
    
-    ret = OXS_KEY_POPULATE(key, env, (axis2_char_t*)buf->data, file_name,  buf->size, OXS_KEY_USAGE_NONE);
+    status = OXS_KEY_POPULATE(key, env,
+                            OXS_BUFFER_GET_DATA(buf, env), file_name,  
+                            OXS_BUFFER_GET_SIZE(buf, env), OXS_KEY_USAGE_NONE);
      
-    return ret; 
+    return status; 
     
 }
 
@@ -357,12 +358,13 @@
         const axis2_env_t *env,
         axis2_char_t *key_algo)
 {
-    oxs_buffer_ptr key_buf = NULL;
+    oxs_buffer_t *key_buf = NULL;
     openssl_cipher_property_t * cprop = NULL;
     axis2_status_t ret = AXIS2_FAILURE;
     int size;
-    
-    
+    unsigned char *temp_str = NULL;
+    int temp_int = 0;   
+ 
     cprop = (openssl_cipher_property_t *)oxs_get_cipher_property_for_url(env, key_algo);
     if(!cprop){
         oxs_error(ERROR_LOCATION, OXS_ERROR_ENCRYPT_FAILED,
@@ -372,15 +374,21 @@
 
     size = OPENSSL_CIPHER_PROPERTY_GET_KEY_SIZE(cprop, env);
 
-    key_buf = oxs_create_buffer(env, size);    
+    key_buf = oxs_buffer_create(env);    
     ret = generate_random_data(env, key_buf, size);    
     if(ret == AXIS2_FAILURE){
          oxs_error(ERROR_LOCATION, OXS_ERROR_ENCRYPT_FAILED,
             "generate_random_data failed");
          return AXIS2_FAILURE;
     }
-    
-    ret = OXS_KEY_POPULATE(key, env,(axis2_char_t*) key_buf->data, NULL, key_buf->size, OXS_KEY_USAGE_NONE);
+   
+    temp_int = OXS_BUFFER_GET_SIZE(key_buf, env);
+    temp_str = OXS_BUFFER_GET_DATA(key_buf, env);
+     
+    ret = OXS_KEY_POPULATE(key, env, 
+                            OXS_BUFFER_GET_DATA(key_buf, env), NULL, 
+                            OXS_BUFFER_GET_SIZE(key_buf, env), OXS_KEY_USAGE_NONE);
 
+    /*free buffer*/
     return ret;
 }

Modified: webservices/axis2/trunk/c/rampart/src/omxmlsec/openssl/util.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/omxmlsec/openssl/util.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/omxmlsec/openssl/util.c (original)
+++ webservices/axis2/trunk/c/rampart/src/omxmlsec/openssl/util.c Sun Sep 10 21:07:30 2006
@@ -26,27 +26,21 @@
 
 
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
-generate_random_data(const axis2_env_t *env, oxs_buffer_ptr buf, int size)
+generate_random_data(const axis2_env_t *env, oxs_buffer_t *buffer, int size)
 {
+    axis2_status_t status =  AXIS2_FAILURE;
     int ret;
-    ret = oxs_buffer_set_size(env, buf, size);
-    if(ret < 0){
-        oxs_error(ERROR_LOCATION,
-                OXS_ERROR_DEFAULT, "oxs_buffer_set_size failed %d",size );
-        return AXIS2_FAILURE;
-    }
-    ret = RAND_bytes(buf->data, size);
+    unsigned char temp_buffer[1024];
+    
+    ret = RAND_bytes(temp_buffer, size);
     if(ret < 0){
         oxs_error(ERROR_LOCATION,
                 OXS_ERROR_DEFAULT, "RAND_bytes failed %d",size );
         return AXIS2_FAILURE;
     }
-/**************REMOVE TODO***/
-#if 1
-    buf->data = (unsigned char *)"012345670123456701234567";
-    buf->size = 24;
-#endif
-/***************************/
+
+    status = OXS_BUFFER_POPULATE(buffer, env, temp_buffer, size);
+
     return AXIS2_SUCCESS;
 }
 

Modified: webservices/axis2/trunk/c/rampart/src/util/rampart_crypto_engine.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/rampart/src/util/rampart_crypto_engine.c?view=diff&rev=442087&r1=442086&r2=442087
==============================================================================
--- webservices/axis2/trunk/c/rampart/src/util/rampart_crypto_engine.c (original)
+++ webservices/axis2/trunk/c/rampart/src/util/rampart_crypto_engine.c Sun Sep 10 21:07:30 2006
@@ -163,7 +163,8 @@
     axis2_char_t *str_to_enc = NULL;
     oxs_ctx_t * enc_ctx = NULL;
     oxs_key_t *sessionkey = NULL;
-    oxs_buffer_ptr session_key_buf_plain = NULL, session_key_buf_encrypted = NULL;    
+    oxs_buffer_t *session_key_buf_plain = NULL;
+    oxs_buffer_t *session_key_buf_encrypted = NULL;    
     axis2_char_t* uuid = NULL;
     oxs_enc_engine_t *enc_engine = NULL;
     rampart_crypto_engine_impl_t *engine_impl = NULL;
@@ -185,6 +186,7 @@
     ret = OXS_KEY_SET_NAME(sessionkey, env, "sessionkey");
     ret = OXS_KEY_SET_USAGE(sessionkey, env, OXS_KEY_USAGE_ENCRYPT);
 
+    /*printf("\nSession Key is %s", OXS_KEY_GET_DATA(sessionkey,env));    */
 
     body = AXIOM_SOAP_ENVELOPE_GET_BODY(soap_envelope, env);
     body_node = AXIOM_SOAP_BODY_GET_BASE_NODE(body, env);
@@ -222,7 +224,7 @@
     OXS_CTX_SET_KEY(enc_ctx, env, sessionkey);
 
 
-    printf("\nSession_key for encryption = %s\n", OXS_KEY_GET_DATA(sessionkey, env));
+    /*printf("\nSession_key for encryption = %s\n", OXS_KEY_GET_DATA(sessionkey, env));*/
     printf("\nString for encryption = %s\n", str_to_enc);
 
     /*Hand the template over to OMXMLSEC*/
@@ -238,8 +240,12 @@
 
     /*Here u have the public key file name or the key store name. Right now we support only the key file name. 
      The meaning is totally wrong but for the moment we have to live with this*/
-    session_key_buf_plain = oxs_string_to_buffer(env, OXS_KEY_GET_DATA(sessionkey, env));
-    session_key_buf_encrypted = oxs_create_buffer(env, (int)OXS_BUFFER_INITIAL_SIZE);
+    session_key_buf_plain = oxs_buffer_create(env);
+    ret = OXS_BUFFER_POPULATE(session_key_buf_plain, env,
+                                OXS_KEY_GET_DATA(sessionkey, env),
+                                 OXS_KEY_GET_SIZE(sessionkey, env));
+
+    session_key_buf_encrypted = oxs_buffer_create(env);
     ret = OXS_ENC_ENGINE_PUB_KEY_ENCRYPT_DATA(enc_engine, env, session_key_buf_plain,
                          session_key_buf_encrypted, 
                             RAMPART_ACTIONS_GET_ENC_PROP_FILE(actions, env));
@@ -261,7 +267,8 @@
     enc_key_key_info_node = oxs_token_build_key_info_element(env, enc_key_node );
     enc_key_key_name_node = oxs_token_build_key_name_element(env, enc_key_key_info_node,"hard-coded-key-name" );
     enc_key_cd_node = oxs_token_build_cipher_data_element(env, enc_key_node);
-    enc_key_cv_node = oxs_token_build_cipher_value_element(env, enc_key_cd_node, (axis2_char_t*)session_key_buf_encrypted->data);
+    enc_key_cv_node = oxs_token_build_cipher_value_element(env, enc_key_cd_node, 
+                        (axis2_char_t*)OXS_BUFFER_GET_DATA(session_key_buf_encrypted, env));
     enc_key_ref_list_node = oxs_token_build_reference_list_element(env, enc_key_node);
     /*TODO If there are multiple elements encrypted by the same session key, enqueue those here*/
     enc_key_data_ref_node = (axiom_node_t*)oxs_token_build_data_reference_element(env, enc_key_ref_list_node, uuid);
@@ -313,7 +320,7 @@
     body_node = AXIOM_SOAP_BODY_GET_BASE_NODE(body, env);
     
     /*TODO Get the Encrypted key*/
-    enc_key_node =  oxs_axiom_get_first_child_node_by_name(env, sec_node, OXS_NodeEncryptedKey, NULL, NULL);
+    enc_key_node =  (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, sec_node, OXS_NodeEncryptedKey, NULL, NULL);
 
     /*Create a private key and use to extract the session key*/
     temp_str = RAMPART_ACTIONS_GET_DEC_PROP_FILE(actions, env) ;
@@ -333,7 +340,7 @@
 
     }
     /*Ohh yeah... now we got the seesion key, which is used encrypt data referred by the reference list*/    
-    ref_list_node = oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeReferenceList, NULL, NULL);
+    ref_list_node = (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, enc_key_node, OXS_NodeReferenceList, NULL, NULL);
     if(!ref_list_node){
         oxs_error(ERROR_LOCATION, OXS_ERROR_DECRYPT_FAILED,
                      "Cannot get the ReferenceList node");
@@ -344,7 +351,7 @@
     
     /*TODO Get the encrypted node(s). Right now we support only one. To support more than one EncryptedData element use the uuid_list*/
     
-    enc_data_node = oxs_axiom_get_first_child_node_by_name(env, body_node, OXS_NodeEncryptedData, NULL, NULL);
+    enc_data_node = (axiom_node_t*)oxs_axiom_get_first_child_node_by_name(env, body_node, OXS_NodeEncryptedData, NULL, NULL);
     
 
     /*TODO We assume that the very first element of bpody is encrypted data.
@@ -373,7 +380,7 @@
     parent_of_enc_node = AXIOM_NODE_GET_PARENT(enc_data_node, env);
     
     #if 1
-    decrypted_node = oxs_axiom_deserialize_node(env, decrypted_data);
+    decrypted_node = (axiom_node_t*)oxs_axiom_deserialize_node(env, decrypted_data);
    
     /*Remove enc_node*/  
     AXIOM_NODE_DETACH(enc_data_node, env);     



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message